From 1dc3b7357db363c51e449adf0a3779924fb13e01 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Wed, 4 Sep 2019 13:32:07 +0200 Subject: Add support for native shared library versioning on Linux Now we can do: lib{foo}: bin.lib.version = linux@1.2 And end up with libfoo.so.1.2 libfoo.so.1 -> libfoo.so.1.2 --- libbuild2/target.hxx | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'libbuild2/target.hxx') diff --git a/libbuild2/target.hxx b/libbuild2/target.hxx index d543da8..5870be4 100644 --- a/libbuild2/target.hxx +++ b/libbuild2/target.hxx @@ -1548,7 +1548,8 @@ namespace build2 // // If name_prefix is not NULL, add it before the name part and after the // directory. Similarly, if name_suffix is not NULL, add it after the name - // part and before the extension. + // part and before the extension. And if extra_ext is not NULL, then add + // it as an extra extension (think libfoo.so.1.2.3). // // Finally, if the path was already assigned to this target, then this // function verifies that the two are the same. @@ -1556,13 +1557,16 @@ namespace build2 const path_type& derive_path (const char* default_ext = nullptr, const char* name_prefix = nullptr, - const char* name_suffix = nullptr); + const char* name_suffix = nullptr, + const char* extra_ext = nullptr); // This version can be used to derive the path from another target's path // by adding another extension. // const path_type& - derive_path (path_type base, const char* default_ext = nullptr); + derive_path (path_type base, + const char* default_ext = nullptr, + const char* extra_ext = nullptr); // As above but only derives (and returns) the extension (empty means no // extension used). -- cgit v1.1