mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-30 17:18:21 +03:00
makefiles: add check for versioned symbols
Simple check produced library has the latest symbol as well as its versioned older version with check for dm_stats_create_region().
This commit is contained in:
parent
40b277ae17
commit
c23f4c8075
@ -47,7 +47,7 @@ endif
|
|||||||
|
|
||||||
LIB_SHARED = $(interface)/libdevmapper.$(LIB_SUFFIX)
|
LIB_SHARED = $(interface)/libdevmapper.$(LIB_SUFFIX)
|
||||||
LIB_VERSION = $(LIB_VERSION_DM)
|
LIB_VERSION = $(LIB_VERSION_DM)
|
||||||
TARGETS = libdevmapper.$(LIB_SUFFIX) libdevmapper.$(LIB_SUFFIX).$(LIB_VERSION)
|
TARGETS = libdevmapper.$(LIB_SUFFIX) libdevmapper.$(LIB_SUFFIX).$(LIB_VERSION) .symver_check
|
||||||
|
|
||||||
CFLOW_LIST = $(SOURCES)
|
CFLOW_LIST = $(SOURCES)
|
||||||
CFLOW_LIST_TARGET = libdevmapper.cflow
|
CFLOW_LIST_TARGET = libdevmapper.cflow
|
||||||
@ -69,6 +69,16 @@ libdevmapper.$(LIB_SUFFIX) libdevmapper.$(LIB_SUFFIX).$(LIB_VERSION): $(LIB_SHAR
|
|||||||
@echo " [LN] $<"
|
@echo " [LN] $<"
|
||||||
$(Q) $(LN_S) -f $< $@
|
$(Q) $(LN_S) -f $< $@
|
||||||
|
|
||||||
|
# Check versioned build when default versioned symbol is present @@
|
||||||
|
# also the older symbol is built-in
|
||||||
|
.symver_check: $(LIB_SHARED)
|
||||||
|
@echo " [CHECK] $<"
|
||||||
|
$(Q) if readelf -Ws $< | grep -q dm_stats_create_region@@; then \
|
||||||
|
SYM=$$(readelf -Ws $< | grep dm_stats_create_region@DM_1_02_106); \
|
||||||
|
if test -n "$$SYM"; then touch $@; \
|
||||||
|
else echo >&2 "Missing versioned symbols in $<"; false; fi; \
|
||||||
|
else touch $@; fi
|
||||||
|
|
||||||
.PHONY: install_dynamic install_static install_include \
|
.PHONY: install_dynamic install_static install_include \
|
||||||
install_ioctl install_ioctl_static \
|
install_ioctl install_ioctl_static \
|
||||||
install_pkgconfig
|
install_pkgconfig
|
||||||
|
Loading…
Reference in New Issue
Block a user