From b8a7e28b34ca4418e367a326cfb1272aabf4249c Mon Sep 17 00:00:00 2001 From: leitner Date: Sat, 24 Nov 2001 19:58:43 +0000 Subject: [PATCH] proper install make target. --- Makefile | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 730425b..8f6c9fb 100644 --- a/Makefile +++ b/Makefile @@ -1,3 +1,8 @@ +prefix=/usr/local +LIBDIR=${prefix}/lib +INCLUDEDIR=${prefix}/include +MAN3DIR=${prefix}/man/man3 + all: t byte.a fmt.a scan.a str.a uint.a open.a stralloc.a unix.a socket.a buffer.a mmap.a libowfat.a VPATH=str:byte:fmt:scan:uint:open:stralloc:unix:socket:buffer:mmap @@ -58,10 +63,16 @@ t: t.o socket.a stralloc.a buffer.a scan.a uint.a mmap.a open.a fmt.a \ str.a byte.a $(DIET) $(CC) -g -o $@ $^ -.PHONY: clean tar +.PHONY: clean tar install rename clean: rm -f *.o *.a core t haveip6.h haven2i.h havesl.h +install: libowfat.a + install -d $(INCLUDEDIR) $(MAN3DIR) $(LIBDIR) + install -m 644 buffer.h byte.h fmt.h ip4.h ip6.h mmap.h open.h scan.h socket.h str.h stralloc.h uint16.h uint32.h uint64.h $(prefix)/include + install -m 644 $(wildcard */*.3) $(MAN3DIR) + install -m 644 libowfat.a $(LIBDIR) + VERSION=libowfat-$(shell head -1 CHANGES|sed 's/://') CURNAME=$(notdir $(shell pwd))