[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Header guards for config.h
From: |
Guido Draheim |
Subject: |
Re: Header guards for config.h |
Date: |
Sat, 11 Jan 2003 20:12:50 +0100 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686; de-AT; rv:1.1) Gecko/20020826 |
Peter Eisentraut schrieb:
Would it make sense to have autoheader create header guards against double
inclusion into its output file?
No. Do not include config.h from a header file, unless it is again the
only single wrapper around it to be included by the rest of your
software - and don't install it. There should no multiple include-config.h
around. Writing a wrapper might also solve your current problem as well ;-)
The reason: there have been problems with third-area compilations
to have their own config.h being somewhat differently, and people
do not notice it. To guard on it, use again AX_PREFIX_CONFIG_H and
shift dependencies on those prefixed symbols - that prefix-config.h
is guarded and in my opinion that makes sense.
-- cheers, guido hptt://ac-archive.sf.net