forked from bithavoc/node-desktop-idle
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbinding.gyp
131 lines (131 loc) · 3.29 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
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
{
"targets": [
{
"target_name": "desktopIdle",
"sources": [
"src/desktop_idle.cc"
],
"conditions": [
['OS=="mac"', {
"sources": [
"src/mac/idle.mm"
],
"xcode_settings": {
"OTHER_LDFLAGS": ["-framework CoreGraphics"]
}
}],
[
'OS=="linux"',
{
"sources": [
"src/linux/idle.cc"
],
"variables": {
"pkg-config": "pkg-config"
},
"sources": [
"src/linux/idle.cc"
],
"direct_dependent_settings": {
"cflags": [
"<!@(<(pkg-config) --cflags x11 xext xscrnsaver)",
],
},
"link_settings": {
"ldflags": [
"<!@(<(pkg-config) --libs-only-other --libs-only-L x11 xext xscrnsaver)",
],
"libraries": [
"<!@(<(pkg-config) --libs-only-l x11 xext xscrnsaver)",
]
}
}
],
[
'OS=="freebsd"',
{
"sources": [
"src/linux/idle.cc"
],
"variables": {
"pkg-config": "pkg-config"
},
"sources": [
"src/linux/idle.cc"
],
"include_dirs": [
"/usr/local/include"
],
"direct_dependent_settings": {
"cflags": [
"<!@(<(pkg-config) --cflags x11 xext xscrnsaver)",
],
},
"link_settings": {
"ldflags": [
"<!@(<(pkg-config) --libs-only-other --libs-only-L x11 xext xscrnsaver)",
],
"libraries": [
"<!@(<(pkg-config) --libs-only-l x11 xext xscrnsaver)",
]
}
}
],
[
'OS=="openbsd"',
{
"sources": [
"src/linux/idle.cc"
],
"variables": {
"pkg-config": "pkg-config"
},
"sources": [
"src/linux/idle.cc"
],
"include_dirs": [
"/usr/X11R6/include"
],
"direct_dependent_settings": {
"cflags": [
"<!@(<(pkg-config) --cflags x11 xext xscrnsaver)",
],
},
"link_settings": {
"ldflags": [
"<!@(<(pkg-config) --libs-only-other --libs-only-L x11 xext xscrnsaver)",
],
"libraries": [
"<!@(<(pkg-config) --libs-only-l x11 xext xscrnsaver)",
]
}
}
],
[
'OS=="win"',
{
"sources": [
"src/win/idle.cc"
],
"msvs_settings": {
"VCLinkerTool": {
# Don't print a linker warning when no imports from either .exe are used.
"AdditionalOptions": ["/ignore:4199"],
}
}
}
]
]
},
{
"target_name": "action_after_build",
"type": "none",
"copies": [
{
"files": [ "<(PRODUCT_DIR)/desktopIdle.node" ],
"destination": "./"
}
]
}
]
}