php5 5.2.5 -> 5.2.6 upgrade fails ?

Ryan Schmidt ryandesign at macports.org
Mon Jul 7 11:52:05 PDT 2008


On Jul 7, 2008, at 13:04, Bill Hernandez wrote:

> MOST everything installed fine but there were several items that  
> FAILED.

As detailed below, you are being bitten by the Leopard environment  
variable issue, described here:

http://trac.macports.org/wiki/LeopardProblems

The problem occurs for certain combinations of ports when multiple  
ports are installed by one invocation of the port command. To work  
around the problem, clean the work area of the failing port and try  
installing that port again.


> ( 1 ) sqlite failed when installed on its own, and later as expected
> when required by Apache2, and later by PHP5
> ( 2 ) for some reason the php 5.2..6 installer could not find awk,
> yet...
>
> $ sudo find / -name awk
> Password:
> /opt/local/libexec/awk
> /opt/local/share/awk
> /opt/local/var/macports/software/gawk/3.1.6_0/opt/local/libexec/awk
> /opt/local/var/macports/software/gawk/3.1.6_0/opt/local/share/awk
> /usr/bin/awk
>
>
> $ port installed
> The following ports are currently installed:
> <snip> ... </snip>
>          gawk @3.1.6_0 (active)
> <snip> ... </snip>
>
> $ sudo port -d selfupdate
> $ sudo port outdated
>
> The following installed ports are outdated:
> apache2                        2.2.8_0 < 2.2.9_1
> apr                            1.2.12_1 < 1.3.2_0
> apr-util                       1.2.12_0 < 1.3.2_0
> bzip2                          1.0.5_0 < 1.0.5_1
> curl                           7.18.1_2 < 7.18.2_0
> fontconfig                     2.5.0_0 < 2.6.0_0
> freetype                       2.3.5_1 < 2.3.7_1
> libpng                         1.2.26_0 < 1.2.29_0
> libxml2                        2.6.31_0 < 2.6.32_1
> libxslt                        1.1.22_0 < 1.1.23_0
> m4                             1.4.10_1 < 1.4.11_0
> openssl                        0.9.8g_0 < 0.9.8h_0
> ossp-uuid                      1.6.0_2 < 1.6.1_0
> pcre                           7.6_0 < 7.7_0
> perl5.8                        5.8.8_2 < 5.8.8_3
> php5                           5.2.5_3 < 5.2.6_1
> postgresql83                   8.3.1_0 < 8.3.3_0
> postgresql83-doc               8.3.1_0 < 8.3.3_0
> postgresql83-server            8.3.1_0 < 8.3.3_0
> readline                       5.2.007_0 < 5.2.012_1
> sqlite3                        3.5.8_0 < 3.5.9_0
> tiff                           3.8.2_1 < 3.8.2_2
>
>
> $ sudo port upgrade outdated
> <snip> ... </snip>
>
> --->  Attempting to fetch sqlite-3.5.9.tar.gz from http:// 
> www.sqlite.org/
> --->  Verifying checksum(s) for sqlite3
> --->  Extracting sqlite3
> --->  Configuring sqlite3
> --->  Building sqlite3 with target all
>
> Error: Target org.macports.build returned: shell command " cd "/opt/
> local/var/macports/build/
> _opt_local_var_macports_sources_rsync
> .macports.org_release_ports_databases_sqlite3/work/sqlite-3.5.9" &&
> gnumake all " returned error 2
>
> Command output: sed -e s/--VERS--/3.5.9/ ./src/sqlite.h.in | \
> 	sed -e s/--VERSION-NUMBER--/3005009/ >sqlite3.h
> /usr/bin/gcc-4.0 -O2 -o mkkeywordhash  ./tool/mkkeywordhash.c
> ./mkkeywordhash >keywordhash.h
> /usr/bin/gcc-4.0 -O2 -o lemon ./tool/lemon.c
> cp ./tool/lempar.c .
> cp ./src/parse.y .
> ./lemon  parse.y
> mv parse.h parse.h.temp
> f ./addopcodes.awk parse.h.temp >parse.h
>
> /bin/sh: f: command not found
> gnumake: [parse.c] Error 127 (ignored)
> cat parse.h ./src/vdbe.c |  -f ./mkopcodeh.awk >opcodes.h
>
> /bin/sh: -f: command not found
> cat: stdout: Broken pipe
> gnumake: *** [opcodes.h] Error 127
>
> Error: Unable to upgrade port: 1

This is the Leopard environment variable issue. Clean the sqlite3  
work area and try again.

sudo port clean --work sqlite3
sudo port install sqlite3


