summaryrefslogtreecommitdiff
path: root/src/task_cc.cc
diff options
context:
space:
mode:
authorBent Bisballe Nyeng <deva@aasimon.org>2021-09-27 21:32:17 +0200
committerBent Bisballe Nyeng <deva@aasimon.org>2021-09-27 21:32:17 +0200
commite73ee708292aac55070701ff0157db4eab6c06f4 (patch)
treec377bc83c6975e5a75b4445afda43407d720e904 /src/task_cc.cc
parentf30d40ec44e7bb4dda5cdd75e9761d67288af4a7 (diff)
Add folder hierarchy in build folder corresponding to that of the source folders and store build-files in corresponding locations.
Diffstat (limited to 'src/task_cc.cc')
-rw-r--r--src/task_cc.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/task_cc.cc b/src/task_cc.cc
index eb361cb..dfda75d 100644
--- a/src/task_cc.cc
+++ b/src/task_cc.cc
@@ -129,6 +129,9 @@ TaskCC::TaskCC(const BuildConfiguration& config, const Settings& settings,
sourceFile /= source.file;
std::filesystem::path base = settings.builddir;
+ base /= sourceFile.parent_path();
+ std::filesystem::create_directories(base);
+
base /= config.target;
base += "-";
base += sourceFile.stem();