From b7b30102882f0a85c169a0eb4944a8f1c344c9e1 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Tue, 1 Aug 2017 15:29:24 +0200 Subject: Add version, project.summary, project.url built-in variables Extract them from manifest in the version module. Use them when generating the pkg-config's .pc files. --- build2/context.cxx | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) (limited to 'build2/context.cxx') diff --git a/build2/context.cxx b/build2/context.cxx index 2464973..d979f92 100644 --- a/build2/context.cxx +++ b/build2/context.cxx @@ -184,6 +184,10 @@ namespace build2 const variable* var_project; const variable* var_amalgamation; const variable* var_subprojects; + const variable* var_version; + + const variable* var_project_url; + const variable* var_project_summary; const variable* var_import_target; @@ -522,11 +526,19 @@ namespace build2 // Note that subprojects is not typed since the value requires // pre-processing (see file.cxx). // - var_project = &vp.insert ("project"); - var_amalgamation = &vp.insert ("amalgamation"); - var_subprojects = &vp.insert ("subprojects"); + { + auto pv (variable_visibility::project); + + var_project = &vp.insert ("project", pv); + var_amalgamation = &vp.insert ("amalgamation", pv); + var_subprojects = &vp.insert ("subprojects", pv); + var_version = &vp.insert ("version", pv); - var_import_target = &vp.insert ("import.target"); + var_project_url = &vp.insert ("project.url", pv); + var_project_summary = &vp.insert ("project.summary", pv); + + var_import_target = &vp.insert ("import.target"); + } // Register builtin rules. // -- cgit v1.1