forked from mikeseven/node-glfw
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbinding.gyp
56 lines (56 loc) · 1.38 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
{
'variables': {
'platform': '<(OS)',
},
'conditions': [
# Replace gyp platform with node platform, blech
['platform == "mac"', {'variables': {'platform': 'darwin'}}],
['platform == "win"', {'variables': {'platform': 'win32'}}],
],
'targets': [
{
#'target_name': 'glfw-<(platform)-<(target_arch)',
'target_name': 'glfw',
'defines': [
'VERSION=0.2.0'
],
'sources': [
'src/glfw.cc',
'deps/glew-1.10.0/src/glew.c',
],
'include_dirs': [
'<(module_root_dir)/deps/glew-1.10.0/include',
'<(module_root_dir)/deps/glfw-3.0.4/include',
],
'conditions': [
['OS=="linux"', {
'libraries': [
'<(module_root_dir)/deps/glfw-3.0.4/src/libglfw.so',
],
'ldflags': [
'-Wl,-rpath,\$$ORIGIN/../../deps/glfw-3.0.4/src',
]
}],
['OS=="mac"', {
'libraries': [
'<(module_root_dir)/deps/glfw-3.0.4/src/libglfw.so',
'-framework OpenGL',
],
'ldflags': [
'-Wl,-rpath,@loader_path/../../deps/glfw-3.0.4/src',
]
}],
['OS=="win"', {
'libraries': [
'opengl32.lib',
],
'defines' : [
'WIN32_LEAN_AND_MEAN',
'VC_EXTRALEAN'
]
},
],
],
}
]
}