php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #35409 undefined reference to `rl_completion_matches'
Submitted: 2005-11-26 15:12 UTC Modified: 2005-11-28 17:51 UTC
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:1 (100.0%)
From: sales at vivizi dot com Assigned:
Status: Closed Package: Compile Failure
PHP Version: 5CVS-2005-11-28 (cvs) OS: *
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: sales at vivizi dot com
New email:
PHP Version: OS:

 

 [2005-11-26 15:12 UTC] sales at vivizi dot com
Description:
------------
I am having problems compiling 5.1.0
Small note: 5.0.5 works fine, EXACT SAME OPTIONS.
4.4.1 also works just fine!

when I use --with-openssl I get:
"checking for OpenSSL support... yes
checking for Kerberos support... no
checking for pkg-config... noconfigure: error: Cannot find OpenSSL's libraries"
when I do not use it it works ok.
I tried re-installing openssl (+ devel) and even upgrading it to the latest (0.9.6b->0.9.8a). No luck.

So I move on, I remove --with-openssl
Then I get: 
"checking for the location of libjpeg... /usr
configure: error: libjpeg.(a|so) not found."

etc etc, same for GD and libpng.
I use --with-jpeg-dir=/usr or /usr/lib or /usr/local, etc... does not matter.

locate libjpeg.a -> /usr/lib/libjpeg.a

Has anything changed, or is this a compile bug? So far as I can track down, it seems like a bug. Especially since 5.0.5 does work just fine. Also see no other problems.


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-11-26 16:35 UTC] sniper@php.net
And what might have been the whole configure line you tried with? And did you check config.log?

 [2005-11-26 17:25 UTC] sales at vivizi dot com
Whole config line I'd have to look up. But, 5.0.5 works... Or is there a combination in 5.1.0 that does not work?

