From 8338799d28a8177921cee2da5e19cd4f97eee68e Mon Sep 17 00:00:00 2001 From: Robin Krahl Date: Thu, 15 Feb 2018 22:56:35 +0100 Subject: Add rules to generate libsqlitepp.so.1 --- Makefile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 34bee3b..6ebdda4 100644 --- a/Makefile +++ b/Makefile @@ -14,6 +14,7 @@ SOURCE_NAMES_TEST := sqlitepp_test.cpp TARGET_NAME_LIB := sqlitepp TARGET_LIB_BASE := $(LIBRARY_DIR)/lib$(TARGET_NAME_LIB).so +TARGET_LIB_LINKS := $(TARGET_LIB_BASE) $(TARGET_LIB_BASE).$(VERSION_MAJOR) TARGET_LIB := $(TARGET_LIB_BASE).$(VERSION) SOURCES_LIB := $(foreach source,$(SOURCE_NAMES_LIB),$(SOURCE_DIR)/$(source)) OBJECTS_LIB := $(SOURCES_LIB:$(SOURCE_DIR)/%.cpp=$(OBJECT_DIR)/%.o) @@ -24,7 +25,7 @@ SOURCES_TEST := $(foreach source,$(SOURCE_NAMES_TEST),$(SOURCE_DIR)/$(source)) OBJECTS_TEST := $(SOURCES_TEST:$(SOURCE_DIR)/%.cpp=$(OBJECT_DIR)/%.o) DEPENDS_TEST := $(OBJECTS_TEST:.o=.d) -TARGETS := $(TARGET_LIB) $(TARGET_LIB_BASE) $(TARGET_TEST) +TARGETS := $(TARGET_LIB) $(TARGET_LIB_LINKS) $(TARGET_TEST) INCLUDES := $(INCLUDE_DIR)/sqlitepp/sqlitepp.h OBJECTS := $(OBJECTS_LIB) $(OBJECTS_TEST) DEPENDS := $(DEPENDS_LIB) $(DEPENDS_TEST) @@ -68,7 +69,7 @@ memcheck: $(TARGET_TEST) test: $(TARGET_TEST) ./$(TARGET_TEST) -$(TARGET_LIB_BASE): $(TARGET_LIB) +$(TARGET_LIB_LINKS): $(TARGET_LIB) $(info (LN) $@) $(QUIET)ln -sr $^ $@ -- cgit v1.2.3