forked from sipwise/rtpengine
/
rtpengine.gyp
116 lines (113 loc) · 3.08 KB
/
rtpengine.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
{
'variables': {
'cflags_common': [
'-std=gnu99',
'-pthread',
'-fstack-protector-all',
'-fno-strict-aliasing',
'-Wall',
'-Werror',
'-Wimplicit-function-declaration',
'-Wno-format',
'-Wno-unused-variable',
'-Wno-deprecated-declarations',
# Make local installed libs be first on include path
'-Ivendor/usr/local/include',
'<!@(pkg-config --cflags glib-2.0)',
'<!@(pkg-config --cflags gthread-2.0)',
'<!@(pkg-config --cflags zlib)',
'<!@(pcre-config --cflags)',
'<!@(xmlrpc-c-config --cflags)',
# pkg-config --cflags from homebrew hiredis are incorrect
'-I/usr/local/opt/hiredis/include',
],
'macosx_deployment_target': '10.10',
},
'configurations': {
'Debug': {
'xcode_settings': {
'ONLY_ACTIVE_ARCH': 'YES',
'SDKROOT': 'macosx',
'MACOSX_DEPLOYMENT_TARGET': '<(macosx_deployment_target)',
},
},
'Release': {
'xcode_settings': {
'SDKROOT': 'macosx',
'MACOSX_DEPLOYMENT_TARGET': '<(macosx_deployment_target)',
},
},
}, # configurations
'target_defaults': {
'configurations': {
'Release': {
'defines': [
'NDEBUG',
],
'cflags': [
'<@(cflags_common)',
'-O3',
],
'xcode_settings': {
'GCC_OPTIMIZATION_LEVEL': '3',
},
},
'Debug': {
'defines': [
'__DEBUG=1',
],
'cflags': [
'<@(cflags_common)',
'-O0',
'-g',
],
'xcode_settings': {
'GCC_OPTIMIZATION_LEVEL': '0',
},
},
},
'default_configuration': 'Debug',
'xcode_settings': {
'OTHER_CFLAGS': ['<@(cflags_common)'],
'ALWAYS_SEARCH_USER_PATHS': 'NO',
'DEBUG_INFORMATION_FORMAT': 'dwarf-with-dsym',
'CODE_SIGN_IDENTITY': 'Developer ID Application',
},
},
'targets': [
{
'target_name': 'rtpengine',
'type': 'executable',
'include_dirs': [
'daemon',
'kernel-module',
],
'defines': [
'RTPENGINE_VERSION=\"dev\"',
],
'xcode_settings': {
'OTHER_LDFLAGS': [
'-lpthread',
'-Lvendor/usr/local/lib/',
'-lcrypto',
'-lssl',
'<!@(pkg-config --libs glib-2.0)',
'<!@(pkg-config --libs gthread-2.0)',
'<!@(pkg-config --libs zlib)',
'<!@(pkg-config --libs libpcre)',
'<!@(pcre-config --libs)',
'<!@(xmlrpc-c-config client --libs)',
'<!@(pkg-config --libs hiredis)',
],
},
'sources': [
'<!@(ls -1 daemon/*.h)',
'<!@(ls -1 daemon/*.c)',
],
'sources!': [
'daemon/poller.c',
'daemon/graphite.c',
],
},
],
}