[wx] Unreviewed build fix. Restore the PPC build and allow users to specify architect...
authorkevino@webkit.org <kevino@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 5 Jun 2011 05:07:04 +0000 (05:07 +0000)
committerkevino@webkit.org <kevino@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 5 Jun 2011 05:07:04 +0000 (05:07 +0000)
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@88131 268f45cc-cd09-0410-ab3c-d52691b4dbfc

ChangeLog
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/wtf/Platform.h
Tools/ChangeLog
Tools/waf/build/settings.py
Tools/wx/install-unix-extras
wscript

index cbd3202..56f745a 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2011-06-04  Kevin Ollivier  <kevino@theolliviers.com>
+
+        [wx] Unreviewed build fix. Restore the PPC build and allow users to specify architectures
+        to build on Mac.
+
+        * wscript:
+
 2011-06-04  Adam Barth  <abarth@webkit.org>
 
         Configure new commit-queue instance.  (Please ignore.)
index 3125f02..3739920 100755 (executable)
@@ -1,3 +1,10 @@
+2011-06-04  Kevin Ollivier  <kevino@theolliviers.com>
+
+        [wx] Unreviewed build fix. Restore the PPC build and allow users to specify architectures
+        to build on Mac.
+
+        * wtf/Platform.h:
+
 2011-06-04  Gustavo Noronha Silva  <gns@gnome.org>
 
         Unreviewed, MIPS build fix.
index 47e5202..03d2201 100644 (file)
 #endif
 
 #if PLATFORM(WX)
+#if !CPU(PPC)
 #define ENABLE_ASSEMBLER 1
+#define ENABLE_JIT 1
+#endif
 #define ENABLE_GLOBAL_FASTMALLOC_NEW 0
 #if OS(DARWIN)
 #define WTF_USE_CF 1
index 608d060..a6c7c03 100644 (file)
@@ -1,5 +1,13 @@
 2011-06-04  Kevin Ollivier  <kevino@theolliviers.com>
 
+        [wx] Unreviewed build fix. Restore the PPC build and allow users to specify architectures
+        to build on Mac.
+
+        * waf/build/settings.py:
+        * wx/install-unix-extras:
+
+2011-06-04  Kevin Ollivier  <kevino@theolliviers.com>
+
         [wx] Unreviewed build fixes for recent trunk changes.
 
         * DumpRenderTree/wx/LayoutTestControllerWx.cpp:
index 67e97fe..acb1329 100644 (file)
@@ -221,6 +221,8 @@ def common_set_options(opt):
                    help='Specify a different compiler prefix (do this if you used COMPILER_PREFIX when building wx itself)')
     opt.add_option('--macosx-version', action='store', default='', help="Version of OS X to build for.")
     opt.add_option('--msvc-version', action='store', default='', help="MSVC version to use to build. Use 8 for 2005, 9 for 2008")
+    opt.add_option('--mac_universal_binary', action='store_true', default=False, help='Build Mac as universal (i386, x86_64, ppc) binary.')
+    opt.add_option('--mac_archs', action='store', default='', help='Comma separated list of architectures (i386, x86_64, ppc) to build on Mac.')
 
 
 def common_configure(conf):
@@ -235,15 +237,13 @@ def common_configure(conf):
     feature_defines = ['ENABLE_DATABASE', 'ENABLE_XSLT', 'ENABLE_JAVASCRIPT_DEBUGGER',
                     'ENABLE_SVG', 'ENABLE_SVG_USE', 'ENABLE_FILTERS', 'ENABLE_SVG_FONTS',
                     'ENABLE_SVG_ANIMATION', 'ENABLE_SVG_AS_IMAGE', 'ENABLE_SVG_FOREIGN_OBJECT',
-                    'ENABLE_JIT', 'ENABLE_DOM_STORAGE', 'BUILDING_%s' % build_port.upper()]
+                    'ENABLE_DOM_STORAGE', 'BUILDING_%s' % build_port.upper()]
 
     conf.env["FEATURE_DEFINES"] = ' '.join(feature_defines)
 
     if Options.options.msvc_version and Options.options.msvc_version != '':
-        print "msvc version = %s" % Options.options.msvc_version
         conf.env['MSVC_VERSIONS'] = ['msvc %s.0' % Options.options.msvc_version]
     else:
