build: relink apps when vfio-user library is updated

Look for 'vfio_user' in SPDK_LIB_FILES to determine
whether the target application actually needs to be
rebuilt.

Fixes issue #1930.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: If3f699c91972e20dc4520e25c655ed11f6843be0
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7826
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: <dongx.yi@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
This commit is contained in:
Jim Harris 2021-05-10 15:30:26 +00:00 committed by Tomasz Zawadzki
parent 1f5bae841a
commit b549f4113c

View File

@ -52,6 +52,10 @@ LIBS += $(SPDK_LIB_LINKER_ARGS)
CLEAN_FILES = $(APP)
ifeq ($(findstring vfio_user,$(SPDK_LIB_FILES)),vfio_user)
VFIO_USER_LIB_FILE=$(VFIO_USER_LIBRARY_DIR)/libvfio-user.a
endif
all : $(APP)
@:
@ -63,7 +67,7 @@ uninstall: empty_rule
empty_rule:
@:
$(APP) : $(OBJS) $(SPDK_LIB_FILES) $(ENV_LIBS)
$(APP) : $(OBJS) $(SPDK_LIB_FILES) $(ENV_LIBS) $(VFIO_USER_LIB_FILE)
$(LINK_C)
clean :