From a3ed04f37c47e2eaa83d87dda2ec4ab060a7a2d0 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Tue, 2 Jun 2020 07:35:44 +0200 Subject: Add process_path_ex with program stable name and checksum --- libbuild2/functions-process-path.cxx | 23 ++++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) (limited to 'libbuild2/functions-process-path.cxx') diff --git a/libbuild2/functions-process-path.cxx b/libbuild2/functions-process-path.cxx index 15bec81..86d4445 100644 --- a/libbuild2/functions-process-path.cxx +++ b/libbuild2/functions-process-path.cxx @@ -11,14 +11,23 @@ namespace build2 void process_path_functions (function_map& m) { - function_family f (m, "process_path"); + { + function_family f (m, "process_path"); + + // As discussed in value_traits, we always have recall. + // + f["recall"] = &process_path::recall; + f["effect"] = [](process_path p) + { + return move (p.effect.empty () ? p.recall : p.effect); + }; + } - // As discussed in value_traits, we always have recall. - // - f["recall"] = &process_path::recall; - f["effect"] = [](process_path p) { - return move (p.effect.empty () ? p.recall : p.effect); - }; + function_family f (m, "process_path_ex"); + + f["name"] = &process_path_ex::name; + f["checksum"] = &process_path_ex::checksum; + } } } -- cgit v1.1