Re: Trouble installing psycopg2 on Mac OSX 10.6

From: Bill Carithers <wccarithers(at)lbl(dot)gov>
To: Daniele Varrazzo <daniele(dot)varrazzo(at)gmail(dot)com>
Cc: <psycopg(at)postgresql(dot)org>
Subject: Re: Trouble installing psycopg2 on Mac OSX 10.6
Date: 2011-05-16 20:46:39
Message-ID: C9F6DB3F.2284C%wccarithers@lbl.gov
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: psycopg

Hi Daniele,

Thanks for the prompt reply. I tried the two things you suggested. Results
are:

c4-2c-3-1-f0-3a:psycopg2-2.4.1 williamcarithers$ python setup.py install
running install
running build
running build_py
running build_ext
pg_config is set to /Library/PostgreSQL/8.4/bin <-- the print statement
error: Permission denied <-- removing the try/except

So it looks like it is getting the correct pg_config from the setup.cfg
file. Stupid question--it is looking for the executable pg_config in ./bin
and not the pg_config.h in the ./include directory, right?

Thanks,
Bill

On 5/16/11 1:09 PM, "Daniele Varrazzo" <daniele(dot)varrazzo(at)gmail(dot)com> wrote:

> Hello Bill,
>
> On Mon, May 16, 2011 at 8:05 PM, Bill Carithers <wccarithers(at)lbl(dot)gov> wrote:
>
>> The psycopg2 install failed because it couldn¹t find the
>> pg_config file. Yet when I go and look where I pointed in the setup.cfg
>> file, there it is. So, I¹m totally confused now.
>
> This is curious. The procedure to find the pg_config in the setup.py
> is honestly messy, but it shouldn't fail so badly.
>
> Could you please check with some print or some breakpoint:
>
> a) if you specify a pg_config in the setup.cfg or in the command line,
> you should find it as "self.pg_config" in finalize_options() (line 248
> of setup.py). If nothing is specified, self.pg_config should be None
> and should be obtained by autodetect_pg_config_path().
>
> b) the try case in get_pg_config (line 88) is probably too broad. Can
> you try to remove it and see if Popen fails with an exception which is
> incorrectly interpreted as pg_config not found?
>
> Thank you very much.
>
> -- Daniele

In response to

Responses

Browse psycopg by date

  From Date Subject
Next Message Daniele Varrazzo 2011-05-16 22:09:14 Re: Trouble installing psycopg2 on Mac OSX 10.6
Previous Message Daniele Varrazzo 2011-05-16 20:09:45 Re: Trouble installing psycopg2 on Mac OSX 10.6