]> git.saurik.com Git - apple/javascriptcore.git/blobdiff - JavaScriptCore.gyp/JavaScriptCore.gyp
JavaScriptCore-1097.3.tar.gz
[apple/javascriptcore.git] / JavaScriptCore.gyp / JavaScriptCore.gyp
index 9e014ddbdc91fe40f8394fecd3209618c0bad2ae..a89ac51203cf246f0caf4181f753cced04f18a1a 100644 (file)
@@ -1,10 +1,10 @@
 #
-# Copyright (C) 2009 Google Inc. All rights reserved.
-# 
+# Copyright (C) 2009, 2012 Google Inc. All rights reserved.
+#
 # Redistribution and use in source and binary forms, with or without
 # modification, are permitted provided that the following conditions are
 # met:
-# 
+#
 #     * Redistributions of source code must retain the above copyright
 # notice, this list of conditions and the following disclaimer.
 #     * Redistributions in binary form must reproduce the above
@@ -14,7 +14,7 @@
 #     * Neither the name of Google Inc. nor the names of its
 # contributors may be used to endorse or promote products derived from
 # this software without specific prior written permission.
-# 
+#
 # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
 # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
 # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
@@ -30,8 +30,7 @@
 
 {
   'includes': [
-    # FIXME: Sense whether upstream or downstream build, and
-    # include the right features.gypi
+    '../../WebKit/chromium/WinPrecompile.gypi',
     '../../WebKit/chromium/features.gypi',
     '../JavaScriptCore.gypi',
   ],
         'chromium_src_dir': '../../WebKit/chromium',
       },{
         # WebKit is checked out in src/chromium/third_party/WebKit
-        'chromium_src_dir': '../../../..',
+        'chromium_src_dir': '../../../../..',
       }],
     ],
   },
