[oe-commits] [meta-openembedded] 40/43: mozjs: customize HOST_CFLAGS

git at git.openembedded.org git at git.openembedded.org
Tue Aug 22 13:40:03 UTC 2017


This is an automated email from the git hooks/post-receive script.

martin_jansa pushed a commit to branch master-next
in repository meta-openembedded.

commit adf91f4f311298fae319b3e0f5d2436ebecb7a03
Author: Mingli Yu <Mingli.Yu at windriver.com>
AuthorDate: Tue Aug 22 15:02:58 2017 +0800

    mozjs: customize HOST_CFLAGS
    
    Customize HOST_CFLAGS, HOST_CXXFLAGS and HOST_LDFLAGS
    to fix do_configure error as previously use the common
    CFLAGS and CXXFLAGS in both cross-compile env and host env,
    and the option -fstack-protector-strong which not
    recognized in host env can result in do_configure
    error as below.
    
    | checking whether the host c compiler (gcc -O2 -pipe -g -fstack-protector-strong -D_FORTIFY_SOURCE=2 -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -fstack-protector-strong -Wl,-z,relro,-z,now) works... configure: error: installation or configuration problem: host compiler gcc cannot create executables.
    
    Signed-off-by: Mingli Yu <Mingli.Yu at windriver.com>
    Signed-off-by: Jackie Huang <jackie.huang at windriver.com>
    Signed-off-by: Martin Jansa <Martin.Jansa at gmail.com>
---
 meta-oe/recipes-extended/mozjs/mozjs_17.0.0.bb | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/meta-oe/recipes-extended/mozjs/mozjs_17.0.0.bb b/meta-oe/recipes-extended/mozjs/mozjs_17.0.0.bb
index b674439..b72ee7b 100644
--- a/meta-oe/recipes-extended/mozjs/mozjs_17.0.0.bb
+++ b/meta-oe/recipes-extended/mozjs/mozjs_17.0.0.bb
@@ -51,6 +51,9 @@ PACKAGECONFIG[x11] = "--with-x --x-includes=${STAGING_INCDIR} --x-libraries=${ST
 
 # mozjs requires autoreconf 2.13
 do_configure() {
+    export HOST_CFLAGS="${BUILD_CFLAGS}"
+    export HOST_CXXFLAGS="${BUILD_CPPFLAGS}"
+    export HOST_LDFLAGS="${BUILD_LDFLAGS}"
     ( cd ${S}
       gnu-configize --force
       mv config.guess config.sub build/autoconf )

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list