From 9365d75ec4870371c102ec9de28cadc75c6876f8 Mon Sep 17 00:00:00 2001 From: Nakidai Date: Thu, 26 Sep 2024 00:39:57 +0300 Subject: Add lib --- Makefile | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/Makefile b/Makefile index 3fb7ded..8bfd5d1 100644 --- a/Makefile +++ b/Makefile @@ -10,28 +10,28 @@ SRCDIR = src OBJDIR = obj OBJS = cpetpet.o -all: cpetpet.a cpetpet.so +all: libcpetpet.a libcpetpet.so $(OBJS): config.h cpetpet.h -cpetpet.a cpetpet.so: $(OBJS) +libcpetpet.a libcpetpet.so: $(OBJS) -cpetpet.so: +libcpetpet.so: cc -shared -o $@ ${LDFLAGS} ${LDLIBS} $^ -cpetpet.a: +libcpetpet.a: ar rcs $@ $^ install: all install -d $(DESTDIR)/lib $(DESTDIR)/share/cpetpet - install -m644 cpetpet.a $(DESTDIR)/lib - install -m755 cpetpet.so $(DESTDIR)/lib + install -m644 libcpetpet.a $(DESTDIR)/lib + install -m755 libcpetpet.so $(DESTDIR)/lib install -m644 share/cpetpet/* $(DESTDIR)/share/cpetpet install -m644 cpetpet.h $(DESTDIR)/include uninstall: $(RM) -r $(DESTDIR)/share/cpetpet - $(RM) $(DESTDIR)/lib/cpetpet.{a,so} + $(RM) $(DESTDIR)/lib/libcpetpet.{a,so} $(RM) $(DESTDIR)/include/cpetpet.h clean: -- cgit 1.4.1