Subject: readline not being configured correctly

From: [email-masked]
Date: Fri, 5 May 2000 10:42:39 -0400 (EDT)

When compiling fvwm-2.3.16, I used the following configure command:

(Line broken up for readability)

CC=cc CFLAGS="-O4" ./configure
	--with-xpm-library=/freeware/lib/libXpm.a
	--with-xpm-includes=/freeware/include
	--with-readline-library=/freeware/lib/libreadline.a
	--with-readline-includes=/freeware/include
	--prefix=/usr/lar3ry

The ending configuration report came out (note ReadLine message):

Configuration:

  FVWM Version:                    2.3.16

  Have ReadLine support?           no
  Have RPlay support?              no
  Have Stroke support?             no
  Have XPM support?                yes
  Have GTK support?                yes
  Have Session Management support? yes

I investigated config.log to figure out why this wasn't working:

    configure:2841: checking for readline in -lreadline
*   configure:2860: cc -o conftest -O4   conftest.c -lreadline /freeware/lib/libreadline.a -ltermcap  1>&5
    ld:
    Can't locate file for: -lreadline
    configure: failed program was:
    #line 2849 "configure"
    #include "confdefs.h"
    /* Override any gcc2 internal prototype to avoid an error.  */
    /* We use char because int might match the return type of a gcc2
	builtin and then its argument prototype would still apply.  */
    char readline();

    int main() {
    readline()
    ; return 0; }
    configure:2967: checking with ncurses
    configure:2970: checking for readline in -lreadline
    configure:2989: cc -o conftest -O4   conftest.c -lreadline -lncurses  1>&5
    ld:
    Can't locate file for: -lreadline
    configure: failed program was:
    #line 2978 "configure"
    #include "confdefs.h"
    /* Override any gcc2 internal prototype to avoid an error.  */
    /* We use char because int might match the return type of a gcc2
	builtin and then its argument prototype would still apply.  */
    char readline();

    int main() {
    readline()
    ; return 0; }

I noted a line above with an asterisk, which I repeat (wrapping it in
the process) below:

configure:2860:  cc -o conftest -O4 conftest.c -lreadline
    /freeware/lib/libreadline.a -ltermcap 1>&5

In other words, configure is attempting to use "-lreadline" and
"/freeware/lib/libreadline.a" in the same line.  This is plain wrong!
I want readline to be taken from /freeware/lib/libreadline.a and not
from any other library.

I think I have found a workaround (setting LDFLAGS manually), but this
appears to be a bug in the configure script.

-- 
Larry Gensch                                          [email-masked]

                  "May I have ten thousand marbles, please?"

--
Visit the official FVWM web page at <URL:http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm-workers" in the
body of a message to [email-masked].
To report problems, send mail to [email-masked]

---

From: Dan Espen <[email-masked]>
Date: Fri, 05 May 2000 10:50:36 -0400

> 	--with-readline-includes=/freeware/include

Try:

CC=cc CFLAGS="-O4" ./configure
	--with-xpm-library=/freeware/lib
	--with-xpm-includes=/freeware/include
	--with-readline-library=/freeware/lib
	--with-readline-includes=/freeware/include
	--prefix=/usr/lar3ry

(With the backslashes or one long line.)

--
Dan Espen
444 Hoes Lane  Room RRC 1C-214           E-mail: [email-masked]
Piscataway, NJ 08854                     Phone: (732) 699-5570
--
Visit the official FVWM web page at <URL:http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm-workers" in the
body of a message to [email-masked].
To report problems, send mail to [email-masked]