From: Stefan Metzmacher Date: Fri, 29 Dec 2023 14:32:02 +0000 (+0000) Subject: wafsamba: introduce SAMBA_LIBRARY(force_unversioned=False) X-Git-Tag: talloc-2.4.2~159 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=533e5daf772b38e21830251d779f083da7197058;p=thirdparty%2Fsamba.git wafsamba: introduce SAMBA_LIBRARY(force_unversioned=False) This can be used in order to avoid a library to be catched by --private-libraries=ALL. It is needed for our wrapper libraries. BUG: https://bugzilla.samba.org/show_bug.cgi?id=15545 Signed-off-by: Stefan Metzmacher Reviewed-by: Björn Jacke Reviewed-by: Ralph Boehme --- diff --git a/buildtools/wafsamba/wafsamba.py b/buildtools/wafsamba/wafsamba.py index 3d6bbb84f6d..e1c2877e630 100644 --- a/buildtools/wafsamba/wafsamba.py +++ b/buildtools/wafsamba/wafsamba.py @@ -134,6 +134,7 @@ def SAMBA_LIBRARY(bld, libname, source, require_builtin_deps=False, provide_builtin_linking=False, builtin_cflags='', + force_unversioned=False, allow_undefined_symbols=False, allow_warnings=False, enabled=True): @@ -171,9 +172,20 @@ def SAMBA_LIBRARY(bld, libname, source, raise Errors.WafError("private library '%s' with orig_vscript_map must not have abi_match" % libname) + if force_unversioned and private_library: + raise Errors.WafError("private library '%s': can't have force_unversioned=True" % + libname) + + if force_unversioned and realname is None: + raise Errors.WafError("library '%s': force_unversioned=True needs realname too" % + libname) + if LIB_MUST_BE_PRIVATE(bld, libname) and target_type not in ['PLUGIN']: private_library = True + if force_unversioned: + private_library = False + if not enabled: SET_TARGET_TYPE(bld, libname, 'DISABLED') return @@ -327,7 +339,9 @@ def SAMBA_LIBRARY(bld, libname, source, vscript = None if bld.env.HAVE_LD_VERSION_SCRIPT: - if private_library: + if force_unversioned: + version = None + elif private_library: version = bld.env.PRIVATE_VERSION elif vnum: version = "%s_%s" % (libname, vnum)