|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2006-03-18 12:04 UTC] james at groovytrain dot com
Description:
------------
Having compiled PHP without XML support on my system several times without problem, I decided to try and include XML support.
When I run the following command:
./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql --without-pear --enable-libxml --with-gd --with-png-dir=/usr/lib --with-jpeg-dir=/usr/lib --with-zlib-dir=/usr --enable-mbstring=all
It fails with:
checking whether libxml build works... no
configure: error: build test failed. Please check the config.log for details.
The "config.log" shows:
configure:19959: checking whether libxml build works
configure:19986: gcc -o conftest -g -O2 -Wl,-rpath,/usr/local/lib -L/usr/local/lib conftest.c
-lresolv -lm -ldl -lnsl -lxml2 -lz -lm 1>&5
configure: failed program was:
#line 19975 "configure"
#include "confdefs.h"
char xmlInitParser();
int main() {
xmlInitParser();
return 0;
}
My system has libxml2 version 2.6.23, which was compiled and installed from source not using an RPM.
I have tried a various "--with-libxml-dir" parameters including "--with-libxml-dir=/usr/local/lib" (libxml2 v2.6.23 is in "/usr/local/lib" and v 2.4.10 in "/usr/lib").
Any help you can give will be gratefully received.
Expected result:
----------------
I expect ./configure to complete successfully.
Actual result:
--------------
./configure fails with:
checking whether libxml build works... no
configure: error: build test failed. Please check the config.log for details.
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Dec 01 18:00:01 2025 UTC |
1) "--with-libxml-dir=/usr/local/lib" This is definitely wrong. The "/lib" part should be omitted, so it would look like "--with-libxml-dir=/usr/local". This also applies to all the other options. 2) If you still can reproduce it, please put this code: ---------- char xmlInitParser(); int main() { xmlInitParser(); return 0; } ---------- into conftest.c and try to compile it like this: gcc -o conftest -g -O2 -Wl,-rpath,/usr/local/lib -L/usr/local/lib conftest.c -lresolv -lm -ldl -lnsl -lxml2 -lz -lm and post here the error message you get.