automake
[Top][All Lists]
Advanced

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

Re: Compiler Flags


From: Tim Heath
Subject: Re: Compiler Flags
Date: Mon, 20 Nov 2000 11:47:41 -0700

AM_CXXFLAGS =  -D_POSIX1C_SOURCE -D_HPUX_SOURCE -D_REENTRANT

at the top of my Makefile.am had the desired affect I was looking for.

Thanks,

Tim Heath

P.S.

If you know of a better way please feel free to share it with me.  I am
interested in how to do and if/then to use this only if I am compiling
on HPUX 11.0 with aCC etc.

Tom Tromey wrote:
> 
> >>>>> "Simon" == Simon Richter <address@hidden> writes:
> 
> >> On Fri, 17 Nov 2000, Tim Heath wrote:
> >> How do I add compiler flags?  What AM is necessary to accomplish that?
> 
> Simon> Make your configure.in add them to $CFLAGS, before AC_PROG_CC
> Simon> (to make sure the compiler actually accepts them).
> 
> Actually, you don't want to do that.  CFLAGS, CPPFLAGS, and the like
> are defined to be "user variables".  That is, the user should be free
> to do this:
> 
>     make CFLAGS='my flags' ...
> 
> If your rewritten CFLAGS contained things necessary for your package,
> this would break.
> 
> You can set private compiler flags using the `AM_' form of variables:
> AM_CFLAGS, AM_CXXFLAGS, AM_CPPFLAGS, etc.
> 
> Tom



reply via email to

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