From 388782b89be0bf8144ae3dc2a590b466c96d3d6d Mon Sep 17 00:00:00 2001 From: Paul LeoNerd Evans Date: Thu, 6 Nov 2008 00:02:41 +0000 Subject: Added manpages for (most of) the external API functions --- Makefile | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 754bafc..84f2e13 100644 --- a/Makefile +++ b/Makefile @@ -8,6 +8,8 @@ SONAME=libtermkey.so.0 PREFIX=/usr/local LIBDIR=$(PREFIX)/lib INCDIR=$(PREFIX)/include +MANDIR=$(PREFIX)/share/man +MAN3DIR=$(MANDIR)/man3 ifeq ($(DEBUG),1) CFLAGS_DEBUG=-ggdb -DDEBUG @@ -29,11 +31,24 @@ clean: rm -f *.o demo .PHONY: install -install: +install: install-inc install-lib install-man + +install-inc: install -d $(DESTDIR)$(INCDIR) install -m644 termkey.h $(DESTDIR)$(INCDIR) + install -d $(DESTDIR)$(LIBDIR)/pkgconfig + sed "s,@PREFIX@,$(PREFIX)," $(DESTDIR)$(LIBDIR)/pkgconfig/termkey.pc + +install-lib: install -d $(DESTDIR)$(LIBDIR) install libtermkey.so $(DESTDIR)$(LIBDIR)/$(SONAME) ln -sf $(SONAME) $(DESTDIR)$(LIBDIR)/libtermkey.so - install -d $(DESTDIR)$(LIBDIR)/pkgconfig - sed "s,@PREFIX@,$(PREFIX)," $(DESTDIR)$(LIBDIR)/pkgconfig/termkey.pc + +install-man: + install -d $(DESTDIR)$(MAN3DIR) + for F in *.3; do \ + gzip <$$F >$(DESTDIR)$(MAN3DIR)/$$F.gz; \ + done + ln -sf termkey_new.3.gz $(DESTDIR)$(MAN3DIR)/termkey_free.3.gz + ln -sf termkey_getkey.3.gz $(DESTDIR)$(MAN3DIR)/termkey_getkey_force.3.gz + ln -sf termkey_setwaittime.3.gz $(DESTDIR)$(MAN3DIR)/termkey_getwaittime.3.gz -- cgit v1.2.3-70-g09d2