需要在ubuntu 16.04
上安装Python3
需要使用的wxpython-4.0.3
,中间过程如下:
1 2 3 4 5 6 7 |
$ sudo apt-get install python3-pip $ sudo apt-get install build-essential $ sudo pip3 install --upgrade pip $ sudo pip3 install wxpython |
如果提示如下错误信息:
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 |
checking for pkg-config... no checking for GTK+ - version >= 3.0.0... no *** A new enough version of pkg-config was not found. *** See http://pkgconfig.sourceforge.net configure: error: The development files for GTK+ were not found. For GTK+ 2, please ensure that pkg-config is in the path and that gtk+-2.0.pc is installed. For GTK+ 1.2 please check that gtk-config is in the path, and that the version is 1.2.3 or above. Also check that the libraries returned by 'pkg-config gtk+-2.0 --libs' or 'gtk-config --libs' are in the LD_LIBRARY_PATH or equivalent. Error running configure ERROR: failed building wxWidgets Traceback (most recent call last): File "build.py", line 1321, in cmd_build_wx wxbuild.main(wxDir(), build_options) File "/tmp/pip-build-i74kd49w/wxpython/buildtools/build_wxwidgets.py", line 375, in main "Error running configure") File "/tmp/pip-build-i74kd49w/wxpython/buildtools/build_wxwidgets.py", line 85, in exitIfError raise builder.BuildError(msg) buildtools.builder.BuildError: Error running configure Finished command: build_wx (0m2.471s) Finished command: build (0m2.471s) Command '"/usr/bin/python3" -u build.py build' failed with exit code 1. ---------------------------------------- Command "/usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-i74kd49w/wxpython/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-kx0e4kl4-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-i74kd49w/wxpython/ |
则执行如下命令:
1 |
$ sudo apt-get install build-essential libgtk-3-dev |
如果出现如下错误信息:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 |
checking for GST... configure: WARNING: GStreamer 1.0 not available, falling back to 0.10 checking for GST... configure: WARNING: GStreamer 0.10 not available, falling back to 0.8 configure: error: GStreamer not available Error running configure ERROR: failed building wxWidgets Traceback (most recent call last): File "build.py", line 1321, in cmd_build_wx wxbuild.main(wxDir(), build_options) File "/tmp/pip-install-_6rbj1se/wxpython/buildtools/build_wxwidgets.py", line 375, in main "Error running configure") File "/tmp/pip-install-_6rbj1se/wxpython/buildtools/build_wxwidgets.py", line 85, in exitIfError raise builder.BuildError(msg) buildtools.builder.BuildError: Error running configure Finished command: build_wx (0m5.302s) Finished command: build (0m5.302s) Command '"/usr/bin/python3" -u build.py build' failed with exit code 1. ---------------------------------------- Command "/usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-_6rbj1se/wxpython/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-gkelw1g2/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-install-_6rbj1se/wxpython/ |
则执行如下命令:
1 |
$ sudo apt install libgstreamer-plugins-base1.0-dev |
如果出现如下错误信息:
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 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 |
../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp: In function ‘PyObject* meth_wxWebViewHistoryItem_GetUrl(PyObject*, PyObject*)’: ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp:24:10: error: ‘::wxWebViewHistoryItem’ has not been declared ::wxWebViewHistoryItem *sipCpp; ^ ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp:24:34: error: ‘sipCpp’ was not declared in this scope ::wxWebViewHistoryItem *sipCpp; ^ ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp: In function ‘PyObject* meth_wxWebViewHistoryItem_GetTitle(PyObject*, PyObject*)’: ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp:58:10: error: ‘::wxWebViewHistoryItem’ has not been declared ::wxWebViewHistoryItem *sipCpp; ^ ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp:58:34: error: ‘sipCpp’ was not declared in this scope ::wxWebViewHistoryItem *sipCpp; ^ ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp: In function ‘void release_wxWebViewHistoryItem(void*, int)’: ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp:90:32: error: ‘wxWebViewHistoryItem’ in namespace ‘::’ does not name a type delete reinterpret_cast< ::wxWebViewHistoryItem *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp:90:53: error: expected ‘>’ before ‘*’ token delete reinterpret_cast< ::wxWebViewHistoryItem *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp:90:53: error: expected ‘(’ before ‘*’ token ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp:90:54: error: expected primary-expression before ‘>’ token delete reinterpret_cast< ::wxWebViewHistoryItem *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp:90:64: error: expected ‘)’ before ‘;’ token delete reinterpret_cast< ::wxWebViewHistoryItem *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp: In function ‘void* init_type_wxWebViewHistoryItem(sipSimpleWrapper*, PyObject*, PyObject*, PyObject**, PyObject**, PyObject**)’: ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp:109:6: error: ‘::wxWebViewHistoryItem’ has not been declared ::wxWebViewHistoryItem *sipCpp = 0; ^ ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp:109:30: error: ‘sipCpp’ was not declared in this scope ::wxWebViewHistoryItem *sipCpp = 0; ^ ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp:127:27: error: expected type-specifier before ‘::’ token sipCpp = new ::wxWebViewHistoryItem(*url,*title); ^ ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp:134:24: error: type ‘<type error>’ argument given to ‘delete’, expected pointer delete sipCpp; ^ ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp:143:18: error: ‘wxWebViewHistoryItem’ in namespace ‘::’ does not name a type const ::wxWebViewHistoryItem* a0; ^ ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp:145:114: error: ‘a0’ was not declared in this scope if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, NULL, sipUnused, "J9", sipType_wxWebViewHistoryItem, &a0)) ^ ../../../../sip/cpp/sip_html2wxWebViewHistoryItem.cpp:148:27: error: expected type-specifier before ‘::’ token sipCpp = new ::wxWebViewHistoryItem(*a0); ^ ../../../../sip/cpp/sip_html2wxWebView.cpp:50:45: error: ‘wxWebView’ was not declared in this scope PyObject* _wxWebView_GetBackwardHistory(wxWebView* self) ^ ../../../../sip/cpp/sip_html2wxWebView.cpp:50:56: error: ‘self’ was not declared in this scope PyObject* _wxWebView_GetBackwardHistory(wxWebView* self) ^ ../../../../sip/cpp/sip_html2wxWebView.cpp:51:5: error: expected ‘,’ or ‘;’ before ‘{’ token { ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:18:1: error: expected class-name before ‘{’ token { ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:21:34: error: ‘wxWebViewHandler’ in namespace ‘::’ does not name a type sipwxWebViewHandler(const ::wxWebViewHandler&); ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp: In constructor ‘sipwxWebViewHandler::sipwxWebViewHandler(const wxString&)’: ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:42:89: error: expected class-name before ‘(’ token sipwxWebViewHandler::sipwxWebViewHandler(const ::wxString& scheme): ::wxWebViewHandler(scheme), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:42:89: error: expected ‘{’ before ‘(’ token ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp: At global scope: ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:42:97: error: expected constructor, destructor, or type conversion before ‘,’ token sipwxWebViewHandler::sipwxWebViewHandler(const ::wxString& scheme): ::wxWebViewHandler(scheme), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:42:108: error: expected constructor, destructor, or type conversion before ‘(’ token sipwxWebViewHandler::sipwxWebViewHandler(const ::wxString& scheme): ::wxWebViewHandler(scheme), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:47:51: error: ‘wxWebViewHandler’ in namespace ‘::’ does not name a type sipwxWebViewHandler::sipwxWebViewHandler(const ::wxWebViewHandler& a0): ::wxWebViewHandler(a0), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp: In constructor ‘sipwxWebViewHandler::sipwxWebViewHandler(const int&)’: ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:47:93: error: expected class-name before ‘(’ token sipwxWebViewHandler::sipwxWebViewHandler(const ::wxWebViewHandler& a0): ::wxWebViewHandler(a0), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:47:93: error: expected ‘{’ before ‘(’ token ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp: At global scope: ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:47:97: error: expected constructor, destructor, or type conversion before ‘,’ token sipwxWebViewHandler::sipwxWebViewHandler(const ::wxWebViewHandler& a0): ::wxWebViewHandler(a0), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:47:108: error: expected constructor, destructor, or type conversion before ‘(’ token sipwxWebViewHandler::sipwxWebViewHandler(const ::wxWebViewHandler& a0): ::wxWebViewHandler(a0), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp: In member function ‘wxString sipwxWebViewHandler::GetName() const’: ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:65:19: error: ‘::wxWebViewHandler’ has not been declared return ::wxWebViewHandler::GetName(); ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp: In function ‘PyObject* meth_wxWebViewHandler_GetFile(PyObject*, PyObject*, PyObject*)’: ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:99:10: error: ‘::wxWebViewHandler’ has not been declared ::wxWebViewHandler *sipCpp; ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:99:30: error: ‘sipCpp’ was not declared in this scope ::wxWebViewHandler *sipCpp; ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp: In function ‘PyObject* meth_wxWebViewHandler_GetName(PyObject*, PyObject*)’: ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:145:18: error: ‘wxWebViewHandler’ in namespace ‘::’ does not name a type const ::wxWebViewHandler *sipCpp; ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:147:91: error: ‘sipCpp’ was not declared in this scope if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_wxWebViewHandler, &sipCpp)) ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:154:66: error: ‘::wxWebViewHandler’ has not been declared sipRes = new ::wxString((sipSelfWasArg ? sipCpp-> ::wxWebViewHandler::GetName() : sipCpp->GetName())); ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp: In function ‘void release_wxWebViewHandler(void*, int)’: ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:180:36: error: ‘wxWebViewHandler’ in namespace ‘::’ does not name a type delete reinterpret_cast< ::wxWebViewHandler *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:180:53: error: expected ‘>’ before ‘*’ token delete reinterpret_cast< ::wxWebViewHandler *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:180:53: error: expected ‘(’ before ‘*’ token ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:180:54: error: expected primary-expression before ‘>’ token delete reinterpret_cast< ::wxWebViewHandler *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:180:64: error: expected ‘)’ before ‘;’ token delete reinterpret_cast< ::wxWebViewHandler *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp: In function ‘void* init_type_wxWebViewHandler(sipSimpleWrapper*, PyObject*, PyObject*, PyObject**, PyObject**, PyObject**)’: ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:234:18: error: ‘wxWebViewHandler’ in namespace ‘::’ does not name a type const ::wxWebViewHandler* a0; ^ ../../../../sip/cpp/sip_html2wxWebViewHandler.cpp:236:110: error: ‘a0’ was not declared in this scope if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, NULL, sipUnused, "J9", sipType_wxWebViewHandler, &a0)) ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:18:1: error: expected class-name before ‘{’ token { ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:21:36: error: ‘wxWebViewFSHandler’ in namespace ‘::’ does not name a type sipwxWebViewFSHandler(const ::wxWebViewFSHandler&); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp: In constructor ‘sipwxWebViewFSHandler::sipwxWebViewFSHandler(const wxString&)’: ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:42:95: error: expected class-name before ‘(’ token sipwxWebViewFSHandler::sipwxWebViewFSHandler(const ::wxString& scheme): ::wxWebViewFSHandler(scheme), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:42:95: error: expected ‘{’ before ‘(’ token ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp: At global scope: ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:42:103: error: expected constructor, destructor, or type conversion before ‘,’ token sipwxWebViewFSHandler::sipwxWebViewFSHandler(const ::wxString& scheme): ::wxWebViewFSHandler(scheme), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:42:114: error: expected constructor, destructor, or type conversion before ‘(’ token sipwxWebViewFSHandler::sipwxWebViewFSHandler(const ::wxString& scheme): ::wxWebViewFSHandler(scheme), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:47:55: error: ‘wxWebViewFSHandler’ in namespace ‘::’ does not name a type sipwxWebViewFSHandler::sipwxWebViewFSHandler(const ::wxWebViewFSHandler& a0): ::wxWebViewFSHandler(a0), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp: In constructor ‘sipwxWebViewFSHandler::sipwxWebViewFSHandler(const int&)’: ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:47:101: error: expected class-name before ‘(’ token sipwxWebViewFSHandler::sipwxWebViewFSHandler(const ::wxWebViewFSHandler& a0): ::wxWebViewFSHandler(a0), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:47:101: error: expected ‘{’ before ‘(’ token ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp: At global scope: ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:47:105: error: expected constructor, destructor, or type conversion before ‘,’ token sipwxWebViewFSHandler::sipwxWebViewFSHandler(const ::wxWebViewFSHandler& a0): ::wxWebViewFSHandler(a0), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:47:116: error: expected constructor, destructor, or type conversion before ‘(’ token sipwxWebViewFSHandler::sipwxWebViewFSHandler(const ::wxWebViewFSHandler& a0): ::wxWebViewFSHandler(a0), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp: In member function ‘wxFSFile* sipwxWebViewFSHandler::GetFile(const wxString&)’: ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:65:19: error: ‘::wxWebViewFSHandler’ has not been declared return ::wxWebViewFSHandler::GetFile(uri); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp: In member function ‘wxString sipwxWebViewFSHandler::GetName() const’: ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:80:19: error: ‘::wxWebViewFSHandler’ has not been declared return ::wxWebViewFSHandler::GetName(); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp: In function ‘PyObject* meth_wxWebViewFSHandler_GetFile(PyObject*, PyObject*, PyObject*)’: ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:99:10: error: ‘::wxWebViewFSHandler’ has not been declared ::wxWebViewFSHandler *sipCpp; ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:99:32: error: ‘sipCpp’ was not declared in this scope ::wxWebViewFSHandler *sipCpp; ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:112:50: error: ‘::wxWebViewFSHandler’ has not been declared sipRes = (sipSelfWasArg ? sipCpp-> ::wxWebViewFSHandler::GetFile(*uri) : sipCpp->GetFile(*uri)); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp: In function ‘void* cast_wxWebViewFSHandler(void*, const sipTypeDef*)’: ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:134:6: error: ‘::wxWebViewFSHandler’ has not been declared ::wxWebViewFSHandler *sipCpp = reinterpret_cast< ::wxWebViewFSHandler *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:134:28: error: ‘sipCpp’ was not declared in this scope ::wxWebViewFSHandler *sipCpp = reinterpret_cast< ::wxWebViewFSHandler *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:134:57: error: ‘wxWebViewFSHandler’ in namespace ‘::’ does not name a type ::wxWebViewFSHandler *sipCpp = reinterpret_cast< ::wxWebViewFSHandler *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:134:76: error: expected ‘>’ before ‘*’ token ::wxWebViewFSHandler *sipCpp = reinterpret_cast< ::wxWebViewFSHandler *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:134:76: error: expected ‘(’ before ‘*’ token ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:134:77: error: expected primary-expression before ‘>’ token ::wxWebViewFSHandler *sipCpp = reinterpret_cast< ::wxWebViewFSHandler *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:134:87: error: expected ‘)’ before ‘;’ token ::wxWebViewFSHandler *sipCpp = reinterpret_cast< ::wxWebViewFSHandler *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:137:31: error: ‘wxWebViewHandler’ in namespace ‘::’ does not name a type return static_cast< ::wxWebViewHandler *>(sipCpp); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:137:48: error: expected ‘>’ before ‘*’ token return static_cast< ::wxWebViewHandler *>(sipCpp); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:137:48: error: expected ‘(’ before ‘*’ token ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:137:49: error: expected primary-expression before ‘>’ token return static_cast< ::wxWebViewHandler *>(sipCpp); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:137:58: error: expected ‘)’ before ‘;’ token return static_cast< ::wxWebViewHandler *>(sipCpp); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp: In function ‘void release_wxWebViewFSHandler(void*, int)’: ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:152:36: error: ‘wxWebViewFSHandler’ in namespace ‘::’ does not name a type delete reinterpret_cast< ::wxWebViewFSHandler *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:152:55: error: expected ‘>’ before ‘*’ token delete reinterpret_cast< ::wxWebViewFSHandler *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:152:55: error: expected ‘(’ before ‘*’ token ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:152:56: error: expected primary-expression before ‘>’ token delete reinterpret_cast< ::wxWebViewFSHandler *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:152:66: error: expected ‘)’ before ‘;’ token delete reinterpret_cast< ::wxWebViewFSHandler *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp: In function ‘void* init_type_wxWebViewFSHandler(sipSimpleWrapper*, PyObject*, PyObject*, PyObject**, PyObject**, PyObject**)’: ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:206:18: error: ‘wxWebViewFSHandler’ in namespace ‘::’ does not name a type const ::wxWebViewFSHandler* a0; ^ ../../../../sip/cpp/sip_html2wxWebViewFSHandler.cpp:208:112: error: ‘a0’ was not declared in this scope if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, NULL, sipUnused, "J9", sipType_wxWebViewFSHandler, &a0)) ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:24:1: error: expected class-name before ‘{’ token { ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:27:34: error: ‘wxWebViewFactory’ in namespace ‘::’ does not name a type sipwxWebViewFactory(const ::wxWebViewFactory&); ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:35:8: error: ‘wxWebView’ in namespace ‘::’ does not name a type ::wxWebView* Create( ::wxWindow*, ::wxWindowID,const ::wxString&,const ::wxPoint&,const ::wxSize&,long,const ::wxString&); ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:36:8: error: ‘wxWebView’ in namespace ‘::’ does not name a type ::wxWebView* Create(); ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp: In constructor ‘sipwxWebViewFactory::sipwxWebViewFactory()’: ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:48:64: error: expected class-name before ‘(’ token sipwxWebViewFactory::sipwxWebViewFactory(): ::wxWebViewFactory(), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:48:64: error: expected ‘{’ before ‘(’ token ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp: At global scope: ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:48:65: error: expected unqualified-id before ‘)’ token sipwxWebViewFactory::sipwxWebViewFactory(): ::wxWebViewFactory(), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:48:77: error: expected constructor, destructor, or type conversion before ‘(’ token sipwxWebViewFactory::sipwxWebViewFactory(): ::wxWebViewFactory(), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:53:51: error: ‘wxWebViewFactory’ in namespace ‘::’ does not name a type sipwxWebViewFactory::sipwxWebViewFactory(const ::wxWebViewFactory& a0): ::wxWebViewFactory(a0), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp: In constructor ‘sipwxWebViewFactory::sipwxWebViewFactory(const int&)’: ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:53:93: error: expected class-name before ‘(’ token sipwxWebViewFactory::sipwxWebViewFactory(const ::wxWebViewFactory& a0): ::wxWebViewFactory(a0), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:53:93: error: expected ‘{’ before ‘(’ token ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp: At global scope: ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:53:97: error: expected constructor, destructor, or type conversion before ‘,’ token sipwxWebViewFactory::sipwxWebViewFactory(const ::wxWebViewFactory& a0): ::wxWebViewFactory(a0), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:53:108: error: expected constructor, destructor, or type conversion before ‘(’ token sipwxWebViewFactory::sipwxWebViewFactory(const ::wxWebViewFactory& a0): ::wxWebViewFactory(a0), sipPySelf(0) ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:63:4: error: ‘wxWebView’ in namespace ‘::’ does not name a type ::wxWebView* sipwxWebViewFactory::Create( ::wxWindow*parent, ::wxWindowID id,const ::wxString& url,const ::wxPoint& pos,const ::wxSize& size,long style,const ::wxString& name) ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:78:4: error: ‘wxWebView’ in namespace ‘::’ does not name a type ::wxWebView* sipwxWebViewFactory::Create() ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp: In function ‘PyObject* meth_wxWebViewFactory_Create(PyObject*, PyObject*, PyObject*)’: ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:108:10: error: ‘::wxWebViewFactory’ has not been declared ::wxWebViewFactory *sipCpp; ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:108:30: error: ‘sipCpp’ was not declared in this scope ::wxWebViewFactory *sipCpp; ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:112:14: error: ‘::wxWebView’ has not been declared ::wxWebView*sipRes; ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:112:26: error: ‘sipRes’ was not declared in this scope ::wxWebView*sipRes; ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:136:37: error: ‘wxWebViewDefaultURLStr’ was not declared in this scope const ::wxString& urldef = wxWebViewDefaultURLStr; ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:146:38: error: ‘wxWebViewNameStr’ was not declared in this scope const ::wxString& namedef = wxWebViewNameStr; ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:149:10: error: ‘::wxWebViewFactory’ has not been declared ::wxWebViewFactory *sipCpp; ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:149:30: error: ‘sipCpp’ was not declared in this scope ::wxWebViewFactory *sipCpp; ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:163:14: error: ‘::wxWebView’ has not been declared ::wxWebView*sipRes; ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:163:26: error: ‘sipRes’ was not declared in this scope ::wxWebView*sipRes; ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp: In function ‘void* cast_wxWebViewFactory(void*, const sipTypeDef*)’: ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:199:6: error: ‘::wxWebViewFactory’ has not been declared ::wxWebViewFactory *sipCpp = reinterpret_cast< ::wxWebViewFactory *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:199:26: error: ‘sipCpp’ was not declared in this scope ::wxWebViewFactory *sipCpp = reinterpret_cast< ::wxWebViewFactory *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:199:55: error: ‘wxWebViewFactory’ in namespace ‘::’ does not name a type ::wxWebViewFactory *sipCpp = reinterpret_cast< ::wxWebViewFactory *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:199:72: error: expected ‘>’ before ‘*’ token ::wxWebViewFactory *sipCpp = reinterpret_cast< ::wxWebViewFactory *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:199:72: error: expected ‘(’ before ‘*’ token ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:199:73: error: expected primary-expression before ‘>’ token ::wxWebViewFactory *sipCpp = reinterpret_cast< ::wxWebViewFactory *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:199:83: error: expected ‘)’ before ‘;’ token ::wxWebViewFactory *sipCpp = reinterpret_cast< ::wxWebViewFactory *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp: In function ‘void release_wxWebViewFactory(void*, int)’: ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:217:36: error: ‘wxWebViewFactory’ in namespace ‘::’ does not name a type delete reinterpret_cast< ::wxWebViewFactory *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:217:53: error: expected ‘>’ before ‘*’ token delete reinterpret_cast< ::wxWebViewFactory *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:217:53: error: expected ‘(’ before ‘*’ token ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:217:54: error: expected primary-expression before ‘>’ token delete reinterpret_cast< ::wxWebViewFactory *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:217:64: error: expected ‘)’ before ‘;’ token delete reinterpret_cast< ::wxWebViewFactory *>(sipCppV); ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp: In function ‘void* init_type_wxWebViewFactory(sipSimpleWrapper*, PyObject*, PyObject*, PyObject**, PyObject**, PyObject**)’: ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:255:18: error: ‘wxWebViewFactory’ in namespace ‘::’ does not name a type const ::wxWebViewFactory* a0; ^ ../../../../sip/cpp/sip_html2wxWebViewFactory.cpp:257:110: error: ‘a0’ was not declared in this scope if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, NULL, sipUnused, "J9", sipType_wxWebViewFactory, &a0)) ^ Waf: Leaving directory `/tmp/pip-install-uc7g8zv4/wxpython/build/waf/3.5/gtk3' Build failed -> task in '_html2' failed with exit status 1 (run with -v to display more information) -> task in '_html2' failed with exit status 1 (run with -v to display more information) -> task in '_html2' failed with exit status 1 (run with -v to display more information) -> task in '_html2' failed with exit status 1 (run with -v to display more information) -> task in '_html2' failed with exit status 1 (run with -v to display more information) Command '"/usr/bin/python3" /tmp/pip-install-uc7g8zv4/wxpython/bin/waf-2.0.7 --wx_config=/tmp/pip-install-uc7g8zv4/wxpython/build/wxbld/gtk3/wx-config --gtk3 --python="/usr/bin/python3" --out=build/waf/3.5/gtk3 configure build ' failed with exit code 1. Finished command: build_py (4m1.752s) Finished command: build (6m9.232s) Command '"/usr/bin/python3" -u build.py build' failed with exit code 1. |
则执行如下命令(显然是编译脚本忘记检查依赖项导致的):
1 |
$ sudo apt-get install libwebkitgtk-3.0-dev |