aboutsummaryrefslogtreecommitdiff
path: root/build/cli/target.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2015-06-24 13:53:28 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2015-06-24 13:53:28 +0200
commite815af118562c68794efbd310c887acd8eae800c (patch)
treecedd8745cce259693c038c309d663a682c982e98 /build/cli/target.cxx
parent4f52c4ed65883dacef32587cf066fbb1182c6628 (diff)
First take on the cli module plus necessary infrastructure
Diffstat (limited to 'build/cli/target.cxx')
-rw-r--r--build/cli/target.cxx46
1 files changed, 46 insertions, 0 deletions
diff --git a/build/cli/target.cxx b/build/cli/target.cxx
new file mode 100644
index 0000000..2854818
--- /dev/null
+++ b/build/cli/target.cxx
@@ -0,0 +1,46 @@
+// file : build/cli/target.cxx -*- C++ -*-
+// copyright : Copyright (c) 2014-2015 Code Synthesis Ltd
+// license : MIT; see accompanying LICENSE file
+
+#include <build/cli/target>
+
+using namespace std;
+
+namespace build
+{
+ namespace cli
+ {
+ // cli
+ //
+ constexpr const char cli_ext[] = "cli";
+ const target_type cli::static_type
+ {
+ typeid (cli),
+ "cli",
+ &file::static_type,
+ &target_factory<cli>,
+ &target_extension_fix<cli_ext>,
+ &search_file
+ };
+
+ // cli.cxx
+ //
+ group_view cli_cxx::
+ members (action) const
+ {
+ return m[0] != nullptr
+ ? group_view {m, (m[2] != nullptr ? 3U : 2U)}
+ : group_view {nullptr, 0};
+ }
+
+ const target_type cli_cxx::static_type
+ {
+ typeid (cli_cxx),
+ "cli.cxx",
+ &target_group::static_type,
+ &target_factory<cli_cxx>,
+ nullptr,
+ &search_target
+ };
+ }
+}