Skip site navigation (1) Skip section navigation (2)

Git Trunk Build Issue

From: "Strauch, Sheldon" <SStrauch(at)enovafinancial(dot)com>
To: "pgadmin-hackers(at)postgresql(dot)org" <pgadmin-hackers(at)postgresql(dot)org>
Subject: Git Trunk Build Issue
Date: 2011-11-09 17:59:08
Message-ID: DF56D06C-0389-4D46-899C-AF037ADBB695@enovafinancial.com (view raw or flat)
Thread:
Lists: pgadmin-hackers
I was hoping to demo some of pgAdmin's upcoming E-R features to my PUG next week, but have had considerable issue trying to build a functioning image. I was hoping someone might be able to set me on the right path...

My latest issue is that configure does not seem to respect the --with-arch-i386 switch (see next paragraph); x86_64 being the default build architecture on OSX Snow Leopard. I'v completely rebuilt my dependency tree as i386 because wxWidgets 10.8 is not available and, according the the wxWidgets documentation at ttp://wiki.wxwidgets.org/Development:_wxMac#Building_under_10.6_Snow_Leopard cannot (or perhaps should not) be built for x86_64: "If you want 64-bit wxWidgets on OS X you'll need 2.9+ and configure -with-osx_cocoa" I have the newer wxWidgets 2.9.2 r1 available, which I can build for x86_64, but configure expects 2.8. I'll gladly rebuild my entire dependency tree for x86_64 using wxWidgets 2.9.2 r1 if we believe this will work, but I was rather concerned about moving up the wxWidgets food chain without a better understanding of how that might break pgAdmin.

What causes me to think that configure is not respecting the --with-arch-i386 switch is around line 510 of the attached configure.log:

  configure:5573: gcc -o conftest -g -O2   -L/opt/local/lib/postgresql91 -lssl conftest.c -lpq   >&5
  ld: warning: in /opt/local/lib/postgresql91/libpq.dylib, file was built for i386 which is not the architecture being linked (x86_64)
  Undefined symbols:
    "_PQexec", referenced from:
        _main in cc1oqlty.o
  ld: symbol(s) not found

Not being a bash or autoconf expert by any means, I was not able to interpret where the call to gcc was made from inside ac_fn_c_try_link or whether the i386 architecture switch made it into that call.

How I got to this point:
I am compiling on a MacBook Pro running OSX Snow Leopard and the latest freely available XCode:

System Software Overview:
  System Version:       Mac OS X 10.6.8 (10K549)
  Kernel Version:       Darwin 10.8.0
  Boot Volume:  Macintosh HD
  Boot Mode:    Normal
  Computer Name:        sstrauch-macbook
  User Name:    Sheldon Strauch (sstrauch)
  Secure Virtual Memory:        Enabled
  64-bit Kernel and Extensions: No
  Time since boot:      21:12

Developer Information:
  Version:      3.2 (10M2518)
  Location:     /Developer
  Applications:
  Xcode:        3.2.6 (1761)
  Interface Builder:    3.2.6 (851)
  Instruments:  2.7 (3017)
  Dashcode:     3.0.2 (333)
  SDKs:
  Mac OS X:
  10.4: (8S2167)
  10.5: (9L31a)
  10.6: (10M2518)

Here is the console output of my configure run:

sstrauch-macbook:pgadmin3 sstrauch$ ./configure --enable-appbundle --with-arch-i386 --with-wx=/opt/local --with-libxml2=/opt/local --with-libxslt=/opt/local --with-pgsql=/opt/local/lib/postgresql91
checking build system type... x86_64-apple-darwin10.8.0
checking host system type... x86_64-apple-darwin10.8.0
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... config/install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... no
checking for awk... awk
checking whether make sets $(MAKE)... yes
checking how to create a ustar tar archive... gnutar
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking for ranlib... ranlib
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking arpa/inet.h usability... yes
checking arpa/inet.h presence... yes
checking for arpa/inet.h... yes
checking netdb.h usability... yes
checking netdb.h presence... yes
checking for netdb.h... yes
checking netinet/in.h usability... yes
checking netinet/in.h presence... yes
checking for netinet/in.h... yes
checking for stdlib.h... (cached) yes
checking for stdbool.h that conforms to C99... yes
checking for _Bool... yes
checking for an ANSI C-conforming const... yes
checking for size_t... yes
checking whether time.h and sys/time.h may both be included... yes
checking for working strtod... yes
checking for gethostbyname... yes
checking for inet_ntoa... yes
checking for memmove... yes
checking for memset... yes
checking for strchr... yes
checking for SSL_library_init in -lssl... yes
checking for krb5_sendauth in -lkrb5... yes
checking for PQexec in -lpq... no
checking for PQconninfoParse in -lpq... no
checking for SSL_connect in -lpq... yes
checking for krb5_free_principal in -lpq... yes
checking libpq-fe.h usability... yes
checking libpq-fe.h presence... yes
checking for libpq-fe.h... yes
checking PostgreSQL in /opt/local/lib/postgresql91... failed
configure: error: you must specify a valid PostgreSQL 8.4+ installation with --with-pgsql=DIR

