[Top][All Lists]

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

Makefile problem: Up to date, when it really isn't

From: Peter Belm
Subject: Makefile problem: Up to date, when it really isn't
Date: Fri, 2 Oct 2009 12:45:08 +0100

I'm writing a makefile to group together a few tools for an embedded project I'm working on, one of these tools 'mburn' (the flasher) is causing me some problems (although I'm not sure the problem lies in that project).

The overall layout of my project is as follows:


In the root makefile I have this target:

    $(MAKE) -s -C $(WORKROOT)/mburn

And the mburn makefile contains:

CFLAGS += -Wall -O2

WRT54GMEMOBJS = wrt54g.o

all: wrt54g

wrt54g: $(WRT54GMEMOBJS)
    gcc $(CFLAGS) -o $@ $(WRT54GMEMOBJS)

    rm -rf *.o wrt54g

If I run "make" in the mburn directory it tries to compile (it fails because it's broken), but if I make sure there's no .o files and no binary, then run "make mburn" in the top directory, it says "make: `mburn' is up to date.". Which it clearly isn't if it doesn't have the binary file.

Any ideas?
Peter Belm

reply via email to

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