forked from couchbase/couchnode
-
Notifications
You must be signed in to change notification settings - Fork 0
/
binding.gyp
106 lines (106 loc) · 2.58 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
{
'targets': [{
'target_name': 'couchbase_impl',
'variables': {
'couchbase_root%': ''
},
'defines': [
'LCBUV_EMBEDDED_SOURCE'
],
'conditions': [
[ 'couchbase_root==""', {
'defines': [
'LIBCOUCHBASE_STATIC'
],
'dependencies': [
'deps/lcb/libcouchbase.gyp:couchbase'
]
}, {
'conditions': [
[ 'OS=="win"', {
'include_dirs': [
'<(couchbase_root)/include/'
],
'link_settings': {
'libraries': [
'-l<(couchbase_root)/lib/libcouchbase.lib'
]
},
'copies': [
{
'files': [ '<(couchbase_root)/bin/libcouchbase.dll' ],
'destination': '<(module_root_dir)/build/Release/'
},{
'files': [ '<(couchbase_root)/bin/libcouchbase.dll' ],
'destination': '<(module_root_dir)/build/Debug/'
}
],
}, {
'link_settings': {
'libraries': [
'-lcouchbase',
],
},
'include_dirs': [ '<(couchbase_root)/include' ],
'libraries+': [ '-L<(couchbase_root)/lib' ],
'conditions': [ [ 'OS!="mac"', {'libraries+':['-Wl,-rpath=<(couchbase_root)/lib']} ] ]
}]
]
}],
[ 'OS=="win"', {
'configurations': {
'Release': {
'msvs_settings': {
'VCCLCompilerTool': {
'ExceptionHandling': '2',
'RuntimeLibrary': 0,
},
},
},
},
}],
['OS=="mac"', {
'xcode_settings': {
'GCC_ENABLE_CPP_EXCEPTIONS': 'YES',
},
}],
['OS!="win"', {
'link_settings': {
'libraries': [
'$(EXTRA_LDFLAGS)'
],
},
'cflags': [
'-g',
'-fPIC',
'-Wall',
'-Wextra',
'-Wno-unused-variable',
'-Wno-unused-function',
'$(EXTRA_CFLAGS)',
'$(EXTRA_CPPFLAGS)',
'$(EXTRA_CXXFLAGS)',
],
'cflags_c':[
'-pedantic',
'-std=gnu99',
]
}]
],
'sources': [
'src/couchbase_impl.cc',
'src/control.cc',
'src/constants.cc',
'src/transcoder.cc',
'src/binding.cc',
'src/operations.cc',
'src/cas.cc',
'src/uv-plugin-all.c'
],
'include_dirs': [
'<!(node -e "require(\'nan\')")',
'./',
'./src/io'
]
}]
}