Solved libQtShadowsocks compilation issue
-
Hello guys
I am not a big pro so need a little help from the comunity with compiling libQtShadowsocks
I am already getting through QT installation and configuration and succefull cmake and than I stucked with project build.
Here is the lib I try to build https://github.com/shadowsocks/libQtShadowsocks/tree/master/lib
My system is Windows 8, QTCreator 4.4.1
Whyle building the lib I got the following errors:
Here are the errors:
C:\QTProjects\libQtShadowsocks-2.0.0beta\lib\cipher.cpp:153: error: C2440: 'reinterpret_cast': cannot convert from 'std::_Vector_iterator<std::_Vector_val<std::_Simple_types>>' to 'const char *' C:\QTProjects\libQtShadowsocks-2.0.0beta\lib\cipher.cpp:154: error: C2440: '': cannot convert from 'unsigned int' to 'std::string' C:\QTProjects\libQtShadowsocks-2.0.0beta\lib\cipher.cpp:176: error: C2440: 'reinterpret_cast': cannot convert from 'std::_Vector_iterator<std::_Vector_val<std::_Simple_types>>' to 'const char *' C:\QTProjects\libQtShadowsocks-2.0.0beta\lib\cipher.cpp:176: error: C2440: '': cannot convert from 'unsigned int' to 'std::string' C:\QTProjects\libQtShadowsocks-2.0.0beta\lib\cipher.cpp:192: error: C2440: 'reinterpret_cast': cannot convert from 'std::_Vector_iterator<std::_Vector_val<std::_Simple_types>>' to 'const char *' C:\QTProjects\libQtShadowsocks-2.0.0beta\lib\cipher.cpp:192: error: C2440: '': cannot convert from 'unsigned int' to 'std::string' Also I have some warnings like C:\QTProjects\libQtShadowsocks-2.0.0beta\lib\address.cpp:34: warning: C4273: 'QSS::Address::Address': inconsistent dll linkage C:\QTProjects\libQtShadowsocks-2.0.0beta\lib\address.cpp:40: warning: C4273: 'QSS::Address::Address': inconsistent dll linkage
Can somebody point me out what I'm doing wrong. Thanks a lot.
-
Hi and welcome to devnet,
What version of Qt are you using ?
What compiler ? Guessing MSVC but which one if it's the case ? -
Hi SGaist
QT 5.9.2 and MSVC 14
-
Hi
Did you give visual studio 2015 all service packs it can get ?
The library you are trying to use demand c++14 and you should be running update 3 in the hope
all needed 14 features are in fact supported.https://stackoverflow.com/questions/41308933/how-to-enable-c17-compiling-in-visual-studio
-
Hi mrjj
My current vc version is 14.0.25431.01 Update 3
Anyway I will try with vc 2017, thanks
-
That the answer from the official github thread
https://github.com/shadowsocks/libQtShadowsocks/issues/151
So the topic is solved. Thank you all.