Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 385 lines (370 sloc) 10.957 kB
4f3c8b3 @ry WIP
ry authored
1 {
bea4827 @ry More progress with gyp
ry authored
2 'variables': {
bca88b2 @ry support nosnapshot in vcbuild.bat
ry authored
3 'v8_use_snapshot%': 'true',
d2ab314 @ry Turn off V8's -Werror in GYP
ry authored
4 # Turn off -Werror in V8
5 # See http://codereview.chromium.org/8159015
6 'werror': '',
cc15299 @davepacheco build: add support for DTrace and postmortem
davepacheco authored
7 'node_use_dtrace%': 'false',
35a1421 Windows: Enable ETW events.
Igor Zinkovsky authored
8 'node_use_etw%': 'false',
a84adad @TooTallNate Default node_shared_v8 to false.
TooTallNate authored
9 'node_shared_v8%': 'false',
d03b848 @tchollingsworth build: support shared zlib
tchollingsworth authored
10 'node_shared_zlib%': 'false',
ae2ac4f @piscisaureus gyp: add js files to node project
piscisaureus authored
11 'node_use_openssl%': 'true',
fe464a2 @ry Rename GYP variable node_use_system_openssl to be consistent
ry authored
12 'node_shared_openssl%': 'false',
ae2ac4f @piscisaureus gyp: add js files to node project
piscisaureus authored
13 'library_files': [
14 'src/node.js',
15 'lib/_debugger.js',
16 'lib/_linklist.js',
17 'lib/assert.js',
18 'lib/buffer.js',
19 'lib/buffer_ieee754.js',
96e423a @ry Remove child_process_legacy
ry authored
20 'lib/child_process.js',
ae2ac4f @piscisaureus gyp: add js files to node project
piscisaureus authored
21 'lib/console.js',
22 'lib/constants.js',
23 'lib/crypto.js',
73b4b86 @ry Add cluster.js to node.gyp
ry authored
24 'lib/cluster.js',
71cce3f @ry Remove dgram_legacy
ry authored
25 'lib/dgram.js',
58e892d @ry Remove dns_legacy
ry authored
26 'lib/dns.js',
963459d @isaacs Domain feature
isaacs authored
27 'lib/domain.js',
ae2ac4f @piscisaureus gyp: add js files to node project
piscisaureus authored
28 'lib/events.js',
29 'lib/freelist.js',
30 'lib/fs.js',
31 'lib/http.js',
32 'lib/https.js',
33 'lib/module.js',
be0bb2d @ry Remove net_legacy timers_legacy
ry authored
34 'lib/net.js',
ae2ac4f @piscisaureus gyp: add js files to node project
piscisaureus authored
35 'lib/os.js',
36 'lib/path.js',
37 'lib/punycode.js',
38 'lib/querystring.js',
39 'lib/readline.js',
40 'lib/repl.js',
41 'lib/stream.js',
42 'lib/string_decoder.js',
43 'lib/sys.js',
be0bb2d @ry Remove net_legacy timers_legacy
ry authored
44 'lib/timers.js',
ae2ac4f @piscisaureus gyp: add js files to node project
piscisaureus authored
45 'lib/tls.js',
cdf5d91 @ry Remove tty_legacy
ry authored
46 'lib/tty.js',
ae2ac4f @piscisaureus gyp: add js files to node project
piscisaureus authored
47 'lib/url.js',
48 'lib/util.js',
49 'lib/vm.js',
5b8e1da @isaacs Initial pass at zlib bindings
isaacs authored
50 'lib/zlib.js',
ae2ac4f @piscisaureus gyp: add js files to node project
piscisaureus authored
51 ],
bea4827 @ry More progress with gyp
ry authored
52 },
53
4f3c8b3 @ry WIP
ry authored
54 'targets': [
55 {
56 'target_name': 'node',
57 'type': 'executable',
bea4827 @ry More progress with gyp
ry authored
58
4f3c8b3 @ry WIP
ry authored
59 'dependencies': [
9e55ba7 @piscisaureus dns: don't rely on libuv for c-ares integration
piscisaureus authored
60 'deps/cares/cares.gyp:cares',
db1bf67 @ry Move GYP file to the project root
ry authored
61 'deps/http_parser/http_parser.gyp:http_parser',
16788f4 @DrPizza Rename gyp files to produce useful solution names.
DrPizza authored
62 'deps/uv/uv.gyp:uv',
a979ab9 @ry Improve gyp build - now works kind of
ry authored
63 'node_js2c#host',
4f3c8b3 @ry WIP
ry authored
64 ],
a979ab9 @ry Improve gyp build - now works kind of
ry authored
65
66 'include_dirs': [
db1bf67 @ry Move GYP file to the project root
ry authored
67 'src',
68 'deps/uv/src/ares',
a979ab9 @ry Improve gyp build - now works kind of
ry authored
69 '<(SHARED_INTERMEDIATE_DIR)' # for node_natives.h
70 ],
71
4f3c8b3 @ry WIP
ry authored
72 'sources': [
8fe5712 fs watcher binding
Igor Zinkovsky authored
73 'src/fs_event_wrap.cc',
db1bf67 @ry Move GYP file to the project root
ry authored
74 'src/cares_wrap.cc',
75 'src/handle_wrap.cc',
76 'src/node.cc',
77 'src/node_buffer.cc',
78 'src/node_constants.cc',
79 'src/node_extensions.cc',
80 'src/node_file.cc',
81 'src/node_http_parser.cc',
82 'src/node_javascript.cc',
83 'src/node_main.cc',
84 'src/node_os.cc',
85 'src/node_script.cc',
f0ce984 @bnoordhuis fs: make fs.watchFile() work on windows
bnoordhuis authored
86 'src/node_stat_watcher.cc',
db1bf67 @ry Move GYP file to the project root
ry authored
87 'src/node_string.cc',
5b8e1da @isaacs Initial pass at zlib bindings
isaacs authored
88 'src/node_zlib.cc',
db1bf67 @ry Move GYP file to the project root
ry authored
89 'src/pipe_wrap.cc',
600a646 @piscisaureus process: use uv_signal instead of ev_signal
piscisaureus authored
90 'src/signal_wrap.cc',
db1bf67 @ry Move GYP file to the project root
ry authored
91 'src/stream_wrap.cc',
08032ef @bnoordhuis core: add reusable slab allocator
bnoordhuis authored
92 'src/slab_allocator.cc',
db1bf67 @ry Move GYP file to the project root
ry authored
93 'src/tcp_wrap.cc',
94 'src/timer_wrap.cc',
c1ae6ea @ry Add TTYWrap
ry authored
95 'src/tty_wrap.cc',
db1bf67 @ry Move GYP file to the project root
ry authored
96 'src/process_wrap.cc',
97b0000 @bnoordhuis build: add src/v8_typed_array.cc to gyp sources list
bnoordhuis authored
97 'src/v8_typed_array.cc',
06f750c @ry fix windows build
ry authored
98 'src/udp_wrap.cc',
64b4168 @DrPizza Add headers to improve the IDE experience.
DrPizza authored
99 # headers to make for a more pleasant IDE experience
100 'src/handle_wrap.h',
101 'src/node.h',
102 'src/node_buffer.h',
103 'src/node_constants.h',
104 'src/node_crypto.h',
105 'src/node_extensions.h',
106 'src/node_file.h',
107 'src/node_http_parser.h',
108 'src/node_javascript.h',
109 'src/node_os.h',
110 'src/node_root_certs.h',
111 'src/node_script.h',
112 'src/node_string.h',
113 'src/node_version.h',
5f04065 @bnoordhuis process: add _getActiveHandles(), _getActiveRequests()
bnoordhuis authored
114 'src/ngx-queue.h',
64b4168 @DrPizza Add headers to improve the IDE experience.
DrPizza authored
115 'src/pipe_wrap.h',
af98fc9 @indutny child_process: new stdio API for .spawn() method
indutny authored
116 'src/tty_wrap.h',
117 'src/tcp_wrap.h',
118 'src/udp_wrap.h',
64b4168 @DrPizza Add headers to improve the IDE experience.
DrPizza authored
119 'src/req_wrap.h',
08032ef @bnoordhuis core: add reusable slab allocator
bnoordhuis authored
120 'src/slab_allocator.h',
64b4168 @DrPizza Add headers to improve the IDE experience.
DrPizza authored
121 'src/stream_wrap.h',
9e55ba7 @piscisaureus dns: don't rely on libuv for c-ares integration
piscisaureus authored
122 'src/tree.h',
64b4168 @DrPizza Add headers to improve the IDE experience.
DrPizza authored
123 'src/v8_typed_array.h',
124 'deps/http_parser/http_parser.h',
125 '<(SHARED_INTERMEDIATE_DIR)/node_natives.h',
ae2ac4f @piscisaureus gyp: add js files to node project
piscisaureus authored
126 # javascript files to make for an even more pleasant IDE experience
127 '<@(library_files)',
c0c4bd4 @piscisaureus Add common.gypi to gyp output
piscisaureus authored
128 # node.gyp is added to the project by default.
129 'common.gypi',
a979ab9 @ry Improve gyp build - now works kind of
ry authored
130 ],
131
132 'defines': [
09dc577 @bnoordhuis build: move internals to separate header file
bnoordhuis authored
133 'NODE_WANT_INTERNALS=1',
a979ab9 @ry Improve gyp build - now works kind of
ry authored
134 'ARCH="<(target_arch)"',
135 'PLATFORM="<(OS)"',
4f3c8b3 @ry WIP
ry authored
136 ],
137
138 'conditions': [
a979ab9 @ry Improve gyp build - now works kind of
ry authored
139 [ 'node_use_openssl=="true"', {
71333b3 @DrPizza Modify GYP scripts for VC build
DrPizza authored
140 'defines': [ 'HAVE_OPENSSL=1' ],
db1bf67 @ry Move GYP file to the project root
ry authored
141 'sources': [ 'src/node_crypto.cc' ],
9f98698 @bnoordhuis build: configure node, v8, cares and openssl
bnoordhuis authored
142 'conditions': [
fe464a2 @ry Rename GYP variable node_use_system_openssl to be consistent
ry authored
143 [ 'node_shared_openssl=="false"', {
9f98698 @bnoordhuis build: configure node, v8, cares and openssl
bnoordhuis authored
144 'dependencies': [ './deps/openssl/openssl.gyp:openssl' ],
145 }]]
a979ab9 @ry Improve gyp build - now works kind of
ry authored
146 }, {
147 'defines': [ 'HAVE_OPENSSL=0' ]
148 }],
149
64b4168 @DrPizza Add headers to improve the IDE experience.
DrPizza authored
150 [ 'node_use_dtrace=="true"', {
cc15299 @davepacheco build: add support for DTrace and postmortem
davepacheco authored
151 'defines': [ 'HAVE_DTRACE=1' ],
152 'dependencies': [ 'node_dtrace_header' ],
153 'include_dirs': [ '<(SHARED_INTERMEDIATE_DIR)' ],
154 #
155 # node_dtrace_provider.cc and node_dtrace_ustack.cc do not actually
156 # exist. They're here to trick GYP into linking the corresponding
157 # object files into the final "node" executable. These files are
158 # generated by "dtrace -G" using custom actions below, and the
159 # GYP-generated Makefiles will properly build them when needed.
160 #
64b4168 @DrPizza Add headers to improve the IDE experience.
DrPizza authored
161 'sources': [
b3ddb89 @ry Don't compile in node_dtrace.cc when not supported
ry authored
162 'src/node_dtrace.cc',
cc15299 @davepacheco build: add support for DTrace and postmortem
davepacheco authored
163 'src/node_dtrace_provider.cc'
64b4168 @DrPizza Add headers to improve the IDE experience.
DrPizza authored
164 ],
cc15299 @davepacheco build: add support for DTrace and postmortem
davepacheco authored
165 'conditions': [ [
166 'target_arch=="ia32"', {
167 'sources': [ 'src/node_dtrace_ustack.cc' ]
168 }
169 ] ],
170 } ],
35a1421 Windows: Enable ETW events.
Igor Zinkovsky authored
171 [ 'node_use_etw=="true"', {
172 'defines': [ 'HAVE_ETW=1' ],
173 'dependencies': [ 'node_etw' ],
174 'sources': [
175 'src/node_win32_etw_provider.h',
176 'src/node_win32_etw_provider-inl.h',
177 'src/node_win32_etw_provider.cc',
178 'src/node_dtrace.cc',
179 '<(SHARED_INTERMEDIATE_DIR)/node_etw_provider.h',
180 '<(SHARED_INTERMEDIATE_DIR)/node_etw_provider.rc',
181 ]
182 } ],
f00c8bc @bnoordhuis build: fix --shared-v8 option
bnoordhuis authored
183 [ 'node_shared_v8=="false"', {
59ecf2c @isaacs Revert "Revert "build: support shared V8 properly""
isaacs authored
184 'sources': [
185 'deps/v8/include/v8.h',
186 'deps/v8/include/v8-debug.h',
187 ],
188 'dependencies': [ 'deps/v8/tools/gyp/v8.gyp:v8' ],
189 }],
190
d03b848 @tchollingsworth build: support shared zlib
tchollingsworth authored
191 [ 'node_shared_zlib=="false"', {
192 'dependencies': [ 'deps/zlib/zlib.gyp:zlib' ],
193 }],
194
4f3c8b3 @ry WIP
ry authored
195 [ 'OS=="win"', {
6ac8c55 @DrPizza Make MSVS build.
DrPizza authored
196 'sources': [
0187b65 @piscisaureus Move resource files to src/res.
piscisaureus authored
197 'src/res/node.rc',
6ac8c55 @DrPizza Make MSVS build.
DrPizza authored
198 ],
4f3c8b3 @ry WIP
ry authored
199 'defines': [
6ac8c55 @DrPizza Make MSVS build.
DrPizza authored
200 'FD_SETSIZE=1024',
79d9f62 @DrPizza Fix bad platform name.
DrPizza authored
201 # we need to use node's preferred "win32" rather than gyp's preferred "win"
202 'PLATFORM="win32"',
d52f502 @piscisaureus Windows: another attempt to support unicode argv
piscisaureus authored
203 '_UNICODE=1',
4f3c8b3 @ry WIP
ry authored
204 ],
1976288 @ry win: link to psapi.lib
ry authored
205 'libraries': [ '-lpsapi.lib' ]
acbfc40 @bnoordhuis build: fix add-on loading on freebsd
bnoordhuis authored
206 }, { # POSIX
a979ab9 @ry Improve gyp build - now works kind of
ry authored
207 'defines': [ '__POSIX__' ],
4f3c8b3 @ry WIP
ry authored
208 }],
209 [ 'OS=="mac"', {
a979ab9 @ry Improve gyp build - now works kind of
ry authored
210 'libraries': [ '-framework Carbon' ],
f2ba4ce @TooTallNate build: remove the old -DPLATFORM="mac" define
TooTallNate authored
211 'defines!': [
212 'PLATFORM="mac"',
213 ],
9ff86a2 @TooTallNate build: set `process.platform` to "darwin" on OS X
TooTallNate authored
214 'defines': [
215 # we need to use node's preferred "darwin" rather than gyp's preferred "mac"
216 'PLATFORM="darwin"',
217 ],
b433c42 @ry gyp: Support Linux
ry authored
218 }],
decd818 @bnoordhuis build: fix freebsd gyp build
bnoordhuis authored
219 [ 'OS=="freebsd"', {
220 'libraries': [
221 '-lutil',
222 '-lkvm',
223 ],
224 }],
13871fa @bnoordhuis build: fix sunos gyp build, include platform file
bnoordhuis authored
225 [ 'OS=="solaris"', {
226 'libraries': [
227 '-lkstat',
f70b138 @trentm always link sunos builds with libumem
trentm authored
228 '-lumem',
13871fa @bnoordhuis build: fix sunos gyp build, include platform file
bnoordhuis authored
229 ],
606a933 @TooTallNate build: set `process.platform` to "sunos" on SunOS
TooTallNate authored
230 'defines!': [
231 'PLATFORM="solaris"',
232 ],
233 'defines': [
234 # we need to use node's preferred "sunos"
235 # rather than gyp's preferred "solaris"
236 'PLATFORM="sunos"',
237 ],
13871fa @bnoordhuis build: fix sunos gyp build, include platform file
bnoordhuis authored
238 }],
16788f4 @DrPizza Rename gyp files to produce useful solution names.
DrPizza authored
239 ],
5691e8a @piscisaureus windows: fix typo in node.gyp
piscisaureus authored
240 'msvs_settings': {
16788f4 @DrPizza Rename gyp files to produce useful solution names.
DrPizza authored
241 'VCLinkerTool': {
242 'SubSystem': 1, # /subsystem:console
243 },
244 },
4f3c8b3 @ry WIP
ry authored
245 },
35a1421 Windows: Enable ETW events.
Igor Zinkovsky authored
246 # generate ETW header and resource files
247 {
248 'target_name': 'node_etw',
249 'type': 'none',
250 'conditions': [
251 [ 'node_use_etw=="true"', {
252 'actions': [
253 {
254 'action_name': 'node_etw',
255 'inputs': [ 'src/res/node_etw_provider.man' ],
256 'outputs': [ '<(SHARED_INTERMEDIATE_DIR)' ],
257 'action': [ 'mc <@(_inputs) -h <@(_outputs) -r <@(_outputs)' ]
258 }
259 ]
260 } ]
261 ]
262 },
4f3c8b3 @ry WIP
ry authored
263 {
264 'target_name': 'node_js2c',
265 'type': 'none',
266 'toolsets': ['host'],
267 'actions': [
268 {
269 'action_name': 'node_js2c',
a979ab9 @ry Improve gyp build - now works kind of
ry authored
270
4f3c8b3 @ry WIP
ry authored
271 'inputs': [
272 '<@(library_files)',
95fd517 @TooTallNate node.gyp: include the config.gypi file in the js2c inputs list
TooTallNate authored
273 './config.gypi',
4f3c8b3 @ry WIP
ry authored
274 ],
a979ab9 @ry Improve gyp build - now works kind of
ry authored
275
4f3c8b3 @ry WIP
ry authored
276 'outputs': [
277 '<(SHARED_INTERMEDIATE_DIR)/node_natives.h',
278 ],
a979ab9 @ry Improve gyp build - now works kind of
ry authored
279
280 # FIXME can the following conditions be shorted by just setting
281 # macros.py into some variable which then gets included in the
282 # action?
283
284 'conditions': [
35a1421 Windows: Enable ETW events.
Igor Zinkovsky authored
285 [ 'node_use_dtrace=="true" or node_use_etw=="true"', {
a979ab9 @ry Improve gyp build - now works kind of
ry authored
286 'action': [
287 'python',
db1bf67 @ry Move GYP file to the project root
ry authored
288 'tools/js2c.py',
a979ab9 @ry Improve gyp build - now works kind of
ry authored
289 '<@(_outputs)',
95fd517 @TooTallNate node.gyp: include the config.gypi file in the js2c inputs list
TooTallNate authored
290 '<@(_inputs)',
a979ab9 @ry Improve gyp build - now works kind of
ry authored
291 ],
292 }, { # No Dtrace
293 'action': [
294 'python',
db1bf67 @ry Move GYP file to the project root
ry authored
295 'tools/js2c.py',
a979ab9 @ry Improve gyp build - now works kind of
ry authored
296 '<@(_outputs)',
95fd517 @TooTallNate node.gyp: include the config.gypi file in the js2c inputs list
TooTallNate authored
297 '<@(_inputs)',
db1bf67 @ry Move GYP file to the project root
ry authored
298 'src/macros.py'
a979ab9 @ry Improve gyp build - now works kind of
ry authored
299 ],
300 }]
71333b3 @DrPizza Modify GYP scripts for VC build
DrPizza authored
301 ],
4f3c8b3 @ry WIP
ry authored
302 },
303 ],
304 }, # end node_js2c
cc15299 @davepacheco build: add support for DTrace and postmortem
davepacheco authored
305 {
306 'target_name': 'node_dtrace_header',
307 'type': 'none',
308 'conditions': [
309 [ 'node_use_dtrace=="true"', {
310 'actions': [
311 {
312 'action_name': 'node_dtrace_header',
313 'inputs': [ 'src/node_provider.d' ],
314 'outputs': [ '<(SHARED_INTERMEDIATE_DIR)/node_provider.h' ],
315 'action': [ 'dtrace', '-h', '-xnolibs', '-s', '<@(_inputs)',
316 '-o', '<@(_outputs)' ]
317 }
318 ]
319 } ]
320 ]
321 },
322 {
323 'target_name': 'node_dtrace_provider',
324 'type': 'none',
325 'conditions': [
326 [ 'node_use_dtrace=="true"', {
327 'actions': [
328 {
329 'action_name': 'node_dtrace_provider_o',
330 'inputs': [
331 'src/node_provider.d',
332 '<(PRODUCT_DIR)/obj.target/node/src/node_dtrace.o'
333 ],
334 'outputs': [
335 '<(PRODUCT_DIR)/obj.target/node/src/node_dtrace_provider.o'
336 ],
337 'action': [ 'dtrace', '-G', '-xnolibs', '-s', '<@(_inputs)',
338 '-o', '<@(_outputs)' ]
339 }
340 ]
341 } ]
342 ]
343 },
344 {
345 'target_name': 'node_dtrace_ustack',
346 'type': 'none',
347 'conditions': [
8559a4a @davepacheco Fix 64-bit SmartOS build
davepacheco authored
348 [ 'node_use_dtrace=="true" and target_arch=="ia32"', {
cc15299 @davepacheco build: add support for DTrace and postmortem
davepacheco authored
349 'actions': [
350 {
351 'action_name': 'node_dtrace_ustack_constants',
352 'inputs': [
353 '<(PRODUCT_DIR)/obj.target/deps/v8/tools/gyp/libv8_base.a'
354 ],
355 'outputs': [
356 '<(SHARED_INTERMEDIATE_DIR)/v8constants.h'
357 ],
358 'action': [
359 'tools/genv8constants.py',
360 '<@(_outputs)',
361 '<@(_inputs)'
362 ]
363 },
364 {
365 'action_name': 'node_dtrace_ustack',
366 'inputs': [
367 'src/v8ustack.d',
368 '<(SHARED_INTERMEDIATE_DIR)/v8constants.h'
369 ],
370 'outputs': [
371 '<(PRODUCT_DIR)/obj.target/node/src/node_dtrace_ustack.o'
372 ],
373 'action': [
374 'dtrace', '-32', '-I<(SHARED_INTERMEDIATE_DIR)', '-Isrc',
375 '-C', '-G', '-s', 'src/v8ustack.d', '-o', '<@(_outputs)',
376 ]
377 }
378 ]
379 } ],
380 ]
381 }
4f3c8b3 @ry WIP
ry authored
382 ] # end targets
383 }
384
Something went wrong with that request. Please try again.