From 239f0bc9b5e72f632aa3d65a45b745d6c9df9b70 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Mon, 21 Feb 2022 07:38:47 +0200 Subject: Do lazy build system initialization only if/when actually needed --- bpkg/package-skeleton.hxx | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'bpkg/package-skeleton.hxx') diff --git a/bpkg/package-skeleton.hxx b/bpkg/package-skeleton.hxx index 0b573e4..d2a848c 100644 --- a/bpkg/package-skeleton.hxx +++ b/bpkg/package-skeleton.hxx @@ -10,6 +10,7 @@ #include #include +#include namespace bpkg { @@ -28,13 +29,14 @@ namespace bpkg // If the package is not external, then none of the root directories // should be specified. // - // Note that the database and available_package are expected to outlive - // this object. + // Note that the options, database, and available_package are expected to + // outlive this object. // // Note also that this creates an "unloaded" skeleton and is therefore - // cheap. + // relatively cheap. // - package_skeleton (database&, + package_skeleton (const common_options& co, + database&, const available_package&, strings config_vars, optional src_root, @@ -90,6 +92,7 @@ namespace bpkg private: // NOTE: remember to update move/copy constructors! // + const common_options* co_; database* db_; const available_package* available_; strings config_vars_; -- cgit v1.1