[Qgis-user] Postgres dependency on mac build

John Abraham jabraham at ucalgary.ca
Sun Apr 20 10:58:17 PDT 2008


Thanks for the hint.  I can't see a difference (svn diff) between the  
two cmake directories.

I tried deleting my build directory, and redoing the cmake command  
with -D POSTGRES_CONFIG=/usr/local/pgsql/  and it responded

-- Found PostgreSQL: sh: /usr/local/pgsql: is a directory/libpq.dylib

but then I got the same error (below) when I ran make :(

--
John

[ 43%] Building CXX object src/app/CMakeFiles/qgis.dir/qgisapp.o
In file included from /Users/jabraham/Development/qgis/src/src/app/ 
qgisapp.cpp:168:
/Users/jabraham/Development/qgis/src/src/app/qgsdbsourceselect.h: 
27:22: error: libpq-fe.h: No such file or directory
/Users/jabraham/Development/qgis/src/src/app/qgsdbsourceselect.h:112:  
error: ‘PGconn’ has not been declared
/Users/jabraham/Development/qgis/src/src/app/qgsdbsourceselect.h:118:  
error: ‘PGconn’ has not been declared
/Users/jabraham/Development/qgis/src/src/app/qgsdbsourceselect.h:141:  
error: ISO C++ forbids declaration of ‘PGconn’ with no type
/Users/jabraham/Development/qgis/src/src/app/qgsdbsourceselect.h:141:  
error: expected ‘;’ before ‘*’ token
make[2]: *** [src/app/CMakeFiles/qgis.dir/qgisapp.o] Error 1
make[1]: *** [src/app/CMakeFiles/qgis.dir/all] Error 2
make: *** [all] Error 2

On 20-Apr-08, at 10:34 AM, William Kyngesburye wrote:

> I think there was a fix for this recently in trunk, and maybe it's  
> not in the diagram branch.  The release tag works fine.  You could  
> try grabbing cmake/FindPostgres.cmake from trunk to replace what you  
> have in the diagram branch.
>
> On Apr 20, 2008, at 11:03 AM, John Abraham wrote:
>
>> I'm trying to build the "diagram" branch on MacOSX Leopard.  I  
>> followed the instructions in the docs, and did get it compiled and  
>> running.  I'm pretty proud of myself since I haven't programmed in  
>> C for a decade or so (java programmer now.)
>>
>> Except there is one problem.  The Postgres stuff wasn't found by  
>> cmake, so there was no Postgis support in my build.
>>
>> So I tried to set up cmake to find my postgres.  I found the file  
>> FindPostgres.cmake and found that it uses environment variables, so  
>> tried to set those using -D options to cmake.  Now it won't compile  
>> at all, with the following error.  I do have a libpq-fe.h in /usr/ 
>> local/pgsql/include.  I didn't make Postgres from source, just  
>> installed it.
>>
>> Thanks for any help,
>> --
>> John Abraham
>> jabraham at ucalgary.ca
>
> -----
> William Kyngesburye <kyngchaos*at*kyngchaos*dot*com>
> http://www.kyngchaos.com/
>
> Earth: "Mostly harmless"
>
> - revised entry in the HitchHiker's Guide to the Galaxy
>
>
>




More information about the Qgis-user mailing list