-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbinding.gyp
95 lines (95 loc) · 2.21 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
{
"variables": {
"GTK_Root%": "c:/msys64/mingw64",
"conditions": [
[
"OS == 'mac'",
{
"pkg_env": "/usr/local/bin/pkg-config"
},
{
"pkg_env": ""
}
]
]
},
"targets": [
{
"target_name": "sevruga",
"sources": [
"src/sevruga.cc",
"src/sevruga_util.cc",
"src/sevruga_render.cc"
],
"variables": {
"packages": "librsvg-2.0",
"conditions": [
["OS!='win'", {
"libraries": "<!(<(pkg_env) pkg-config --libs-only-l <(packages))",
"ldflags": "<!(<(pkg_env) pkg-config --libs-only-L --libs-only-other <(packages))",
"cflags": "<!(<(pkg_env) pkg-config --cflags <(packages))"
}]
]
},
'conditions': [
["OS!='mac' and OS!='win'", {
"cflags": [
"<@(cflags)",
"-std=c++0x"
],
"ldflags": [
"<@(ldflags)"
],
"libraries": [
"<@(libraries)"
]
}],
["OS=='mac'", {
"xcode_settings": {
"OTHER_CFLAGS": [
"<@(cflags)"
],
"OTHER_LDFLAGS": [
"<@(ldflags)"
]
},
"libraries": [
"<@(libraries)"
]
}],
["OS=='win'", {
"include_dirs": [
"<(GTK_Root)\include\gdk-pixbuf-2.0",
"<(GTK_Root)\include\librsvg-2.0",
"<(GTK_Root)\include\cairo",
"<(GTK_Root)\include\glib-2.0",
"<(GTK_Root)\lib\glib-2.0\include"
],
"link_settings": {
"libraries": [
"libcairo.dll.a"
],
"library_dirs": [
"<(GTK_Root)\lib"
]
},
"msvs_settings": {
'VCCLCompilerTool': {
'AdditionalOptions': [
"/EHsc"
]
}
},
"copies": [
{
"destination": "build/Release/",
"files": [
"<!@(node -p \"require('fs').readdirSync('<(GTK_Root)/bin').filter(f=>f.match(/.*\.dll/ig)).map(f=>'<(GTK_Root)/bin/'+f).join(' ')\")"
]
}
]
}]
]
}
]
}