+  'conditions': [
+    ['os_posix == 1 and OS != "mac" and OS != "android" and gcc_version==46', {
+      'target_defaults': {
+        # Disable warnings about c++0x compatibility, as some names (such as nullptr) conflict
+        # with upcoming c++0x types.
+        'cflags_cc': ['-Wno-c++0x-compat'],
+      },
+    }],
+  ],
   'targets': [
     {
-      # This target sets up defines and includes that are required by WTF and
-      # its dependents.
-      'target_name': 'wtf_config',
-      'type': 'none',
-      'msvs_guid': '2E2D3301-2EC4-4C0F-B889-87073B30F673',
-      'direct_dependent_settings': {
-        'defines': [
-          # Import features_defines from features.gypi
-          '<@(feature_defines)',
-          
-          # Turns on #if PLATFORM(CHROMIUM)
-          'BUILDING_CHROMIUM__=1',
-          # Controls wtf/FastMalloc
-          # FIXME: consider moving into config.h
-          'USE_SYSTEM_MALLOC=1',
-        ],
-        'conditions': [
-          ['OS=="win"', {
-            'defines': [
-              '__STD_C',
-              '_CRT_SECURE_NO_DEPRECATE',
-              '_SCL_SECURE_NO_DEPRECATE',
-              'CRASH=__debugbreak',
-            ],
-            'include_dirs': [
-              '../os-win32',
-            ],
-          }],
-          ['OS=="mac"', {
-            'defines': [
-              # Use USE_NEW_THEME on Mac.
-              'WTF_USE_NEW_THEME=1',
-            ],
-          }],
-          ['OS=="linux" or OS=="freebsd"', {
-            'defines': [
-              'WTF_USE_PTHREADS=1',
-            ],
-          }],
-        ],
-      }
-    },
-    {
-      'target_name': 'wtf',
-      'type': '<(library)',
-      'msvs_guid': 'AA8A5A85-592B-4357-BC60-E0E91E026AF6',
+      'target_name': 'yarr',
+      'type': 'static_library',
       'dependencies': [
-        'wtf_config',
-        '<(chromium_src_dir)/third_party/icu/icu.gyp:icui18n',
-        '<(chromium_src_dir)/third_party/icu/icu.gyp:icuuc',
-      ],
-      'include_dirs': [
-        '../',
-        '../wtf',
-        '../wtf/unicode',
-      ],
-      'sources': [
-        '<@(javascriptcore_files)',
-      ],
-      'sources/': [
-        # First exclude everything ...
-        ['exclude', '../'],
-        # ... Then include what we want.
-        ['include', '../wtf/'],
-        # GLib/GTK, even though its name doesn't really indicate.
-        ['exclude', '/(gtk|glib|gobject)/.*\\.(cpp|h)$'],
-        ['exclude', '(Default|Gtk|Mac|None|Qt|Win|Wx)\\.(cpp|mm)$'],
-        ['exclude', 'wtf/CurrentTime\\.cpp$'],
-        ['exclude', 'wtf/MainThread.cpp$'],
-        ['exclude', 'wtf/TC.*\\.(cpp|h)$'],
+        '../../WTF/WTF.gyp/WTF.gyp:wtf',
       ],
-      'direct_dependent_settings': {
-        'include_dirs': [
-          '../',
-          '../wtf',
-        ],
-      },
-      'export_dependent_settings': [
-        'wtf_config',
-        '<(chromium_src_dir)/third_party/icu/icu.gyp:icui18n',
-        '<(chromium_src_dir)/third_party/icu/icu.gyp:icuuc',
-      ],
-      'msvs_disabled_warnings': [4127, 4355, 4510, 4512, 4610, 4706],
-      'conditions': [
-        ['OS=="win"', {
-          'sources/': [
-            ['exclude', 'ThreadIdentifierDataPthreads\\.(h|cpp)$'],
-            ['exclude', 'ThreadingPthreads\\.cpp$'],
-            ['include', 'Thread(ing|Specific)Win\\.cpp$']
+      'variables': { 'optimize': 'max' },
+      'actions': [
+        {
+          'action_name': 'retgen',
+          'inputs': [
+            '../create_regex_tables',
           ],
-          'include_dirs!': [
-            '<(SHARED_INTERMEDIATE_DIR)/webkit',
+          'arguments': [
+            '--no-tables',
           ],
-        }],
-      ],
-    },
-    {
-      'target_name': 'pcre',
-      'type': '<(library)',
-      'dependencies': [
-        'wtf',
-      ],
-      'conditions': [
-        ['OS=="win"', {
-          'dependencies': ['<(chromium_src_dir)/build/win/system.gyp:cygwin'],
-        }],
-      ],
-      'msvs_guid': '49909552-0B0C-4C14-8CF6-DB8A2ADE0934',
-      'actions': [
+          'outputs': [
+            '<(INTERMEDIATE_DIR)/RegExpJitTables.h',
+          ],
+          'action': ['python', '<@(_inputs)', '<@(_arguments)', '<@(_outputs)'],
+        },
         {
-          'action_name': 'dftables',
+          'action_name': 'klgen',
           'inputs': [
-            '../pcre/dftables',
+            '../KeywordLookupGenerator.py',
+            '../parser/Keywords.table'
+          ],
+          'arguments': [
           ],
           'outputs': [
-            '<(INTERMEDIATE_DIR)/chartables.c',
+            '<(INTERMEDIATE_DIR)/KeywordLookup.h',
           ],
-          'action': ['perl', '-w', '<@(_inputs)', '<@(_outputs)'],
+          'action': ['python', '<@(_inputs)', '<@(_arguments)', '<@(_outputs)'],
         },
       ],
       'include_dirs': [
         '<(INTERMEDIATE_DIR)',
+        '..',
+        '../runtime',
       ],
       'sources': [
         '<@(javascriptcore_files)',
         # First exclude everything ...
         ['exclude', '../'],
         # ... Then include what we want.
-        ['include', '../pcre/'],
-        # ucptable.cpp is #included by pcre_ucp_searchfunchs.cpp and is not
-        # intended to be compiled directly.
-        ['exclude', '../pcre/ucptable.cpp$'],
+        ['include', '../yarr/'],
+        # The Yarr JIT isn't used in WebCore.
+        ['exclude', '../yarr/YarrJIT\\.(h|cpp)$'],
       ],
       'export_dependent_settings': [
-        'wtf',
+        '../../WTF/WTF.gyp/WTF.gyp:wtf',
       ],
     },
   ], # targets