Here is the console output listing for what I could determine as the critical directories for configure:

sstrauch-macbook:pgadmin3 sstrauch$ ls -l /opt/local/lib/postgresql91
total 10400
-rwxr-xr-x   1 root  admin    15848 Nov  7 23:36 adminpack.so
-rwxr-xr-x   1 root  admin     8884 Nov  7 23:36 ascii_and_mic.so
drwxr-xr-x  25 root  admin      850 Nov  7 23:36 bin
-rwxr-xr-x   1 root  admin    15908 Nov  7 23:36 cyrillic_and_mic.so
-rwxr-xr-x   1 root  admin    43800 Nov  7 23:36 dblink.so
-rwxr-xr-x   1 root  admin   308320 Nov  7 23:36 dict_snowball.so
-rwxr-xr-x   1 root  admin     9092 Nov  7 23:36 euc2004_sjis2004.so
-rwxr-xr-x   1 root  admin     8940 Nov  7 23:36 euc_cn_and_mic.so
-rwxr-xr-x   1 root  admin    13628 Nov  7 23:36 euc_jp_and_sjis.so
-rwxr-xr-x   1 root  admin     9008 Nov  7 23:36 euc_kr_and_mic.so
-rwxr-xr-x   1 root  admin    14196 Nov  7 23:36 euc_tw_and_big5.so
-rwxr-xr-x   1 root  admin    31908 Nov  7 23:36 fuzzystrmatch.so
-rwxr-xr-x   1 root  admin     9952 Nov  7 23:36 latin2_and_win1250.so
-rwxr-xr-x   1 root  admin     9364 Nov  7 23:36 latin_and_mic.so
-rwxr-xr-x   1 root  admin    76372 Nov  7 23:36 libecpg.6.3.dylib
lrwxr-xr-x   1 root  admin       17 Nov  7 23:36 libecpg.6.dylib -> libecpg.6.3.dylib
-rw-r--r--   1 root  admin   100840 Nov  7 23:36 libecpg.a
lrwxr-xr-x   1 root  admin       17 Nov  7 23:36 libecpg.dylib -> libecpg.6.3.dylib
-rwxr-xr-x   1 root  admin    17228 Nov  7 23:36 libecpg_compat.3.3.dylib
lrwxr-xr-x   1 root  admin       24 Nov  7 23:36 libecpg_compat.3.dylib -> libecpg_compat.3.3.dylib
-rw-r--r--   1 root  admin    11584 Nov  7 23:36 libecpg_compat.a
lrwxr-xr-x   1 root  admin       24 Nov  7 23:36 libecpg_compat.dylib -> libecpg_compat.3.3.dylib
-rw-r--r--   1 root  admin    33104 Nov  7 23:36 libpgport.a
-rwxr-xr-x   1 root  admin    63032 Nov  7 23:36 libpgtypes.3.2.dylib
lrwxr-xr-x   1 root  admin       20 Nov  7 23:36 libpgtypes.3.dylib -> libpgtypes.3.2.dylib
-rw-r--r--   1 root  admin    76840 Nov  7 23:36 libpgtypes.a
lrwxr-xr-x   1 root  admin       20 Nov  7 23:36 libpgtypes.dylib -> libpgtypes.3.2.dylib
-rwxr-xr-x   1 root  admin   144312 Nov  7 23:36 libpq.5.4.dylib
lrwxr-xr-x   1 root  admin       15 Nov  7 23:36 libpq.5.dylib -> libpq.5.4.dylib
-rw-r--r--   1 root  admin   184128 Nov  7 23:36 libpq.a
lrwxr-xr-x   1 root  admin       15 Nov  7 23:36 libpq.dylib -> libpq.5.4.dylib
-rwxr-xr-x   1 root  admin    14952 Nov  7 23:36 libpqwalreceiver.so
-rwxr-xr-x   1 root  admin     9024 Nov  7 23:36 lo.so
-rwxr-xr-x   1 root  admin     9600 Nov  7 23:36 pg_buffercache.so
-rwxr-xr-x   1 root  admin    25480 Nov  7 23:36 pg_trgm.so
-rwxr-xr-x   1 root  admin   109752 Nov  7 23:36 pgcrypto.so
-rwxr-xr-x   1 root  admin    22184 Nov  7 23:36 pgxml.so
drwxr-xr-x   4 root  admin      136 Nov  7 23:36 pgxs
-rwxr-xr-x   1 root  admin   145156 Nov  7 23:36 plpgsql.so
-rwxr-xr-x   1 root  admin    25400 Nov  7 23:36 tsearch2.so
-rwxr-xr-x   1 root  admin     8892 Nov  7 23:36 utf8_and_ascii.so
-rwxr-xr-x   1 root  admin   226012 Nov  7 23:36 utf8_and_big5.so
-rwxr-xr-x   1 root  admin    13328 Nov  7 23:36 utf8_and_cyrillic.so
-rwxr-xr-x   1 root  admin   189312 Nov  7 23:36 utf8_and_euc2004.so
-rwxr-xr-x   1 root  admin   127728 Nov  7 23:36 utf8_and_euc_cn.so
-rwxr-xr-x   1 root  admin   217840 Nov  7 23:36 utf8_and_euc_jp.so
-rwxr-xr-x   1 root  admin   140016 Nov  7 23:36 utf8_and_euc_kr.so
-rwxr-xr-x   1 root  admin   336624 Nov  7 23:36 utf8_and_euc_tw.so
-rwxr-xr-x   1 root  admin  1020664 Nov  7 23:36 utf8_and_gb18030.so
-rwxr-xr-x   1 root  admin   357072 Nov  7 23:36 utf8_and_gbk.so
-rwxr-xr-x   1 root  admin    34488 Nov  7 23:36 utf8_and_iso8859.so
-rwxr-xr-x   1 root  admin     9088 Nov  7 23:36 utf8_and_iso8859_1.so
-rwxr-xr-x   1 root  admin   279268 Nov  7 23:36 utf8_and_johab.so
-rwxr-xr-x   1 root  admin   127708 Nov  7 23:36 utf8_and_sjis.so
-rwxr-xr-x   1 root  admin   189336 Nov  7 23:36 utf8_and_sjis2004.so
-rwxr-xr-x   1 root  admin   283348 Nov  7 23:36 utf8_and_uhc.so
-rwxr-xr-x   1 root  admin    30188 Nov  7 23:36 utf8_and_win.so
-rwxr-xr-x   1 root  admin    10752 Nov  7 23:36 uuid-ossp.so
sstrauch-macbook:pgadmin3 sstrauch$ ls -l /opt/local/lib/postgresql91/bin
total 14872
-rwxr-xr-x  1 root  admin    45440 Nov  7 23:36 clusterdb
-rwxr-xr-x  1 root  admin    45376 Nov  7 23:36 createdb
-rwxr-xr-x  1 root  admin    57776 Nov  7 23:36 createlang
-rwxr-xr-x  1 root  admin    45420 Nov  7 23:36 createuser
-rwxr-xr-x  1 root  admin    45308 Nov  7 23:36 dropdb
-rwxr-xr-x  1 root  admin    57716 Nov  7 23:36 droplang
-rwxr-xr-x  1 root  admin    45308 Nov  7 23:36 dropuser
-rwxr-xr-x  1 root  admin   707004 Nov  7 23:36 ecpg
-rwxr-xr-x  1 root  admin    66960 Nov  7 23:36 initdb
-rwxr-xr-x  1 root  admin    36532 Nov  7 23:36 pg_basebackup
-rwxr-xr-x  1 root  admin    25272 Nov  7 23:36 pg_config
-rwxr-xr-x  1 root  admin    24816 Nov  7 23:36 pg_controldata
-rwxr-xr-x  1 root  admin    35008 Nov  7 23:36 pg_ctl
-rwxr-xr-x  1 root  admin   332116 Nov  7 23:36 pg_dump
-rwxr-xr-x  1 root  admin    70472 Nov  7 23:36 pg_dumpall
-rwxr-xr-x  1 root  admin    34004 Nov  7 23:36 pg_resetxlog
-rwxr-xr-x  1 root  admin   132020 Nov  7 23:36 pg_restore
-rwxr-xr-x  1 root  admin  5224740 Nov  7 23:36 postgres
lrwxr-xr-x  1 root  admin        8 Nov  7 23:36 postmaster -> postgres
-rwxr-xr-x  1 root  admin   413832 Nov  7 23:36 psql
-rwxr-xr-x  1 root  admin    45440 Nov  7 23:36 reindexdb
-rwxr-xr-x  1 root  admin    30892 Nov  7 23:36 vacuumdb
-rwxr-xr-x  1 root  admin    20676 Nov  7 23:36 vacuumlo

Which is my current, functioning PostgreSQL instance:

sstrauch-macbook:pgadmin3 sstrauch$ psql -p5433 postgres -V
psql (PostgreSQL) 9.1.1
contains support for command-line editing
sstrauch-macbook:pgadmin3 sstrauch$ psql -p5433 postgres
psql (9.1.1)
Type "help" for help.

postgres=# \q
sstrauch-macbook:pgadmin3 sstrauch$



Sheldon Strauch
Sr. Database Developer
sstrauch(at)enovafinancial(dot)com


Attachment: config.log
Description: application/octet-stream (28.5 KB)

Responses

pgadmin-hackers by date

Next:From: Dave PageDate: 2011-11-10 09:13:20
Subject: Re: Git Trunk Build Issue
Previous:From: Ken HaleyDate: 2011-11-07 15:26:35
Subject: Re: v1.14 SQL editor collapsing feature

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group