Bug 1256512 - Move TARGET_CPU and TARGET_OS to moz.configure draft
authorMike Hommey <mh+mozilla@glandium.org>
Tue, 15 Mar 2016 10:14:09 +0900
changeset 340449 3472fb32d5d8b3d830ea86474f258cbbeaba873b
parent 340440 32d1b9f378be035704bf1c7c2b6ed1b39f05c081
child 340450 a0159169eb568e9442622819bbe5bec7189e8a4c
push id12965
push userbmo:mh+mozilla@glandium.org
push dateTue, 15 Mar 2016 08:56:33 +0000
bugs1256512
milestone48.0a1
Bug 1256512 - Move TARGET_CPU and TARGET_OS to moz.configure And remove the unused TARGET_VENDOR
build/moz.configure/init.configure
js/src/old-configure.in
old-configure.in
--- a/build/moz.configure/init.configure
+++ b/build/moz.configure/init.configure
@@ -399,16 +399,17 @@ def split_triplet(triplet):
         canonical_cpu = cpu
 
     return namespace(
         alias=triplet,
         cpu=canonical_cpu,
         kernel=canonical_kernel,
         os=canonical_os,
         raw_cpu=cpu,
+        raw_os=os,
     )
 
 
 @depends('--host', shell)
 @advanced
 def host(value, shell):
     if not value:
         import subprocess
@@ -461,16 +462,19 @@ def target_variables(target):
     set_config('OS_TEST', os_test)
 
     add_old_configure_assignment('CPU_ARCH', target.cpu)
     set_config('CPU_ARCH', target.cpu)
 
     if target.cpu in ('x86', 'x86_64'):
         set_config('INTEL_ARCHITECTURE', '1')
 
+    set_config('TARGET_CPU', target.raw_cpu)
+    set_config('TARGET_OS', target.raw_os)
+
 @depends(host)
 def host_variables(host):
     if host.kernel == 'kFreeBSD':
         os_arch = 'GNU_kFreeBSD'
     else:
         os_arch = host.kernel
     add_old_configure_assignment('HOST_OS_ARCH', os_arch)
     set_config('HOST_OS_ARCH', os_arch)
--- a/js/src/old-configure.in
+++ b/js/src/old-configure.in
@@ -6,19 +6,16 @@ dnl file, You can obtain one at http://m
 
 dnl Process this file with autoconf to produce a configure script.
 dnl ========================================================
 
 AC_PREREQ(2.13)
 AC_INIT(js/src/jsapi.h)
 AC_CONFIG_AUX_DIR(${srcdir}/build/autoconf)
 AC_CANONICAL_SYSTEM
-TARGET_CPU="${target_cpu}"
-TARGET_VENDOR="${target_vendor}"
-TARGET_OS="${target_os}"
 
 dnl ========================================================
 dnl =
 dnl = Don't change the following two lines.  Doing so breaks:
 dnl =
 dnl = CFLAGS="-foo" ./configure
 dnl =
 dnl ========================================================
@@ -2899,19 +2896,16 @@ AC_SUBST(HOST_CXXFLAGS)
 AC_SUBST(HOST_LDFLAGS)
 AC_SUBST(HOST_OPTIMIZE_FLAGS)
 AC_SUBST(HOST_AR)
 AC_SUBST(HOST_AR_FLAGS)
 AC_SUBST(HOST_LD)
 AC_SUBST(HOST_RANLIB)
 AC_SUBST(HOST_BIN_SUFFIX)
 
-AC_SUBST(TARGET_CPU)
-AC_SUBST(TARGET_VENDOR)
-AC_SUBST(TARGET_OS)
 AC_SUBST(TARGET_XPCOM_ABI)
 
 AC_SUBST(WRAP_LDFLAGS)
 AC_SUBST(MKSHLIB)
 AC_SUBST(MKCSHLIB)
 AC_SUBST(DSO_CFLAGS)
 AC_SUBST(DSO_PIC_CFLAGS)
 AC_SUBST(DSO_LDOPTS)
--- a/old-configure.in
+++ b/old-configure.in
@@ -6,19 +6,16 @@ dnl file, You can obtain one at http://m
 
 dnl Process this file with autoconf to produce a configure script.
 dnl ========================================================
 
 AC_PREREQ(2.13)
 AC_INIT(config/config.mk)
 AC_CONFIG_AUX_DIR(${srcdir}/build/autoconf)
 AC_CANONICAL_SYSTEM
-TARGET_CPU="${target_cpu}"
-TARGET_VENDOR="${target_vendor}"
-TARGET_OS="${target_os}"
 
 dnl ========================================================
 dnl =
 dnl = Don't change the following two lines.  Doing so breaks:
 dnl =
 dnl = CFLAGS="-foo" ./configure
 dnl =
 dnl ========================================================
@@ -8150,19 +8147,16 @@ AC_SUBST(HOST_OPTIMIZE_FLAGS)
 AC_SUBST(HOST_AR)
 AC_SUBST(HOST_AR_FLAGS)
 AC_SUBST(HOST_LD)
 AC_SUBST(HOST_RANLIB)
 AC_SUBST(HOST_BIN_SUFFIX)
 
 AC_SUBST(RUSTFLAGS)
 
-AC_SUBST(TARGET_CPU)
-AC_SUBST(TARGET_VENDOR)
-AC_SUBST(TARGET_OS)
 AC_SUBST(TARGET_XPCOM_ABI)
 AC_SUBST(HAVE_TOOLCHAIN_SUPPORT_MSSSE3)
 AC_SUBST(HAVE_TOOLCHAIN_SUPPORT_MSSE4_1)
 AC_SUBST(HAVE_X86_AVX2)
 AC_SUBST(GCC_USE_GNU_LD)
 
 AC_SUBST(MOZ_CHROME_FILE_FORMAT)