[PATCH] Explicitly use BUILD_CC and TARGET_CC

Jeremy Kerr jk at ozlabs.org
Tue Aug 19 10:40:16 EDT 2008


> That should be fine: we just add a rule for %.o: %.S

OK, that's not going to work, because rules of the form

 list: pattern: prereq

*require* the prereqs to be build. ie, in our case:

 $(PURGATORY_OBJS): %.o: %.S

will require a .S for all .o files in PURGATORY_OBJS. Which is not what 
we want :(

So, the solution left would be to override COMPILE.c, COMPILE.S and 
LINK.o for target and build compiles. For example:

$(PURGATORY_OBJS): COMPILE.c = $(TARGET_CC) $(TARGET_CFLAGS) \
                               $(TARGET_CPPFLAGS) -c

It's unlikely that a user is going to override COMPILE.c on the make 
command-line :)

How does that sound?

Cheers,


Jeremy



More information about the kexec mailing list