-
Notifications
You must be signed in to change notification settings - Fork 0
/
binding.gyp
96 lines (83 loc) · 2.3 KB
/
binding.gyp
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
{
'targets': [
# node threads .node
{
'target_name': 'node-threads',
'sources': [
'node-threads.cc',
'src/node-threads/nt-environment.cc',
'src/node-threads/node-threads-object.cc',
'src/node-threads/web-worker.cc',
'src/node-threads/node-threads-factory.cc',
'src/file/file_info.cc',
'src/emulation/process_emulation.cc',
'src/emulation/require.cc',
'src/thread/thread.cc',
'src/thread/thread-isolate.cc',
'src/thread/callback-manager.cc',
'src/work-items/work-item.cc',
'src/work-items/function-work-item.cc',
'src/work-items/web-work-item.cc',
'src/utilities/utilities.cc',
'src/utilities/error-handling.cc',
'src/utilities/json.cc'
],
'include_dirs': [
'./src',
'./src/node-threads',
'./src/file',
'./src/thread',
'./src/work-items',
'./src/emulation',
'./src/utilities',
'./src/threadpool',
'<!(node -e \"require(\'nan\')\")'
],
'dependencies': [
'threadpool'
],
'conditions': [
['OS=="linux"', {
'cflags': [
'-std=c++0x'
]
}],
['OS=="mac"', {
'cflags': [
'-std=c++11',
'-stdlib=libc++'
]
}]
]
},
# thread pool library
{
'target_name': 'threadpool',
'type': 'static_library',
'include_dirs': [
'./src/threadpool'
],
'sources': [
'./src/threadpool/synchronize.c',
'./src/threadpool/task_queue.c',
'./src/threadpool/thread_pool.c'
],
'conditions': [
['OS=="win"', {
'defines': [
'_WIN32'
]
}],
['OS=="linux"', {
'ldflags': [
'-pthread'
]
}],
['OS=="mac"', {
'ldflags': [
'-pthread'
]
}]
]
}]
}