pdf-devel
[Top][All Lists]
Advanced

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

Re: [pdf-devel] Debug options: autotools errors


From: Aleksander Morgado
Subject: Re: [pdf-devel] Debug options: autotools errors
Date: Thu, 28 Feb 2008 10:38:00 +0100
User-agent: Thunderbird 2.0.0.9 (Macintosh/20071031)

Hi Gerel,

##
Error message:

autoheader: warning: missing template: autoheader: Use AC_DEFINE([], [], [Description])
autoreconf: /usr/bin/autoheader failed with exit status: 1
###


You should use AC_DEFINE_UNQUOTED for shell variables only. But the real error is that the third parameter is not given (the description). The description is mandatory when you want to use autoheader (by calling AM_CONFIG_HEADER or AC_CONFIG_HEADERS) to create a config.h.in file with all the defines, as we do.

In addition to this, the defines should only appear if the specific option was selected in the configure, and not always, even if the value defined is different (we use `ifdef' within the code, not `if').

I send you my changes to your proposal.

-Aleksander


Index: configure.ac
===================================================================
RCS file: /cvsroot/pdf/libgnupdf/configure.ac,v
retrieving revision 1.27
diff -r1.27 configure.ac
38a39
>
137a139,174
> dnl debug_*_mode
> debug_base_mode=no
> debug_object_mode=no
> debug_document_mode=no
> debug_page_mode=no
> AC_ARG_ENABLE([debug-base], AS_HELP_STRING([--enable-debug-base],
> [debug mode at the base layer (default is NO)]),
>               [debug_base_mode=yes], [debug_base_mode=no])
>
> AC_ARG_ENABLE([debug-object], AS_HELP_STRING([--enable-debug-object],
> [debug mode at the object layer (default is NO)]),
>               [debug_object_mode=yes], [debug_object_mode=no])
>
> AC_ARG_ENABLE([debug-document], AS_HELP_STRING([--enable-debug-document],
> [debug mode at the document layer (default is NO)]),
>               [debug_document_mode=yes], [debug_document_mode=no])
>
> AC_ARG_ENABLE([debug-page], AS_HELP_STRING([--enable-debug-page],
> [debug mode at the page layer (default is NO)]),
>               [debug_page_mode=yes], [debug_page_mode=no])
>
> if test "x$debug_base_mode" = "xyes"; then
>    AC_DEFINE([HAVE_DEBUG_BASE],,[Debugging Base Layer])
> fi
> if test "x$debug_object_mode" = "xyes"; then
>    AC_DEFINE([HAVE_DEBUG_OBJECT],,[Debugging Object Layer])
> fi
> if test "x$debug_document_mode" = "xyes"; then
>    AC_DEFINE([HAVE_DEBUG_DOCUMENT],,[Debugging Document Layer])
> fi
> if test "x$debug_page_mode" = "xyes"; then
>    AC_DEFINE([HAVE_DEBUG_PAGE],,[Debugging Page Layer])
> fi
> dnl end debug_*_mode
>




reply via email to

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