From c0eacf8e85003844b95e71b9004fa464d4586a38 Mon Sep 17 00:00:00 2001 From: Bent Bisballe Nyeng Date: Thu, 14 Oct 2021 22:19:26 +0200 Subject: Use dependency system and build system for compiling ctor on config changes. --- src/libctor.h | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) (limited to 'src/libctor.h') diff --git a/src/libctor.h b/src/libctor.h index 6026ffb..5c22614 100644 --- a/src/libctor.h +++ b/src/libctor.h @@ -35,14 +35,10 @@ enum class OutputSystem struct Source { - Source(const char* file) - : file(file) {} - Source(const std::string& file) - : file(file) {} - Source(const char* file, Language language) - : file(file), language(language) {} - Source(const std::string& file, Language language) - : file(file), language(language) {} + Source(const char* file) : file(file) {} + Source(const std::string& file) : file(file) {} + Source(const char* file, Language lang) : file(file), language(lang) {} + Source(const std::string& file, Language lang) : file(file), language(lang) {} std::string file; Language language{Language::Auto}; @@ -50,9 +46,10 @@ struct Source struct BuildConfiguration { + std::string name; // Name - used for referring in other configurations. TargetType type{TargetType::Auto}; OutputSystem system{OutputSystem::Host}; - std::string target; + std::string target; // Output target file for this configuration std::vector sources; // source list std::vector depends; // internal dependencies std::vector cxxflags; // flags for c++ compiler -- cgit v1.2.3