Bug 1269513 - Move --with-system-hunspell to Python configure. r=glandium
authorChris Manchester <cmanchester@mozilla.com>
Tue, 17 May 2016 14:40:03 -0700
changeset 297803 54f2a1fe535f2c623142c42401b38413c887d305
parent 297802 b465c1ff97c4cebb6f2ec13c323b993e51578c1d
child 297804 0852b1d540bf5d383dbef083b6d2a830638bfc3d
push id19274
push userryanvm@gmail.com
push dateWed, 18 May 2016 16:14:35 +0000
treeherderfx-team@4cfa7a2cefa7 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersglandium
bugs1269513
milestone49.0a1
Bug 1269513 - Move --with-system-hunspell to Python configure. r=glandium MozReview-Commit-ID: ERnnsr1hnpu
build/moz.configure/old.configure
moz.configure
old-configure.in
--- a/build/moz.configure/old.configure
+++ b/build/moz.configure/old.configure
@@ -243,17 +243,16 @@ def old_configure_options(*options):
     '--enable-startupcache',
     '--enable-stdcxx-compat',
     '--enable-strip',
     '--enable-synth-pico',
     '--enable-synth-speechd',
     '--enable-system-cairo',
     '--enable-system-extension-dirs',
     '--enable-system-ffi',
-    '--enable-system-hunspell',
     '--enable-system-pixman',
     '--enable-system-sqlite',
     '--enable-tasktracer',
     '--enable-tests',
     '--enable-thread-sanitizer',
     '--enable-trace-logging',
     '--enable-tree-freetype',
     '--enable-ui-locale',
--- a/moz.configure
+++ b/moz.configure
@@ -161,12 +161,23 @@ def extra_programs(target):
 
 check_prog('DSYMUTIL', delayed_getattr(extra_programs, 'DSYMUTIL'),
            allow_missing=True)
 check_prog('GENISOIMAGE', delayed_getattr(extra_programs, 'GENISOIMAGE'),
            allow_missing=True)
 check_prog('RPMBUILD', delayed_getattr(extra_programs, 'RPMBUILD'),
            allow_missing=True)
 
+option('--enable-system-hunspell',
+       help="Use system hunspell (located with pkgconfig)")
+
+@depends('--enable-system-hunspell', compile_environment)
+def check_for_hunspell(value, compile_env):
+    return value and compile_env
+
+system_hunspell = pkg_check_modules('MOZ_HUNSPELL', 'hunspell',
+                                    check_for_hunspell)
+
+set_config('MOZ_SYSTEM_HUNSPELL', system_hunspell)
 
 # Fallthrough to autoconf-based configure
 include('build/moz.configure/old.configure')
 # Please do not add anything after the include of old.configure.
--- a/old-configure.in
+++ b/old-configure.in
@@ -2625,30 +2625,16 @@ if test "$MOZ_SYSTEM_PNG" != 1 -a "$CPU_
     esac
 fi
 
 fi # SKIP_LIBRARY_CHECKS
 
 AC_SUBST(MOZ_PNG_ARM_NEON)
 
 dnl ========================================================
-dnl system HunSpell Support
-dnl ========================================================
-MOZ_ARG_ENABLE_BOOL(system-hunspell,
-[  --enable-system-hunspell
-                          Use system hunspell (located with pkgconfig)],
-    MOZ_SYSTEM_HUNSPELL=1 )
-
-if test -n "$MOZ_SYSTEM_HUNSPELL"; then
-    PKG_CHECK_MODULES(MOZ_HUNSPELL, hunspell)
-fi
-
-AC_SUBST(MOZ_SYSTEM_HUNSPELL)
-
-dnl ========================================================
 dnl system libffi Support
 dnl ========================================================
 MOZ_CONFIG_FFI()
 
 dnl ========================================================
 dnl =
 dnl = Application
 dnl =