-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbinding.gyp
66 lines (65 loc) · 1.83 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
# ===
# This is the main GYP file, which builds better-sqlite3 with SQLite3 itself.
# ===
{
'includes': ['deps/common.gypi'],
'targets': [
{
'target_name': 'better_sqlite3',
'dependencies': ['deps/sqlite3.gyp:sqlite3'],
'sources': ['src/better_sqlite3.cpp'],
'cflags_cc': ['-std=c++20'],
'xcode_settings': {
'OTHER_CPLUSPLUSFLAGS': ['-std=c++20', '-stdlib=libc++'],
},
'msvs_settings': {
'VCCLCompilerTool': {
'AdditionalOptions': [
'/std:c++20',
],
},
},
'conditions': [
['OS=="linux"', {
'ldflags': [
'-Wl,-Bsymbolic',
'-Wl,--exclude-libs,ALL',
],
}],
],
},
{
'target_name': 'zero_sqlite3',
'type': 'executable',
'dependencies': ['deps/sqlite3.gyp:locate_sqlite3'],
'sources': ['<(SHARED_INTERMEDIATE_DIR)/sqlite3/sqlite3.c', '<(SHARED_INTERMEDIATE_DIR)/sqlite3/shell.c'],
'include_dirs': ['<(SHARED_INTERMEDIATE_DIR)/sqlite3/'],
'direct_dependent_settings': {
'include_dirs': ['<(SHARED_INTERMEDIATE_DIR)/sqlite3/'],
},
'cflags': ['-std=c99', '-w'],
'xcode_settings': {
'OTHER_CFLAGS': ['-std=c99'],
'WARNING_CFLAGS': ['-w'],
},
'conditions': [
['sqlite3 == ""', {
'includes': ['deps/defines.gypi'],
}, {
'defines': [
# This is currently required by better-sqlite3.
'SQLITE_ENABLE_COLUMN_METADATA',
],
}]
],
'configurations': {
'Debug': {
'msvs_settings': { 'VCCLCompilerTool': { 'RuntimeLibrary': 1 } }, # static debug
},
'Release': {
'msvs_settings': { 'VCCLCompilerTool': { 'RuntimeLibrary': 0 } }, # static release
},
},
},
],
}