Bug 973143 - Move some variables to moz.build; r=glandium
--- a/configure.in
+++ b/configure.in
@@ -8613,16 +8613,21 @@ AC_SUBST(LIBJPEG_TURBO_X64_ASM)
AC_SUBST(LIBJPEG_TURBO_ARM_ASM)
AC_SUBST(MOZ_PACKAGE_JSSHELL)
AC_SUBST(MOZ_FOLD_LIBS)
AC_SUBST(MOZ_ENABLE_SZIP)
AC_SUBST(MOZ_SZIP_FLAGS)
+if test "$MOZ_DEBUG"; then
+ MOZ_EM_DEBUG=1
+fi
+AC_SUBST(MOZ_EM_DEBUG)
+
if test -n "$COMPILE_ENVIRONMENT"; then
AC_MSG_CHECKING([for posix_fallocate])
AC_TRY_LINK([#define _XOPEN_SOURCE 600
#include <fcntl.h>],
[posix_fallocate(0, 0, 0);],
[ac_cv___posix_fallocate=true],
[ac_cv___posix_fallocate=false])
deleted file mode 100644
--- a/dom/apps/src/Makefile.in
+++ /dev/null
@@ -1,7 +0,0 @@
-# This Source Code Form is subject to the terms of the Mozilla Public
-# 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/.
-
-ifdef MOZ_DEBUG
- DEFINES += -DMOZ_DEBUG=1
-endif
--- a/dom/apps/src/Webapps.jsm
+++ b/dom/apps/src/Webapps.jsm
@@ -50,17 +50,17 @@ Cu.import("resource://gre/modules/Promis
#ifdef MOZ_WIDGET_GONK
XPCOMUtils.defineLazyGetter(this, "libcutils", function() {
Cu.import("resource://gre/modules/systemlibs.js");
return libcutils;
});
#endif
function debug(aMsg) {
-#ifdef MOZ_DEBUG
+#ifdef DEBUG
dump("-*- Webapps.jsm : " + aMsg + "\n");
#endif
}
function getNSPRErrorCode(err) {
return -1 * ((err) & 0xffff);
}
--- a/gfx/cairo/libpixman/src/Makefile.in
+++ b/gfx/cairo/libpixman/src/Makefile.in
@@ -60,39 +60,17 @@ ifdef HAVE_ARM_NEON
USE_ARM_NEON_GCC=1
endif
endif
endif
endif
-ifdef USE_MMX
-CSRCS += pixman-mmx.c
-DEFINES += -DUSE_MMX
-endif
-
-ifdef USE_SSE2
-CSRCS += pixman-sse2.c
-DEFINES += -DUSE_SSE -DUSE_SSE2
-endif
-
-ifdef USE_VMX
-CSRCS += pixman-vmx.c
-DEFINES += -DUSE_VMX
-endif
-
-ifdef USE_ARM_SIMD_GCC
-CSRCS += pixman-arm-simd.c
-DEFINES += -DUSE_ARM_SIMD
-endif
-
ifdef USE_ARM_NEON_GCC
-CSRCS += pixman-arm-neon.c
-DEFINES += -DUSE_ARM_NEON
ARM_NEON_CFLAGS = -mfpu=neon
endif
include $(topsrcdir)/config/rules.mk
# Disable spammy "missing initializer" GCC warning
ifdef GNU_CC
CFLAGS += -Wno-missing-field-initializers
--- a/gfx/cairo/libpixman/src/moz.build
+++ b/gfx/cairo/libpixman/src/moz.build
@@ -70,8 +70,29 @@ if CONFIG['MOZ_USE_PTHREADS']:
DEFINES['HAVE_PTHREAD_SETSPECIFIC'] = True
if CONFIG['_MSC_VER']:
DEFINES['PIXMAN_USE_XP_DLL_TLS_WORKAROUND'] = True
DEFINES['PACKAGE'] = 'mozpixman'
DEFINES['_USE_MATH_DEFINES'] = True
+
+if CONFIG['USE_MMX']:
+ DEFINES['USE_MMX'] = True
+ SOURCES += ['pixman-mmx.c']
+
+if CONFIG['USE_SSE2']:
+ DEFINES['USE_SSE'] = True
+ DEFINES['USE_SSE2'] = True
+ SOURCES += ['pixman-sse2.c']
+
+if CONFIG['USE_VMX']:
+ DEFINES['USE_VMX'] = True
+ SOURCES += ['pixman-vmx.c']
+
+if CONFIG['USE_ARM_SIMD_GCC']:
+ DEFINES['USE_ARM_SIMD'] = True
+ SOURCES += ['pixman-arm-simd.c']
+
+if CONFIG['USE_ARM_NEON_GCC']:
+ DEFINES['USE_ARM_NEON'] = True
+ SOURCES += ['pixman-arm-neon.c']
--- a/js/src/Makefile.in
+++ b/js/src/Makefile.in
@@ -198,21 +198,16 @@ DIST_GARBAGE = config.cache config.log c
backend.mk config/backend.mk devtools/backend.mk editline/backend.mk \
gdb/backend.mk jsapi-tests/backend.mk shell/backend.mk tests/backend.mk \
backend.RecursiveMakeBackend backend.RecursiveMakeBackend.pp \
devtools/rootAnalysis/Makefile
distclean::
$(RM) $(DIST_GARBAGE)
-ifneq (,$(filter WINNT,$(OS_ARCH)))
-# _CRT_RAND_S must be #defined before #including stdlib.h to get rand_s()
-DEFINES += -D_CRT_RAND_S
-endif
-
ifneq ($(findstring -L,$(NSPR_LIBS)),)
NSPR_STATIC_PATH = $(subst -L,,$(findstring -L,$(NSPR_LIBS)))
else
NSPR_STATIC_PATH = $(DIST)/lib
endif
# HP-UX does not require the extra linking of "-lm"
ifeq (,$(filter HP-UX WINNT,$(OS_ARCH)))
--- a/js/src/moz.build
+++ b/js/src/moz.build
@@ -338,16 +338,18 @@ if CONFIG['ENABLE_ION']:
'jit/arm/Simulator-arm.cpp'
]
if CONFIG['OS_ARCH'] == 'WINNT':
SOURCES += [
'assembler/jit/ExecutableAllocatorWin.cpp',
'yarr/OSAllocatorWin.cpp',
]
+ # _CRT_RAND_S must be #defined before #including stdlib.h to get rand_s()
+ DEFINES['_CRT_RAND_S'] = True
else:
SOURCES += [
'assembler/jit/ExecutableAllocatorPosix.cpp',
'yarr/OSAllocatorPosix.cpp',
]
if CONFIG['ENABLE_ION'] or CONFIG['ENABLE_YARR_JIT']:
if CONFIG['JS_CODEGEN_X86'] or CONFIG['JS_CODEGEN_X64']:
deleted file mode 100644
--- a/toolkit/mozapps/extensions/Makefile.in
+++ /dev/null
@@ -1,9 +0,0 @@
-# This Source Code Form is subject to the terms of the Mozilla Public
-# 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/.
-
-# Additional debugging info is exposed by setting the MOZ_EM_DEBUG
-# environment variable when building.
-ifneq (,$(MOZ_EM_DEBUG))
-DEFINES += -DMOZ_EM_DEBUG=1
-endif
--- a/toolkit/mozapps/extensions/moz.build
+++ b/toolkit/mozapps/extensions/moz.build
@@ -48,12 +48,12 @@ EXTRA_PP_JS_MODULES += [
if CONFIG['MOZ_UPDATE_CHANNEL'] not in ('aurora', 'beta', 'release', 'esr'):
DEFINES['MOZ_COMPATIBILITY_NIGHTLY'] = 1
# This is used in multiple places, so is defined here to avoid it getting
# out of sync.
DEFINES['MOZ_EXTENSIONS_DB_SCHEMA'] = 16
# Additional debugging info is exposed in debug builds
-if CONFIG['MOZ_DEBUG']:
+if CONFIG['MOZ_EM_DEBUG']:
DEFINES['MOZ_EM_DEBUG'] = 1
-JAR_MANIFESTS += ['jar.mn']
\ No newline at end of file
+JAR_MANIFESTS += ['jar.mn']