aboutsummaryrefslogtreecommitdiff
path: root/backend
diff options
context:
space:
mode:
authordec05eba <dec05eba@protonmail.com>2018-09-25 20:47:40 +0200
committerdec05eba <dec05eba@protonmail.com>2020-07-06 07:39:33 +0200
commitc4d1491af938a12a0167dae4fd3ea8f1810c752a (patch)
tree8ecd47ca15e3caaace085f1880129231d329472c /backend
parent0bbb9be629ce35c11e4bf4a5180810ae2b16e5b4 (diff)
Fix build for windows
Diffstat (limited to 'backend')
-rw-r--r--backend/ninja/Ninja.cpp14
1 files changed, 10 insertions, 4 deletions
diff --git a/backend/ninja/Ninja.cpp b/backend/ninja/Ninja.cpp
index 64f8f53..9220593 100644
--- a/backend/ninja/Ninja.cpp
+++ b/backend/ninja/Ninja.cpp
@@ -206,9 +206,10 @@ namespace backend
{
switch(cppVersion)
{
- case CPPVersion::CPP11: return { ninja::NinjaArg("/std=c++11") };
- case CPPVersion::CPP14: return { ninja::NinjaArg("/std=c++14") };
- case CPPVersion::CPP17: return { ninja::NinjaArg("/std=c++17") };
+ // Use /Za flag?
+ case CPPVersion::CPP11: return { ninja::NinjaArg("/std:c++11") };
+ case CPPVersion::CPP14: return { ninja::NinjaArg("/std:c++14") };
+ case CPPVersion::CPP17: return { ninja::NinjaArg("/std:c++17") };
}
break;
}
@@ -882,6 +883,11 @@ namespace backend
else
compileCCommand.push_back(ninja::NinjaArg("/w"));
+// TODO: Remove this once locate_windows_sdk has been updated to locate multiple arch windows sdk
+#if SYSTEM_PLATFORM == PLATFORM_WIN32
+#error "sibs is currently not supported on windows 32-bit because locate_windows_sdk can only locate x64 windows sdk"
+#endif
+
switch (SYSTEM_PLATFORM)
{
case PLATFORM_WIN32:
@@ -1435,7 +1441,7 @@ namespace backend
ninja.sourceFiles.reserve(config.zigTestFiles.size());
for(const sibs::FileString &testFile : config.zigTestFiles)
{
- ninja.addSourceFile(sibs::Language::ZIG, testFile.c_str());
+ ninja.addSourceFile(sibs::Language::ZIG, toUtf8(testFile.c_str()).c_str());
}
zigTest = true;
}