update
This commit is contained in:
parent
90f8d3e1d9
commit
a36beab2ac
6 changed files with 71 additions and 10 deletions
|
|
@ -239,7 +239,7 @@ void Project::Build(Configuration& config, fs::path outputDir, fs::path binDir)
|
|||
files+=std::format("{}_source.o ",(buildDir/config.c_files[i].filename()).generic_string());
|
||||
if(!fs::exists((buildDir/config.c_files[i].filename()).generic_string()+"_source.o") || fs::last_write_time(config.c_files[i].generic_string()+".c") > fs::last_write_time((buildDir/config.c_files[i].filename()).generic_string()+"_source.o")) {
|
||||
threads.emplace_back([i, &config, pcmDir, target, clangDir, flags, march, &buildDir](){
|
||||
system(std::format("clang {}.c -c -O{} {} {} -o {}_source.o {}", config.c_files[i].generic_string(), config.optimizationLevel, march, flags, (buildDir/config.c_files[i].filename()).generic_string(), target).c_str());
|
||||
BounceCommand(std::format("clang {}.c -c -O{} {} {} -o {}_source.o {}", config.c_files[i].generic_string(), config.optimizationLevel, march, flags, (buildDir/config.c_files[i].filename()).generic_string(), target).c_str());
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
@ -257,11 +257,11 @@ void Project::Build(Configuration& config, fs::path outputDir, fs::path binDir)
|
|||
if(config.verbose) {
|
||||
std::cout << command << std::endl;
|
||||
}
|
||||
system(command.c_str());
|
||||
BounceCommand(command.c_str());
|
||||
} else if(config.type == "library"){
|
||||
system(std::format("ar r {}.a {}", (outputDir/fs::path("lib"+name)).generic_string(), files).c_str());
|
||||
BounceCommandIgnore(std::format("ar r {}.a {}", (outputDir/fs::path("lib"+name)).generic_string(), files).c_str());
|
||||
} else if(config.type == "shared-library"){
|
||||
system(std::format("ar r {}.so {}", (outputDir/fs::path("lib"+name)).generic_string(), files).c_str());
|
||||
BounceCommandIgnore(std::format("ar r {}.so {}", (outputDir/fs::path("lib"+name)).generic_string(), files).c_str());
|
||||
}
|
||||
|
||||
for(const fs::path& additionalFile : config.additionalFiles){
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue