octave-bug-tracker
[Top][All Lists]
Advanced

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

[Octave-bug-tracker] [bug #36064] MAGICK_X extra flags are shadowed by s


From: Rik
Subject: [Octave-bug-tracker] [bug #36064] MAGICK_X extra flags are shadowed by system CPPFLAGS and LDFLAGS
Date: Sun, 27 Oct 2013 18:33:40 +0000
User-agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:24.0) Gecko/20100101 Firefox/24.0

Follow-up Comment #6, bug #36064 (project octave):

And this still might not be enough, but if it mostly works then I think it is
a useful addition. 

The Automake manual talks about CPPFLAGS, but their use case is actually more
appropriate for CFLAGS.  For CFLAGS, the last entered option overrides any
preceding ones (gcc -O1 -O3 is interpreted as -O3).  Thus, I always want the
user's CFLAGS variable last so that they can have the last word.

The CPPFLAGS are different in that if I use "cpp -Idir1 -Idir2" the dir1
directory is searched first instead of being overridden by the second option. 
So, for CPPFLAGs I need to have the user's preferences *ahead* of the default
AM_CPPFLAGS.  But, there is one more complication in that some CPPFLAGS, like
-D, *are* overridden by the last occurring version.  To be utterly safe I
should really write


$(MAGICK_CPPFLAGS) $(AM_CPPFLAGS) $(MAGICK_CPPFLAGS) $(CPPFLAGS)


This seemed redundant so I didn't, in fact, do this.  If there are
re-definitions then gcc produces a big 2-line warning about it so they will be
easy to find.  And we know that we don't have this sort of situation going on
because we would have been getting these warnings even for the previous
ordering of flags.


$(AM_CPPFLAGS) $(MAGICK_CPPFLAGS) $(CPPFLAGS)



    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?36064>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

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