automake
[Top][All Lists]
Advanced

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

multi-line AC_SUBSTs as targets in Makefile.am


From: William Pursell
Subject: multi-line AC_SUBSTs as targets in Makefile.am
Date: Mon, 08 Oct 2007 09:24:52 +0100
User-agent: Icedove 1.5.0.12 (X11/20070607)


I've been using AC_SUBST_FILE to put common targets into my
makefile.am's.  eg, Makefile.am contains:

@FOO_TARGET@

where configure.ac contains
FOO_TARGET=foo_target
AC_SUBST_FILE(FOO_TARGET)

and foo_target contains:

foo:
        echo foo

I would like to do this via AC_SUBST, but this completely hoses
the Makefile.  For example, if configure.ac instead contains:

BAR_TARGET="bar:
        echo bar"
AC_SUBST( BAR_TARGET)

Then Make bails since Makefile now contains the invalid construct:
BAR_TARGET = bar:
        echo bar

I'd like to get away from AC_SUBST_FILE, but I don't see a way
around the manner in which automake is building the Makefile.
Is there a way to construct a generic target via AC_SUBST?





reply via email to

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