]> git.ipfire.org Git - thirdparty/ipxe.git/commitdiff
[build] Accept EMBED=... as a synonym for EMBEDDED_IMAGE=...
authorMichael Brown <mcb30@ipxe.org>
Thu, 28 Apr 2011 10:56:27 +0000 (11:56 +0100)
committerMichael Brown <mcb30@ipxe.org>
Thu, 28 Apr 2011 10:56:27 +0000 (11:56 +0100)
Make the build command line less cumbersome by accepting

  make DEBUG=int13 EMBED=test.ipxe

rather then

  make DEBUG=int13 EMBEDDED_IMAGE=test.ipxe

Signed-off-by: Michael Brown <mcb30@ipxe.org>
src/Makefile.housekeeping

index b05aedd69e69b1c1ec3d0af1947bd2733c659f26..06f9e7aeece24ff4488949a3d779727aeaef4374 100644 (file)
@@ -601,21 +601,22 @@ roms :
 # This is needed in order to correctly rebuild embedded.o whenever the
 # list of objects changes.
 #
+EMBED          := $(EMBEDDED_IMAGE) # Maintain backwards compatibility
 EMBEDDED_LIST  := $(BIN)/.embedded.list
 ifeq ($(wildcard $(EMBEDDED_LIST)),)
-EMBEDDED_IMAGE_OLD := <invalid>
+EMBED_OLD := <invalid>
 else
-EMBEDDED_IMAGE_OLD := $(shell cat $(EMBEDDED_LIST))
+EMBED_OLD := $(shell cat $(EMBEDDED_LIST))
 endif
-ifneq ($(EMBEDDED_IMAGE_OLD),$(EMBEDDED_IMAGE))
-$(shell $(ECHO) "$(EMBEDDED_IMAGE)" > $(EMBEDDED_LIST))
+ifneq ($(EMBED_OLD),$(EMBED))
+$(shell $(ECHO) "$(EMBED)" > $(EMBEDDED_LIST))
 endif
 
 $(EMBEDDED_LIST) :
 
 VERYCLEANUP    += $(EMBEDDED_LIST)
 
-EMBEDDED_FILES := $(subst $(COMMA), ,$(EMBEDDED_IMAGE))
+EMBEDDED_FILES := $(subst $(COMMA), ,$(EMBED))
 EMBED_ALL      := $(foreach i,$(call seq,1,$(words $(EMBEDDED_FILES))),\
                     EMBED ( $(i), \"$(word $(i), $(EMBEDDED_FILES))\",\
                             \"$(notdir $(word $(i),$(EMBEDDED_FILES)))\" ))