Also set warnings to errors for Windows build, fix one of those warnings.
continuous-integration/drone/push Build is passing Details

This commit is contained in:
Deukhoofd 2019-12-07 22:15:50 +01:00
parent ef28f9cd52
commit f5aa168f1b
2 changed files with 3 additions and 3 deletions

View File

@ -39,7 +39,7 @@ target_link_libraries(CreatureLibTests CreatureLibLibrary)
target_link_libraries(CreatureLibTests CreatureLibBattling) target_link_libraries(CreatureLibTests CreatureLibBattling)
if (WINDOWS) if (WINDOWS)
set(CMAKE_CXX_FLAGS "-m64 -Wa,-mbig-obj -Wl,-allow-multiple-definition") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -m64 -Wa,-mbig-obj -Wl,-allow-multiple-definition")
# Statically link libraries we need in Windows. # Statically link libraries we need in Windows.
target_link_libraries(CreatureLibCore -static -static-libgcc -static-libstdc++) target_link_libraries(CreatureLibCore -static -static-libgcc -static-libstdc++)
target_link_libraries(CreatureLibLibrary -static -static-libgcc -static-libstdc++) target_link_libraries(CreatureLibLibrary -static -static-libgcc -static-libstdc++)

View File

@ -11,10 +11,10 @@
namespace CreatureLib::Battling { namespace CreatureLib::Battling {
class ScriptAggregator { class ScriptAggregator {
std::vector<ScriptWrapper> _scripts; std::vector<ScriptWrapper> _scripts;
int _index = 0; size_t _index = 0;
bool _isSetSet = false; bool _isSetSet = false;
const std::vector<Script*>* _setScripts; const std::vector<Script*>* _setScripts;
int _setIndex; size_t _setIndex;
public: public:
ScriptAggregator(std::vector<ScriptWrapper> scripts) : _scripts(std::move(scripts)){}; ScriptAggregator(std::vector<ScriptWrapper> scripts) : _scripts(std::move(scripts)){};