aboutsummaryrefslogtreecommitdiff
path: root/libbrep/build.hxx
diff options
context:
space:
mode:
authorKaren Arutyunov <karen@codesynthesis.com>2018-10-28 01:01:53 +0300
committerKaren Arutyunov <karen@codesynthesis.com>2018-10-30 16:20:21 +0300
commit873987793b05fc0d6e9908f5030b2bca145c4e6d (patch)
tree6641e447d892e5b364ae7471e7a0a71581c85e91 /libbrep/build.hxx
parent018603c5529117b993066f4f3a0f45f48f92e801 (diff)
Add tenant object
Diffstat (limited to 'libbrep/build.hxx')
-rw-r--r--libbrep/build.hxx14
1 files changed, 10 insertions, 4 deletions
diff --git a/libbrep/build.hxx b/libbrep/build.hxx
index fc314eb..279c1d7 100644
--- a/libbrep/build.hxx
+++ b/libbrep/build.hxx
@@ -26,7 +26,7 @@
//
#define LIBBREP_BUILD_SCHEMA_VERSION_BASE 4
-#pragma db model version(LIBBREP_BUILD_SCHEMA_VERSION_BASE, 4, closed)
+#pragma db model version(LIBBREP_BUILD_SCHEMA_VERSION_BASE, 5, open)
// We have to keep these mappings at the global scope instead of inside
// the brep namespace because they need to be also effective in the
@@ -251,7 +251,11 @@ namespace brep
}
};
- #pragma db view object(build) query(distinct)
+ #pragma db view object(build) \
+ object(build_package inner: \
+ brep::operator== (build::id.package, build_package::id) && \
+ build_package::internal_repository.canonical_name.is_not_null ()) \
+ query(distinct)
struct toolchain
{
string name;
@@ -297,7 +301,8 @@ namespace brep
object(build) \
object(build_package inner: \
brep::operator== (build::id.package, build_package::id) && \
- build_package::internal_repository.canonical_name.is_not_null ())
+ build_package::internal_repository.canonical_name.is_not_null ()) \
+ object(build_tenant: build_package::id.tenant == build_tenant::id)
struct package_build
{
shared_ptr<brep::build> build;
@@ -307,7 +312,8 @@ namespace brep
object(build) \
object(build_package inner: \
brep::operator== (build::id.package, build_package::id) && \
- build_package::internal_repository.canonical_name.is_not_null ())
+ build_package::internal_repository.canonical_name.is_not_null ()) \
+ object(build_tenant: build_package::id.tenant == build_tenant::id)
struct package_build_count
{
size_t result;