Fixup fromcvs/togit conversion
[minix-pkgsrc.git] / sysutils / munin-node / patches / patch-aa
bloba41c63f4bf165b5beb7112c95598ecd8632a8130
1 $NetBSD: patch-aa,v 1.3 2010/07/11 18:15:47 joerg Exp $
3 --- Makefile.config.orig        2005-04-15 20:29:18.000000000 +0000
4 +++ Makefile.config
5 @@ -7,32 +7,32 @@
6  #
7  # the base of the Munin installation.
8  # 
9 -PREFIX     = $(DESTDIR)/opt/munin
10 +UPREFIX=${DESTDIR}$(PREFIX)
12  # Where Munin keeps its configurations (server.conf, client.conf, ++)
13 -CONFDIR    = $(DESTDIR)/etc/opt/munin
14 +CONFDIR   ?= $(UPREFIX)/etc/munin
16  # Server only - where to put munin-cron
17 -BINDIR     = $(PREFIX)/bin
18 +BINDIR     = $(UPREFIX)/bin
20  # Client only - where to put munin-node, munin-node-configure, and munin-run
21 -SBINDIR    = $(PREFIX)/sbin
22 +SBINDIR    = $(UPREFIX)/sbin
24  # Where to put text and html documentation
25 -DOCDIR     = $(PREFIX)/doc
26 +DOCDIR     = $(UPREFIX)/share/doc/munin
28  # Where to put man pages
29 -MANDIR     = $(PREFIX)/man
30 +MANDIR     = $(UPREFIX)/${PKGMANDIR}
32  # Where to put internal binaries and plugin repository
33 -LIBDIR     = $(PREFIX)/lib
34 +LIBDIR     = $(UPREFIX)/lib/munin
36  # Server only - Output directory
37 -HTMLDIR    = $(PREFIX)/var/www
38 +HTMLDIR    = $(UPREFIX)/www/munin/data
39  CGIDIR     = $(HTMLDIR)/cgi
41  # Client only - Where to put RRD files and other intenal data
42 -DBDIR      = $(DESTDIR)/var/opt/munin
43 +DBDIR      = $(DESTDIR)/var/munin
45  # Client only - Where plugins should put their states. Must be writable by
46  # group "munin", and should be preserved between reboots
47 @@ -45,14 +45,14 @@ LOGDIR     = $(DESTDIR)/var/log/munin
48  # writable by the user "munin".
49  STATEDIR   = $(DESTDIR)/var/run/munin
51 -# The perl interpreter to use
52 -PERL       = $(shell which perl)
53 +# The perl interpreter to use (passed in by pkgsrc)
54 +PERL       = ${PERL5}
56  # The python interpreter to use (used by some plugins)
57 -PYTHON     = /usr/bin/env python
58 +PYTHON     = ${PYTHONBIN}
60  # Server only - Where to install the perl libraries
61 -PERLLIB    = $(DESTDIR)$(shell $(PERL) -V:sitelib | cut -d= -f2 | sed "s/[\';]//g")
62 +PERLLIB    = ${PERL5_SITELIB}
64  # Client only - Install plugins for this architecture
65  OSTYPE     = $(shell uname | tr '[A-Z]' '[a-z]')
66 @@ -65,16 +65,15 @@ HOSTNAME   = $(shell hostname)
67  VERSION    = $(shell cat RELEASE)
69  # User to run munin as
70 -USER       = munin
71 -GROUP      = munin
72 +USER       = ${MUNIN_USER}
73 +GROUP      = ${MUNIN_GROUP}
75  # Default user to run the plugins as
76  PLUGINUSER = nobody
78  # Which command to use to check if the USER and GROUP to run Munin as, exists.
79 -GETENT = $(shell which getent || which true 2>/dev/null)
80 -CHECKUSER  = $(shell $(GETENT) passwd $(USER) >/dev/null 2>/dev/null || (echo "echo User $(USER) nonexistant. Create the user and retry; exit 2"))
81 -CHECKGROUP = $(shell $(GETENT) group $(GROUP) >/dev/null 2>/dev/null || (echo "echo Group $(GROUP) nonexistant. Create the group and retry; exit 2"))
82 +CHECKUSER  = $(shell grep $(USER) /etc/passwd >/dev/null 2>/dev/null || (echo "echo User $(USER) nonexistent. Create the user and retry; exit 2"))
83 +CHECKGROUP = $(shell grep $(GROUP) /etc/group >/dev/null 2>/dev/null || (echo "echo Group $(GROUP) nonexistent. Create the group and retry; exit 2"))
85  CHOWN      = chown
86  CHMOD      = chmod