aboutsummaryrefslogtreecommitdiff
path: root/build2/cc/target.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2016-08-31 10:48:51 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2016-08-31 10:48:51 +0200
commit3d8f2b3779ae32a16627a0f09f1798224cdaf68f (patch)
treefab60da301c5e686514b8cedfedf541548ec912b /build2/cc/target.cxx
parent02f294ade6ba3c7c33fd4fb4dccb7901eaa7ae5c (diff)
Improve mixed source (e.g., C and C++) building support
Diffstat (limited to 'build2/cc/target.cxx')
-rw-r--r--build2/cc/target.cxx13
1 files changed, 12 insertions, 1 deletions
diff --git a/build2/cc/target.cxx b/build2/cc/target.cxx
index 7c2bb24..4961b35 100644
--- a/build2/cc/target.cxx
+++ b/build2/cc/target.cxx
@@ -10,6 +10,17 @@ namespace build2
{
namespace cc
{
+ const target_type cc::static_type
+ {
+ "cc",
+ &file::static_type,
+ nullptr,
+ nullptr,
+ nullptr,
+ &search_target,
+ false
+ };
+
extern const char ext_var[] = "extension"; // VC 19 rejects constexpr.
extern const char h_ext_def[] = "h";
@@ -28,7 +39,7 @@ namespace build2
const target_type c::static_type
{
"c",
- &file::static_type,
+ &cc::static_type,
&target_factory<c>,
&target_extension_var<ext_var, c_ext_def>,
nullptr,