From 9891dbfdc88b94d01144151a8e30116e2ed28a59 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Wed, 3 May 2017 15:24:53 +0300 Subject: Add support for task request manifest toolchain name/version --- libbrep/build.cxx | 9 +++++++-- libbrep/build.hxx | 21 +++++++++++++++------ libbrep/build.xml | 27 +++++++++++++++++++++++++++ libbrep/version.hxx.in | 1 + 4 files changed, 50 insertions(+), 8 deletions(-) (limited to 'libbrep') diff --git a/libbrep/build.cxx b/libbrep/build.cxx index 710c0b2..c0b780d 100644 --- a/libbrep/build.cxx +++ b/libbrep/build.cxx @@ -33,11 +33,16 @@ namespace brep // build // build:: - build (string pnm, version pvr, string cfg, string mnm, string msm) - : id (package_id (move (pnm), pvr), move (cfg)), + build (string pnm, version pvr, + string cfg, + string tnm, version tvr, + string mnm, string msm) + : id (package_id (move (pnm), pvr), move (cfg), tvr), package_name (id.package.name), package_version (move (pvr)), configuration (id.configuration), + toolchain_name (move (tnm)), + toolchain_version (move (tvr)), state (build_state::testing), timestamp (timestamp_type::clock::now ()), forced (false), diff --git a/libbrep/build.hxx b/libbrep/build.hxx index d28f5ab..86630a7 100644 --- a/libbrep/build.hxx +++ b/libbrep/build.hxx @@ -39,10 +39,14 @@ namespace brep { package_id package; string configuration; + canonical_version toolchain_version; build_id () = default; - build_id (package_id p, string c) - : package (move (p)), configuration (move (c)) {} + build_id (package_id p, string c, const brep::version& v) + : package (move (p)), + configuration (move (c)), + toolchain_version { + v.epoch, v.canonical_upstream, v.canonical_release, v.revision} {} }; inline bool @@ -104,15 +108,18 @@ namespace brep // Create the build object with the testing state, non-existent status, // the timestamp set to now and the forced flag set to false. // - build (string name, version, + build (string package_name, version package_version, string configuration, + string toolchain_name, version toolchain_version, string machine, string machine_summary); build_id id; - string& package_name; // Tracks id.package.name. - upstream_version package_version; // Original of id.package.version. - string& configuration; // Tracks id.configuration. + string& package_name; // Tracks id.package.name. + upstream_version package_version; // Original of id.package.version. + string& configuration; // Tracks id.configuration. + string toolchain_name; + upstream_version toolchain_version; // Original of id.toolchain_version. build_state state; @@ -150,6 +157,8 @@ namespace brep #pragma db member(package_version) \ set(this.package_version.init (this.id.package.version, (?))) #pragma db member(configuration) transient + #pragma db member(toolchain_version) \ + set(this.toolchain_version.init (this.id.toolchain_version, (?))) #pragma db member(results) id_column("") value_column("") diff --git a/libbrep/build.xml b/libbrep/build.xml index 8d9178a..5793de3 100644 --- a/libbrep/build.xml +++ b/libbrep/build.xml @@ -7,8 +7,15 @@ + + + + + + + @@ -22,6 +29,10 @@ + + + + @@ -31,6 +42,10 @@ + + + + @@ -42,6 +57,10 @@ + + + + @@ -49,6 +68,10 @@ + + + + @@ -58,6 +81,10 @@ + + + + diff --git a/libbrep/version.hxx.in b/libbrep/version.hxx.in index e3c52ce..437163f 100644 --- a/libbrep/version.hxx.in +++ b/libbrep/version.hxx.in @@ -70,5 +70,6 @@ $libstudxml.check(LIBSTUDXML_VERSION, LIBSTUDXML_SNAPSHOT)$ // #define LIBBREP_VERSION BREP_VERSION #define LIBBREP_VERSION_STR BREP_VERSION_STR +#define LIBBREP_VERSION_ID BREP_VERSION_ID #endif // BREP_VERSION -- cgit v1.1