[1/1] sudo: set CFLAGS for build mksigname and mksiglist

Submitted by Kang Kai on May 21, 2013, 9:11 a.m. | Patch ID: 50229


Message ID 16a1824f8161704b485873e5534b17fdc03f5ab1.1369124512.git.kai.kang@windriver.com
State Accepted
Commit 6022e81570b80232f272a1aa474e8ced3a089382
Headers show

Commit Message

Kang Kai May 21, 2013, 9:11 a.m.
mksigname and mksiglist are compiled by BUILD_CC for build host. When
there are some options in CFLAGS that BUILD_CC doesn't support,
compilation fails.

Build for arm on a x86 host, if option "-mapcs-frame" is provided, error
occurs with:

| cc1: error: unrecognized command line option "-mapcs-frame"

Pass BUILD_CFLAGS to CFLAGS to fix that kind of failure.

Signed-off-by: Kang Kai <kai.kang@windriver.com>
 meta/recipes-extended/sudo/sudo.inc |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

Patch hide | download patch | download mbox

diff --git a/meta/recipes-extended/sudo/sudo.inc b/meta/recipes-extended/sudo/sudo.inc
index 35da367..9dcb677 100644
--- a/meta/recipes-extended/sudo/sudo.inc
+++ b/meta/recipes-extended/sudo/sudo.inc
@@ -23,7 +23,7 @@  do_configure_prepend () {
 # mksigname/mksiglist are used on build host to generate source files
 do_compile_prepend () {
-	oe_runmake SSP_CFLAGS="" SSP_LDFLAGS="" CC=$BUILD_CC CPPFLAGS="$BUILD_CPPFLAGS -I${S}/include -I${S} -I${B}"  -C compat mksigname mksiglist
+	oe_runmake SSP_CFLAGS="" SSP_LDFLAGS="" CC=$BUILD_CC CFLAGS="$BUILD_CFLAGS" CPPFLAGS="$BUILD_CPPFLAGS -I${S}/include -I${S} -I${B}"  -C compat mksigname mksiglist
 # Explicitly create ${localstatedir}/lib before do_install to ensure