pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

aha: Improve project Makefile to be more generic



Module Name:	pkgsrc-wip
Committed By:	Kamil Rytarowski <n54%gmx.com@localhost>
Pushed By:	kamil
Date:		Tue Jan 12 22:08:47 2016 +0100
Changeset:	cc165abb10b3b91064679e88bb219e9a256f993c

Modified Files:
	aha/Makefile
	aha/distinfo
Added Files:
	aha/patches/patch-Makefile

Log Message:
aha: Improve project Makefile to be more generic

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=cc165abb10b3b91064679e88bb219e9a256f993c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 aha/Makefile               |  4 ++++
 aha/distinfo               |  1 +
 aha/patches/patch-Makefile | 37 +++++++++++++++++++++++++++++++++++++
 3 files changed, 42 insertions(+)

diffs:
diff --git a/aha/Makefile b/aha/Makefile
index 5a26828..a9aca9b 100644
--- a/aha/Makefile
+++ b/aha/Makefile
@@ -12,4 +12,8 @@ LICENSE=	mpl-1.1 OR gnu-lgpl-v2 OR gnu-lgpl-v2.1 OR gnu-lgpl-v3
 
 USE_TOOLS+=	gmake
 
+MAKE_ENV+=	MANDIR=${PKGMANDIR:Q}
+MAKE_ENV+=	MANMODE=${MANMODE:Q}
+MAKE_ENV+=	BINMODE=${BINMODE:Q}
+
 .include "../../mk/bsd.pkg.mk"
diff --git a/aha/distinfo b/aha/distinfo
index b4a716b..d0295db 100644
--- a/aha/distinfo
+++ b/aha/distinfo
@@ -4,3 +4,4 @@ SHA1 (aha-0.4.8.tar.gz) = 45d91e1cda8663e8bf0c5fa8b94e4d2290aa9895
 RMD160 (aha-0.4.8.tar.gz) = 423311d1dd79ada23c4a67daae1a064afeb76ca4
 SHA512 (aha-0.4.8.tar.gz) = 8d66ee7ec6d59873c1f0bedbc4deecd0c7b84c18069d2181d7b0563d9600821455c62c37c0af1774c7190ce08b14ec52f10bdf2c15a97fd29a2b6b095d5924fa
 Size (aha-0.4.8.tar.gz) = 6744 bytes
+SHA1 (patch-Makefile) = 6fb0dc5c2b8df0a42a348c325a10a7ce61e066b2
diff --git a/aha/patches/patch-Makefile b/aha/patches/patch-Makefile
new file mode 100644
index 0000000..40aac0c
--- /dev/null
+++ b/aha/patches/patch-Makefile
@@ -0,0 +1,37 @@
+$NetBSD$
+
+--- Makefile.orig	2015-01-24 12:12:35.000000000 +0000
++++ Makefile
+@@ -1,22 +1,22 @@
+ .PHONY: all clean install
+ 
+-ifndef PREFIX
+-    PREFIX=/usr/local
+-endif
++PREFIX?=/usr/local
+ 
+-BIN:=$(DESTDIR)$(PREFIX)/bin
+-MAN:=$(DESTDIR)$(PREFIX)/man/man1
++MANDIR?=man
++
++BINMODE?=0755
++MANMODE?=644
+ 
+ all: aha
+ 
+ aha: aha.c
+-	gcc -std=c99 $(CFLAGS) $(LDFLAGS) $(CPPFLAGS) aha.c -o aha
++	$(CC) -std=c99 $(CFLAGS) $(LDFLAGS) $(CPPFLAGS) aha.c -o aha
+ 
+ clean:
+ 	rm -f aha
+ 
+ install: aha
+-	install -d $(BIN)
+-	install aha $(BIN)
+-	install -d $(MAN)
+-	install aha.1 $(MAN)
++	install -d $(DESTDIR)$(PREFIX)/bin
++	install -m ${BINMODE} aha $(DESTDIR)$(PREFIX)/bin
++	install -d $(DESTDIR)$(PREFIX)/$(MANDIR)/man1
++	install -m ${MANMODE} aha.1 $(DESTDIR)$(PREFIX)/$(MANDIR)/man1


Home | Main Index | Thread Index | Old Index