From 0db40ed54bd7084a49553ff8df931048742c096e Mon Sep 17 00:00:00 2001 From: crosire Date: Tue, 8 Jan 2019 14:18:25 +0100 Subject: [PATCH] Fix compiler failing to compile when target application was created from a single source filesystem See #16 --- source/blink.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/source/blink.cpp b/source/blink.cpp index 96e29da..c54fda4 100644 --- a/source/blink.cpp +++ b/source/blink.cpp @@ -359,7 +359,8 @@ std::string blink::application::build_compile_command_line(const std::filesystem } }); - cmdline += ' '; + // Make sure to only compile and not link too + cmdline += " /c "; // Remove some arguments from the command-line since they are set to different values below const auto remove_arg = [&cmdline](std::string arg) { @@ -395,7 +396,7 @@ std::string blink::application::build_compile_command_line(const std::filesystem // Always write to a separate object file since the original one may be in user by a debugger object_file = source_file; - object_file.replace_extension(".obj"); + object_file.replace_extension("temp.obj"); // Append input source file to command-line cmdline += '\"' + source_file.string() + '\"';