From: Kefu Chai Date: Wed, 11 Mar 2020 14:41:29 +0000 (+0800) Subject: admin/build-doc: use "ceph" for prefix of functions defined by libcephfs X-Git-Tag: v16.0.0~51^2 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=b9e282f0e3eed2cacf1aac0853dc6607053607a3;p=ceph-ci.git admin/build-doc: use "ceph" for prefix of functions defined by libcephfs if some python module tries to `import cephfs`, it should not fail. Signed-off-by: Kefu Chai --- diff --git a/admin/build-doc b/admin/build-doc index 930e2768ee3..289a2a68871 100755 --- a/admin/build-doc +++ b/admin/build-doc @@ -93,7 +93,12 @@ for bind in rados rbd cephfs rgw; do if [ ! -e $lib_fn ]; then lib_fn=$vdir/lib/python*/*-packages/${bind}.so fi - nm $lib_fn | grep -E "U (lib)?${bind}" | \ + if [ ${bind} = "cephfs" ]; then + func_prefix="ceph" + else + func_prefix="(lib)?${bind}" + fi + nm $lib_fn | grep -E "U ${func_prefix}" | \ awk '{ print "void "$2"(void) {}" }' | \ gcc -shared -o $vdir/lib/lib${bind}.so.1 -xc - if [ ${bind} != rados ]; then