ID: 20928 User updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] -Status: Feedback +Status: Open Bug Type: ODBC related Operating System: RH 7.2 PHP Version: 4.3.0RC2 New Comment:
It got much further this time, but results are the same. Here is the paste of the last command and error: <=== src/modules/throttle ===> src/modules/php4 gcc -c -I../../os/unix -I../../include -O2 -march=i386 -mcpu=i686 -DLINUX=22 - I/usr/include/db1 -DMOD_SSL=208110 -DEAPI `../../apaci` -fpic -DSHARED_MODULE -D LINUX=22 -I/usr/include/db1 -DMOD_SSL=208110 -I/usr/src/redhat/BUILD/php4-20021 2110630/main -I/usr/src/redhat/BUILD/php4-200212110630/Zend -I/usr/src/redhat/BU ILD/php4-200212110630/TSRM -I/usr/src/redhat/BUILD/php4-200212110630 -I/usr/src/ redhat/BUILD/php4-200212110630/sapi/apache -I/usr/src/redhat/BUILD/php4-20021211 0630/main -I/usr/src/redhat/BUILD/php4-200212110630/Zend -I/usr/src/redhat/BUILD /php4-200212110630/TSRM mod_php4.c && mv mod_php4.o mod_php4.so-o rm -f libphp4.so gcc -shared -o libphp4.so mod_php4.so-o libmodphp4.a -Wl,-rpath,/usr/local/lib -Wl,-rpath,/usr/local/Informix/lib -Wl,-rpath,/usr/local/Informix/lib/esql -Wl,- rpath,/usr/src/redhat/BUILD/php4-200212110630/ext/informix -rdynamic -rdynamic -L/usr/local/lib -L/usr/local/Informix/lib -L/usr/local/Informix/lib/esql -L/usr /src/redhat/BUILD/php4-200212110630/ext/informix -Lmodules/php4 -L../modules/php 4 -L../../modules/php4 -lmodphp4 -ldb2 -lcrypto -lssl -lc-client -lifsql -lifa sf -lifgen -lifos -lifgls -ldl -lcrypt -lphpifx -lifglx -lpdf -lz -lldap -llber -lcrypt -lpam -lfdftk -lz -lcrypt -lresolv -lm -ldl -lnsl -lcrypt -lm -lcrypt -ldb1 -ldb -lexpat -ldl -Wl,-rpath,/usr/local/lib -Wl,-rpath,/usr/local/Informi x/lib -Wl,-rpath,/usr/local/Informix/lib/esql -Wl,-rpath,/usr/src/redhat/BUILD/p hp4-200212110630/ext/informix -rdynamic -rdynamic -L/usr/local/lib -L/usr/local /Informix/lib -L/usr/local/Informix/lib/esql -L/usr/src/redhat/BUILD/php4-200212 110630/ext/informix -Lmodules/php4 -L../modules/php4 -L../../modules/php4 -lmodp hp4 -ldb2 -lcrypto -lssl -lc-client -lifsql -lifasf -lifgen -lifos -lifgls -ld l -lcrypt -lphpifx -lifglx -lpdf -lz -lldap -llber -lcrypt -lpam -lfdftk -lz -lc rypt -lresolv -lm -ldl -lnsl -lcrypt -lm -lcrypt -ldb1 -ldb /usr/bin/ld: cannot find -ldb2 collect2: ld returned 1 exit status make[4]: *** [libphp4.so] Error 1 make[3]: *** [all] Error 1 make[2]: *** [subdirs] Error 1 make[2]: Leaving directory `/usr/src/redhat/BUILD/apache_1.3.26/src' make[1]: *** [build-std] Error 2 make[1]: Leaving directory `/usr/src/redhat/BUILD/apache_1.3.26' make: *** [build] Error 2 error: Bad exit status from /var/tmp/rpm-tmp.89498 (%build) RPM build errors: Bad exit status from /var/tmp/rpm-tmp.89498 (%build) Previous Comments: ------------------------------------------------------------------------ [2002-12-11 00:48:46] [EMAIL PROTECTED] Please try using this CVS snapshot: http://snaps.php.net/php4-latest.tar.gz For Windows: http://snaps.php.net/win32/php4-win32-latest.zip ------------------------------------------------------------------------ [2002-12-11 00:46:35] [EMAIL PROTECTED] BTW, when I look at the command that compiles apache, it is clearly missing the -L/home/db2inst1/sqllib/lib in the list of library paths. This is the reason it's failing. I don't know how to add that path so that make in the apache dir will pick it up properly. ------------------------------------------------------------------------ [2002-12-11 00:43:16] [EMAIL PROTECTED] I actually added the LDFLAGS myself to try and get things to start working. When you set up an instance (called db2inst1), it creates symbolic links in the instance directory to the /usr/IBMdb2/V7.1 directory for all the commands, libraries, and utilities. So LDFLAGS can be set to either, it really doesn't matter. ------------------------------------------------------------------------ [2002-12-11 00:24:49] [EMAIL PROTECTED] You're passing the configure a different path to the DB2 install directory and then you set LDFLAGS to something else. Not PHP bug, user error. ------------------------------------------------------------------------ [2002-12-10 20:11:40] [EMAIL PROTECTED] I'm trying to compile PHP as a static apache module, and I get the following error: PATH="$PATH:/sbin" ldconfig -n /usr/src/redhat/BUILD/php-4.3.0RC2/modules ---------------------------------------------------------------------- Libraries have been installed in: /usr/src/redhat/BUILD/php-4.3.0RC2/modules If you ever happen to want to link against installed libraries in a given directory, LIBDIR, you must either use libtool, and specify the full pathname of the library, or use the `-LLIBDIR' flag during linking and do at least one of the following: - add LIBDIR to the `LD_LIBRARY_PATH' environment variable during execution - add LIBDIR to the `LD_RUN_PATH' environment variable during linking - use the `-Wl,--rpath -Wl,LIBDIR' linker flag - have your system administrator add LIBDIR to `/etc/ld.so.conf' See any operating system documentation about shared libraries for more information, such as the ld(1) and ld.so(8) manual pages. ---------------------------------------------------------------------- gcc -Imain/ -I/usr/src/redhat/BUILD/php-4.3.0RC2/main/ -DPHP_ATOM_INC -I/usr/sr c/redhat/BUILD/php-4.3.0RC2/include -I/usr/src/redhat/BUILD/php-4.3.0RC2/main -I /usr/src/redhat/BUILD/php-4.3.0RC2 -I/usr/src/redhat/BUILD/php-4.3.0RC2/Zend -I/ usr/local/include -I/usr/include/imap -I/usr/src/redhat/BUILD/php-4.3.0RC2/ext/x ml/expat -I/usr/src/redhat/BUILD/php-4.3.0RC2/TSRM -g -O2 -c main/internal_fu nctions_cli.c -o main/internal_functions_cli.o && echo > main/internal_function s_cli.lo /bin/sh libtool --silent --mode=link gcc -export-dynamic -g -O2 -L/home/db2inst 1/lib -rdynamic -L/usr/local/lib -L/usr/local/Informix/lib -L/usr/local/Informix /lib/esql -L/usr/src/redhat/BUILD/php-4.3.0RC2/ext/informix -R /usr/local/lib - R /usr/local/Informix/lib -R /usr/local/Informix/lib/esql -R /usr/src/redhat/BUI LD/php-4.3.0RC2/ext/informix ext/zlib/zlib.lo ext/zlib/zlib_fopen_wrapper.lo ext /bcmath/bcmath.lo ext/bcmath/number.lo ext/bcmath/libbcmath/src/add.lo ext/bcmat h/libbcmath/src/div.lo ext/bcmath/libbcmath/src/init.lo ext/bcmath/libbcmath/src /neg.lo ext/bcmath/libbcmath/src/outofmem.lo ext/bcmath/libbcmath/src/raisemod.l o ext/bcmath/libbcmath/src/rt.lo ext/bcmath/libbcmath/src/sub.lo ext/bcmath/libb cmath/src/compare.lo ext/bcmath/libbcmath/src/divmod.lo ext/bcmath/libbcmath/src /int2num.lo ext/bcmath/libbcmath/src/num2long.lo ext/bcmath/libbcmath/src/output .lo ext/bcmath/libbcmath/src/recmul.lo ext/bcmath/libbcmath/src/sqrt.lo ext/bcma th/libbcmath/src/zero.lo ext/bcmath/libbcmath/src/debug.lo ext/bcmath/libbcmath/ src/doaddsub.lo ext/bcmath/libbcmath/src/nearzero.lo ext/bcmath/libbcmath/src/nu m2str.lo ext/bcmath/libbcmath/src/raise.lo ext/bcmath/libbcmath/src/rmzero.lo ex t/bcmath/libbcmath/src/str2num.lo ext/ctype/ctype.lo ext/fdf/fdf.lo ext/imap/php _imap.lo ext/informix/ifx.lo ext/ldap/ldap.lo ext/mysql/php_mysql.lo ext/mysql/l ibmysql/libmysql.lo ext/mysql/libmysql/errmsg.lo ext/mysql/libmysql/net.lo ext/m ysql/libmysql/violite.lo ext/mysql/libmysql/password.lo ext/mysql/libmysql/my_in it.lo ext/mysql/libmysql/my_lib.lo ext/mysql/libmysql/my_static.lo ext/mysql/lib mysql/my_malloc.lo ext/mysql/libmysql/my_realloc.lo ext/mysql/libmysql/my_create .lo ext/mysql/libmysql/my_delete.lo ext/mysql/libmysql/my_tempnam.lo ext/mysql/l ibmysql/my_open.lo ext/mysql/libmysql/mf_casecnv.lo ext/mysql/libmysql/my_read.l o ext/mysql/libmysql/my_write.lo ext/mysql/libmysql/errors.lo ext/mysql/libmysql /my_error.lo ext/mysql/libmysql/my_getwd.lo ext/mysql/libmysql/my_div.lo ext/mys ql/libmysql/mf_pack.lo ext/mysql/libmysql/my_messnc.lo ext/mysql/libmysql/mf_dir name.lo ext/mysql/libmysql/mf_fn_ext.lo ext/mysql/libmysql/mf_wcomp.lo ext/mysql /libmysql/typelib.lo ext/mysql/libmysql/safemalloc.lo ext/mysql/libmysql/my_allo c.lo ext/mysql/libmysql/mf_format.lo ext/mysql/libmysql/mf_path.lo ext/mysql/lib mysql/mf_unixpath.lo ext/mysql/libmysql/my_fopen.lo ext/mysql/libmysql/mf_loadpa th.lo ext/mysql/libmysql/my_pthread.lo ext/mysql/libmysql/my_thr_init.lo ext/mys ql/libmysql/thr_mutex.lo ext/mysql/libmysql/mulalloc.lo ext/mysql/libmysql/strin g.lo ext/mysql/libmysql/default.lo ext/mysql/libmysql/my_compress.lo ext/mysql/l ibmysql/array.lo ext/mysql/libmysql/my_once.lo ext/mysql/libmysql/list.lo ext/my sql/libmysql/my_net.lo ext/mysql/libmysql/dbug.lo ext/mysql/libmysql/strmov.lo e xt/mysql/libmysql/strxmov.lo ext/mysql/libmysql/strnmov.lo ext/mysql/libmysql/st rmake.lo ext/mysql/libmysql/strend.lo ext/mysql/libmysql/strfill.lo ext/mysql/li bmysql/is_prefix.lo ext/mysql/libmysql/int2str.lo ext/mysql/libmysql/str2int.lo ext/mysql/libmysql/strinstr.lo ext/mysql/libmysql/strcont.lo ext/mysql/libmysql/ strcend.lo ext/mysql/libmysql/bchange.lo ext/mysql/libmysql/bmove.lo ext/mysql/l ibmysql/bmove_upp.lo ext/mysql/libmysql/longlong2str.lo ext/mysql/libmysql/strto ull.lo ext/mysql/libmysql/strtoll.lo ext/mysql/libmysql/charset.lo ext/mysql/lib mysql/ctype.lo ext/odbc/php_odbc.lo ext/overload/overload.lo ext/pcre/pcrelib/ma ketables.lo ext/pcre/pcrelib/get.lo ext/pcre/pcrelib/study.lo ext/pcre/pcrelib/p cre.lo ext/pcre/php_pcre.lo ext/pdf/pdf.lo ext/posix/posix.lo ext/session/sessio n.lo ext/session/mod_files.lo ext/session/mod_mm.lo ext/session/mod_user.lo ext/ standard/array.lo ext/standard/base64.lo ext/standard/basic_functions.lo ext/sta ndard/browscap.lo ext/standard/crc32.lo ext/standard/crypt.lo ext/standard/cyr_c onvert.lo ext/standard/datetime.lo ext/standard/dir.lo ext/standard/dl.lo ext/st andard/dns.lo ext/standard/exec.lo ext/standard/file.lo ext/standard/filestat.lo ext/standard/flock_compat.lo ext/standard/formatted_print.lo ext/standard/fsock .lo ext/standard/head.lo ext/standard/html.lo ext/standard/image.lo ext/standard /info.lo ext/standard/iptc.lo ext/standard/lcg.lo ext/standard/link.lo ext/stand ard/mail.lo ext/standard/math.lo ext/standard/md5.lo ext/standard/metaphone.lo e xt/standard/microtime.lo ext/standard/pack.lo ext/standard/pageinfo.lo ext/stand ard/parsedate.lo ext/standard/quot_print.lo ext/standard/rand.lo ext/standard/re g.lo ext/standard/soundex.lo ext/standard/string.lo ext/standard/scanf.lo ext/st andard/syslog.lo ext/standard/type.lo ext/standard/uniqid.lo ext/standard/url.lo ext/standard/url_scanner.lo ext/standard/var.lo ext/standard/versioning.lo ext/ standard/assert.lo ext/standard/strnatcmp.lo ext/standard/levenshtein.lo ext/sta ndard/incomplete_class.lo ext/standard/url_scanner_ex.lo ext/standard/ftp_fopen_ wrapper.lo ext/standard/http_fopen_wrapper.lo ext/standard/php_fopen_wrapper.lo ext/standard/credits.lo ext/standard/css.lo ext/standard/var_unserializer.lo ext /standard/ftok.lo ext/standard/aggregation.lo ext/standard/sha1.lo ext/sysvsem/s ysvsem.lo ext/sysvshm/sysvshm.lo ext/tokenizer/tokenizer.lo ext/wddx/wddx.lo ext /xml/xml.lo ext/xml/expat/xmlparse.lo ext/xml/expat/xmlrole.lo ext/xml/expat/xml tok.lo regex/regcomp.lo regex/regexec.lo regex/regerror.lo regex/regfree.lo TSRM /TSRM.lo TSRM/tsrm_strtok_r.lo TSRM/tsrm_virtual_cwd.lo main/main.lo main/snprin tf.lo main/spprintf.lo main/php_sprintf.lo main/safe_mode.lo main/fopen_wrappers .lo main/alloca.lo main/php_ini.lo main/SAPI.lo main/rfc1867.lo main/php_content _types.lo main/strlcpy.lo main/strlcat.lo main/mergesort.lo main/reentrancy.lo m ain/php_variables.lo main/php_ticks.lo main/streams.lo main/network.lo main/php_ open_temporary_file.lo main/php_logos.lo main/output.lo main/memory_streams.lo m ain/user_streams.lo Zend/zend_language_parser.lo Zend/zend_language_scanner.lo Z end/zend_ini_parser.lo Zend/zend_ini_scanner.lo Zend/zend_alloc.lo Zend/zend_com pile.lo Zend/zend_constants.lo Zend/zend_dynamic_array.lo Zend/zend_execute_API. lo Zend/zend_highlight.lo Zend/zend_llist.lo Zend/zend_opcode.lo Zend/zend_opera tors.lo Zend/zend_ptr_stack.lo Zend/zend_stack.lo Zend/zend_variables.lo Zend/ze nd.lo Zend/zend_API.lo Zend/zend_extensions.lo Zend/zend_hash.lo Zend/zend_list. lo Zend/zend_indent.lo Zend/zend_builtin_functions.lo Zend/zend_sprintf.lo Zend/ zend_ini.lo Zend/zend_qsort.lo Zend/zend_multibyte.lo Zend/zend_execute.lo sapi/ cli/php_cli.lo sapi/cli/getopt.lo main/internal_functions_cli.lo -ldb2 -lcrypto -lssl -lc-client -lifsql -lifasf -lifgen -lifos -lifgls -ldl -lcrypt -lphpifx -l ifglx -lpdf -lz -lldap -llber -lcrypt -lpam -lfdftk -lz -lcrypt -lresolv -lm -ld l -lnsl -lcrypt -o sapi/cli/php /usr/bin/ld: cannot find -ldb2 collect2: ld returned 1 exit status make: *** [sapi/cli/php] Error 1 error: Bad exit status from /var/tmp/rpm-tmp.22825 (%build) RPM build errors: Bad exit status from /var/tmp/rpm-tmp.22825 (%build) ====================================================== Here is the configure string: . /home/db2inst1/sqllib/db2profile LDFLAGS="-L/usr/IBMdb2/V7.1/lib" \ INFORMIXDIR=/usr/local/Informix \ ./configure \ --with-apache=../apache_1.3.26 \ --prefix=/usr \ --enable-safe-mode \ --with-exec-dir=/usr/bin \ --with-zlib \ --with-config-file-path=/etc/php3/apache \ --disable-debug \ --enable-magic-quotes \ --enable-debugger \ --enable-bcmath \ --enable-track-vars \ --enable-trans-sid \ --enable-wddx \ --with-imap \ --with-imap-ssl \ --with-ldap \ --with-ibm-db2=/home/db2inst1 \ --with-system-regex \ --with-informix=/usr/local/Informix \ --with-pdflib=/usr/local \ --enable-inline-optimization \ --enable-sysvsem \ --enable-sysvshm \ --with-mcrypt=shared \ --without-gd \ --with-fdftk=/usr/local ================================================ That works fine, and compile works fine. Here is the configure on the apache: LDFLAGS="-L/usr/IBMdb2/V7.1/lib" \ OPTIM="$RPM_OPT_FLAGS" \ SSL_BASE=../openssl-0.9.6b \ ./configure --prefix=/usr \ --with-layout=RedHat \ --mandir=/usr/share/man \ --add-module=$RPM_SOURCE_DIR/mod_bandwidth.c \ --add-module=$RPM_SOURCE_DIR/mod_put.c \ --activate-module=src/modules/throttle/mod_throttle.o \ --activate-module=src/modules/php4/libphp4.a \ --enable-module=all \ --enable-module=ssl \ --enable-shared=max \ --enable-rule=EAPI \ --disable-rule=WANTHSREGEX \ --disable-module=auth_dbm \ --with-perl=/usr/bin/perl \ --enable-suexec \ --suexec-docroot=/home/httpd/html \ --suexec-caller=nobody ========================================= The problem occurs after I type "make" in the apache directory. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=20928&edit=1