help-make
[Top][All Lists]
Advanced

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

Repost: Updating local makefile


From: Tristan Van Berkom
Subject: Repost: Updating local makefile
Date: Fri, 06 Feb 2004 13:11:54 -0500
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2.1) Gecko/20030225

Tristan Van Berkom wrote:
[snip]
 From what I understand from reading the docs at gnu.org/manual
is that if I provide a rule to update a makefile (a makefile that
is /used/) then it should be updated before any other targets.


To test this rule without my entire build environment,
I used a makefile like this:
####################################################
all:
    @echo "Thats all she wrote"

$(CURDIR)/Makefile:$(CURDIR)/globalconfig/Makefile
        @echo -n "Updating address@hidden "
        @cp -f $< $@
        @echo "Done."

# XXX This line fixes it, but I don't think I should need it
#all:$(CURDIR)/Makefile

####################################################

My apolagies for the repost,
    but I would really like to know if this is a bug in GNU Make
or if this is the expected behaviour.

Must I go about this using relative paths/vpaths and pattern rules ?


Best regards,
                     -Tristan

PS:
    If its unclear, the problem is; when invoking the afore mentioned
makefile with `make all'; `Makefile' doesn't get updated first when
the Makefile in $(CURDIR)/globalconfig is "new".

This is reproducable with GNU Make 3.79






reply via email to

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