summaryrefslogtreecommitdiff
path: root/src/externals_manual.cc
diff options
context:
space:
mode:
authorBent Bisballe Nyeng <deva@aasimon.org>2023-01-13 19:56:35 +0100
committerBent Bisballe Nyeng <deva@aasimon.org>2023-01-13 22:32:09 +0100
commit916060cb53fddb94f64b20d3616e7360c5e91f64 (patch)
tree4a2bcef4672b5e04b106f88cca3bec631b214c00 /src/externals_manual.cc
parentc093758b4688fb5bae2cc7727b6c9b52b824043e (diff)
Capture flags in a class instead of a string and add conversion functions between them.
Diffstat (limited to 'src/externals_manual.cc')
-rw-r--r--src/externals_manual.cc8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/externals_manual.cc b/src/externals_manual.cc
index bc8e9d0..3b96263 100644
--- a/src/externals_manual.cc
+++ b/src/externals_manual.cc
@@ -16,21 +16,19 @@ extern std::map<std::string, std::string> external_libdir;
int resolv(const ctor::settings& settings, const ctor::external_configuration& config,
const ctor::external_manual& ext, ctor::flags& flags)
{
- auto toolchain = getToolChain(config.system);
-
flags = ext.flags;
auto inc = external_includedir.find(config.name);
if(inc != external_includedir.end())
{
- append(flags.cflags, getOption(toolchain, ctor::opt::include_path, inc->second));
- append(flags.cxxflags, getOption(toolchain, ctor::opt::include_path, inc->second));
+ flags.cflags.push_back({ctor::c_opt::include_path, inc->second});
+ flags.cxxflags.push_back({ctor::cxx_opt::include_path, inc->second});
}
auto lib = external_libdir.find(config.name);
if(lib != external_libdir.end())
{
- append(flags.ldflags, getOption(toolchain, ctor::opt::library_path, lib->second));
+ flags.ldflags.push_back({ctor::ld_opt::library_path, lib->second});
}
return 0;