]> git.ipfire.org Git - thirdparty/ipxe.git/commitdiff
[build] Run parserom.pl only on potential driver files
authorMichael Brown <mcb30@ipxe.org>
Sat, 9 Apr 2011 22:34:34 +0000 (23:34 +0100)
committerMichael Brown <mcb30@ipxe.org>
Sat, 9 Apr 2011 22:41:45 +0000 (23:41 +0100)
PCI_ROM() and ISA_ROM() macros occur only within driver files.
Running parserom.pl on non-driver files is therefore redundant.

Skip running parserom.pl on any files outside a "drivers" directory.
This reduces the time taken to generate build rules and dependencies
after a "make veryclean" by around 12%.

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

index ba01f16d5682edfc7fe095b658929b9695bc4805..b05aedd69e69b1c1ec3d0af1947bd2733c659f26 100644 (file)
@@ -549,7 +549,8 @@ define rules_template
                    '\n$(TGT)_OBJS += $$(BIN)/$(3).$(TGT)\n' ) ) \
                 '\n$(BIN)/deps/$(1).d : $$($(3)_DEPS)\n' \
                 '\nTAGS : $$($(3)_DEPS)\n' > $(BIN)/rules/$(1).r
-       @$(PERL) $(PARSEROM) $(1) >> $(BIN)/rules/$(1).r
+       @$(if $(findstring drivers/,$(1)),\
+          $(PERL) $(PARSEROM) $(1) >> $(BIN)/rules/$(1).r)
 endef
 
 # Rule to generate the dependency list file