Postado Maio 12, 2018 7 anos BASE: (ela foi editada mais foi baseada no othire) Bom o meu erro é o seguinte eu tou compilando a source eu compilei deu tudo certo quando eu abro o executavel compilado acontece o seguinte independente de no config.lua esteja setada para usar mysql ela sempre busca por SQLite eu já adicionei as FLAGS na hora de compilar do mysql (_USE_MYSQL_) eu não sei porque ela sempre busca SQLite e não MYSQL que eu quero usar já revi toda configuração já recompilei umas 10x e nada Tutorial que eu sigo: Compiling tutorial for Windows using Microsoft Visual C++ - A modified Open Tibia Server You need Visual C++ 2010 Express Edition - http://filehippo.com/download_visualc_2010_express_edition/ Download Sources - https://github.com/Qwizer/rlmap740x Steps Download source code Create new project click File -> New -> Project... select Visual C++ -> General -> Empty Project set 'Name' for your project (I'll name it "server") set 'Location' for your project (It's "D:\projects" for me) leave 'Solution name' same as 'Name' ("server") 'Create directory' for solution should be checked Adding files go to 'Location\Name\Solution name' of your project (D:\projects\server\server), and copy there all content of source folder in Solution Explorer right click on Header Files -> Add -> Existing item..., right click on Sort by -> Type, select all header files (.h extension), don't forget about the msvc.h and workarounds.h (from 'compiler' folder) in Solution Explorer right click on Source Files -> Add -> Existing Item..., select all source files (.cpp extension) Setting project up go to (in menubar) Project -> Properties in the top left corner, set Configuration to 'Release' in tree widget on the left, go to Configuration Properties (you should be there anyway) General, Platform Toolset should be 'v100', Character Set should be 'Use Multi-Byte Character Set ' , rest leave as default C/C++ General click Additional Include Directories, drop down button shall appear, click on it, and in new window add following directories: libraries\inc\boost libraries\inc\libiconv libraries\inc\libxml libraries\inc\lua libraries\inc\mpir libraries\inc\mysql libraries\inc\sqlite Multi-processor compilation (optional), you can set it to 'Yes', that will speed compilation Preprocessor Preprocessor definitions, click on it, choose edit, and add: __USE_OTPCH__ __USE_MYSQL__ __SKULLSYSTEM__ __OLD_GUILD_SYSTEM__ __GUILDWARSLUARELOAD__ __ENABLE_SERVER_DIAGNOSTIC__ Precompiled Headers set Precompiled Header to 'Use' set Precompiled Header File to 'otpch.h' Linker General Additional Library Directories, click dropdown button, edit and add: libraries\lib (entire path, as exemple D:\otserv\projects\libraries\lib) Input Additional Dependencies, click dropdown button, edit and add: libmysql.lib libxml2.lib lua5.1.lib mpir.lib sqlite3.lib dbghelp.lib we are done here, press Ok in Solution Explorer -> Source Files, right click on otpch.cpp -> Properties make sure Configuration (top left) is 'Release' go to Configuration Properties -> C/C++ -> Precompiled Headers set Precompiled Header to 'Create' set Precompiled Header File to 'otpch.h' press Ok Compilation in the toolbar (top center) change configuration from 'Debug' to 'Release' click Build -> Build Solution Editado Maio 12, 2018 7 anos por italo1071 (veja o histórico de edições)
Participe da conversa
Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.