> --->  Configuring apache2
> --->  Building apache2 with target all
>
> Error: Target org.macports.build returned: shell command " cd "/opt/
> local/var/macports/build/
> _opt_local_var_macports_sources_rsync
> .macports.org_release_ports_www_apache2/work/httpd-2.2.9" && make all
> " returned error 2
>
> Command output: /opt/local/share/apr-1/build/libtool --silent --
> mode=link /usr/bin/gcc-4.0 -I/opt/local/include  -O2   -L/opt/local/
> lib/db46  -L/opt/local/lib -o logresolve  logresolve.lo   -L/opt/ 
> local/
> lib -lpcre /opt/local/lib/libaprutil-1.la -ldb-4.6 -lexpat -liconv /
> opt/local/lib/libapr-1.la -lpthread
> <snip> ... </snip>
> server/mpm/prefork/libprefork.la os/unix/libos.la -L/opt/local/lib -
> lpcre /opt/local/lib/libaprutil-1.la -ldb-4.6 -lexpat -liconv /opt/
> local/lib/libapr-1.la -lpthread
>
> Undefined symbols:
>    "_ap_ugly_hack", referenced from:
>        _ap_ugly_hack$non_lazy_ptr in libmain.a(main.o)
>    "_ap_prelinked_module_symbols", referenced from:
>        _ap_prelinked_module_symbols$non_lazy_ptr in libmain.a(core.o)
>    "_ap_prelinked_modules", referenced from:
>        _ap_prelinked_modules$non_lazy_ptr in libmain.a(main.o)
>        _ap_prelinked_modules$non_lazy_ptr in libmain.a(config.o)
>    "_ap_http_input_filter_handle", referenced from:
>        _ap_http_input_filter_handle$non_lazy_ptr in
> libmain.a(protocol.o)
>    "_ap_preloaded_modules", referenced from:
>        _ap_preloaded_modules$non_lazy_ptr in libmain.a(config.o)
>
> ld: symbol(s) not found
> collect2: ld returned 1 exit status
> make[1]: *** [httpd] Error 1
> make: *** [all-recursive] Error 1
>
> Error: Unable to upgrade port: 1

This is also caused by the Leopard environment variable issue. See:

http://trac.macports.org/ticket/13066


> --->  Attempting to fetch php-5.2.6.tar.bz2 from http://www.php.net/ 
> distributions/
> --->  Verifying checksum(s) for php5
> --->  Extracting php5
> --->  Configuring php5
>
> Error: Target org.macports.configure returned: configure failure:
> shell command " cd "/opt/local/var/macports/build/
> _opt_local_var_macports_sources_rsync
> .macports.org_release_ports_www_php5/work/php-5.2.6" && ./configure --
> prefix=/opt/local --mandir=/opt/local/share/man --infodir=/opt/local/
> share/info --with-config-file-path=/opt/local/etc --enable-calendar --
> with-iconv=/opt/local --enable-exif --enable-ftp --enable-wddx --with-
> zlib=/opt/local --with-bz2=/opt/local --with-libxml-dir=/opt/local --
> with-gettext=/opt/local --with-xml --with-expat-dir=/opt/local --with-
> xmlrpc --enable-soap --enable-filepro --enable-bcmath --enable-trans-
> sid --enable-mbstring --enable-dbx --enable-dba --enable-zip --with-
> openssl=/opt/local --with-mhash=/opt/local --with-mcrypt=/opt/local --
> with-xsl=/opt/local --with-curl=/opt/local --with-pcre-regex=/opt/
> local --with-gd=/opt/local --with-jpeg-dir=/opt/local --with-png-dir=/
> opt/local --enable-gd-native-ttf --with-freetype-dir=/opt/local -- 
> with-
> ldap=/usr --with-kerberos=/usr --with-iodbc=/usr --with-apxs2=/opt/
> local/apache2/bin/apxs --with-tidy=/opt/local --with-mysql=/opt/local/
> var/macports/build/
> _opt_local_var_macports_sources_rsync
> .macports.org_release_ports_www_php5/work/mysql5 --with-pdo-mysql=/ 
> opt/
> local/bin/mysql_config5 --with-mysql-sock=/opt/local/var/run/mysql5/
> mysqld.sock --with-mysqli=/opt/local/bin/mysql_config5 --with-pgsql=/
> opt/local/lib/postgresql83/bin --with-pdo-pgsql=/opt/local/lib/
> postgresql83/bin --with-sqlite --with-pdo-sqlite=/opt/local --enable-
> sqlite-utf8 --enable-shmop --enable-sysvsem --enable-sysvshm --enable-
> sysvmsg --enable-pcntl --with-pear=/opt/local/lib/php --with- 
> readline=/
> opt/local --enable-sockets " returned error 1
>
> Command output: checking for Cygwin environment... no
> <snip> ... </snip>
> configure: warning: You will need re2c 0.12.0 or later if you want to
> regenerate PHP parsers.
> checking for gawk... (cached) no
> checking for nawk... (cached) no
> checking for awk... (cached) no
> checking for mawk... (cached) no
> configure: error: Could not find awk; Install GNU awk
>
> Error: Unable to upgrade port: 1

I'm not sure. It may be the same issue. Clean php5's work area and  
install just php5.


