diff options
author | Taylor Holberton <taylorcholberton@gmail.com> | 2016-12-01 21:28:32 -0800 |
---|---|---|
committer | Taylor Holberton <taylorcholberton@gmail.com> | 2016-12-01 21:28:32 -0800 |
commit | 9df0309a78c85f354f96a01c2f192c6281057a05 (patch) | |
tree | 4d3e9697088e9f16a43f9c26d781bde15e2d78c1 | |
parent | 313c1d17f2593e1eead11bc4efd0b704c32855a3 (diff) |
added soversion with minor and patch number
-rw-r--r-- | src/Makefile | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/src/Makefile b/src/Makefile index da19c54..cde8267 100644 --- a/src/Makefile +++ b/src/Makefile @@ -19,7 +19,7 @@ VPATH = ../include/tinyalsa OBJECTS = mixer.o pcm.o .PHONY: all -all: libtinyalsa.a libtinyalsa.so.1 +all: libtinyalsa.a libtinyalsa.so pcm.o: pcm.c pcm.h @@ -28,19 +28,28 @@ mixer.o: mixer.c mixer.h libtinyalsa.a: $(OBJECTS) $(AR) $(ARFLAGS) $@ $^ -libtinyalsa.so.1: $(OBJECTS) - $(LD) $(LDFLAGS) -shared $^ -o $@ +libtinyalsa.so: libtinyalsa.so.1 + ln -sf $< $@ + +libtinyalsa.so.1: libtinyalsa.so.1.1.0 + ln -sf $< $@ + +libtinyalsa.so.1.1.0: $(OBJECTS) + $(LD) $(LDFLAGS) -shared -Wl,-soname,libtinyalsa.so.1 $^ -o $@ .PHONY: clean clean: rm -f libtinyalsa.a + rm -f libtinyalsa.so rm -f libtinyalsa.so.1 + rm -f libtinyalsa.so.1.1.0 rm -f $(OBJECTS) .PHONY: install install: libtinyalsa.a libtinyalsa.so.1 install -d $(DESTDIR)$(LIBDIR)/ - ln -sf libtinyalsa.so.1 $(DESTDIR)$(LIBDIR)/libtinyalsa.so install libtinyalsa.a $(DESTDIR)$(LIBDIR)/ - install libtinyalsa.so.1 $(DESTDIR)$(LIBDIR)/ + install libtinyalsa.so.1.1.0 $(DESTDIR)$(LIBDIR)/ + ln -sf libtinyalsa.so.1.1.0 $(DESTDIR)$(LIBDIR)/libtinyalsa.so.1 + ln -sf libtinyalsa.so.1 $(DESTDIR)$(LIBDIR)/libtinyalsa.so |