Hi,
Yet another bug in the library detection code
This time I am unable to provide a patch because of a lack of time to completely debug the problem.
I'm running Fedora Core 5 on a 64 bits server. When using this configuration command:
I get this error message:
It seems that the configure script correctly links with "-lcurl" when doing the first test (check line configure:8604, but when (and only when) "--enable-static" is used, it forgets "-lcurl" in the list of libraries to link in the second test (check line configure:8724).
Here is the relevant part of the config.log file:
Regards
Yet another bug in the library detection code
This time I am unable to provide a patch because of a lack of time to completely debug the problem.I'm running Fedora Core 5 on a 64 bits server. When using this configuration command:
Code:
./configure --prefix=/opt/zabbix-server --enable-server --enable-static --with-mysql --with-libcurl --with-net-snmp
Code:
checking for main in -lz ... yes checking for main in -lcurl... yes checking whether libcurl is usable... no configure: error: Not found Curl library
Here is the relevant part of the config.log file:
Code:
configure:8575: checking for main in -lcurl
configure:8604: gcc -o conftest -g -O2 -I/usr/include/mysql -g -pipe -Wp,-D_FORTIFY_SOURCE=2 -fexception
s -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_
LARGEFILE_SOURCE -fno-strict-aliasing -fwrapv -static -L/usr/lib64/mysql -L/usr/lib64 -L/usr/ke
rberos/lib64 conftest.c -lcurl -lz -lcrypto -lssl -lidn -lresolv -lcom_err -lkrb5support -lk5crypt
o -lkrb5 -lgssapi_krb5 -ldl -lresolv -lnsl -lmysqlclient -lz -lcrypt -lnsl -lm -lssl -lcrypto -l
dl -lgssapi_krb5 -lkrb5 -lk5crypto -lkrb5support -lcom_err -lresolv -lidn -lssl -lcrypto -lz >&5
configure:8610: $? = 0
configure:8628: result: yes
configure:8681: checking whether libcurl is usable
configure:8724: gcc -o conftest -g -O2 -I/usr/include/mysql -g -pipe -Wp,-D_FORTIFY_SOURCE=2 -fexception
s -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_
LARGEFILE_SOURCE -fno-strict-aliasing -fwrapv -static -L/usr/lib64/mysql -L/usr/lib64 conftest.c
-ldl -lgssapi_krb5 -lkrb5 -lk5crypto -lkrb5support -lcom_err -lresolv -lidn -lssl -lcrypto -lz -lz -lcr
ypto -lssl -lidn -lresolv -lcom_err -lkrb5support -lk5crypto -lkrb5 -lgssapi_krb5 -ldl -lresolv
-lnsl -lmysqlclient -lz -lcrypt -lnsl -lm -lssl -lcrypto >&5
/tmp/ccmdXJlJ.o: In function `main':
/usr/src/ZABBIX/zabbix-1.3.9/conftest.c:128: undefined reference to `curl_easy_setopt'
collect2: ld returned 1 exit status
configure:8730: $? = 1
configure: failed program was:
| /* confdefs.h. */
| #define PACKAGE_NAME ""
| #define PACKAGE_TARNAME ""
| #define PACKAGE_VERSION ""
| #define PACKAGE_STRING ""
.........
| #define HAVE_LIBCRYPTO_ 1
| #define HAVE_LIBZ_ 1
| #define HAVE_LIBCURL 1
| /* end confdefs.h. */
| #include <curl/curl.h>
| int
| main ()
| {
|
| /* Try and use a few common options to force a failure if we are
| missing symbols or can't link. */
| int x;
| curl_easy_setopt(NULL,CURLOPT_URL,NULL);
| x=CURL_ERROR_SIZE;
| x=CURLOPT_WRITEFUNCTION;
| x=CURLOPT_FILE;
| x=CURLOPT_ERRORBUFFER;
| x=CURLOPT_STDERR;
| x=CURLOPT_VERBOSE;
|
| ;
| return 0;
| }
configure:8753: result: no
configure:8934: error: Not found Curl library
Comment