Blame sofort/core/version.mk

5b49a6
include $(PROJECT_DIR)/project/tagver.mk
5b49a6
5b49a6
CFLAGS_VERSION	+= -D$(VER_NAMESPACE)_TAG_VER_MAJOR=$(VER_MAJOR)
5b49a6
CFLAGS_VERSION	+= -D$(VER_NAMESPACE)_TAG_VER_MINOR=$(VER_MINOR)
5b49a6
CFLAGS_VERSION	+= -D$(VER_NAMESPACE)_TAG_VER_PATCH=$(VER_PATCH)
5b49a6
5b49a6
ifeq ($(AVOID_VERSION),yes)
5b49a6
5b49a6
VER_XYZ		=
5b49a6
VER_SONAME	=
5b49a6
5b49a6
package-shared-soname:
5b49a6
package-shared-solink:
5b49a6
package-install-soname:
5b49a6
package-install-solink:
5b49a6
5b49a6
else
5b49a6
5b49a6
VER_XYZ		= .$(VER_MAJOR).$(VER_MINOR).$(VER_PATCH)
5b49a6
VER_SONAME	= .$(VER_MAJOR)
5b49a6
5b49a6
package-shared-soname:	shared-soname
5b49a6
package-shared-solink:	shared-solink
5b49a6
package-install-soname:	install-soname
5b49a6
package-install-solink:	install-solink
5b49a6
5b49a6
5b49a6
5b49a6
# libfoo.so (common)
5b49a6
install-solink:		install-lib
f93c65
			rm -f $(SHARED_SOLINK).tmp
f93c65
			ln -s $(DSO_VER) $(SHARED_SOLINK).tmp
f93c65
			mv $(SHARED_SOLINK).tmp $(DESTDIR)$(LIBDIR)/$(DSO_SOLINK)
5b49a6
5b49a6
$(SHARED_SOLINK):	$(SHARED_LIB)
5b49a6
			rm -f $@.tmp
5b49a6
			ln -s $(DSO_VER) $@.tmp
5b49a6
			mv $@.tmp $@
5b49a6
5b49a6
# libfoo.so.x (symlink)
5b49a6
ifeq ($(OS_SONAME),symlink)
5b49a6
$(SHARED_SONAME):	$(SHARED_LIB)
5b49a6
			rm -f $@.tmp
5b49a6
			ln -s $(DSO_VER) $@.tmp
5b49a6
			mv $@.tmp $@
5b49a6
5b49a6
install-soname:		install-lib
998db9
			rm -f $(SHARED_SONAME).tmp
998db9
			ln -s $(DSO_VER) $(SHARED_SONAME).tmp
998db9
			mv $(SHARED_SONAME).tmp $(DESTDIR)$(LIBDIR)/$(DSO_SONAME)
5b49a6
endif
5b49a6
5b49a6
5b49a6
# libfoo.so.x (copy)
5b49a6
ifeq ($(OS_SONAME),copy)
5b49a6
install-soname:		install-lib
5b49a6
			cp $(SHARED_LIB) $(DESTDIR)$(LIBDIR)/$(DSO_SONAME)
5b49a6
5b49a6
$(SHARED_SONAME):	$(SHARED_LIB)
5b49a6
			cp $(SHARED_LIB) $(SHARED_SONAME)
5b49a6
endif
5b49a6
5b49a6
endif