From 10604d850510e46b2ee625548abe5eb9a1172a0d Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Tue, 21 Jul 2015 09:39:57 +0200 Subject: Add alias{} target type, use as base for dir{} --- build/target.cxx | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) (limited to 'build/target.cxx') diff --git a/build/target.cxx b/build/target.cxx index 63bb2fe..f9662fa 100644 --- a/build/target.cxx +++ b/build/target.cxx @@ -297,9 +297,8 @@ namespace build static target* search_alias (const prerequisite_key& pk) { - // For an alias/action we don't want to silently create a target - // since it will do nothing and it most likely not what the author - // intended. + // For an alias we don't want to silently create a target since it + // will do nothing and it most likely not what the user intended. // target* t (search_existing_target (pk)); @@ -368,11 +367,22 @@ namespace build false }; + const target_type alias::static_type + { + typeid (alias), + "alias", + &target::static_type, + &target_factory, + nullptr, // Should never need. + &search_alias, + false + }; + const target_type dir::static_type { typeid (dir), "dir", - &target::static_type, + &alias::static_type, &target_factory, nullptr, // Should never need. &search_alias, -- cgit v1.1