Home | History | Annotate | Download | only in temp_gyp
      1 # Copyright (c) 2009 The Chromium Authors. All rights reserved.
      2 # Use of this source code is governed by a BSD-style license that can be
      3 # found in the LICENSE file.
      4 
      5 # TODO(mark): Upstream this file to googleurl.
      6 {
      7   'variables': {
      8     'chromium_code': 1,
      9   },
     10   'targets': [
     11     {
     12       'target_name': 'googleurl',
     13       'type': '<(component)',
     14       'msvs_guid': 'EF5E94AB-B646-4E5B-A058-52EF07B8351C',
     15       'dependencies': [
     16         '../../base/base.gyp:base',
     17         '../../third_party/icu/icu.gyp:icudata',
     18         '../../third_party/icu/icu.gyp:icui18n',
     19         '../../third_party/icu/icu.gyp:icuuc',
     20       ],
     21       'sources': [
     22         '../../googleurl/src/gurl.cc',
     23         '../../googleurl/src/gurl.h',
     24         '../../googleurl/src/url_canon.h',
     25         '../../googleurl/src/url_canon_etc.cc',
     26         '../../googleurl/src/url_canon_fileurl.cc',
     27         '../../googleurl/src/url_canon_host.cc',
     28         '../../googleurl/src/url_canon_icu.cc',
     29         '../../googleurl/src/url_canon_icu.h',
     30         '../../googleurl/src/url_canon_internal.cc',
     31         '../../googleurl/src/url_canon_internal.h',
     32         '../../googleurl/src/url_canon_internal_file.h',
     33         '../../googleurl/src/url_canon_ip.cc',
     34         '../../googleurl/src/url_canon_ip.h',
     35         '../../googleurl/src/url_canon_mailtourl.cc',
     36         '../../googleurl/src/url_canon_path.cc',
     37         '../../googleurl/src/url_canon_pathurl.cc',
     38         '../../googleurl/src/url_canon_query.cc',
     39         '../../googleurl/src/url_canon_relative.cc',
     40         '../../googleurl/src/url_canon_stdstring.h',
     41         '../../googleurl/src/url_canon_stdurl.cc',
     42         '../../googleurl/src/url_file.h',
     43         '../../googleurl/src/url_parse.cc',
     44         '../../googleurl/src/url_parse.h',
     45         '../../googleurl/src/url_parse_file.cc',
     46         '../../googleurl/src/url_parse_internal.h',
     47         '../../googleurl/src/url_util.cc',
     48         '../../googleurl/src/url_util.h',
     49       ],
     50       'direct_dependent_settings': {
     51         'include_dirs': [
     52           '../..',
     53         ],
     54       },
     55       'conditions': [
     56         ['OS=="win" and component=="shared_library"', {
     57           'defines': [
     58             'GURL_DLL',
     59             'GURL_IMPLEMENTATION=1',
     60           ],
     61           'direct_dependent_settings': {
     62             'defines': [
     63               'GURL_DLL',
     64             ],
     65           },
     66         }],
     67       ],
     68     },
     69     {
     70       'target_name': 'googleurl_unittests',
     71       'dependencies': [
     72         'googleurl',
     73         '../../base/base.gyp:base_i18n',
     74         '../../base/base.gyp:test_support_base',
     75         '../../testing/gtest.gyp:gtest',
     76         '../../third_party/icu/icu.gyp:icuuc',
     77       ],
     78       'sources': [
     79         '../../googleurl/src/gurl_unittest.cc',
     80         '../../googleurl/src/url_canon_unittest.cc',
     81         '../../googleurl/src/url_parse_unittest.cc',
     82         '../../googleurl/src/url_test_utils.h',
     83         '../../googleurl/src/url_util_unittest.cc',
     84         # Make sure base and ICU are started up the 'Chromium way' since the
     85         # build is using the Chromium base & ICU.
     86         '../../base/test/run_all_unittests.cc',
     87       ],
     88       'conditions': [
     89         ['OS=="linux" or OS=="freebsd"', {
     90           'conditions': [
     91             ['linux_use_tcmalloc==1', {
     92               'dependencies': [
     93                 '../../base/allocator/allocator.gyp:allocator',
     94               ],
     95             }],
     96           ],
     97         }],
     98         # TODO(victorw): The unittest code uses inline functions that access
     99         # global variables, it also uses internal functions that we may not want
    100         # to export, so skip building unittests for windows multi dll build.
    101         # The googleurl functions are tested by the static library build.
    102         ['OS=="win" and component=="shared_library"', {
    103           'type': 'none',
    104         }, {
    105           'type': 'executable',
    106         }],
    107       ],
    108     },
    109   ],
    110 }
    111 
    112 # Local Variables:
    113 # tab-width:2
    114 # indent-tabs-mode:nil
    115 # End:
    116 # vim: set expandtab tabstop=2 shiftwidth=2:
    117