Use existing browser's profile to open file browser.
[chromium-blink-merge.git] / ppapi / native_client / native_client.gyp
blob5ac3d70e890de24a7418f8abab57eb593cf9f0b8
1 # Copyright (c) 2011 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.
6   'includes': [
7     '../../native_client/build/common.gypi',
8   ],
9   'conditions': [
10     ['disable_nacl==0 and disable_nacl_untrusted==0', {
11       'targets': [
12         {
13           'target_name': 'ppapi_lib',
14           'type': 'none',
15           'dependencies': [
16              '../../native_client/src/untrusted/pthread/pthread.gyp:pthread_lib',
17              '../../native_client/src/untrusted/irt_stub/irt_stub.gyp:ppapi_stub_lib',
18           ],
19           'copies': [
20             {
21               'destination': '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib32',
22               'files': [
23                   '<(DEPTH)/native_client/src/untrusted/irt_stub/libppapi.a',
24               ],
25             },
26             {
27               'destination': '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib64',
28               'files': [
29                   '<(DEPTH)/native_client/src/untrusted/irt_stub/libppapi.a',
30               ],
31             },
32             {
33               'destination': '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/libarm',
34               'files': [
35                 '<(DEPTH)/native_client/src/untrusted/irt_stub/libppapi.a',
36               ],
37             },
38           ],
39         },
40         {
41           'target_name': 'nacl_irt',
42           'type': 'none',
43           'variables': {
44             'nexe_target': 'nacl_irt',
45             'out64': '<(PRODUCT_DIR)/nacl_irt_x86_64.nexe',
46             'out32': '<(PRODUCT_DIR)/nacl_irt_x86_32.nexe',
47             'out_arm': '<(PRODUCT_DIR)/nacl_irt_arm.nexe',
48             'build_glibc': 0,
49             'build_newlib': 1,
50             'include_dirs': [
51               'lib/gl/include',
52               '..',
53             ],
54             'link_flags': [
55               '-Wl,--start-group',
56               '-lirt_browser',
57               '-lppruntime',
58               '-lsrpc',
59               '-limc_syscalls',
60               '-lplatform',
61               '-lgio',
62               '-Wl,--end-group',
63               '-lm',
64             ],
65             # See http://code.google.com/p/nativeclient/issues/detail?id=2691.
66             # The PNaCl linker (gold) does not implement the "-Ttext-segment"
67             # option.  However, with the linker for x86, the "-Ttext" option
68             # does not affect the executable's base address.
69             # TODO(olonho): simplify flags handling and avoid duplication
70             # with NaCl logic.
71             'conditions': [
72               ['target_arch!="arm"',
73                {
74                  'link_flags': [
75                    '-Wl,--section-start,.rodata=<(NACL_IRT_DATA_START)',
76                    '-Wl,-Ttext-segment=<(NACL_IRT_TEXT_START)',
77                  ]
78                }, { # target_arch == "arm"
79                  'link_flags': [
80                    '-Wl,--section-start,.rodata=<(NACL_IRT_DATA_START)',
81                    '-Wl,-Ttext=<(NACL_IRT_TEXT_START)',
82                    '--pnacl-allow-native',
83                    '-arch', 'arm',
84                    '-Wt,-mtls-use-call',
85                  ],
86                },
87              ],
88             ],
89             'sources': [
90             ],
91             'extra_args': [
92               '--strip-debug',
93             ],
94             'extra_deps64': [
95               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib64/libppruntime.a',
96               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib64/libirt_browser.a',
97               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib64/libsrpc.a',
98               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib64/libplatform.a',
99               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib64/libimc_syscalls.a',
100               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib64/libgio.a',
101             ],
102             'extra_deps32': [
103               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib32/libppruntime.a',
104               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib32/libirt_browser.a',
105               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib32/libsrpc.a',
106               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib32/libplatform.a',
107               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib32/libimc_syscalls.a',
108               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib32/libgio.a',
109             ],
110             'extra_deps_arm': [
111               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/libarm/libppruntime.a',
112               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/libarm/libirt_browser.a',
113               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/libarm/libsrpc.a',
114               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/libarm/libplatform.a',
115               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/libarm/libimc_syscalls.a',
116               '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/libarm/libgio.a',
117             ],
118           },
119           'dependencies': [
120             'src/shared/ppapi_proxy/ppapi_proxy_untrusted.gyp:ppruntime_lib',
121             '../../native_client/src/untrusted/irt/irt.gyp:irt_browser_lib',
122             '../../native_client/src/shared/srpc/srpc.gyp:srpc_lib',
123             '../../native_client/src/shared/platform/platform.gyp:platform_lib',
124             '../../native_client/src/untrusted/nacl/nacl.gyp:imc_syscalls_lib',
125             '../../native_client/src/shared/gio/gio.gyp:gio_lib',
126           ],
127         },
128       ],
129     }],
130   ],