This is the mail archive of the automake@gnu.org mailing list for the automake project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: configure substitutions in generated Makefile


>>> "jk" == Kremp, Johannes <Johannes.Kremp@gedas.de> writes:

[...]

 jk> test_SOURCES = test.c
 jk> test_LDADD	 = $(LIBTEST)

[...]

 jk> but $(LIBTEST) doesn't appear in the generated Makefile in
 jk> test_DEPENDENCIES:

 jk> Makefile:
 jk> ...
 jk> am_test_OBJECTS = test.$(OBJEXT)
 jk> test_OBJECTS = $(am_test_OBJECTS)
 jk> test_DEPENDENCIES =
 jk> test_LDFLAGS =
 jk> ...

Automake is not able to guess that $(LIBTEST) will be a valid
dependency when it is run.  After all, $(LIBTEST) could has well
contain something like `-lfoo' which is valid for test_LDADD,
but not for test_SOURCES.

So you have to set test_DEPENDENCIES yourself, from your
Makefile.am:

 test_SOURCES = test.c
 test_LDADD = $(LIBTEST)
 test_DEPENDENCIES = $(LIBTEST)

[...]

-- 
Alexandre Duret-Lutz



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]