[openwrt/openwrt] tools/elfutils: remove header symlink between subdirectories
LEDE Commits
lede-commits at lists.infradead.org
Sun Jul 7 23:49:47 PDT 2024
robimarko pushed a commit to openwrt/openwrt.git, branch main:
https://git.openwrt.org/f9a1996367628d4e5a0849f58a2d29abb6b89bd5
commit f9a1996367628d4e5a0849f58a2d29abb6b89bd5
Author: Michael Pratt <mcpratt at pm.me>
AuthorDate: Wed May 15 19:43:00 2024 -0400
tools/elfutils: remove header symlink between subdirectories
Replace the symlink in the build recipe for gnulib
with an extra include path flag in CPPFLAGS to the lib subdirectory
so that it is the last in the order of include paths,
and use a quote escape to make the flag a literal string
in order to use Make variables within it.
The original reason this is necessary is because the config.h header
provided by the project at the top-level build directory
calls another header eu-config.h
which is stored in the lib subdirectory instead of the top-level,
and building the gnulib library requires the config.h header.
Signed-off-by: Michael Pratt <mcpratt at pm.me>
Link: https://github.com/openwrt/openwrt/pull/15853
Signed-off-by: Robert Marko <robimarko at gmail.com>
---
tools/elfutils/Makefile | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/tools/elfutils/Makefile b/tools/elfutils/Makefile
index 11a2ff7261..bbbb1da914 100644
--- a/tools/elfutils/Makefile
+++ b/tools/elfutils/Makefile
@@ -67,6 +67,8 @@ HOST_MAKE_FLAGS += \
REPLACE_FCNTL=0 REPLACE_FREE=0 REPLACE_FSTAT=0 REPLACE_OPEN=0 \
bin_PROGRAMS='$(PKG_PROGRAMS)' EXEEXT=
+HOST_CPPFLAGS += "'-I$$$$(top_srcdir)/lib'"
+
ifeq ($(HOST_OS),Darwin)
HOST_CFLAGS += -I/opt/homebrew/include
endif
@@ -99,7 +101,6 @@ HOST_CONFIGURE_VARS += \
Hooks/HostConfigure/Pre := Host/Gnulib $(Hooks/HostConfigure/Pre)
define Host/Gnulib
$(STAGING_DIR_HOST)/bin/gnulib-tool $(PKG_GNULIB_ARGS) $(PKG_GNULIB_MODS);
- ln -sf ../lib/eu-config.h $(HOST_BUILD_DIR)/libgnu/;
endef
define Host/Compile
More information about the lede-commits
mailing list