diff options
author | Michael Olbrich <m.olbrich@pengutronix.de> | 2020-08-27 10:10:41 +0200 |
---|---|---|
committer | Michael Olbrich <m.olbrich@pengutronix.de> | 2020-08-27 16:37:01 +0200 |
commit | 22c9cb5f8fa4d7cc8b28aa1db8d78348d0462273 (patch) | |
tree | 436e40ee7f1417c252fc5b9547e893e63b7cc8e2 | |
parent | 37e5c5918e12b85a93070b907ce3ed376b0fce82 (diff) | |
download | OSELAS.Toolchain-22c9cb5f8fa4d7cc8b28aa1db8d78348d0462273.tar.gz OSELAS.Toolchain-22c9cb5f8fa4d7cc8b28aa1db8d78348d0462273.tar.xz |
cross-gcc: really remove the sysroot path in statx.h
The $(wildcard ) does not work here: It is evaluated when the target starts
to execute. At that point the file does not exist yet.
So explicitly check if the file exists in shell code.
Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
-rw-r--r-- | rules/cross-gcc.make | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/rules/cross-gcc.make b/rules/cross-gcc.make index 9a3c90d..4faa421 100644 --- a/rules/cross-gcc.make +++ b/rules/cross-gcc.make @@ -182,8 +182,11 @@ $(STATEDIR)/cross-gcc.install: $(STATEDIR)/cross-gcc.report @find $(CROSS_GCC_PKGDIR) -name "*.la" -print0 | xargs -0 rm -v -f ifneq ($(call remove_quotes,$(PTXDIST_SYSROOT_CROSS)),) sed -i -e 's;$(call remove_quotes,$(PTXDIST_SYSROOT_CROSS));;' \ - $(CROSS_GCC_PKGDIR)$(PTXCONF_PREFIX_CROSS)/lib/gcc/$(PTXCONF_GNU_TARGET)/$(CROSS_GCC_VERSION)/install-tools/mkheaders.conf \ - $(wildcard $(CROSS_GCC_PKGDIR)$(PTXCONF_PREFIX_CROSS)/lib/gcc/$(PTXCONF_GNU_TARGET)/$(CROSS_GCC_VERSION)/include-fixed/bits/statx.h) + $(CROSS_GCC_PKGDIR)$(PTXCONF_PREFIX_CROSS)/lib/gcc/$(PTXCONF_GNU_TARGET)/$(CROSS_GCC_VERSION)/install-tools/mkheaders.conf + if [ -e $(CROSS_GCC_PKGDIR)$(PTXCONF_PREFIX_CROSS)/lib/gcc/$(PTXCONF_GNU_TARGET)/$(CROSS_GCC_VERSION)/include-fixed/bits/statx.h ]; then \ + sed -i -e 's;$(call remove_quotes,$(PTXDIST_SYSROOT_CROSS));;' \ + $(CROSS_GCC_PKGDIR)$(PTXCONF_PREFIX_CROSS)/lib/gcc/$(PTXCONF_GNU_TARGET)/$(CROSS_GCC_VERSION)/include-fixed/bits/statx.h; \ + fi endif @$(call touch) |