-        print "msvc not set!"
         conf.env['MSVC_VERSIONS'] = ['msvc 9.0', 'msvc 8.0']
 
     if sys.platform.startswith('cygwin'):
@@ -345,13 +345,27 @@ def common_configure(conf):
             conf.env.append_value('LIB_WKINTERFACE', ['WebKitSystemInterfaceLeopard'])
 
         # match WebKit Mac's default here unless we're building on platforms that won't support 64-bit.
-        global arch
-        is_cocoa = "__WXOSX_COCOA__" in conf.env["CXXDEFINES_WX"]
-        if min_version == "10.4" or not is_cocoa:
-            arch = "i386"
+        archs = []
+        
+        if Options.options.mac_archs != '':
+            arch_list = Options.options.mac_archs.replace("'", '').replace('"', '').split(",")
+            for arch in arch_list:
+                if arch.strip() != '':
+                    archs.append(arch.strip())
+        elif Options.options.mac_universal_binary:
+            archs = ['i386', 'x86_64', 'ppc']
+        else:
+            is_cocoa = "__WXOSX_COCOA__" in conf.env["CXXDEFINES_WX"]
+            if min_version == "10.4" or not is_cocoa:
+                archs = ["i386"]
+            else:
+                global arch
+                archs = [arch]
 
         sdkroot = '/Developer/SDKs/MacOSX%s.sdk' % sdk_version
-        sdkflags = ['-arch', arch, '-isysroot', sdkroot]
+        sdkflags = ['-isysroot', sdkroot]
+        for arch in archs:
+            sdkflags.extend(['-arch', arch])
 
         conf.env.append_value('CPPFLAGS', sdkflags)
         conf.env.append_value('LINKFLAGS', sdkflags)
index 868acde..973820f 100755 (executable)
@@ -48,6 +48,10 @@ fi
 mkdir -p $DL_DIR
 mkdir -p $DEPS_PREFIX
 
+mkdir -p $DEPS_PREFIX/bin
+mkdir -p $DEPS_PREFIX/lib
+mkdir -p $DEPS_PREFIX/include
 ICU_VERSION="3.4.1"
 ICU_TARBALL="icu-$ICU_VERSION.tgz"
 ICU_URL="ftp://ftp.software.ibm.com/software/globalization/icu/$ICU_VERSION/$ICU_TARBALL"
@@ -118,28 +122,6 @@ if [ `which icu-config >/dev/null 2>&1` ]; then
   rm -rf icu
 fi
 
-# TODO: What would be a good way to test for this?
-if [ ! -f $DEPS_PREFIX/lib/libiconv.$DLLEXT ]; then
-  $DL_CMD -o $DL_DIR/$ICONV_TARBALL $ICONV_URL
-
-  tar xzvf $DL_DIR/$ICONV_TARBALL
-  cd $DL_DIR/libiconv-$ICONV_VERSION
-
-  if [ "${OSTYPE:0:6}" == "darwin" ]; then  
-    ./configure --prefix=$DEPS_PREFIX --disable-dependency-tracking
-    make CFLAGS="-O -g -isysroot $SDK $ARCH_FLAGS" \
-    LDFLAGS="$ARCH_FLAGS"
-    make install
-  else
-    ./configure --prefix=$DEPS_PREFIX
-  
-    make
-    make install
-  fi
-  cd $DL_DIR
-  rm -rf $DL_DIR/libiconv-$ICONV_VERSION
-fi
-
 if [ ! -f $DEPS_PREFIX/lib/libjpeg.a ]; then
   $DL_CMD -o $DL_DIR/$LIBJPEG_TARBALL $LIBJPEG_URL
 
diff --git a/wscript b/wscript
index 0034ea7..5564702 100644 (file)
--- a/wscript
+++ b/wscript
@@ -187,7 +187,6 @@ def build(bld):
                    'Source/WebCore/platform/graphics/mac/SimpleFontDataATSUI.mm',
                    'Source/WebCore/platform/graphics/mac/SimpleFontDataCoreText.cpp',
                    'Source/WebCore/platform/graphics/wx/FontPlatformDataWxMac.mm',
-                   'Source/WebCore/platform/text/mac/ShapeArabic.c',
                    'Source/WebCore/platform/wx/wxcode/mac/carbon/fontprops.mm',
                    'Source/WebCore/plugins/mac/PluginPackageMac.cpp',
                    'Source/WebCore/plugins/mac/PluginViewMac.mm'