:  Pekka> This sort of thing is not possible now and makes it
:  Pekka> really ugly to use the conditionals in makefiles, imo.
:  Pekka> Currently only way to do this is to conditionalize the
:  Pekka> entire FILES variable.  Alternatively it could just
:  Pekka> remove the lines not to be included.
:
: Sorry, I forgot to reply to this.  A simpler solution is to use
: a sub-variable.
:
: FILES = somefile.c $(FILES_IF_SOMETHING) $(FILES_IF_SOMETHING_ELSE) something.c
: if HAVE_SOMETHING
: FILES_IF_SOMETHING = someotherfile.c
: endif
: if HAVE_SOMETHING_ELSE
: FILES_IF_SOMETHING_ELSE = somethingelse.c
: endif
:
Yes, I know.  This is what I've been using.  The reason I posted this was
that I'm creating currently three different distributions from the same
code base, and it would be really nice to be able say what goes into what
distribution without messing up all Makefiles and repeating everything
three times in all Makefiles. :)  Also, the reason was to be able to make
more detailed list of what goes into a distribution (like which of the n
features) by using conditionals in _SOURCES and _HEADERS, etc.

        Pekka
________________________________________________________________________
 Pekka Riikonen                                 priikone at silcnet.org
 Secure Internet Live Conferencing (SILC)       http://silcnet.org/



Reply via email to