summaryrefslogtreecommitdiff
path: root/src/rebuild.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/rebuild.cc')
-rw-r--r--src/rebuild.cc23
1 files changed, 12 insertions, 11 deletions
diff --git a/src/rebuild.cc b/src/rebuild.cc
index 460bbfb..c176744 100644
--- a/src/rebuild.cc
+++ b/src/rebuild.cc
@@ -163,22 +163,23 @@ bool recompileCheck(const ctor::settings& global_settings, int argc, char* argv[
config.name = "ctor";
config.system = ctor::output_system::build;
- config.flags.cxxflags.push_back({ctor::cxx_opt::optimization, "3"});
- config.flags.cxxflags.push_back({ctor::cxx_opt::cpp_std, "c++20"});
+ config.flags.cxxflags.emplace_back(ctor::cxx_opt::optimization, "3");
+ config.flags.cxxflags.emplace_back(ctor::cxx_opt::cpp_std, "c++20");
const auto& c = ctor::get_configuration();
if(c.has(ctor::cfg::ctor_includedir))
{
- config.flags.cxxflags.push_back({ctor::cxx_opt::include_path,
- c.get(ctor::cfg::ctor_includedir)});
+ config.flags.cxxflags.emplace_back(ctor::cxx_opt::include_path,
+ c.get(ctor::cfg::ctor_includedir));
}
if(c.has(ctor::cfg::ctor_libdir))
{
- config.flags.ldflags.push_back({ctor::ld_opt::library_path, c.get(ctor::cfg::ctor_libdir)});
+ config.flags.ldflags.emplace_back(ctor::ld_opt::library_path,
+ c.get(ctor::cfg::ctor_libdir));
}
- config.flags.ldflags.push_back({ctor::ld_opt::link, "ctor"});
- config.flags.ldflags.push_back({ctor::ld_opt::strip});
- config.flags.ldflags.push_back({ctor::ld_opt::threads});
+ config.flags.ldflags.emplace_back(ctor::ld_opt::link, "ctor");
+ config.flags.ldflags.emplace_back(ctor::ld_opt::strip);
+ config.flags.ldflags.emplace_back(ctor::ld_opt::threads);
ctor::settings settings{global_settings};
settings.verbose = -1; // Make check completely silent.
@@ -261,14 +262,14 @@ bool recompileCheck(const ctor::settings& global_settings, int argc, char* argv[
if(reconfigure)
{
std::vector<std::string> args;
- args.push_back("reconfigure");
+ args.emplace_back("reconfigure");
if(!relaunch_allowed)
{
- args.push_back("--no-rerun");
+ args.emplace_back("--no-rerun");
}
for(int i = 1; i < argc; ++i)
{
- args.push_back(argv[i]);
+ args.emplace_back(argv[i]);
}
auto ret = execute(settings, argv[0], args);
//if(ret != 0)