File: libc%2B%2B.gyp

package info (click to toggle)
chromium-browser 57.0.2987.98-1~deb8u1
  • links: PTS, VCS
  • area: main
  • in suites: jessie
  • size: 2,637,852 kB
  • ctags: 2,544,394
  • sloc: cpp: 12,815,961; ansic: 3,676,222; python: 1,147,112; asm: 526,608; java: 523,212; xml: 286,794; perl: 92,654; sh: 86,408; objc: 73,271; makefile: 27,698; cs: 18,487; yacc: 13,031; tcl: 12,957; pascal: 4,875; ml: 4,716; lex: 3,904; sql: 3,862; ruby: 1,982; lisp: 1,508; php: 1,368; exp: 404; awk: 325; csh: 117; jsp: 39; sed: 37
file content (126 lines) | stat: -rw-r--r-- 3,916 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
# Copyright 2015 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

{
  'variables': {
    'libcxx_root': '../../buildtools/third_party/libc++',
  },
  'targets': [
    {
      'target_name': 'libcxx_proxy',
      'type': 'none',
      'toolsets': ['host', 'target'],
      'dependencies=': [
        'libc++',
      ],
      # Do not add dependency on libc++.so to dependents of this target. We
      # don't want to pass libc++.so on the command line to the linker, as that
      # would cause it to be linked into C executables which don't need it.
      # Instead, we supply -stdlib=libc++ and let the clang driver decide.
      'dependencies_traverse': 0,
      'variables': {
        # Don't add this target to the dependencies of targets with type=none.
        'link_dependency': 1,
      },
      'all_dependent_settings': {
        'target_conditions': [
          ['_type!="none"', {
            'cflags_cc': [
              '-nostdinc++',
              '-isystem<(libcxx_root)/trunk/include',
              '-isystem<(libcxx_root)/../libc++abi/trunk/include',
            ],
            'ldflags': [
              '-stdlib=libc++',
              # Normally the generator takes care of RPATH. Our case is special
              # because the generator is unaware of the libc++.so dependency.
              # Note that setting RPATH here is a potential security issue. See:
              # https://code.google.com/p/gyp/issues/detail?id=315
              '-Wl,-rpath,\$$ORIGIN/lib/',
            ],
            'library_dirs': [
              '<(PRODUCT_DIR)/lib/',
            ],
          }],
        ],
      },
    },
    {
      'target_name': 'libc++',
      'type': 'shared_library',
      'toolsets': ['host', 'target'],
      'dependencies=': [
        # libc++abi is linked statically into libc++.so. This allows us to get
        # both libc++ and libc++abi by passing '-stdlib=libc++'. If libc++abi
        # was a separate DSO, we'd have to link against it explicitly.
        '../libc++abi/libc++abi.gyp:libc++abi',
      ],
      'sources': [
        'trunk/src/algorithm.cpp',
        'trunk/src/any.cpp',
        'trunk/src/bind.cpp',
        'trunk/src/chrono.cpp',
        'trunk/src/condition_variable.cpp',
        'trunk/src/debug.cpp',
        'trunk/src/exception.cpp',
        'trunk/src/future.cpp',
        'trunk/src/hash.cpp',
        'trunk/src/ios.cpp',
        'trunk/src/iostream.cpp',
        'trunk/src/locale.cpp',
        'trunk/src/memory.cpp',
        'trunk/src/mutex.cpp',
        'trunk/src/new.cpp',
        'trunk/src/optional.cpp',
        'trunk/src/random.cpp',
        'trunk/src/regex.cpp',
        'trunk/src/shared_mutex.cpp',
        'trunk/src/stdexcept.cpp',
        'trunk/src/string.cpp',
        'trunk/src/strstream.cpp',
        'trunk/src/system_error.cpp',
        'trunk/src/thread.cpp',
        'trunk/src/typeinfo.cpp',
        'trunk/src/utility.cpp',
        'trunk/src/valarray.cpp',
      ],
      'cflags': [
        '-fPIC',
        '-fstrict-aliasing',
        '-pthread',
      ],
      'cflags_cc': [
        '-nostdinc++',
        '-isystem<(libcxx_root)/trunk/include',
        '-isystem<(libcxx_root)/../libc++abi/trunk/include',
        '-std=c++11',
      ],
      'cflags_cc!': [
        '-fno-exceptions',
        '-fno-rtti',
      ],
      'cflags!': [
        '-fvisibility=hidden',
      ],
      'defines': [
        'LIBCXX_BUILDING_LIBCXXABI',
      ],
      'ldflags': [
        '-nodefaultlibs',
      ],
      'ldflags!': [
        # -nodefaultlibs turns -pthread into a no-op, causing an unused argument
        # warning. Explicitly link with -lpthread instead.
        '-pthread',
      ],
      'libraries': [
        '-lc',
        '-lgcc_s',
        '-lm',
        '-lpthread',
        '-lrt',
      ],
    },
  ]
}