automake
[Top][All Lists]
Advanced

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

Re: Changing library does *not* always cause executable to beremade with


From: Guido Draheim
Subject: Re: Changing library does *not* always cause executable to beremade with "make"!?!?..
Date: Wed, 07 May 2003 11:46:59 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; de-AT; rv:1.1) Gecko/20020826

zaufi schrieb:
Executable is only rebuilt if one of name_SOURCES files is changed.

This is a problem because modifying something in the

name_LDADD list does NOT cause executable to be remade?!?!?!


bin_PROGRAMS = name
name_SOURCES = ...
name_DEPENDENCIES = $(top_builddir)/path/libnoinst.a ...
name_LDADD = $(name_DEPENDENCIES)

The main trick is to explain to make how to rebuild noinst library in other than current directory.To do this I use the following in my admin/Makefile.deps (which is included in _EVERY_ Makefile.am's):


a very sophisticated trick that is, a simple one might be to
add the rebuild rule on every instance where a library is
linked that exists in the same configured tree:

name_LDADD = ../other/libthing.la

../other/libthing.la : ../other/*.c ../other/*.h
        cd ../other && $(MAKE) `basename address@hidden

that works with every automake version IYAM, if you can
live with it, you could even leave out the righthand deps
which will `make` to make a short step over into the other
build dir quickly returning without doing anything there.

cheers, guido
(p.s. dont feed trolling threads)





reply via email to

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