Changeset 49693 in webkit


Ignore:
Timestamp:
Oct 16, 2009 1:37:41 PM (15 years ago)
Author:
eric@webkit.org
Message:

2009-10-16 Steven Knight <sgk@chromium.org>

Reviewed by David Levin.

https://bugs.webkit.org/show_bug.cgi?id=30447
Handle long link lines by building .idl-generated bindings in a
separate webcore_bindings library target. Avoid Visual Studio
dependency issues by building additional generated .cpp and .h files
in a separate webcore_bindings_sources target.

Chrome should still build and test successfully.

  • WebCore.gyp/WebCore.gyp:
  • WebCore.gypi:
Location:
trunk/WebCore
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebCore/ChangeLog

    r49692 r49693  
     12009-10-16  Steven Knight  <sgk@chromium.org>
     2
     3        Reviewed by David Levin.
     4
     5        https://bugs.webkit.org/show_bug.cgi?id=30447
     6        Handle long link lines by building .idl-generated bindings in a
     7        separate webcore_bindings library target.  Avoid Visual Studio
     8        dependency issues by building additional generated .cpp and .h files
     9        in a separate webcore_bindings_sources target.
     10
     11        Chrome should still build and test successfully.
     12
     13        * WebCore.gyp/WebCore.gyp:
     14        * WebCore.gypi:
     15
    1162009-10-16  Simon Fraser  <simon.fraser@apple.com>
    217
  • trunk/WebCore/WebCore.gyp/WebCore.gyp

    r49080 r49693  
    143143  'targets': [
    144144    {
    145       'target_name': 'webcore',
    146       'type': '<(library)',
    147       'msvs_guid': '1C16337B-ACF3-4D03-AA90-851C5B5EADA6',
    148       'dependencies': [
    149         '../../JavaScriptCore/JavaScriptCore.gyp/JavaScriptCore.gyp:pcre',
    150         '../../JavaScriptCore/JavaScriptCore.gyp/JavaScriptCore.gyp:wtf',
    151         '<(chromium_src_dir)/build/temp_gyp/googleurl.gyp:googleurl',
    152         '<(chromium_src_dir)/skia/skia.gyp:skia',
    153         '<(chromium_src_dir)/third_party/libjpeg/libjpeg.gyp:libjpeg',
    154         '<(chromium_src_dir)/third_party/libpng/libpng.gyp:libpng',
    155         '<(chromium_src_dir)/third_party/libxml/libxml.gyp:libxml',
    156         '<(chromium_src_dir)/third_party/libxslt/libxslt.gyp:libxslt',
    157         '<(chromium_src_dir)/third_party/npapi/npapi.gyp:npapi',
    158         '<(chromium_src_dir)/third_party/sqlite/sqlite.gyp:sqlite',
    159       ],
    160       'defines': [
    161         'WEBCORE_NAVIGATOR_VENDOR="Google Inc."',
    162       ],
    163       'actions': [
    164         # Actions to build derived sources.
    165         {
    166           'action_name': 'CSSPropertyNames',
    167           'inputs': [
    168             '../css/makeprop.pl',
    169             '../css/CSSPropertyNames.in',
    170             '../css/SVGCSSPropertyNames.in',
    171           ],
    172           'outputs': [
    173             '<(INTERMEDIATE_DIR)/CSSPropertyNames.cpp',
    174             '<(SHARED_INTERMEDIATE_DIR)/webkit/CSSPropertyNames.h',
    175           ],
    176           'action': ['python', '<(chromium_src_dir)/webkit/build/action_csspropertynames.py', '<@(_outputs)', '--', '<@(_inputs)'],
    177         },
    178         {
    179           'action_name': 'CSSValueKeywords',
    180           'inputs': [
    181             '../css/makevalues.pl',
    182             '../css/CSSValueKeywords.in',
    183             '../css/SVGCSSValueKeywords.in',
    184           ],
    185           'outputs': [
    186             '<(INTERMEDIATE_DIR)/CSSValueKeywords.c',
    187             '<(SHARED_INTERMEDIATE_DIR)/webkit/CSSValueKeywords.h',
    188           ],
    189           'action': ['python', '<(chromium_src_dir)/webkit/build/action_cssvaluekeywords.py', '<@(_outputs)', '--', '<@(_inputs)'],
    190         },
    191         {
    192           'action_name': 'HTMLNames',
    193           'inputs': [
    194             '../dom/make_names.pl',
    195             '../html/HTMLTagNames.in',
    196             '../html/HTMLAttributeNames.in',
    197           ],
    198           'outputs': [
    199             '<(INTERMEDIATE_DIR)/HTMLNames.cpp',
    200             '<(SHARED_INTERMEDIATE_DIR)/webkit/HTMLNames.h',
    201             '<(INTERMEDIATE_DIR)/HTMLElementFactory.cpp',
    202             # Pass --wrapperFactory to make_names to get these (JSC build?)
    203             #'<(INTERMEDIATE_DIR)/JSHTMLElementWrapperFactory.cpp',
    204             #'<(INTERMEDIATE_DIR)/JSHTMLElementWrapperFactory.h',
    205           ],
    206           'action': ['python', '<(chromium_src_dir)/webkit/build/action_makenames.py', '<@(_outputs)', '--', '<@(_inputs)', '--', '--factory', '--extraDefines', '<(feature_defines)'],
    207           'process_outputs_as_sources': 1,
    208         },
    209         {
    210           'action_name': 'SVGNames',
    211           'inputs': [
    212             '../dom/make_names.pl',
    213             '../svg/svgtags.in',
    214             '../svg/svgattrs.in',
    215           ],
    216           'outputs': [
    217             '<(INTERMEDIATE_DIR)/SVGNames.cpp',
    218             '<(INTERMEDIATE_DIR)/SVGNames.h',
    219             '<(INTERMEDIATE_DIR)/SVGElementFactory.cpp',
    220             '<(INTERMEDIATE_DIR)/SVGElementFactory.h',
    221             # Pass --wrapperFactory to make_names to get these (JSC build?)
    222             #'<(INTERMEDIATE_DIR)/JSSVGElementWrapperFactory.cpp',
    223             #'<(INTERMEDIATE_DIR)/JSSVGElementWrapperFactory.h',
    224           ],
    225           'action': ['python', '<(chromium_src_dir)/webkit/build/action_makenames.py', '<@(_outputs)', '--', '<@(_inputs)', '--', '--factory', '--extraDefines', '<(feature_defines)'],
    226           'process_outputs_as_sources': 1,
    227         },
    228         {
    229           'action_name': 'UserAgentStyleSheets',
    230           'inputs': [
    231             '../css/make-css-file-arrays.pl',
    232             '../css/html.css',
    233             '../css/quirks.css',
    234             '../css/view-source.css',
    235             '../css/themeChromiumLinux.css',
    236             '../css/themeWin.css',
    237             '../css/themeWinQuirks.css',
    238             '../css/svg.css',
    239             '../css/mediaControls.css',
    240             '../css/mediaControlsChromium.css',
    241           ],
    242           'outputs': [
    243             '<(INTERMEDIATE_DIR)/UserAgentStyleSheets.h',
    244             '<(INTERMEDIATE_DIR)/UserAgentStyleSheetsData.cpp',
    245           ],
    246           'action': ['python', '<(chromium_src_dir)/webkit/build/action_useragentstylesheets.py', '<@(_outputs)', '--', '<@(_inputs)'],
    247           'process_outputs_as_sources': 1,
    248         },
    249         {
    250           'action_name': 'XLinkNames',
    251           'inputs': [
    252             '../dom/make_names.pl',
    253             '../svg/xlinkattrs.in',
    254           ],
    255           'outputs': [
    256             '<(INTERMEDIATE_DIR)/XLinkNames.cpp',
    257             '<(INTERMEDIATE_DIR)/XLinkNames.h',
    258           ],
    259           'action': ['python', '<(chromium_src_dir)/webkit/build/action_makenames.py', '<@(_outputs)', '--', '<@(_inputs)', '--', '--extraDefines', '<(feature_defines)'],
    260           'process_outputs_as_sources': 1,
    261         },
    262         {
    263           'action_name': 'XMLNames',
    264           'inputs': [
    265             '../dom/make_names.pl',
    266             '../xml/xmlattrs.in',
    267           ],
    268           'outputs': [
    269             '<(INTERMEDIATE_DIR)/XMLNames.cpp',
    270             '<(INTERMEDIATE_DIR)/XMLNames.h',
    271           ],
    272           'action': ['python', '<(chromium_src_dir)/webkit/build/action_makenames.py', '<@(_outputs)', '--', '<@(_inputs)', '--', '--extraDefines', '<(feature_defines)'],
    273           'process_outputs_as_sources': 1,
    274         },
    275         {
    276           'action_name': 'tokenizer',
    277           'inputs': [
    278             '../css/maketokenizer',
    279             '../css/tokenizer.flex',
    280           ],
    281           'outputs': [
    282             '<(INTERMEDIATE_DIR)/tokenizer.cpp',
    283           ],
    284           'action': ['python', '<(chromium_src_dir)/webkit/build/action_maketokenizer.py', '<@(_outputs)', '--', '<@(_inputs)'],
    285         },
    286       ],
    287       'rules': [
    288         # Rules to build derived sources.
    289         {
    290           'rule_name': 'bison',
    291           'extension': 'y',
    292           'outputs': [
    293             '<(INTERMEDIATE_DIR)/<(RULE_INPUT_ROOT).cpp',
    294             '<(INTERMEDIATE_DIR)/<(RULE_INPUT_ROOT).h'
    295           ],
    296           'action': ['python', '<(chromium_src_dir)/webkit/build/rule_bison.py', '<(RULE_INPUT_PATH)', '<(INTERMEDIATE_DIR)'],
    297           'process_outputs_as_sources': 1,
    298         },
    299         {
    300           'rule_name': 'gperf',
    301           'extension': 'gperf',
    302           # gperf output is only ever #included by other source files.  As
    303           # such, process_outputs_as_sources is off.  Some gperf output is
    304           # #included as *.c and some as *.cpp.  Since there's no way to tell
    305           # which one will be needed in a rule definition, declare both as
    306           # outputs.  The harness script will generate one file and copy it to
    307           # the other.
    308           #
    309           # This rule places outputs in SHARED_INTERMEDIATE_DIR because glue
    310           # needs access to HTMLEntityNames.c.
    311           'outputs': [
    312             '<(SHARED_INTERMEDIATE_DIR)/webkit/<(RULE_INPUT_ROOT).c',
    313             '<(SHARED_INTERMEDIATE_DIR)/webkit/<(RULE_INPUT_ROOT).cpp',
    314           ],
    315           'action': ['python', '<(chromium_src_dir)/webkit/build/rule_gperf.py', '<(RULE_INPUT_PATH)', '<(SHARED_INTERMEDIATE_DIR)/webkit'],
    316           'process_outputs_as_sources': 0,
    317         },
    318         # Rule to build generated JavaScript (V8) bindings from .idl source.
    319         {
    320           'rule_name': 'binding',
    321           'extension': 'idl',
    322           'msvs_external_rule': 1,
    323           'inputs': [
    324             '../bindings/scripts/generate-bindings.pl',
    325             '../bindings/scripts/CodeGenerator.pm',
    326             '../bindings/scripts/CodeGeneratorV8.pm',
    327             '../bindings/scripts/IDLParser.pm',
    328             '../bindings/scripts/IDLStructure.pm',
    329           ],
    330           'outputs': [
    331             '<(INTERMEDIATE_DIR)/bindings/V8<(RULE_INPUT_ROOT).cpp',
    332             '<(SHARED_INTERMEDIATE_DIR)/webkit/bindings/V8<(RULE_INPUT_ROOT).h',
    333           ],
    334           'variables': {
    335             'generator_include_dirs': [
    336               '--include', '../css',
    337               '--include', '../dom',
    338               '--include', '../html',
    339               '--include', '../notifications',
    340               '--include', '../page',
    341               '--include', '../plugins',
    342               '--include', '../svg',
    343               '--include', '../websockets',
    344               '--include', '../workers',
    345               '--include', '../xml',
    346             ],
    347           },
    348           'action': ['python', '<(chromium_src_dir)/webkit/build/rule_binding.py', '<(RULE_INPUT_PATH)', '<(INTERMEDIATE_DIR)/bindings', '<(SHARED_INTERMEDIATE_DIR)/webkit/bindings', '--', '<@(_inputs)', '--', '--defines', '<(feature_defines) LANGUAGE_JAVASCRIPT V8_BINDING', '--generator', 'V8', '<@(generator_include_dirs)'],
    349           # They are included by DerivedSourcesAllInOne.cpp instead.
    350           'process_outputs_as_sources': 0,
    351           'message': 'Generating binding from <(RULE_INPUT_PATH)',
    352         },
    353       ],
    354       'include_dirs': [
    355         '<(INTERMEDIATE_DIR)',
    356         '<(SHARED_INTERMEDIATE_DIR)/webkit',
    357         '<(SHARED_INTERMEDIATE_DIR)/webkit/bindings',
    358         '<@(webcore_include_dirs)',
    359       ],
     145      'target_name': 'webcore_bindings_sources',
     146      'type': 'none',
     147      'hard_dependency': 1,
    360148      'sources': [
    361149        # bison rule
     
    368156        '../platform/ColorData.gperf',
    369157
    370         # This file includes all the .cpp files generated from the .idl files
    371         # in webcore_files.
    372         '../bindings/v8/DerivedSourcesAllInOne.cpp',
    373 
    374         '<@(webcore_files)',
    375 
    376         # For WebCoreSystemInterface, Mac-only.
    377         '../../WebKit/mac/WebCoreSupport/WebSystemInterface.m',
     158        # idl rule
     159        '<@(webcore_bindings_idl_files)',
    378160      ],
    379161      'sources/': [
    380         # Exclude JSC custom bindings.
    381         ['exclude', 'bindings/js'],
    382 
    383162        # SVG_FILTERS only.
    384163        ['exclude', 'svg/SVG(FE|Filter)[^/]*\\.idl$'],
    385164
    386         # Fortunately, many things can be excluded by using broad patterns.
    387 
    388         # Exclude things that don't apply to the Chromium platform on the basis
    389         # of their enclosing directories and tags at the ends of their
    390         # filenames.
    391         ['exclude', '(android|cairo|cf|cg|curl|gtk|haiku|linux|mac|opentype|posix|qt|soup|symbian|win|wx)/'],
    392         ['exclude', '(?<!Chromium)(SVGAllInOne|Android|Cairo|CF|CG|Curl|Gtk|Linux|Mac|OpenType|POSIX|Posix|Qt|Safari|Soup|Symbian|Win|Wx)\\.(cpp|mm?)$'],
    393 
    394         # JSC-only.
    395         ['exclude', 'inspector/JavaScript[^/]*\\.cpp$'],
    396 
    397         # ENABLE_OFFLINE_WEB_APPLICATIONS, exclude most of webcore's impl
    398         ['exclude', 'loader/appcache/'],
    399         ['include', 'loader/appcache/ApplicationCacheHost\.h$'],
    400         ['include', 'loader/appcache/DOMApplicationCache\.(h|cpp|idl)$'],
    401 
    402         # SVG_FILTERS only.
    403         ['exclude', '(platform|svg)/graphics/filters/'],
    404         ['exclude', 'svg/Filter[^/]*\\.cpp$'],
    405         ['exclude', 'svg/SVG(FE|Filter)[^/]*\\.cpp$'],
    406 
    407         # Exclude some DB-related files.
    408         ['exclude', 'platform/sql/SQLiteFileSystem.cpp'],
    409165      ],
    410166      'sources!': [
     
    447203        '../css/CSSUnknownRule.idl',
    448204
     205      ],
     206      'actions': [
     207        # Actions to build derived sources.
     208        {
     209          'action_name': 'CSSPropertyNames',
     210          'inputs': [
     211            '../css/makeprop.pl',
     212            '../css/CSSPropertyNames.in',
     213            '../css/SVGCSSPropertyNames.in',
     214          ],
     215          'outputs': [
     216            '<(SHARED_INTERMEDIATE_DIR)/webkit/CSSPropertyNames.cpp',
     217            '<(SHARED_INTERMEDIATE_DIR)/webkit/CSSPropertyNames.h',
     218          ],
     219          'action': [
     220            'python',
     221            '<(chromium_src_dir)/webkit/build/action_csspropertynames.py',
     222            '<@(_outputs)',
     223            '--',
     224            '<@(_inputs)'
     225          ],
     226        },
     227        {
     228          'action_name': 'CSSValueKeywords',
     229          'inputs': [
     230            '../css/makevalues.pl',
     231            '../css/CSSValueKeywords.in',
     232            '../css/SVGCSSValueKeywords.in',
     233          ],
     234          'outputs': [
     235            '<(SHARED_INTERMEDIATE_DIR)/webkit/CSSValueKeywords.c',
     236            '<(SHARED_INTERMEDIATE_DIR)/webkit/CSSValueKeywords.h',
     237          ],
     238          'action': [
     239            'python',
     240            '<(chromium_src_dir)/webkit/build/action_cssvaluekeywords.py',
     241            '<@(_outputs)',
     242            '--',
     243            '<@(_inputs)'
     244          ],
     245        },
     246        {
     247          'action_name': 'HTMLNames',
     248          'inputs': [
     249            '../dom/make_names.pl',
     250            '../html/HTMLTagNames.in',
     251            '../html/HTMLAttributeNames.in',
     252          ],
     253          'outputs': [
     254            '<(SHARED_INTERMEDIATE_DIR)/webkit/HTMLNames.cpp',
     255            '<(SHARED_INTERMEDIATE_DIR)/webkit/HTMLNames.h',
     256            '<(SHARED_INTERMEDIATE_DIR)/webkit/HTMLElementFactory.cpp',
     257            # Pass --wrapperFactory to make_names to get these (JSC build?)
     258            #'<(SHARED_INTERMEDIATE_DIR)/webkit/JSHTMLElementWrapperFactory.cpp',
     259            #'<(SHARED_INTERMEDIATE_DIR)/webkit/JSHTMLElementWrapperFactory.h',
     260          ],
     261          'action': [
     262            'python',
     263            '<(chromium_src_dir)/webkit/build/action_makenames.py',
     264            '<@(_outputs)',
     265            '--',
     266            '<@(_inputs)',
     267            '--',
     268            '--factory',
     269            '--extraDefines', '<(feature_defines)'
     270          ],
     271        },
     272        {
     273          'action_name': 'SVGNames',
     274          'inputs': [
     275            '../dom/make_names.pl',
     276            '../svg/svgtags.in',
     277            '../svg/svgattrs.in',
     278          ],
     279          'outputs': [
     280            '<(SHARED_INTERMEDIATE_DIR)/webkit/SVGNames.cpp',
     281            '<(SHARED_INTERMEDIATE_DIR)/webkit/SVGNames.h',
     282            '<(SHARED_INTERMEDIATE_DIR)/webkit/SVGElementFactory.cpp',
     283            '<(SHARED_INTERMEDIATE_DIR)/webkit/SVGElementFactory.h',
     284            # Pass --wrapperFactory to make_names to get these (JSC build?)
     285            #'<(SHARED_INTERMEDIATE_DIR)/webkit/JSSVGElementWrapperFactory.cpp',
     286            #'<(SHARED_INTERMEDIATE_DIR)/webkit/JSSVGElementWrapperFactory.h',
     287          ],
     288          'action': [
     289            'python',
     290            '<(chromium_src_dir)/webkit/build/action_makenames.py',
     291            '<@(_outputs)',
     292            '--',
     293            '<@(_inputs)',
     294            '--',
     295            '--factory',
     296            '--extraDefines', '<(feature_defines)'
     297          ],
     298        },
     299        {
     300          'action_name': 'UserAgentStyleSheets',
     301          'inputs': [
     302            '../css/make-css-file-arrays.pl',
     303            '../css/html.css',
     304            '../css/quirks.css',
     305            '../css/view-source.css',
     306            '../css/themeChromiumLinux.css',
     307            '../css/themeWin.css',
     308            '../css/themeWinQuirks.css',
     309            '../css/svg.css',
     310            '../css/mediaControls.css',
     311            '../css/mediaControlsChromium.css',
     312          ],
     313          'outputs': [
     314            '<(SHARED_INTERMEDIATE_DIR)/webkit/UserAgentStyleSheets.h',
     315            '<(SHARED_INTERMEDIATE_DIR)/webkit/UserAgentStyleSheetsData.cpp',
     316          ],
     317          'action': [
     318            'python',
     319            '<(chromium_src_dir)/webkit/build/action_useragentstylesheets.py',
     320            '<@(_outputs)',
     321            '--',
     322            '<@(_inputs)'
     323          ],
     324        },
     325        {
     326          'action_name': 'XLinkNames',
     327          'inputs': [
     328            '../dom/make_names.pl',
     329            '../svg/xlinkattrs.in',
     330          ],
     331          'outputs': [
     332            '<(SHARED_INTERMEDIATE_DIR)/webkit/XLinkNames.cpp',
     333            '<(SHARED_INTERMEDIATE_DIR)/webkit/XLinkNames.h',
     334          ],
     335          'action': [
     336            'python',
     337            '<(chromium_src_dir)/webkit/build/action_makenames.py',
     338            '<@(_outputs)',
     339            '--',
     340            '<@(_inputs)',
     341            '--',
     342            '--extraDefines', '<(feature_defines)'
     343          ],
     344        },
     345        {
     346          'action_name': 'XMLNames',
     347          'inputs': [
     348            '../dom/make_names.pl',
     349            '../xml/xmlattrs.in',
     350          ],
     351          'outputs': [
     352            '<(SHARED_INTERMEDIATE_DIR)/webkit/XMLNames.cpp',
     353            '<(SHARED_INTERMEDIATE_DIR)/webkit/XMLNames.h',
     354          ],
     355          'action': [
     356            'python',
     357            '<(chromium_src_dir)/webkit/build/action_makenames.py',
     358            '<@(_outputs)',
     359            '--',
     360            '<@(_inputs)',
     361            '--',
     362            '--extraDefines', '<(feature_defines)'
     363          ],
     364        },
     365        {
     366          'action_name': 'tokenizer',
     367          'inputs': [
     368            '../css/maketokenizer',
     369            '../css/tokenizer.flex',
     370          ],
     371          'outputs': [
     372            '<(SHARED_INTERMEDIATE_DIR)/webkit/tokenizer.cpp',
     373          ],
     374          'action': [
     375            'python',
     376            '<(chromium_src_dir)/webkit/build/action_maketokenizer.py',
     377            '<@(_outputs)',
     378            '--',
     379            '<@(_inputs)'
     380          ],
     381        },
     382      ],
     383      'rules': [
     384        # Rules to build derived sources.
     385        {
     386          'rule_name': 'bison',
     387          'extension': 'y',
     388          'outputs': [
     389            '<(SHARED_INTERMEDIATE_DIR)/webkit/<(RULE_INPUT_ROOT).cpp',
     390            '<(SHARED_INTERMEDIATE_DIR)/webkit/<(RULE_INPUT_ROOT).h'
     391          ],
     392          'action': [
     393            'python',
     394            '<(chromium_src_dir)/webkit/build/rule_bison.py',
     395            '<(RULE_INPUT_PATH)',
     396            '<(SHARED_INTERMEDIATE_DIR)/webkit'
     397          ],
     398        },
     399        {
     400          'rule_name': 'gperf',
     401          'extension': 'gperf',
     402          # gperf output is only ever #included by other source files.  As
     403          # such, process_outputs_as_sources is off.  Some gperf output is
     404          # #included as *.c and some as *.cpp.  Since there's no way to tell
     405          # which one will be needed in a rule definition, declare both as
     406          # outputs.  The harness script will generate one file and copy it to
     407          # the other.
     408          #
     409          # This rule places outputs in SHARED_INTERMEDIATE_DIR because glue
     410          # needs access to HTMLEntityNames.c.
     411          'outputs': [
     412            '<(SHARED_INTERMEDIATE_DIR)/webkit/<(RULE_INPUT_ROOT).c',
     413            '<(SHARED_INTERMEDIATE_DIR)/webkit/<(RULE_INPUT_ROOT).cpp',
     414          ],
     415          'action': [
     416            'python',
     417            '<(chromium_src_dir)/webkit/build/rule_gperf.py',
     418            '<(RULE_INPUT_PATH)',
     419            '<(SHARED_INTERMEDIATE_DIR)/webkit'
     420          ],
     421          'process_outputs_as_sources': 0,
     422        },
     423        # Rule to build generated JavaScript (V8) bindings from .idl source.
     424        {
     425          'rule_name': 'binding',
     426          'extension': 'idl',
     427          'msvs_external_rule': 1,
     428          'inputs': [
     429            '../bindings/scripts/generate-bindings.pl',
     430            '../bindings/scripts/CodeGenerator.pm',
     431            '../bindings/scripts/CodeGeneratorV8.pm',
     432            '../bindings/scripts/IDLParser.pm',
     433            '../bindings/scripts/IDLStructure.pm',
     434          ],
     435          'outputs': [
     436            # FIXME:  The .cpp file should be in webkit/bindings once
     437            # we coax GYP into supporting it (see 'action' below).
     438            '<(SHARED_INTERMEDIATE_DIR)/webcore/bindings/V8<(RULE_INPUT_ROOT).cpp',
     439            '<(SHARED_INTERMEDIATE_DIR)/webkit/bindings/V8<(RULE_INPUT_ROOT).h',
     440          ],
     441          'variables': {
     442            'generator_include_dirs': [
     443              '--include', '../css',
     444              '--include', '../dom',
     445              '--include', '../html',
     446              '--include', '../notifications',
     447              '--include', '../page',
     448              '--include', '../plugins',
     449              '--include', '../svg',
     450              '--include', '../websockets',
     451              '--include', '../workers',
     452              '--include', '../xml',
     453            ],
     454          },
     455          # FIXME:  Note that we put the .cpp files in webcore/bindings
     456          # but the .h files in webkit/bindings.  This is to work around
     457          # the unfortunate fact that GYP strips duplicate arguments
     458          # from lists.  When we have a better GYP way to suppress that
     459          # behavior, change the output location.
     460          'action': [
     461            'python',
     462            '<(chromium_src_dir)/webkit/build/rule_binding.py',
     463            '<(RULE_INPUT_PATH)',
     464            '<(SHARED_INTERMEDIATE_DIR)/webcore/bindings',
     465            '<(SHARED_INTERMEDIATE_DIR)/webkit/bindings',
     466            '--',
     467            '<@(_inputs)',
     468            '--',
     469            '--defines', '<(feature_defines) LANGUAGE_JAVASCRIPT V8_BINDING',
     470            '--generator', 'V8',
     471            '<@(generator_include_dirs)'
     472          ],
     473          'message': 'Generating binding from <(RULE_INPUT_PATH)',
     474        },
     475      ],
     476    },
     477    {
     478      'target_name': 'webcore_bindings',
     479      'type': '<(library)',
     480      'hard_dependency': 1,
     481      'dependencies': [
     482        'webcore_bindings_sources',
     483        '../../JavaScriptCore/JavaScriptCore.gyp/JavaScriptCore.gyp:pcre',
     484        '../../JavaScriptCore/JavaScriptCore.gyp/JavaScriptCore.gyp:wtf',
     485        '<(chromium_src_dir)/build/temp_gyp/googleurl.gyp:googleurl',
     486        '<(chromium_src_dir)/skia/skia.gyp:skia',
     487        '<(chromium_src_dir)/third_party/libjpeg/libjpeg.gyp:libjpeg',
     488        '<(chromium_src_dir)/third_party/libpng/libpng.gyp:libpng',
     489        '<(chromium_src_dir)/third_party/libxml/libxml.gyp:libxml',
     490        '<(chromium_src_dir)/third_party/libxslt/libxslt.gyp:libxslt',
     491        '<(chromium_src_dir)/third_party/npapi/npapi.gyp:npapi',
     492        '<(chromium_src_dir)/third_party/sqlite/sqlite.gyp:sqlite',
     493      ],
     494      'include_dirs': [
     495        '<(INTERMEDIATE_DIR)',
     496        # FIXME:  Remove <(SHARED_INTERMEDIATE_DIR)/webcore when we
     497        # can entice gyp into letting us put both the .cpp and .h
     498        # files in the same output directory.
     499        '<(SHARED_INTERMEDIATE_DIR)/webcore',
     500        '<(SHARED_INTERMEDIATE_DIR)/webkit',
     501        '<(SHARED_INTERMEDIATE_DIR)/webkit/bindings',
     502        '<@(webcore_include_dirs)',
     503      ],
     504      'direct_dependent_settings': {
     505        'include_dirs': [
     506          '<(SHARED_INTERMEDIATE_DIR)/webkit',
     507          '<(SHARED_INTERMEDIATE_DIR)/webkit/bindings',
     508        ],
     509      },
     510      'sources': [
     511        # This file includes all the .cpp files generated from the .idl files
     512        # in webcore_files.
     513        '../bindings/v8/DerivedSourcesAllInOne.cpp',
     514
     515        # Additional .cpp files from webcore_bindings_sources actions.
     516        '<(SHARED_INTERMEDIATE_DIR)/webkit/HTMLElementFactory.cpp',
     517        '<(SHARED_INTERMEDIATE_DIR)/webkit/HTMLNames.cpp',
     518        '<(SHARED_INTERMEDIATE_DIR)/webkit/SVGElementFactory.cpp',
     519        '<(SHARED_INTERMEDIATE_DIR)/webkit/SVGNames.cpp',
     520        '<(SHARED_INTERMEDIATE_DIR)/webkit/UserAgentStyleSheetsData.cpp',
     521        '<(SHARED_INTERMEDIATE_DIR)/webkit/XLinkNames.cpp',
     522        '<(SHARED_INTERMEDIATE_DIR)/webkit/XMLNames.cpp',
     523
     524        # Additional .cpp files from the webcore_bindings_sources rules.
     525        '<(SHARED_INTERMEDIATE_DIR)/webkit/CSSGrammar.cpp',
     526        '<(SHARED_INTERMEDIATE_DIR)/webkit/XPathGrammar.cpp',
     527      ],
     528      'conditions': [
     529        ['javascript_engine=="v8"', {
     530          'dependencies': [
     531            '<(chromium_src_dir)/v8/tools/gyp/v8.gyp:v8',
     532          ],
     533        }],
     534        ['OS=="mac"', {
     535          'include_dirs': [
     536            '../../WebKitLibraries',
     537          ],
     538        }],
     539        ['OS=="win"', {
     540          'dependencies': [
     541            '<(chromium_src_dir)/build/win/system.gyp:cygwin'
     542          ],
     543          'defines': [
     544            'WEBCORE_NAVIGATOR_PLATFORM="Win32"',
     545            '__PRETTY_FUNCTION__=__FUNCTION__',
     546          ],
     547          # This is needed because Event.h in this directory is blocked
     548          # by a system header on windows.
     549          'include_dirs++': ['../dom'],
     550          'direct_dependent_settings': {
     551            'include_dirs+++': ['../dom'],
     552          },
     553        }],
     554        ['OS!="win" and remove_webcore_debug_symbols==1', {
     555          'configurations': {
     556            'Debug': {
     557              'cflags!': ['-g'],
     558            }
     559          },
     560        }],
     561      ],
     562    },
     563    {
     564      'target_name': 'webcore',
     565      'type': '<(library)',
     566      'msvs_guid': '1C16337B-ACF3-4D03-AA90-851C5B5EADA6',
     567      'dependencies': [
     568        'webcore_bindings',
     569        '../../JavaScriptCore/JavaScriptCore.gyp/JavaScriptCore.gyp:pcre',
     570        '../../JavaScriptCore/JavaScriptCore.gyp/JavaScriptCore.gyp:wtf',
     571        '<(chromium_src_dir)/build/temp_gyp/googleurl.gyp:googleurl',
     572        '<(chromium_src_dir)/skia/skia.gyp:skia',
     573        '<(chromium_src_dir)/third_party/libjpeg/libjpeg.gyp:libjpeg',
     574        '<(chromium_src_dir)/third_party/libpng/libpng.gyp:libpng',
     575        '<(chromium_src_dir)/third_party/libxml/libxml.gyp:libxml',
     576        '<(chromium_src_dir)/third_party/libxslt/libxslt.gyp:libxslt',
     577        '<(chromium_src_dir)/third_party/npapi/npapi.gyp:npapi',
     578        '<(chromium_src_dir)/third_party/sqlite/sqlite.gyp:sqlite',
     579      ],
     580      'defines': [
     581        'WEBCORE_NAVIGATOR_VENDOR="Google Inc."',
     582      ],
     583      'include_dirs': [
     584        '<(INTERMEDIATE_DIR)',
     585        '<@(webcore_include_dirs)',
     586      ],
     587      'sources': [
     588        '<@(webcore_files)',
     589
     590        # For WebCoreSystemInterface, Mac-only.
     591        '../../WebKit/mac/WebCoreSupport/WebSystemInterface.m',
     592      ],
     593      'sources/': [
     594        # Exclude JSC custom bindings.
     595        ['exclude', 'bindings/js'],
     596
     597        # Fortunately, many things can be excluded by using broad patterns.
     598
     599        # Exclude things that don't apply to the Chromium platform on the basis
     600        # of their enclosing directories and tags at the ends of their
     601        # filenames.
     602        ['exclude', '(android|cairo|cf|cg|curl|gtk|haiku|linux|mac|opentype|posix|qt|soup|symbian|win|wx)/'],
     603        ['exclude', '(?<!Chromium)(SVGAllInOne|Android|Cairo|CF|CG|Curl|Gtk|Linux|Mac|OpenType|POSIX|Posix|Qt|Safari|Soup|Symbian|Win|Wx)\\.(cpp|mm?)$'],
     604
     605        # JSC-only.
     606        ['exclude', 'inspector/JavaScript[^/]*\\.cpp$'],
     607
     608        # ENABLE_OFFLINE_WEB_APPLICATIONS, exclude most of webcore's impl
     609        ['exclude', 'loader/appcache/'],
     610        ['include', 'loader/appcache/ApplicationCacheHost\.h$'],
     611        ['include', 'loader/appcache/DOMApplicationCache\.(h|cpp)$'],
     612
     613        # SVG_FILTERS only.
     614        ['exclude', '(platform|svg)/graphics/filters/'],
     615        ['exclude', 'svg/Filter[^/]*\\.cpp$'],
     616        ['exclude', 'svg/SVG(FE|Filter)[^/]*\\.cpp$'],
     617
     618        # Exclude some DB-related files.
     619        ['exclude', 'platform/sql/SQLiteFileSystem.cpp'],
     620      ],
     621      'sources!': [
    449622        # A few things can't be excluded by patterns.  List them individually.
    450623
     
    501674      'direct_dependent_settings': {
    502675        'include_dirs': [
    503           '<(SHARED_INTERMEDIATE_DIR)/webkit',
    504           '<(SHARED_INTERMEDIATE_DIR)/webkit/bindings',
    505676          '<@(webcore_include_dirs)',
    506677        ],
     
    510681      },
    511682      'export_dependent_settings': [
     683        'webcore_bindings',
    512684        '../../JavaScriptCore/JavaScriptCore.gyp/JavaScriptCore.gyp:wtf',
    513685        '<(chromium_src_dir)/build/temp_gyp/googleurl.gyp:googleurl',
     
    754926        }],
    755927        ['OS=="win"', {
    756           'dependencies': ['<(chromium_src_dir)/build/win/system.gyp:cygwin'],
     928          'dependencies': [
     929            '<(chromium_src_dir)/build/win/system.gyp:cygwin'
     930          ],
    757931          'sources/': [
    758932            ['exclude', 'Posix\\.cpp$'],
     
    773947          },
    774948        }],
    775         ['OS!="linux" and OS!="freebsd"', {'sources/': [['exclude', '(Gtk|Linux)\\.cpp$']]}],
    776         ['OS!="mac"', {'sources/': [['exclude', 'Mac\\.(cpp|mm?)$']]}],
     949        ['OS!="linux" and OS!="freebsd"', {
     950          'sources/': [['exclude', '(Gtk|Linux)\\.cpp$']]
     951        }],
     952        ['OS!="mac"', {
     953          'sources/': [['exclude', 'Mac\\.(cpp|mm?)$']]
     954        }],
    777955        ['OS!="win"', {
    778956          'sources/': [
  • trunk/WebCore/WebCore.gypi

    r49686 r49693  
    11{
    22    'variables': {
    3         'webcore_files': [
     3        'webcore_bindings_idl_files': [
    44
    55            #IDL files
     
    375375            'xml/XPathResult.idl',
    376376            'xml/XSLTProcessor.idl',
     377        ],
     378        'webcore_files': [
    377379
    378380            # Source/Header Files
Note: See TracChangeset for help on using the changeset viewer.