It is my understanding (after having re-read the doc ;) that these
flags are exclusive: either one of the two is used.  So I have in a
Makefile.am of mine:

| AM_LDFLAGS = -avoid-version -module -shared
| ...
| # Override AM_LDFLAGS: this guy must not be a module.
| libtcswigpy_la_LDFLAGS =

and Makefile.in does contain:

libtcswigpy.la: $(libtcswigpy_la_OBJECTS) $(libtcswigpy_la_DEPENDENCIES) 
        $(CXXLINK) -rpath $(pyexecdir) $(libtcswigpy_la_LDFLAGS) 
$(libtcswigpy_la_OBJECTS) $(libtcswigpy_la_LIBADD) $(LIBS)

but CXXLINKS is:

CXXLINK = $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
        --mode=link $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) \
        $(LDFLAGS) -o $@

so I'm stuck with AM_LDFLAGS although I meant to escape from it.  Of
course I'll get rid of AM_LDFLAGS, but I'm not sure I was an outlaw
according to the documentation.

And shouldn't the LDFLAGS be last?  It is in CXXLINKS, but in the
command line.


Reply via email to