bug-autoconf
[Top][All Lists]
Advanced

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

two autoconf bugs


From: Werner LEMBERG
Subject: two autoconf bugs
Date: Tue, 15 Apr 2003 20:52:11 +0200 (CEST)

Akim,


almost three months ago I sent two bug reports (repeated below).  At
least the second one is serious IMHO.  Anything new here?  I'd really
like to see this fixed.


    Werner


======================================================================


Consider the following:

  AC_DEFUN(GROFF_SRAND, [ 
    AC_LANG_PUSH(C++)
    AC_MSG_CHECKING([for return type of srand])
    AC_COMPILE_IFELSE([ 
      AC_LANG_PROGRAM([[

  #include <stdlib.h>
  extern "C" { void srand(unsigned int); }

      ]])
    ], [
      AC_MSG_RESULT(void)
      AC_DEFINE(RET_TYPE_SRAND_IS_VOID, 1,
                [Define if srand() returns void not int.])
    ], [
      AC_MSG_RESULT(int)
    ])
    AC_LANG_POP(C++)
  ])

Look how `AC_LANG_PROGRAM' is indented by four spaces.  After macro
expansion, you get

      #line $LINENO "configure"
  /* confdefs.h.  */
  ...

which is incorrect, of course.  I think the start of
AC_LANG_SOURCE(C) in c.m4 shouldn't be

  m4_define([AC_LANG_SOURCE(C)],
  [#line $LINENO "configure"
  /* confdefs.h.  */

but

  m4_define([AC_LANG_SOURCE(C)],[
  #line $LINENO "configure"
  /* confdefs.h.  */

to protect against indentation.


    Werner


======================================================================


[autoconf 2.57]

With autoconf 2.54, a call to AC_DECL_SYS_SIGLIST gives

  checking for sys_siglist declaration in signal.h or unistd.h... yes

With 2.57, I get

  checking whether sys_siglist is declared... no

Reason is that `signal.h' is no longer included; only the default
set of header files is used.


    Werner




reply via email to

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