commit:     f79d4a8e09239e41136ea6879546699e269f3096
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: Thu Dec  3 00:21:22 2015 +0000
URL:        https://gitweb.gentoo.org/proj/mozilla.git/commit/?id=f79d4a8e

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