From 3f44e2e791d4a067ff16b5246463487a25371880 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Thu, 15 Aug 2019 11:11:43 +0200 Subject: Embed build core version into build system modules as load path --- libbuild2/bash/buildfile | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'libbuild2/bash/buildfile') diff --git a/libbuild2/bash/buildfile b/libbuild2/bash/buildfile index e1a9f53..ed95998 100644 --- a/libbuild2/bash/buildfile +++ b/libbuild2/bash/buildfile @@ -50,10 +50,15 @@ libs{build2-bash}: cxx.export.poptions += -DLIBBUILD2_BASH_SHARED # in place of another pre-release or the final version. See the version module # for details on the version.* variable values. # -if $version.pre_release - lib{build2-bash}: bin.lib.version = @"-$version.project_id" -else - lib{build2-bash}: bin.lib.version = @"-$version.major.$version.minor" +# And seeing that this is a build system module, we also embed the same +# version as the build system core version. +# +ver = ($version.pre_release \ + ? "$version.project_id" \ + : "$version.major.$version.minor") + +lib{build2-bash}: bin.lib.version = @"-$ver" +libs{build2-bash}: bin.lib.load_suffix = "-$ver" # Install into the libbuild2/bash/ subdirectory of, say, /usr/include/ # recreating subdirectories. -- cgit v1.1