330 error C2146: syntax error: missing ';' before identifier 'Sql_t'
Code: Select all
extern thread_local Sql_t* SqlHandle;
C2086: 'Sql_t *SqlHandle' : redefinition
Code: Select all
thread_local Sql_t* SqlHandle = nullptr;
Code: Select all
extern thread_local Sql_t* SqlHandle;
Code: Select all
thread_local Sql_t* SqlHandle = nullptr;
you need to use the visual studio 2015 compiler to compile it as wellAlice5150 wrote:I'm having the same error on map.cpp ('Sql_t *SqlHandle' : redefinition), and I just updated to 2015 Visual Studio. Any more tips on how to fix this? It's the only thing making my game server fail to build.
I'm running Visual Studio 2015. Is the compiler something separate?kjLotus wrote:you need to use the visual studio 2015 compiler to compile it as wellAlice5150 wrote:I'm having the same error on map.cpp ('Sql_t *SqlHandle' : redefinition), and I just updated to 2015 Visual Studio. Any more tips on how to fix this? It's the only thing making my game server fail to build.
I actually set it to v120 earlier per suggestion from a friend. Would you recommend v140? If so, where can I get it?kjLotus wrote:right click DSGame-server in solution explorer, properties, under General is "Platform Toolset", make sure thats Visual Studio 2015 (v140) (and the same for the other projects)
Yes, it won't compile with v120 (which is visual studio 2013). v140 comes with Visual Studio 2015.Alice5150 wrote:I actually set it to v120 earlier per suggestion from a friend. Would you recommend v140? If so, where can I get it?kjLotus wrote:right click DSGame-server in solution explorer, properties, under General is "Platform Toolset", make sure thats Visual Studio 2015 (v140) (and the same for the other projects)
Also, thanks for taking your time to help me with this, I appreciate it.
I started with default 2013, then changed it to v120 in the Properties. Go back to v140?kjLotus wrote:Yes, it won't compile with v120 (which is visual studio 2013). v140 comes with Visual Studio 2015.Alice5150 wrote:I actually set it to v120 earlier per suggestion from a friend. Would you recommend v140? If so, where can I get it?kjLotus wrote:right click DSGame-server in solution explorer, properties, under General is "Platform Toolset", make sure thats Visual Studio 2015 (v140) (and the same for the other projects)
Also, thanks for taking your time to help me with this, I appreciate it.
edit: assuming you did a custom install and included the C++ stuff instead of using default install