summaryrefslogtreecommitdiff
path: root/src/task_cc.cc
diff options
context:
space:
mode:
authorBent Bisballe Nyeng <deva@aasimon.org>2023-01-21 12:50:43 +0100
committerBent Bisballe Nyeng <deva@aasimon.org>2023-01-21 12:50:43 +0100
commite4ccfe780f52cdb6c0764074effcd60235d33762 (patch)
treecf23adbd17d9bada3fa470a84c541acf84f56737 /src/task_cc.cc
parentabaf47c7b8fec08803d7b2deab3a4f13c2dfcb29 (diff)
Make sure to create target directories as they appear in their actual (cleaned) form.
Diffstat (limited to 'src/task_cc.cc')
-rw-r--r--src/task_cc.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/task_cc.cc b/src/task_cc.cc
index 2238b67..5c4adfb 100644
--- a/src/task_cc.cc
+++ b/src/task_cc.cc
@@ -24,7 +24,6 @@ TaskCC::TaskCC(const ctor::build_configuration& config, const ctor::settings& se
sourceFile /= source.file;
std::filesystem::path base = sourceFile.parent_path();
- std::filesystem::create_directories(std::filesystem::path(settings.builddir) / base);
base /= cleanUp(config.target);
base += "-";
@@ -68,6 +67,8 @@ TaskCC::TaskCC(const ctor::build_configuration& config, const ctor::settings& se
depsFile += ".d";
flagsFile = targetFile().parent_path() / targetFile().stem();
flagsFile += ".flags";
+
+ std::filesystem::create_directories(targetFile().parent_path());
}
int TaskCC::registerDepTasksInner(const std::set<std::shared_ptr<Task>>& tasks)