windows build fix
Some checks failed
demo.yaml / windows build fix (push) Failing after 0s

This commit is contained in:
Jorijn van der Graaf 2026-03-01 19:18:48 +01:00
commit e336fe2eab
2 changed files with 7 additions and 4 deletions

View file

@ -282,8 +282,6 @@ namespace Crafter {
const fs::path cacheDir = GetPath() / "cloneCache";
std::cout << cacheDir << std::endl;
if (!fs::exists(cacheDir)) {
fs::create_directories(cacheDir);
}
@ -307,8 +305,6 @@ namespace Crafter {
// Update path to the project.json of the dependency
path = cacheDir / depFolder / "project.json";
}
std::cout << path << std::endl;
// Create a Project object for the dependency
std::unique_ptr<Project> depProject = std::make_unique<Project>(std::move(path), configName);

View file

@ -66,7 +66,14 @@ namespace Crafter {
}
}
}
#ifdef CRAFTER_BUILD_CONFIGURATION_TARGET_x86_64_pc_linux_gnu
result += RunClang(std::format("{} {}.cppm --precompile -o {}.pcm", clang, path.string(), (pcmDir/path.filename()).string()));
#endif
#if defined(CRAFTER_BUILD_CONFIGURATION_TARGET_x86_64_pc_windows_msvc) || defined(CRAFTER_BUILD_CONFIGURATION_TARGET_x86_64_w64_mingw32)
result += RunClang(std::format("{} && cd {} && {}.cppm --precompile -o {}.pcm", clang, pcmDir, path.string(), path.filename().string()));
#endif
result += RunClang(std::format("{} {}.pcm -c -o {}.o", clang, (pcmDir/path.filename()).string(), (buildDir/path.filename()).string()));
if(result.empty()) {
compiled.store(CRAFTER_COMPILE_STATUS_COMPLETED);