Here is a config.log output of the libjpeg failure:
--
configure:33753: checking for GD support
configure:33800: checking for the location of libjpeg
configure:33827: checking for the location of libpng
configure:33880: checking for the location of libXpm
configure:33905: checking for FreeType 1.x support
configure:33930: checking for FreeType 2
configure:33955: checking for T1lib support
configure:33980: checking whether to enable truetype string function in GD
configure:34005: checking whether to enable JIS-mapped Japanese font support in GD
configure:34059: checking for fabsf
configure:34087: /usr/sg/bin/gcc -o conftest -DEAPI -O2 -m486 -fno-strength-reduce   conftest.c -lz -lresolv -lm -ldl -lnsl  -lxml2 -lz -lm -lxml2 -lz -lm 1>&5
configure:34071: warning: conflicting types for built-in function `fabsf'
configure:34059: checking for floorf
configure:34087: /usr/sg/bin/gcc -o conftest -DEAPI -O2 -m486 -fno-strength-reduce   conftest.c -lz -lresolv -lm -ldl -lnsl  -lxml2 -lz -lm -lxml2 -lz -lm 1>&5
--

for openSSL:

--
configure:20168: checking for OpenSSL support
configure:20214: checking for Kerberos support
configure:20905: checking for pkg-config
--
 [2005-11-26 17:47 UTC] mj@php.net
Could you please also look up the ./configure line?  Otherwise chances are small that people will be able to help you.
 [2005-11-26 18:36 UTC] sales at vivizi dot com
./configure --prefix=/usr --with-apxs=/usr/sbin/apxs --disable-debug --enable-apc --enable-bcmath --enable-calendar --enable-ctype --enable-exif --enable-fastcgi --enable-filepro --enable-ftp --enable-inline-optimization --enable-magic-quotes --enable-mbstring --enable-mbstr-enc-trans --enable-mbregex --enable-memory-limit --enable-mm=shared --enable-pcntl --enable-safe-mode --enable-shmop --enable-sigchild --enable-sockets --enable-sysvsem --enable-sysvshm --enable-track-vars --enable-trans-sid --enable-versioning --enable-wddx=shared --with-config-file-path=/etc/httpd/raqtweak --with-exec-dir=/usr/bin --with-gettext=/usr --with-iconv --with-libdir=/usr/lib --with-ncurses --with-openssl --with-pgsql=shared --with-readline --with-regex=system --with-tsrm-pthreads --with-zlib-dir=/usr/lib --with-gd --enable-gd-imgstrttf --enable-gd-native-ttf --enable-gd-jis-conv --with-imagick=/usr --with-pspell=/usr --with-db=shared --with-interbase=shared --with-mysql=/usr --with-mssql=shared --with-ldap-dir=/usr --with-imap --with-curl=shared --with-mcrypt=shared --with-mhash=shared --with-freetype-dir=/usr/include/freetype2 --with-png-dir=/usr --with-jpeg-dir=/usr --with-ttf --with-ttf=/usr/lib/libttf.so --with-pdflib --with-libxml --with-libxml2 --with-dom=shared --with-dom-xslt=/usr --with-xsl=shared --with-xsl-sablot=/usr --with-expat-dir=/usr --with-sablot-js=/usr --with-ming=shared
 [2005-11-26 20:58 UTC] mj@php.net
You are saying that compiling 5.0.5 works for you:  Does that mean that you are able to build it on the same box _right now_ or did it work back when you installed it some time ago?
 [2005-11-26 21:01 UTC] sales at vivizi dot com
same box, _right now_
 [2005-11-27 20:05 UTC] tony2001@php.net
And this box is a 64-bit one?
 [2005-11-27 20:09 UTC] sales at vivizi dot com
No, this happens to be a 32bit. P3-1.0Ghz, 512MB RAM.
 [2005-11-27 20:17 UTC] tony2001@php.net
Well, I don't see any changes that can cause it, except for the 64bit support that was added in 5.1.
And no, I can't reproduce it.
So try to see where ./configure seeks for those files and what makes it to fail.
 [2005-11-27 20:20 UTC] sales at vivizi dot com
I already tried this. With openSSL it complained about evp.h

I reinstall openSSL completely (even upgraded too, also did not work), then evp.h error disappeared.
Then I got what you get now (Can not find openSSL files, etc)...

Even when I specify all possible paths!
Same with libjpeg/png/gd! (--with-jpeg-dir=/usr, etc)
 [2005-11-27 23:47 UTC] sniper@php.net
Try this:

# rm config.cache 
# ./configure --disable-all --with-openssl

 [2005-11-28 00:08 UTC] sales at vivizi dot com
That seems to work!
"Thank you for using PHP." (= success!)
 [2005-11-28 00:41 UTC] sniper@php.net
Now just add those configure other options one by one..
 [2005-11-28 12:33 UTC] sales at vivizi dot com
OK,

the problem here was the line:

--with-libdir=/usr/lib
(/usr also did not work).

I removed it and that seemed to work.
Then I ran into:

configure: error: --enable-versioning cannot be used with shared modules

Removed that, then it worked.

Then, near the end, it gave me:

e -lncurses -laspell -lpspell -lpanel -lncurses -lmysqlclient -lm -lcrypt -lpam -lfreetype -lpng -lz -ljpeg -lssl -lcrypto -lz -lssl -lcrypto -lresolv -lm -ldl -lnsl -lxml2 -lz -lm -lxml2 -lz -lm -lxml2 -lz -lm -lcrypt -lxml2 -lz -lm -lcrypt  -o sapi/cli/php
sapi/cli/.libs/php_cli_readline.o: In function `cli_code_completion':
sapi/cli/.libs/php_cli_readline.o(.text+0xab2): undefined reference to `rl_completion_matches'
collect2: ld returned 1 exit status
make: *** [sapi/cli/php] Error 1

So I removed --with-readline, and it worked...

However, these options worked just fine on 5.0.5, same box, _right now_ (read previous posts)
 [2005-11-28 12:38 UTC] tony2001@php.net
There is no --with-libdir option in 5.0.
I bet you don't know what --enable-versioning does, why do you use it then, huh?
Please try to configure --with-readline only and report this issue separately, if you're able to reproduce it.
 [2005-11-28 15:11 UTC] sales at vivizi dot com
Wow, no reason to get picky!

--with-libdir=/usr/lib worked just fine with 5.0.5, I actually just compiled it. No fatal errors.
When using 5.1.0, it does not work.
So don't blame ME for that.

--enable-versioning: I thought this would give more details on versions being used. There is not a lot of docs available (on that), so don't blame me on that... I've always used it and it has always worked fine!

when using 
rm -f config.cache ; ./configure --disable-all --with-readline

I get:

sapi/cgi/.libs/cgi_main.o: In function `main':
/usr/src/redhat/BUILD/php-5.1.0/sapi/cgi/cgi_main.c:968: undefined reference to `FCGX_IsCGI'
/usr/src/redhat/BUILD/php-5.1.0/sapi/cgi/cgi_main.c:1149: undefined reference to `FCGX_OpenSocket'
/usr/src/redhat/BUILD/php-5.1.0/sapi/cgi/cgi_main.c:1152: undefined reference to `FCGX_OpenSocket'
/usr/src/redhat/BUILD/php-5.1.0/sapi/cgi/cgi_main.c:1161: undefined reference to `FCGX_IsCGI'
/usr/src/redhat/BUILD/php-5.1.0/sapi/cgi/cgi_main.c:1179: undefined reference to `FCGX_Init'
/usr/src/redhat/BUILD/php-5.1.0/sapi/cgi/cgi_main.c:1180: undefined reference to `FCGX_InitRequest'
/usr/src/redhat/BUILD/php-5.1.0/sapi/cgi/cgi_main.c:1288: undefined reference to `FCGX_Accept_r'
/usr/src/redhat/BUILD/php-5.1.0/sapi/cgi/cgi_main.c:1501: undefined reference to `FCGX_Finish_r'
/usr/src/redhat/BUILD/php-5.1.0/sapi/cgi/cgi_main.c:1640: undefined reference to `FCGX_Finish_r'
/usr/src/redhat/BUILD/php-5.1.0/sapi/cgi/cgi_main.c:1671: undefined reference to `__canary_death_handler'
sapi/cgi/.libs/cgi_main.o: In function `sapi_cgibin_single_write':
/usr/src/redhat/BUILD/php-5.1.0/sapi/cgi/cgi_main.c:231: undefined reference to `FCGX_IsCGI'
/usr/src/redhat/BUILD/php-5.1.0/sapi/cgi/cgi_main.c:233: undefined reference to `FCGX_PutStr'
/usr/src/redhat/BUILD/php-5.1.0/sapi/cgi/cgi_main.c:248: undefined reference to `__canary_death_handler'
sapi/cgi/.libs/getopt.o: In function `php_opt_error':
/usr/src/redhat/BUILD/php-5.1.0/sapi/cgi/getopt.c:51: undefined reference to `__canary_death_handler'
sapi/cgi/.libs/getopt.o: In function `php_getopt':
/usr/src/redhat/BUILD/php-5.1.0/sapi/cgi/getopt.c:154: undefined reference to `__canary_death_handler'
collect2: ld returned 1 exit status
make: *** [sapi/cgi/php] Error 1
 [2005-11-28 15:14 UTC] sniper@php.net
