[dm-devel] [PATCH 10/11] libmpathpersist: add linker version script
mwilck at suse.com
mwilck at suse.com
Thu Sep 24 13:36:43 UTC 2020
From: Martin Wilck <mwilck at suse.com>
This defines the ABI of libmpathpersist in the current state.
---
libmpathpersist/Makefile | 6 ++++--
libmpathpersist/libmpathpersist.version | 20 ++++++++++++++++++++
2 files changed, 24 insertions(+), 2 deletions(-)
create mode 100644 libmpathpersist/libmpathpersist.version
diff --git a/libmpathpersist/Makefile b/libmpathpersist/Makefile
index 9e869fd..456ce4c 100644
--- a/libmpathpersist/Makefile
+++ b/libmpathpersist/Makefile
@@ -3,6 +3,7 @@ include ../Makefile.inc
SONAME = 0
DEVLIB = libmpathpersist.so
LIBS = $(DEVLIB).$(SONAME)
+VERSION_SCRIPT := libmpathpersist.version
CFLAGS += $(LIB_CFLAGS) -I$(multipathdir) -I$(mpathpersistdir) -I$(mpathcmddir)
@@ -13,8 +14,9 @@ OBJS = mpath_persist.o mpath_updatepr.o mpath_pr_ioctl.o
all: $(DEVLIB) man
-$(LIBS): $(OBJS)
- $(CC) $(LDFLAGS) $(SHARED_FLAGS) $(LIBDEPS) -Wl,-soname=$@ -o $@ $(OBJS)
+$(LIBS): $(OBJS) $(VERSION_SCRIPT)
+ $(CC) $(LDFLAGS) $(SHARED_FLAGS) $(LIBDEPS) -Wl,-soname=$@ \
+ -Wl,--version-script=$(VERSION_SCRIPT) -o $@ $(OBJS)
$(DEVLIB): $(LIBS)
$(LN) $(LIBS) $@
diff --git a/libmpathpersist/libmpathpersist.version b/libmpathpersist/libmpathpersist.version
new file mode 100644
index 0000000..1bb8212
--- /dev/null
+++ b/libmpathpersist/libmpathpersist.version
@@ -0,0 +1,20 @@
+LIBMPATHPERSIST_0.8.4.0 {
+global:
+
+ __mpath_persistent_reserve_in;
+ __mpath_persistent_reserve_out;
+ dumpHex;
+ mpath_alloc_prin_response;
+ mpath_lib_exit;
+ mpath_lib_init;
+ mpath_mx_alloc_len;
+ mpath_persistent_reserve_in;
+ mpath_persistent_reserve_init_vecs;
+ mpath_persistent_reserve_out;
+ mpath_persistent_reserve_free_vecs;
+ prin_do_scsi_ioctl;
+ prout_do_scsi_ioctl;
+ update_map_pr;
+
+local: *;
+};
--
2.28.0
More information about the dm-devel
mailing list