commit:     3295c1c8647c047dd22475665f30be0ce0b58aa7
Author:     Ian Stakenvicius <axs <AT> gentoo <DOT> org>
AuthorDate: Sun Nov 29 22:57:43 2015 +0000
Commit:     Ian Stakenvicius <axs <AT> gentoo <DOT> org>
CommitDate: Mon Nov 30 03:14:30 2015 +0000
URL:        https://gitweb.gentoo.org/proj/mozilla.git/commit/?id=3295c1c8

set --build=chost when not cross-compiling and set --host only when 
cross-compiling

 eclass/mozconfig-v6.42.eclass | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/eclass/mozconfig-v6.42.eclass b/eclass/mozconfig-v6.42.eclass
index ce5d26c..5a26067 100644
--- a/eclass/mozconfig-v6.42.eclass
+++ b/eclass/mozconfig-v6.42.eclass
@@ -249,7 +249,13 @@ mozconfig_config() {
        # of --build, and --target intstead of --host.
        # Note, mozilla also has --build but it does not do what you think it 
does.
        mozconfig_annotate '' --target="${CHOST}"
-       mozconfig_annotate '' --host="${CBUILD:-${CHOST}}"
+       if [[ "${CBUILD:-${CHOST}}" == "${CHOST}" ]]; then
+               # apply old --build setting when not cross-compiling
+               mozconfig_annotate '' --build="${CHOST}"
+       else
+               # set --host when cross-compiling as otherwise it won't 
subconfigure
+               mozconfig_annotate '' --host="${CBUILD:-${CHOST}}"
+       fi
 
        if use gstreamer ; then
                mozconfig_annotate '+gstreamer' --enable-gstreamer=1.0

Reply via email to