diff options
author | Masahiro Yamada <masahiroy@kernel.org> | 2020-05-19 16:13:45 +0900 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2020-05-20 13:16:56 +0200 |
commit | ff047395b9746aee1fe24e9c3f122c3706e72781 (patch) | |
tree | a8718b43f9d97c8bd0ad9a351ce23e35d5840851 /scripts | |
parent | c6aea1e9a377de5e67ce5c71d7487525af633a0b (diff) | |
download | barebox-ff047395b9746aee1fe24e9c3f122c3706e72781.tar.gz barebox-ff047395b9746aee1fe24e9c3f122c3706e72781.tar.xz |
kbuild: rename pbl object pbl-*.o to *.pbl.o
Currently, pbl objects are output to:
<directory-path>/pbl-<basename>.o
This commit changes as follows:
<directory-path>/<basename>.pbl.o
The motivation is not only to get rid of the ugly code introduced by
commit 257abdaa36c8 ("Do not rm the path from pbl-y target"), but also
to make it easier to remove obj-dtb-y, pbl-dtb-y, lwl-dtb-y syntax in
the next commit.
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/Makefile.build | 4 | ||||
-rw-r--r-- | scripts/Makefile.lib | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/scripts/Makefile.build b/scripts/Makefile.build index 0232158570..956df9e23a 100644 --- a/scripts/Makefile.build +++ b/scripts/Makefile.build @@ -158,7 +158,7 @@ endef # Built-in and composite module parts -pbl-%.o: %.c FORCE +%.pbl.o: %.c FORCE $(call cmd,force_checksrc) $(call if_changed_rule,pbl_cc_o_c) @@ -201,7 +201,7 @@ cmd_as_o_S = $(CC) $(a_flags) -c -o $@ $< quiet_cmd_pbl_as_o_S = PBLAS $@ cmd_pbl_as_o_S = $(CC) -D__PBL__ $(a_flags) $(PBL_CPPFLAGS) -c -o $@ $< -pbl-%.o: %.S FORCE +%.pbl.o: %.S FORCE $(call if_changed_dep,pbl_as_o_S) %.o: %.S FORCE diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib index 39cc24b196..273113ff5a 100644 --- a/scripts/Makefile.lib +++ b/scripts/Makefile.lib @@ -48,8 +48,8 @@ endif obj-y += $(obj-pbl-y) pbl-y += $(obj-pbl-y) -# add pbl- prefix to the target -pbl-y := $(shell echo $(pbl-y) | sed -e 's%\(\([^ \t]\+/\)*\)\([^ \t]*\.o\)%\2pbl-\3%g') +# pbl objects are suffixed with .pbl.o +pbl-y := $(patsubst %.o,%.pbl.o,$(pbl-y)) # add subdir from $(obj-y) too so we do not need to have the dir define in # both $(obj-y) and $(pbl-y) |