Bug 857526 - Check webrtc target arch right after checking target OS, instead of after AC_OUTPUT, which is too late. r=ted, a=akeybl
Bug 857526 - Check webrtc target arch right after checking target OS, instead of after AC_OUTPUT, which is too late. r=ted, a=akeybl
--- a/configure.in
+++ b/configure.in
@@ -5217,16 +5217,41 @@ if test -n "$MOZ_WEBRTC"; then
;;
*)
dnl default to disabled for all others
MOZ_WEBRTC=
;;
esac
fi
+# target_arch is from {ia32|x64|arm|ppc}
+case "$CPU_ARCH" in
+x86_64 | ia64)
+ WEBRTC_TARGET_ARCH=x64
+ ;;
+
+arm*)
+ WEBRTC_TARGET_ARCH=arm
+ ;;
+
+x86)
+ WEBRTC_TARGET_ARCH=ia32
+ ;;
+
+ppc*)
+ WEBRTC_TARGET_ARCH=ppc
+ ;;
+*)
+# unsupported arch for webrtc
+ WEBRTC_TARGET_ARCH=unknown
+ MOZ_WEBRTC=
+ ;;
+
+esac
+
dnl ========================================================
dnl = Disable WebRTC code
dnl ========================================================
MOZ_ARG_DISABLE_BOOL(webrtc,
[ --disable-webrtc Disable support for WebRTC],
MOZ_WEBRTC=,
MOZ_WEBRTC=1)
@@ -8933,38 +8958,16 @@ dnl Load the list of Makefiles to genera
dnl To add new Makefiles, edit allmakefiles.sh.
dnl allmakefiles.sh sets the variable, MAKEFILES.
. ${srcdir}/allmakefiles.sh
echo $MAKEFILES > unallmakefiles
AC_OUTPUT($MAKEFILES)
-# target_arch is from {ia32|x64|arm}
-case "$CPU_ARCH" in
-x86_64 | ia64)
- WEBRTC_TARGET_ARCH=x64
- ;;
-
-arm*)
- WEBRTC_TARGET_ARCH=arm
- ;;
-
-x86)
- WEBRTC_TARGET_ARCH=ia32
- ;;
-
-*)
-# unsupported arch for webrtc
- WEBRTC_TARGET_ARCH=unknown
- MOZ_WEBRTC=
- ;;
-
-esac
-
# Generate Makefiles for WebRTC directly from .gyp files
if test "${OS_TARGET}" = "WINNT"; then
if test "$HAVE_64BIT_OS"; then
OS_BITS=64
else
OS_BITS=32
fi
EXTRA_GYP_DEFINES="-D MSVS_VERSION=${_MSVS_VERSION} -D MSVS_OS_BITS=${OS_BITS}"