Bug 1269513 - Move --with-system-hunspell to Python configure. r=glandium
MozReview-Commit-ID: ERnnsr1hnpu
--- 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
@@ -2619,30 +2619,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 =