On Thu, Jun 14, 2001 at 06:51:09PM -0600, Tom Tromey wrote:
> >>>>> "Steve" == Steve M Robbins <[EMAIL PROTECTED]> writes:
>
> Steve> Given the following Makefile.am
> Steve> bin_PROGRAMS = foo
> Steve> foo_SOURCES = foo.c sub/foo2.c
> Steve> it turns out that "foo.c" is compiled using $(COMPILE), and hence
> Steve> includes AM_CFLAGS. However, "foo2.c" is compiled *without*
> Steve> AM_CFLAGS.
>
> Thanks for noticing this!
>
> What I intended is that by default everything is compiled with
> AM_CFLAGS. But if there are per-executable CFLAGS in effect, then
> AM_CFLAGS is omitted. So I agree you've found a bug.
>
> Your message, plus my recent adventures into automake.texi, make me
> wonder if this is the best approach. It would certainly be easier to
> document if AM_CFLAGS was simply always used.
>
> Now is the time to decide this sort of thing -- before 1.5 goes out.
> Any comments? Reasons to prefer one over the other? As I recall I
> planned it this way on the theory that adding AM_CFLAGS to the per-exe
> CFLAGS is easy for the user, but removing it would be hard.
So what you are saying is that AM_CFLAGS and foo_CFLAGS will behave
like LDADD and foo_LDADD (i.e. setting the foo_ version overrides the
other)?
I've always found this a bit of a nuisance with LDADD, to be honest.
I normally want the program-specific flags _in addition_ to the
generic flags. So I *always* have $(LDADD) in $foo_LDADD.
I see that you've already checked in a fix: thanks!
-Steve
--
by Rocket to the Moon,
by Airplane to the Rocket,
by Taxi to the Airport,
by Frontdoor to the Taxi,
by throwing back the blanket and laying down the legs ...
- They Might Be Giants