Skip to content

Commit 3015cbd

Browse files
committed
added release_dbg option and WD_BUILD_MONGOOSE and WD_BUILD_MODP_B64
1 parent 2d425eb commit 3015cbd

File tree

3 files changed

+49
-3
lines changed

3 files changed

+49
-3
lines changed

wd.gyp

Lines changed: 45 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
'WD_CONFIG_QWIDGET_VIEW%': '0',
99
'WD_CONFIG_QWIDGET_VIEW_ACCESSABILITY%': '0',
1010
'WD_CONFIG_QML_VIEW%': '0',
11+
'WD_BUILD_MONGOOSE%': '0',
12+
'WD_BUILD_MODP_B64%': '0',
1113
},
1214

1315
'conditions': [
@@ -25,6 +27,7 @@
2527

2628
'include_dirs': [
2729
'inc/',
30+
'src/',
2831
'<(QT_INC_PATH)',
2932
],
3033

@@ -34,7 +37,6 @@
3437

3538
'sources': [
3639
'src/Test/main.cc',
37-
'src/third_party/mongoose/mongoose.c',
3840
],
3941

4042
'conditions': [
@@ -74,6 +76,18 @@
7476
'-ldl',
7577
],
7678
} ],
79+
80+
[ '<(WD_BUILD_MONGOOSE) == 0', {
81+
'sources': [
82+
'src/third_party/mongoose/mongoose.c',
83+
],
84+
} ],
85+
86+
[ '<(WD_BUILD_MODP_B64) == 0', {
87+
'sources': [
88+
'src/third_party/modp_b64/modp_b64.cc',
89+
],
90+
} ],
7791
],
7892
},
7993
],
@@ -90,7 +104,6 @@
90104

91105
'target_defaults': {
92106
'cflags': [
93-
'-g',
94107
'-fPIC',
95108
'-Wall',
96109
'-W',
@@ -121,11 +134,27 @@
121134
'WD_CONFIG_QML_VIEW',
122135
],
123136
} ],
137+
[ 'mode == "debug"', {
138+
'cflags': [
139+
'-O0',
140+
'-g',
141+
],
142+
} ],
124143
[ 'mode == "release"', {
144+
'cflags': [
145+
'-O3',
146+
],
147+
125148
'defines': [
126149
'NDEBUG',
127150
],
128151
} ],
152+
[ 'mode == "release_dbg"', {
153+
'cflags': [
154+
'-O3',
155+
'-g',
156+
],
157+
} ]
129158
],
130159
},
131160

@@ -305,7 +334,6 @@
305334
'src/qtaskrunner.cc',
306335
'src/qwebviewext.h',
307336
'src/qwebviewext.cc',
308-
'src/third_party/modp_b64/modp_b64.cc',
309337
'src/third_party/webdriver/atoms.cc',
310338
'src/third_party/zlib/adler32.c',
311339
'src/third_party/zlib/contrib/minizip/ioapi.c',
@@ -326,6 +354,20 @@
326354
'action': [ '<(QT_BIN_PATH)/moc', '<(RULE_INPUT_PATH)', '-o', 'src/moc_<(RULE_INPUT_ROOT).cc' ],
327355
'message': 'Generating <(RULE_INPUT_ROOT).cc.',
328356
} ],
357+
358+
'conditions': [
359+
[ '<(WD_BUILD_MONGOOSE) == 1', {
360+
'sources': [
361+
'src/third_party/mongoose/mongoose.c',
362+
],
363+
} ],
364+
365+
[ '<(WD_BUILD_MODP_B64) == 1', {
366+
'sources': [
367+
'src/third_party/modp_b64/modp_b64.cc',
368+
],
369+
} ],
370+
],
329371
}, {
330372
'target_name': 'WebDriverShared',
331373
'type': 'shared_library',

wd.gypi

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
'WD_CONFIG_QWIDGET_VIEW': '1',
55
'WD_CONFIG_QWIDGET_VIEW_ACCESSABILITY': '0',
66
'WD_CONFIG_QML_VIEW': '1',
7+
'WD_BUILD_MONGOOSE': '1',
8+
'WD_BUILD_MODP_B64': '1',
79
'CISCO_QT_BIN_PATH': '/opt/qt4_nds/linux2_2/release/bin/',
810
'CISCO_QT_INC_PATH': '/opt/qt4_nds/linux2_2/release/include/',
911
'CISCO_QT_LIB_PATH': '/opt/qt4_nds/linux2_2/release/lib/',

wd.gypi.sample

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55
'WD_CONFIG_QWIDGET_VIEW': '1',
66
'WD_CONFIG_QWIDGET_VIEW_ACCESSABILITY': '0',
77
'WD_CONFIG_QML_VIEW': '1',
8+
'WD_BUILD_MONGOOSE': '1',
9+
'WD_BUILD_MODP_B64': '1',
810
'CISCO_QT_BIN_PATH': '/opt/qt4_nds/linux2_2/release/bin/',
911
'CISCO_QT_INC_PATH': '/opt/qt4_nds/linux2_2/release/include/',
1012
'CISCO_QT_LIB_PATH': '/opt/qt4_nds/linux2_2/release/lib/',

0 commit comments

Comments
 (0)