sysvinit: Fix environment variables override bug.

As we have specified "-e MAKEFLAGS= " to make, environment
variables will override variables in the top makefile but not
subdir makefiles.

Current bb uses sysvinit-xxx/src as ${B}, the environment variable
CPPFLAGS would override all "CPPFLAGS" lines in
sysvinit-xxx/src/Makefile. Such as "CPPFLAGS+= -DACCTON_OFF",
"CPPFLAGS += $(SELINUX_DEF)" and "CPPFLAGS += -DINIT_MAIN".

This causes some sections(#ifdef INIT_MAIN/WITH_SELINUX ... #endif)
will never be used.
This commit is contained in:
Xin Ouyang 2012-04-27 16:04:13 +08:00
parent 4fcefe71fd
commit a435febae2

View File

@ -1,5 +1,7 @@
FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}-${PV}:"
B = "${S}"
SRC_URI += "file://sysvinit-fix-is_selinux_enabled.patch"
DEPENDS += "${@base_contains('DISTRO_FEATURES', 'selinux', 'libselinux', '', d)}"