Abuse lua2c_LDFLAGS to pass the correct host cflags/ldflags when lua2c
is built for the host.
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
ifeq ($(BR2_PACKAGE_HASERL_WITH_LUA),y)
HASERL_CONF_OPT += --with-lua=$(STAGING_DIR) \
--with-lua-headers=$(STAGING_DIR)
- HASERL_DEPENDENCIES += lua
+ HASERL_DEPENDENCIES += lua host-lua
+ # lua2c is built for host, so needs to find host libs/headers
+ HASERL_MAKE_OPT += lua2c_LDFLAGS='$(HOST_CFLAGS) $(HOST_LDFLAGS)'
endif
define HASERL_REMOVE_EXAMPLES