plebby1 |
10-26-2009 09:30 PM |
php configure --with-mysql problem
Well I've searched high and low without luck for an answer to this before posting, so here I go...
I have the latest mysql mac os x binary installed and working in /usr/local/mysql.
I am running Mac OS X 10.5.8 on MacBookPro. httpd-2.2.14.
I am trying to configure php-5.3.0 from source like this:
Code:
MACOSX_DEPLOYMENT_TARGET=10.5 CFLAGS="-arch ppc -arch ppc64 -arch i386 -arch x86_64 -g -Os -pipe -no-cpp-precomp" CCFLAGS="-arch ppc -arch ppc64 -arch i386 -arch x86_64 -g -Os -pipe" CXXFLAGS="-arch ppc -arch ppc64 -arch i386 -arch x86_64 -g -Os -pipe" LDFLAGS="-arch ppc -arch ppc64 -arch i386 -arch x86_64 -bind_at_load"
./configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --with-apxs2=/usr/sbin/apxs --with-config-file-path=/etc --sysconfdir=/private/etc --with-openssl --with-zlib=/usr --with-zlib-dir=/usr --with-bz2 --enable-cli --with-gd --with-png-dir=/usr/local --with-xpm-dir=/usr/X11R6 --enable-gd-native-ttf --with-jpeg-dir=/usr/local/lib/ --with-curl=/usr --enable-exif --enable-ftp --enable-mbstring --enable-mbregex --enable-sockets --with-ldap=/usr --with-kerberos=/usr --with-mime-magic=/etc/apache2/magic --without-sqlite --with-mcrypt --with-iconv --with-mysql=/usr/local/mysql --with-mysqli=/usr/local/mysql/bin/mysql_config --with-pdo-mysql=/usr/local/mysql --with-mysql-sock=/private/var/mysql/mysql.sock --with-freetype-dir=/usr/local/lib --enable-shared --with-xsl --enable-pcntl --enable-sysvsem --enable-sysvmsg --enable-sysvshm --with-ffmpeg
And my error during ./configure is:
Code:
checking for MySQL support... yes
checking for specified location of the MySQL UNIX socket... /private/var/mysql/mysql.sock
checking for MySQL UNIX socket location... /private/var/mysql/mysql.sock
checking for mysql_close in -lmysqlclient... no
checking for mysql_error in -lmysqlclient... no
configure: error: mysql configure failed. Please check config.log for more information.
And config.log says:
Code:
configure:75712: checking for MySQL UNIX socket location
configure:75721: result: /private/var/mysql/mysql.sock
configure:75916: checking for mysql_close in -lmysqlclient
configure:75951: cc -o conftest -I/usr/include -gstabs -fvisibility=hidden -Wno-deprecated-declarations -Wall -fno-strict-aliasing -no-cpp-precomp -Wl,-rpath,/usr/local/mysql/lib -L/usr/local/mysql/lib -liconv -L/usr/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib -Wl,-rpath,/usr/X11R6/lib -L/usr/X11R6/lib conftest.c -lmysqlclient -lmcrypt -lltdl -lldap -llber -liconv -liconv -lfreetype -lX11 -lXpm -lpng -lz -ljpeg -lssl -lcrypto -lavformat -lavcodec -lcurl -lbz2 -lz -lssl -lcrypto -lm -lxml2 -lz -licucore -lm -lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -lcurl -lssl -lcrypto -lz -lxml2 -lz -licucore -lm >&5
ld warning: in /usr/local/mysql/lib/libmysqlclient.dylib, file is not of required architecture
Undefined symbols:
"_mysql_close", referenced from:
_main in ccI5hkYP.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
configure:75957: $? = 1
configure: failed program was:
**AND**
Code:
| #define PHP_MYSQL_UNIX_SOCK_ADDR "/private/var/mysql/mysql.sock"
| /* end confdefs.h. */
|
| /* Override any GCC internal prototype to avoid an error.
| Use char because int might match the return type of a GCC
| builtin and then its argument prototype would still apply. */
| #ifdef __cplusplus
| extern "C"
| #endif
| char mysql_close ();
| int
| main ()
| {
| return mysql_close ();
| ;
| return 0;
| }
configure:75976: result: no
configure:76186: checking for mysql_error in -lmysqlclient
configure:76221: cc -o conftest -I/usr/include -gstabs -fvisibility=hidden -Wno-deprecated-declarations -Wall -fno-strict-aliasing -no-cpp-precomp -Wl,-rpath,/usr/local/mysql/lib -L/usr/local/mysql/lib -liconv -L/usr/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib -Wl,-rpath,/usr/X11R6/lib -L/usr/X11R6/lib -Wl,-rpath,/usr -L/usr conftest.c -lmysqlclient -lz -lmcrypt -lltdl -lldap -llber -liconv -liconv -lfreetype -lX11 -lXpm -lpng -lz -ljpeg -lssl -lcrypto -lavformat -lavcodec -lcurl -lbz2 -lz -lssl -lcrypto -lm -lxml2 -lz -licucore -lm -lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -lcurl -lssl -lcrypto -lz -lxml2 -lz -licucore -lm >&5
ld warning: in /usr/local/mysql/lib/libmysqlclient.dylib, file is not of required architecture
Undefined symbols:
"_mysql_error", referenced from:
_main in ccB7XjON.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
configure:76227: $? = 1
configure: failed program was:
Anybody have any ideas?
|