From 75091d42e175320b10ce4d341027c193ddeb4b66 Mon Sep 17 00:00:00 2001 From: Florian Fainelli Date: Sun, 2 Apr 2017 14:17:33 -0700 Subject: [PATCH] haproxy: Pass down TARGET_CPPFLAGS for lua build Some external toolchaind don't automatically search for headers in $(STAGING_DIR), make sure we do pass TARGET_CPPFLAGS as appropriate. This fixes build errors such as: mipsel-linux-gnu-gcc -O2 -Wall -Wextra -DLUA_COMPAT_5_2 -DLUA_USE_LINUX -c -o lua.o lua.c lua.c:80:31: fatal error: readline/readline.h: No such file or directory #include ^ compilation terminated. : recipe for target 'lua.o' failed make[6]: *** [lua.o] Error 1 Signed-off-by: Florian Fainelli --- net/haproxy/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/net/haproxy/Makefile b/net/haproxy/Makefile index d8bd4b9f7..86423da66 100644 --- a/net/haproxy/Makefile +++ b/net/haproxy/Makefile @@ -111,6 +111,7 @@ define Build/Compile $(MAKE) TARGET=$(LINUX_TARGET) -C $(PKG_BUILD_DIR)/lua \ INSTALL_TOP="$(STAGING_DIR)/lua-5.3.3/" \ CC="$(TARGET_CC)" \ + CFLAGS="$(TARGET_CFLAGS) $(TARGET_CPPFLAGS)" \ LDFLAGS="$(TARGET_LDFLAGS) -lncurses -lreadline" \ LD="$(TARGET_LD)" \ linux install