Bug 1309015 - Move MOZ_BUNDLED_FONTS to Python configure.
MozReview-Commit-ID: AG9tzi445P9
--- a/browser/confvars.sh
+++ b/browser/confvars.sh
@@ -3,21 +3,16 @@
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
MOZ_APP_BASENAME=Firefox
MOZ_APP_VENDOR=Mozilla
MOZ_UPDATER=1
MOZ_PHOENIX=1
-if test "$OS_ARCH" = "WINNT" -o \
- "$OS_ARCH" = "Linux"; then
- MOZ_BUNDLED_FONTS=1
-fi
-
# Enable building ./signmar and running libmar signature tests
MOZ_ENABLE_SIGNMAR=1
MOZ_APP_VERSION=$FIREFOX_VERSION
MOZ_APP_VERSION_DISPLAY=$FIREFOX_VERSION_DISPLAY
MOZ_EXTENSIONS_DEFAULT=" gio"
# MOZ_APP_DISPLAYNAME will be set by branding/configure.sh
# MOZ_BRANDING_DIRECTORY is the default branding directory used when none is
--- a/browser/moz.configure
+++ b/browser/moz.configure
@@ -25,9 +25,27 @@ def stub_installer(target, have_64_bit,
not have_64_bit,
not debug,
update_channel in ('nightly', 'aurora', 'beta',
'beta-dev', 'release', 'release-dev')]):
return True
set_config('MOZ_STUB_INSTALLER', stub_installer)
+@depends(target)
+def windows_or_linux(target):
+ if target.os in ('WINNT', 'GNU'):
+ return True
+
+imply_option('--enable-bundled-fonts', windows_or_linux,
+ reason='target')
+
+# Bundled fonts on desktop platforms
+# ========================================================
+option('--enable-bundled-fonts',
+ env='MOZ_BUNDLED_FONTS',
+ help='Enable support for bundled fonts on desktop platforms')
+
+bundled_fonts = depends_if('--enable-bundled-fonts')(lambda _: True)
+
+set_define('MOZ_BUNDLED_FONTS', bundled_fonts)
+
include('../toolkit/moz.configure')
--- a/build/moz.configure/old.configure
+++ b/build/moz.configure/old.configure
@@ -158,17 +158,16 @@ def old_configure_options(*options):
'--datadir',
'--enable-accessibility',
'--enable-address-sanitizer',
'--enable-alsa',
'--enable-android-omx',
'--enable-b2g-bt',
'--enable-b2g-camera',
'--enable-b2g-ril',
- '--enable-bundled-fonts',
'--enable-clang-plugin',
'--enable-content-sandbox',
'--enable-cookies',
'--enable-cpp-rtti',
'--enable-crashreporter',
'--enable-dbus',
'--enable-debug-js-modules',
'--enable-directshow',
--- a/old-configure.in
+++ b/old-configure.in
@@ -3890,29 +3890,16 @@ if test -n "$MOZ_TREE_FREETYPE"; then
AC_DEFINE(HAVE_FT_LOAD_SFNT_TABLE)
AC_SUBST_LIST(CAIRO_FT_CFLAGS)
fi
AC_CHECK_PROGS(WGET, wget, "")
AC_SUBST(WGET)
dnl ========================================================
-dnl Bundled fonts on desktop platforms
-dnl ========================================================
-
-MOZ_ARG_ENABLE_BOOL(bundled-fonts,
-[ --enable-bundled-fonts Enable support for bundled fonts on desktop platforms],
- MOZ_BUNDLED_FONTS=1,
- MOZ_BUNDLED_FONTS=)
-
-if test -n "$MOZ_BUNDLED_FONTS"; then
- AC_DEFINE(MOZ_BUNDLED_FONTS)
-fi
-
-dnl ========================================================
dnl Verify MAR signatures
dnl ========================================================
MOZ_ARG_ENABLE_BOOL(verify-mar,
[ --enable-verify-mar Enable verifying MAR signatures],
MOZ_VERIFY_MAR_SIGNATURE=1,
MOZ_VERIFY_MAR_SIGNATURE= )