firmware build: Fix build failure when using CONFIG_EXTRA_FIRMWARE with seperate output dir.
PATCH 1/1 firmware build: Fix build failure when using CONFIG_EXTRA_FIRMWARE with seperate output dir.
When building with a seperate output directory (O=) andCONFIG_EXTRA_FIRMWARE the build failed with
firmware/3com/typhoon.bin.gen.S: Assembler messages:
firmware/3com/typhoon.bin.gen.S:5: Error: file not found: /home/linux_src/firmware/3com/typhoon.bin
Because the generated binary is in the $(objdir) but the generated .S file tries to reference it in the $(srcdir)
Signed-off-by Martin Fuzzey <[email protected]>
--- firmware/Makefile | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
firmware/Makefile +1 -1
@@ -5,7 +5,7 @@ # Create $(fwabs) from $(CONFIG_EXTRA_FIRMWARE_DIR) -- if it doesn't have a # leading /, it's relative to $(srctree). fwdir := $(subst ",,$(CONFIG_EXTRA_FIRMWARE_DIR)) -fwabs := $(addprefix $(srctree)/,$(filter-out /%,$(fwdir)))$(filter /%,$(fwdir)) +fwabs := $(addprefix $(objtree)/,$(filter-out /%,$(fwdir)))$(filter /%,$(fwdir)) fw-external-y := $(subst ",,$(CONFIG_EXTRA_FIRMWARE))