Bug 1412983 - part 3 - move stlport_cppflags prior to extra_toolchain_flags; r=ted.mielczarek
authorNathan Froyd <froydnj@mozilla.com>
Wed, 15 Nov 2017 10:12:23 -0500
changeset 392000 776266640ecada42623596ad6ef5c0b203eaae2e
parent 391999 0fb376428333495e7958c16c1ad4a977aef4f7d2
child 392001 9615a90cf9b030ea72fdc1dd0f42bfa2348aae68
push id32909
push usercbrindusan@mozilla.com
push dateWed, 15 Nov 2017 22:25:14 +0000
treeherdermozilla-central@f41930a869a8 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersted.mielczarek
bugs1412983
milestone59.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1412983 - part 3 - move stlport_cppflags prior to extra_toolchain_flags; r=ted.mielczarek extra_toolchain_flags is going to depend on stlport_cppflags momentarily, so this commit is just for moving code around. Note that the diff shows other things moving *after* stlport_cppflags.
build/moz.configure/android-ndk.configure
--- a/build/moz.configure/android-ndk.configure
+++ b/build/moz.configure/android-ndk.configure
@@ -193,35 +193,16 @@ set_config('ANDROID_TOOLCHAIN', android_
 def android_toolchain_prefix_base(target):
     if target.cpu == 'x86':
         # Ideally, the --target should just have the right x86 variant
         # in the first place.
         return 'i686-linux-android'
     return target.toolchain
 
 
-@depends(android_platform, android_toolchain)
-def extra_toolchain_flags(platform_dir, toolchain_dir):
-    if not platform_dir:
-        return []
-    return ['-isystem',
-            os.path.join(platform_dir, 'usr', 'include'),
-            '-gcc-toolchain',
-            toolchain_dir]
-
-
-@depends(android_toolchain_prefix_base, android_toolchain)
-def android_toolchain_prefix(prefix_base, toolchain):
-    if toolchain:
-        return '%s/bin/%s-' % (toolchain, prefix_base)
-
-
-imply_option('--with-toolchain-prefix', android_toolchain_prefix,
-             reason='--with-android-ndk')
-
 option(env='STLPORT_CPPFLAGS',
        nargs=1,
        help='Options compiler should pass for standard C++ library')
 
 
 @depends('STLPORT_CPPFLAGS', ndk, '--help')
 @imports(_from='os.path', _import='isdir')
 def stlport_cppflags(value, ndk, _):
@@ -255,16 +236,36 @@ def stlport_cppflags(value, ndk, _):
         '-I%s' % cxx_include,
         '-I%s' % os.path.join(ndk, 'sources', 'android', 'support', 'include'),
         '-I%s' % cxxabi_include]
 
 
 add_old_configure_assignment('stlport_cppflags', stlport_cppflags)
 
 
+@depends(android_platform, android_toolchain)
+def extra_toolchain_flags(platform_dir, toolchain_dir):
+    if not platform_dir:
+        return []
+    return ['-isystem',
+            os.path.join(platform_dir, 'usr', 'include'),
+            '-gcc-toolchain',
+            toolchain_dir]
+
+
+@depends(android_toolchain_prefix_base, android_toolchain)
+def android_toolchain_prefix(prefix_base, toolchain):
+    if toolchain:
+        return '%s/bin/%s-' % (toolchain, prefix_base)
+
+
+imply_option('--with-toolchain-prefix', android_toolchain_prefix,
+             reason='--with-android-ndk')
+
+
 @depends(stlport_cppflags, extra_toolchain_flags, android_toolchain,
          android_toolchain_prefix_base, '--help')
 @imports(_from='os.path', _import='isdir')
 def bindgen_cflags_defaults(stlport_cppflags, toolchain_flags,
                             toolchain, toolchain_prefix, _):
     if not stlport_cppflags:
         return