[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Need help with autoconf configure script

From: Bob Rossi
Subject: Re: Need help with autoconf configure script
Date: Wed, 13 Jul 2005 07:38:25 -0400
User-agent: Mutt/1.3.28i

On Wed, Jul 13, 2005 at 11:02:48AM +0200, Andreas Schwab wrote:
> Bob Rossi <address@hidden> writes:
> > On Wed, Jul 13, 2005 at 12:04:27AM +0200, Andreas Schwab wrote:
> >> Bob Rossi <address@hidden> writes:
> >> 
> >> > If I run ./configure then by default opt_with_readline_prefix is "no".
> >> > During ../cgdb/configure I get,
> >> >    checking pty.h usability... yes
> >> >    checking pty.h presence... no
> >> >    configure: WARNING: pty.h: accepted by the compiler, rejected by the 
> >> > preprocessor!
> >> >    configure: WARNING: pty.h: proceeding with the compiler's result
> >> >    checking for pty.h... yes
> >> > so I get error's when VL_LIB_READLINE is *not* run.
> >> 
> >> Please check config.log for the actual preprocessor error you get.
> >> Without that it is impossible to guess what's going on.
> >
> > Thanks for the response Andreas. The attached is the diff between when
> > the config.log that works and doesn't work.
> That's the old AC_REQUIRE problem.  VL_LIB_READLINE is probably the first
> macro requiring the AC_PROG_CPP framework, but since all of this is
> skipped when $vl_cv_lib_readline is no, the expansion from that macro is
> never executed, and many of the internal autoconf variables remain unset.
> Workaround: Put AC_PROG_CPP somewhere before this block.
Hi Andreas,

It really sounds like you have something here! At least, the reasoning
could explain why things don't work, just because the macro is in the, but it's not ever executed.

VL_LIB_READLINE does not depend on AC_PROG_CPP, in fact, CGDB is entirly
written in C. However, you suggestion made me think, and I did find out
yesterday that AC_CHECK_HEADERS was the macro that was causing
VL_LIB_READLINE to cause the problem. 

Because of your suggestion, I moved everything  (3 lines)
   dnl Checking for log10 function in math - I would like to remove this
   AC_CHECK_LIB(m, log10)

   dnl Checks for header files.
in my that was after the 'if ... VL_LIB_READLINE', and
before all of my checks to AC_CHECK_HEADERS, above the VL_LIB_READLINE
macro. Now things seem to work!

Is this a bug in autoconf? I would really like to get to the root of
this problem, so that others do not have to deal with it, ever. It took
me a very long time to even get close to solving the problem, and it
wouldn't of happened without you guys!

Please see the attached files.
  attachment 1, the good
  attachment 2, the diff between the good and bad
    This shows that moving those 3 lines is causing the problem.
  attachment 3, the readline.m4 macro

Bob Rossi

Description: Text document

Description: Text document

Attachment: readline.m4
Description: Text document

reply via email to

[Prev in Thread] Current Thread [Next in Thread]