From fe16ae1fe8345259a380eb1d02a20eb043e08d47 Mon Sep 17 00:00:00 2001 From: Anoop C S Date: Thu, 25 Jan 2024 22:56:26 +0530 Subject: [PATCH] source3/wscript: Announce deprecation of old Ceph version support *at() variants for various libcephfs APIs were added with Ceph v17.x. Any other version less than v17.x is soon to be considered EOL[1] which we will now indicate with the help of a warning message during configure time. Going further such a situation will result in disabling the module altogether with the next major Samba version after v4.20. [1] https://docs.ceph.com/en/latest/releases/#ceph-releases-index Signed-off-by: Anoop C S Reviewed-by: Guenther Deschner --- source3/wscript | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/source3/wscript b/source3/wscript index 12394ef84b1..060e8d3ffe0 100644 --- a/source3/wscript +++ b/source3/wscript @@ -1679,16 +1679,19 @@ int main(void) { conf.DEFINE('HAVE_CEPH', '1') conf.CHECK_FUNCS_IN('ceph_select_filesystem', 'cephfs', headers='cephfs/libcephfs.h') - conf.CHECK_FUNCS_IN('ceph_mkdirat', 'cephfs', - headers='cephfs/libcephfs.h') - conf.CHECK_FUNCS_IN('ceph_openat', 'cephfs', - headers='cephfs/libcephfs.h') - conf.CHECK_FUNCS_IN('ceph_unlinkat', 'cephfs', - headers='cephfs/libcephfs.h') - conf.CHECK_FUNCS_IN('ceph_symlinkat', 'cephfs', - headers='cephfs/libcephfs.h') - conf.CHECK_FUNCS_IN('ceph_readlinkat', 'cephfs', - headers='cephfs/libcephfs.h') + conf.DEFINE('HAVE_MANDATORY_CEPH_API', '1') + for api in ['ceph_mkdirat', 'ceph_openat', 'ceph_unlinkat', + 'ceph_symlinkat', 'ceph_readlinkat']: + if not conf.CHECK_FUNCS_IN(api, 'cephfs', + headers='cephfs/libcephfs.h'): + conf.undefine('HAVE_MANDATORY_CEPH_API') + if not conf.env.HAVE_MANDATORY_CEPH_API: + Logs.warn("Installed Ceph version support is at the verge of " + "deprecation due to the absence of some mandatory " + "libcephfs APIs. This warning there shall result in " + "disabling the Ceph VFS module altogether with the " + "next major Samba version. It is highly recommended " + "to update to a more recent/active version of Ceph.") else: Logs.warn('''Ceph support disabled due to --without-acl-support or lack of ceph_statx support''') -- 2.34.1