<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <br>
    <div class="moz-cite-prefix">On 06/25/2012 11:32 AM, Sandro Santilli
      wrote:<br>
    </div>
    <blockquote cite="mid:20120625093215.GA25133@gnash" type="cite"><br>
      <pre wrap="">Autotools do something like this:

DEFAULT_INCLUDES = -I. -I$(top_builddir)/include -I$(top_builddir)/include/geos
CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
        $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)

Where DEFAULT_INCLUDES is automatically generated and $(CPPFLAGS) 
and $(CXXFLAGS) are the ones you eventually override.

In PostGIS we don't have this double definition so it won't work:

        $(LIBTOOL) --mode=compile $(CC) $(CFLAGS) -c -o $@ $<

I guess we could add a $(DEFAULT_INCLUDES) right before the CFLAGS.
Then you could use:

 make CFLAGS=...

Note that "CFLAGS=... make" has no effect on either PostGIS or GEOS
(autotools-based) for me.


</pre>
    </blockquote>
    <font face="Times New Roman, Times, serif">No, it is a configure
      problem. Sorry, I didn't explain it right. The command is
      "CFLAGS=... LDFLAGS=...  configure".  After that, all following
      "makes" include those paths before all system generated paths. The
      problem arises when in an earlier path there is an older version
      of a library or header file. I don't see a simple solution.<br>
      <br>
      Jan  </font><br>
  </body>
</html>