Bug 747856 - Add Win 64 bit mozconfigs and fix Mac universal mozconfigs. r=jhopkins NPOTB DONTBUILD
authorMark Banner <bugzilla@standard8.plus.com>
Mon, 23 Apr 2012 14:48:03 +0100
changeset 9974 9427206297feffc445f6fd1139d105443acf9c88
parent 9973 2cbb85b289f56133378ae30e52edeacef4cfed19
child 9975 3456f7a95ce20fed255803c95a6f0eeed5042c92
push id7596
push userbugzilla@standard8.plus.com
push dateMon, 23 Apr 2012 13:48:15 +0000
treeherdercomm-central@9427206297fe [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjhopkins
bugs747856
Bug 747856 - Add Win 64 bit mozconfigs and fix Mac universal mozconfigs. r=jhopkins NPOTB DONTBUILD
build/macosx/common
build/macosx/universal/mozconfig
build/macosx/universal/mozconfig.common
mail/config/mozconfigs/macosx-universal/nightly
mail/config/mozconfigs/macosx-universal/release
mail/config/mozconfigs/win64/debug
mail/config/mozconfigs/win64/nightly
mail/config/mozconfigs/win64/vs2010-mozconfig
new file mode 100644
--- /dev/null
+++ b/build/macosx/common
@@ -0,0 +1,4 @@
+CC=/usr/bin/gcc-4.2
+CXX=/usr/bin/g++-4.2
+
+ac_add_options --enable-stdcxx-compat
new file mode 100644
--- /dev/null
+++ b/build/macosx/universal/mozconfig
@@ -0,0 +1,7 @@
+# i386/x86-64 Universal Build mozconfig
+
+# As used here, arguments in $MOZ_BUILD_PROJECTS are suitable as arguments
+# to gcc's -arch parameter.
+mk_add_options MOZ_BUILD_PROJECTS="i386 x86_64"
+
+. $topsrcdir/build/macosx/universal/mozconfig.common
new file mode 100644
--- /dev/null
+++ b/build/macosx/universal/mozconfig.common
@@ -0,0 +1,88 @@
+# ***** BEGIN LICENSE BLOCK *****
+# Version: MPL 1.1/GPL 2.0/LGPL 2.1
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+# http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Original Code is the Mozilla Mac OS X Universal Binary Packaging System
+#
+# The Initial Developer of the Original Code is Google Inc.
+# Portions created by the Initial Developer are Copyright (C) 2006
+# the Initial Developer. All Rights Reserved.
+#
+# Contributor(s):
+#  Mark Mentovai <mark@moxienet.com> (Original Author)
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 2 or later (the "GPL"), or
+# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+# in which case the provisions of the GPL or the LGPL are applicable instead
+# of those above. If you wish to allow use of your version of this file only
+# under the terms of either the GPL or the LGPL, and not to allow others to
+# use your version of this file under the terms of the MPL, indicate your
+# decision by deleting the provisions above and replace them with the notice
+# and other provisions required by the GPL or the LGPL. If you do not delete
+# the provisions above, a recipient may use your version of this file under
+# the terms of any one of the MPL, the GPL or the LGPL.
+#
+# ***** END LICENSE BLOCK *****
+
+mk_add_options MOZ_UNIFY_BDATE=1
+
+mk_add_options MOZ_POSTFLIGHT_ALL+=build/macosx/universal/flight.mk
+
+# Note, the version (10) is used by libffi's configure.
+ac_add_app_options i386 --target=i386-apple-darwin10
+ac_add_app_options x86_64 --target=x86_64-apple-darwin10
+
+ac_add_options --with-macos-sdk=/Developer/SDKs/MacOSX10.6.sdk
+
+. $topsrcdir/build/macosx/common
+
+# $MOZ_BUILD_APP is only defined when sourced by configure.  That's not a
+# problem, because the variables it affects only need to be set for
+# configure.
+if test -n "$MOZ_BUILD_APP" ; then
+if test "$MOZ_BUILD_APP" = "i386" -o "$MOZ_BUILD_APP" = "x86_64"; then
+  TARGET_CPU=$MOZ_BUILD_APP
+
+  # $HOST_CXX is presently unused.  $HOST_CC will only be used during a cross
+  # compile.
+  HOST_CC=$CC
+  HOST_CXX=$CXX
+
+  NATIVE_CPU=`$topsrcdir/build/autoconf/config.guess | cut -f1 -d-`
+
+  # It's not strictly necessary to specify -arch during native builds, but it
+  # makes the merged about:buildconfig easier to follow, and it reduces
+  # conditionalized differences between builds.
+  CC="$CC -arch $TARGET_CPU"
+  CXX="$CXX -arch $TARGET_CPU"
+
+  # These must be set for cross builds, and don't hurt straight builds.
+  RANLIB=ranlib
+  AR=ar
+  AS=$CC
+  LD=ld
+  STRIP="strip -x -S"
+
+  # Let configure know that we mean business.
+  if test "$NATIVE_CPU" != "$TARGET_CPU" ; then
+    CROSS_COMPILE=1
+  fi
+
+  # Each per-CPU build should be entirely oblivious to the fact that a
+  # universal binary will be produced.  The exception is packager.mk, which
+  # needs to know to look for universal bits when building the .dmg.
+  UNIVERSAL_BINARY=1
+
+  export CC CXX HOST_CC HOST_CXX RANLIB AR AS LD STRIP
+fi
+fi
--- a/mail/config/mozconfigs/macosx-universal/nightly
+++ b/mail/config/mozconfigs/macosx-universal/nightly
@@ -1,26 +1,19 @@
-if test -e "$topsrcdir/mozilla/build/macosx/universal/mozconfig"; then
-  oldtopsrcdir=$topsrcdir
-  export topsrcdir=$topsrcdir/mozilla
-else
-  # Big Hack that unsets CC / CXX so that mozconfig.common doesn't get
-  # mixed up with host/target CPUs when trying to work out how to do the
-  # universal build. When we redo the build system (bug 648979) this will
-  # go away.
+# Big Hack that unsets CC / CXX so that mozconfig.common doesn't get
+# mixed up with host/target CPUs when trying to work out how to do the
+# universal build. When we redo the build system (bug 648979) this will
+# go away.
+if test -e "$topsrcdir/mail/config/version.txt"; then
   unset CC
   unset CXX
 fi
 
 . $topsrcdir/build/macosx/universal/mozconfig
 
-if test -n $oldtopsrcdir; then
-  export topsrcdir=$oldtopsrcdir
-fi
-
 ac_add_options --enable-application=mail
 ac_add_options --enable-update-channel=${MOZ_UPDATE_CHANNEL}
 ac_add_options --enable-update-packaging
 ac_add_options --enable-optimize
 ac_add_options --disable-debug
 ac_add_options --enable-tests
 ac_add_options --enable-codesighs
 ac_add_options --disable-install-strip
--- a/mail/config/mozconfigs/macosx-universal/release
+++ b/mail/config/mozconfigs/macosx-universal/release
@@ -1,26 +1,19 @@
-if test -e "$topsrcdir/mozilla/build/macosx/universal/mozconfig"; then
-  oldtopsrcdir=$topsrcdir
-  export topsrcdir=$topsrcdir/mozilla
-else
-  # Big Hack that unsets CC / CXX so that mozconfig.common doesn't get
-  # mixed up with host/target CPUs when trying to work out how to do the
-  # universal build. When we redo the build system (bug 648979) this will
-  # go away.
+# Big Hack that unsets CC / CXX so that mozconfig.common doesn't get
+# mixed up with host/target CPUs when trying to work out how to do the
+# universal build. When we redo the build system (bug 648979) this will
+# go away.
+if test -e "$topsrcdir/mail/config/version.txt"; then
   unset CC
   unset CXX
 fi
 
 . $topsrcdir/build/macosx/universal/mozconfig
 
-if test -n $oldtopsrcdir; then
-  export topsrcdir=$oldtopsrcdir
-fi
-
 ac_add_options --enable-application=mail
 ac_add_options --enable-update-channel=${MOZ_UPDATE_CHANNEL}
 ac_add_options --enable-update-packaging
 ac_add_options --enable-optimize
 ac_add_options --disable-debug
 ac_add_options --enable-tests
 ac_add_options --enable-official-branding
 
new file mode 100644
--- /dev/null
+++ b/mail/config/mozconfigs/win64/debug
@@ -0,0 +1,18 @@
+ac_add_options --target=x86_64-pc-mingw32
+ac_add_options --host=x86_64-pc-mingw32
+
+ac_add_options --enable-application=mail
+ac_add_options --enable-debug
+ac_add_options --enable-trace-malloc
+
+# Needed to enable breakpad in application.ini
+export MOZILLA_OFFICIAL=1
+
+mk_add_options MOZ_MAKE_FLAGS=-j1
+
+# This is a hack, until we can get a consistent location for both of these.
+if test -e "$topsrcdir/mail/config/mozconfigs/win64/vs2010-mozconfig"; then
+  . $topsrcdir/mail/config/mozconfigs/win64/vs2010-mozconfig
+else
+  . $topsrcdir/browser/config/mozconfigs/win64/vs2010-mozconfig
+fi
new file mode 100644
--- /dev/null
+++ b/mail/config/mozconfigs/win64/nightly
@@ -0,0 +1,19 @@
+ac_add_options --target=x86_64-pc-mingw32
+ac_add_options --host=x86_64-pc-mingw32
+
+ac_add_options --enable-application=mail
+ac_add_options --enable-update-channel=${MOZ_UPDATE_CHANNEL}
+ac_add_options --enable-update-packaging
+ac_add_options --enable-jemalloc
+
+# Needed to enable breakpad in application.ini
+export MOZILLA_OFFICIAL=1
+
+mk_add_options MOZ_MAKE_FLAGS=-j1
+
+# This is a hack, until we can get a consistent location for both of these.
+if test -e "$topsrcdir/mail/config/mozconfigs/win64/vs2010-mozconfig"; then
+  . $topsrcdir/mail/config/mozconfigs/win64/vs2010-mozconfig
+else
+  . $topsrcdir/browser/config/mozconfigs/win64/vs2010-mozconfig
+fi
new file mode 100644
--- /dev/null
+++ b/mail/config/mozconfigs/win64/vs2010-mozconfig
@@ -0,0 +1,16 @@
+export INCLUDE=/c/tools/msvs10/vc/include:/c/tools/msvs10/vc/atlmfc/include:/c/tools/sdks/v7.0/include:/c/tools/sdks/v7.0/include/atl:/c/tools/sdks/dx10/include
+export LIBPATH=/c/tools/msvs10/vc/lib/amd64:/c/tools/msvs10/vc/atlmfc/lib/amd64
+export LIB=/c/tools/msvs10/vc/lib/amd64:/c/tools/msvs10/vc/atlmfc/lib/amd64:/c/tools/sdks/v7.0/lib/x64:/c/tools/sdks/dx10/lib/x64
+export PATH="/c/tools/msvs10/Common7/IDE:/c/tools/msvs10/VC/BIN/amd64:/c/tools/msvs10/VC/BIN/x86_amd64:/c/tools/msvs10/VC/BIN:/c/tools/msvs10/Common7/Tools:/c/tools/msvs10/VC/VCPackages:${PATH}"
+export WIN32_REDIST_DIR=/c/tools/msvs10/VC/redist/x64/Microsoft.VC100.CRT
+
+# Use 32bit linker for PGO crash bug.
+# https://connect.microsoft.com/VisualStudio/feedback/details/686117/
+export LD=/c/tools/msvs10/VC/BIN/x86_amd64/link.exe
+
+
+mk_add_options "export LIB=$LIB"
+mk_add_options "export LIBPATH=$LIBPATH"
+mk_add_options "export PATH=$PATH"
+mk_add_options "export INCLUDE=$INCLUDE"
+mk_add_options "export WIN32_REDIST_DIR=$WIN32_REDIST_DIR"