#50209 [Opn->Fbk]: Compiling with libedit cannot find readline.h

From: Date: Wed, 18 Nov 2009 14:26:02 +0000
Subject: #50209 [Opn->Fbk]: Compiling with libedit cannot find readline.h
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-144746@lists.php.net to get a copy of this message
 ID:               50209
 Updated by:       jani@php.net
 Reported By:      tcallawa at redhat dot com
-Status:           Open
+Status:           Feedback
 Bug Type:         Compile Failure
 Operating System: Linux (Fedora)
 PHP Version:      5.3.0
 New Comment:

Please try using this snapshot:

  http://snaps.php.net/php5.3-latest.tar.gz
 
For Windows:

  http://windows.php.net/snapshots/




Previous Comments:
------------------------------------------------------------------------

[2009-11-17 21:49:34] tcallawa at redhat dot com

Description:
------------
The PHP code assumes that even with libedit in use (instead of
readline), that the header can be found in readline/readline.h.

libedit installs its "readline.h" into editline/ (to avoid the obvious
conflict with readline).

Accordingly, configure claims that libedit is not properly installed,
when it is. I've written a straightforward patch to fix this:

http://spot.fedorapeople.org/php-5.3.0-libedit.patch

It is also possible to use pkgconfig to ask libedit for its include
flags (and cflags), which would return "-I/usr/include/editline", but as
that was slightly more intrusive, I did not go down that road.

In addition, on a system where readline-devel and libedit-devel are
both installed, the existing code checking for
/usr/include/readline-devel will cause a false positive when checking
for libedit, and will end up doing a compile with readline's headers and
libedit's library.

Reproduce code:
---------------
./configure --without-readline --with-libedit


Expected result:
----------------
checking for libedit readline replacement... yes
checking for readline in -ledit... yes


Actual result:
--------------
checking for libedit readline replacement... yes
configure: error: Please reinstall libedit - I cannot find readline.h



------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=50209&edit=1



Thread (5 messages)

« previous php.bugs (#144746) next »