configure doesn't detect normal curses
carter at qosient.com
carter at qosient.com
Sat Jun 16 20:19:50 EDT 2007
Ahhhh, avoiding invalid syntax is key ;o)
Thanks, I'll have this in the clients tomorrow night!!
Carter
Carter Bullard
QoSient LLC
150 E. 57th Street Suite 12D
New York, New York 10022
+1 212 588-9133 Phone
+1 212 588-9134 Fax
-----Original Message-----
From: Christoph Badura <bad at bsd.de>
Date: Sat, 16 Jun 2007 21:40:13
To:argus-info <argus-info at lists.andrew.cmu.edu>
Subject: Re: [ARGUS] configure doesn't detect normal curses
Hi Carter,
I think the following patch will correct the detection of initscr()
in -lcurses.
I moved the check for initscr() in -lcurses from the "else" part
of "AC_CHECK_LIB(ncurses, initscr..." to the "else" part of
"AC_CHECK_HEADER(ncurses.h...". This seems more logical to me: If the
the ncurses.h header file is there we want to check for initscr() by
linking against -lncurses. If ncurses.h doesn't exist we'd want to check
for initscr() by linking against -lcurses.
I believe you also have to quote the nested calls to AC_CHECK_LIB with
[brackets] or autoconf will generate invalid syntax.
--- configure.in.orig 2007-05-28 21:58:14.000000000 +0200
+++ configure.in 2007-06-16 21:20:23.000000000 +0200
@@ -192,10 +192,10 @@
CURSESLIB=""
-AC_CHECK_HEADER(ncurses.h, AC_CHECK_LIB(ncurses, initscr,
- CURSESLIB="-lncurses",
- AC_CHECK_LIB(curses, initscr,
- CURSESLIB="-lcurses"),))
+AC_CHECK_HEADER(ncurses.h, [AC_CHECK_LIB(ncurses, initscr,
+ CURSESLIB="-lncurses")],
+ [AC_CHECK_LIB(curses, initscr,
+ CURSESLIB="-lcurses")],)
if test $CURSESLIB = "-lncurses"; then
cat >> confdefs.h <<\EOF
ratop now compiles correctly for me.
Cheers,
--chris
More information about the argus
mailing list