--with-libdir is for 64bit systems where there might be different directory than 'lib', where you'd use --with-libdir=lib64 for example.

--enable-versioning - If you don't know what it is meant for DO NOT USE IT!

And try with clean sources. "make clean" might help too..

 [2005-11-28 15:28 UTC] sales at vivizi dot com
--with-libdir: Thanks for the explination. Not sure why it did not 'fatal error' on 5.0.5 then. Maybe it gave a warning, but then I didn't see it. But it DID work with the exact same option. It did not on 5.1.0??

Anyway, glad to finally understand why this failed and that it is not required.

Am I right on the --enable-versioning?
I was told to do it ages ago. I've been using it ever since. What is it for then?? I would really like to understand why I should not use it.

Just tried your suggestion, "make clean" and then "./configure --disable-all --with-readline":
That worked. However, "make" gave:

zend_ini.lo Zend/zend_qsort.lo Zend/zend_multibyte.lo Zend/zend_ts_hash.lo Zend/zend_stream.lo Zend/zend_iterators.lo Zend/zend_interfaces.lo Zend/zend_exceptions.lo Zend/zend_strtod.lo Zend/zend_objects.lo Zend/zend_object_handlers.lo Zend/zend_objects_API.lo Zend/zend_mm.lo Zend/zend_default_classes.lo Zend/zend_reflection_api.lo Zend/zend_execute.lo sapi/cli/php_cli.lo sapi/cli/php_cli_readline.lo sapi/cli/getopt.lo main/internal_functions_cli.lo -lcrypt -lcrypt -lhistory -lreadline -lncurses -lresolv -lm -ldl -lnsl -lcrypt -lcrypt  -o sapi/cli/php
sapi/cli/php_cli_readline.o: In function `cli_code_completion':
/usr/src/redhat/BUILD/php-5.1.0/sapi/cli/php_cli_readline.c:432: undefined reference to `rl_completion_matches'
collect2: ld returned 1 exit status
make: *** [sapi/cli/php] Error 1
 [2005-11-28 16:40 UTC] sniper@php.net
--with-libdir does not exist with 5.0.5, that's why it "worked". You don't need --enable-versioning. That's all you need to know. 

What readline version do you have installed?



 [2005-11-28 16:45 UTC] sales at vivizi dot com
readline-4.1-9
readline-devel-4.1-9

Is there really no documentation on versioning? Sorry to be a pain. Just like to understand.
 [2005-11-28 17:51 UTC] sniper@php.net
This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 25 13:01:30 2024 UTC