pre-release cleanup
[svn/Prometheus-QoS/.git] / Makefile
1 PACKAGE=prometheus
2 VERSION=0.7.8
3 CFLAGS=-std=c99 -Wall
4 prefix=/usr
5 mandir=$(prefix)/share/man
6 sbindir=$(prefix)/sbin
7 sysconfdir=/etc/
8
9 main: prometheus
10 $(CC) -o prometheus prometheus.c
11
12 deb: main
13 arch=`dpkg-architecture -qDEB_HOST_ARCH`
14 maintainer="gandalf <gandalf@arachne.cz>"
15 #patch -Nl <deb/prometheus.patch
16 sed -e "s/__ARCHITECTURE__/$(arch)/" -e "s/__VERSION__/($VERSION)/" -e "s/__PACKAGE__/($PACKAGE)/" -e "s/__MAINTAINER__/$(maintainer)/" deb/prometheus.control > deb/control
17 dpkg-buildpackage
18
19 tgz: clean
20 cp -r . ../$(PACKAGE)-$(VERSION)
21 rm -rf ../$(PACKAGE)-$(VERSION)/.svn/
22 rm -rf ../$(PACKAGE)-$(VERSION)/*/.svn/
23 rm -rf ../$(PACKAGE)-$(VERSION)/*~ $(PACKAGE)-$(VERSION)/*/*~
24 tar -czf $(PACKAGE)-$(VERSION).tar.gz ../$(PACKAGE)-$(VERSION)
25 rm -rf ../$(PACKAGE)-$(VERSION)
26
27 install: main
28 install -d $(sbindir)
29 install -d $(mandir)/man1
30 install -d $(mandir)/man5
31 install -d $(sysconfdir)/cron.d
32 install -d $(sysconfdir)/prometheus
33 install -m 755 prometheus $(sbindir)
34 install -m 644 prometheus.1 $(mandir)/man1
35 install -m 644 prometheus.conf.5 $(mandir)/man5
36 install -m 755 conf/prometheus.cron $(sysconfdir)/cron.d/prometheus
37 install -m 755 conf/prometheus.init $(sysconfdir)/init.d/prometheus
38 install -m 600 conf/prometheus.conf $(sysconfdir)/prometheus
39 install -m 600 conf/prometheus.hosts $(sysconfdir)/prometheus/hosts
40 install -m 644 conf/prometheus.default $(sysconfdir)/default/prometheus
41
42 clean:
43 rm -f prometheus
44 rm -f optinal-tools/prometheus-stats
This page took 0.348795 seconds and 5 git commands to generate.