> --->  Fetching postgresql83
> --->  Attempting to fetch postgresql-8.3.3.tar.bz2 from http:// 
> ftp8.de.postgresql.org/pub/misc/pgsql//source/v8.3.3/
> --->  Verifying checksum(s) for postgresql83
> --->  Extracting postgresql83
> --->  Configuring postgresql83
> --->  Building postgresql83
>
> Error: Target org.macports.build returned: shell command " cd "/opt/
> local/var/macports/build/
> _opt_local_var_macports_sources_rsync
> .macports.org_release_ports_databases_postgresql83/work/
> postgresql-8.3.3" && gnumake " returned error 2
>
> Command output: /usr/bin/gcc-4.0 -no-cpp-precomp -O2 -I/opt/local/
> include -I/opt/local/include/ossp -Wall -Wmissing-prototypes - 
> Wpointer-
> arith -Winline -Wdeclaration-after-statement -Wendif-labels -fno-
> strict-aliasing -fwrapv -I../../../../src/include -I/opt/local/include
> -I/opt/local/include/libxml2  -I/opt/local/include  -c -o tsrank.o
> tsrank.c
> <snip> ... </snip>
> /usr/bin/gcc-4.0 -no-cpp-precomp -O2 -I/opt/local/include -I/opt/ 
> local/
> include/ossp -Wall -Wmissing-prototypes -Wpointer-arith -Winline -
> Wdeclaration-after-statement -Wendif-labels -fno-strict-aliasing -
> fwrapv -I../../../../src/include -I/opt/local/include -I/opt/local/
> include/libxml2  -I/opt/local/include -DDLSUFFIX=\".so\"  -c -o
> dfmgr.o dfmgr.c
> dfmgr.c:82: error: syntax error before '/' token

I'm not sure. Could be the same thing. Clean postgresql83's work area  
and install just postgresql83.


> --->  Fetching postgresql83-server
> --->  Verifying checksum(s) for postgresql83-server
> -<snip> ... </snip>
>
> To tweak your DBMS, consider increasing kern.sysv.shmmax by adding an
> increased kern.sysv.shmmax .. to /etc/sysctl.conf
> --->  Activating postgresql83-server 8.3.3_0
> --->  Cleaning postgresql83-server
> --->  Building sqlite3 with target all
>
> Error: Target org.macports.build returned: shell command " cd "/opt/
> local/var/macports/build/
> _opt_local_var_macports_sources_rsync
> .macports.org_release_ports_databases_sqlite3/work/sqlite-3.5.9" &&
> gnumake all " returned error 2
>
> Command output: sqlite3.c:75960: error: 'TK_GE' undeclared (first use
> in this function)
> sqlite3.c:75963: error: 'TK_RSHIFT' undeclared (first use in this
> function)
> sqlite3.c:75966: error: 'TK_GT' undeclared (first use in this  
> function)
> sqlite3.c:75972: error: 'TK_ILLEGAL' undeclared (first use in this
> function)
> sqlite3.c:75981: error: 'TK_BITOR' undeclared (first use in this
> function)
> sqlite3.c:75984: error: 'TK_CONCAT' undeclared (first use in this
> function)
> sqlite3.c:75989: error: 'TK_COMMA' undeclared (first use in this
> function)
> sqlite3.c:75993: error: 'TK_BITAND' undeclared (first use in this
> function)
> sqlite3.c:75997: error: 'TK_BITNOT' undeclared (first use in this
> function)
> sqlite3.c:76014: error: 'TK_STRING' undeclared (first use in this
> function)
> sqlite3.c:76026: error: 'TK_DOT' undeclared (first use in this  
> function)
> sqlite3.c:76034: error: 'TK_INTEGER' undeclared (first use in this
> function)
> sqlite3.c:76040: error: 'TK_FLOAT' undeclared (first use in this
> function)
> sqlite3.c:76060: error: 'TK_ID' undeclared (first use in this  
> function)
> sqlite3.c:76060: warning: assignment makes integer from pointer
> without a cast
> sqlite3.c:76064: error: 'TK_VARIABLE' undeclared (first use in this
> function)
> sqlite3.c:76073: error: 'TK_REGISTER' undeclared (first use in this
> function)
> sqlite3.c:76113: error: 'TK_BLOB' undeclared (first use in this
> function)
> sqlite3.c: In function 'sqlite3RunParser':
> sqlite3.c:76184: error: 'TK_SPACE' undeclared (first use in this
> function)
> sqlite3.c:76184: warning: case label value exceeds maximum value for
> type
> sqlite3.c:76185: error: 'TK_COMMENT' undeclared (first use in this
> function)
> sqlite3.c:76185: warning: case label value exceeds maximum value for
> type
> sqlite3.c:76193: error: 'TK_ILLEGAL' undeclared (first use in this
> function)
> sqlite3.c:76193: warning: case label value exceeds maximum value for
> type
> sqlite3.c:76202: error: 'TK_SEMI' undeclared (first use in this
> function)
> sqlite3.c:76202: warning: case label value exceeds maximum value for
> type
> sqlite3.c:76218: warning: comparison between pointer and integer
> sqlite3.c:76219: warning: passing argument 2 of 'sqlite3Parser' makes
> integer from pointer without a cast
> gnumake: *** [sqlite3.lo] Error 1

A different error for sqlite3, but this is also known to be the  
Leopard environment variable issue.

http://trac.macports.org/ticket/13953

Clean sqlite3's work area and install just sqlite3.




More information about the macports-users mailing list