diff options
author | Philip Knirsch <pknirsch@hamburg.stuttgart.redhat.com> | 2009-02-20 18:29:35 +0100 |
---|---|---|
committer | Philip Knirsch <pknirsch@hamburg.stuttgart.redhat.com> | 2009-02-20 18:29:35 +0100 |
commit | c02f25afb09ff1f38484a8b69c4dcc85ed2378c7 (patch) | |
tree | f0c8a9d0a4552f07bac2272fca8a70cf736d453d /Makefile | |
parent | 5818e327421ff22f41618c7b9fa74be8d23d4fd5 (diff) | |
download | tuned-c02f25afb09ff1f38484a8b69c4dcc85ed2378c7.tar.gz tuned-c02f25afb09ff1f38484a8b69c4dcc85ed2378c7.tar.xz tuned-c02f25afb09ff1f38484a8b69c4dcc85ed2378c7.zip |
- Lots of updates to packaging and installation (specfile, makefile)
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..f17879e --- /dev/null +++ b/Makefile @@ -0,0 +1,52 @@ +NAME=tuned +VERSION=$(shell awk '/^Version:/ {print $$2}' tuned.spec) +RELEASE=$(shell awk '/^Release:/ {print $$2}' tuned.spec) +VERSIONED_NAME=$(NAME)-$(VERSION) + +DESTDIR=/ +MANDIR=/usr/share/man/ +GITTAG = r$(subst .,-,$(VERSION)) + +DIRS = doc contrib tuningplugins monitorplugins +FILES = tuned +DOCS = AUTHORS ChangeLog COPYING INSTALL NEWS README tuned.spec + +archive: + rm -rf $(VERSIONED_NAME) + mkdir -p $(VERSIONED_NAME) + cp $(FILES) $(VERSIONED_NAME)/ + cp $(DOCS) $(VERSIONED_NAME)/ + + tar cjf $(VERSIONED_NAME).tar.bz2 $(VERSIONED_NAME) + ln -fs $(VERSIONED_NAME).tar.bz2 latest-archive + +tag: + git tag $(GITTAG) + +srpm: archive + rm -rf rpm-build-dir + mkdir rpm-build-dir + rpmbuild --define "_sourcedir `pwd`/rpm-build-dir" --define "_srcrpmdir `pwd`/rpm-build-dir" \ + --define "_specdir `pwd`/rpm-build-dir" --nodeps -ts $(VERSIONED_NAME).tar.bz2 + rm -rf rpm-build-dir + +build: + # Make Magicfilter + +install: + mkdir -p $(DESTDIR) + + # Install the binaries + mkdir -p $(DESTDIR)/usr/bin/ + + mkdir -p $(DESTDIR)/etc/alchemist/namespace/printconf + install -m 0644 adl_files/rpm.adl adl_files/local.adl $(DESTDIR)/etc/alchemist/namespace/printconf/ + + # drop in some basics + install -m 0644 printcap.local $(DESTDIR)/etc/ + +clean: + rm -rf *.pyc monitorplugins/*.pyc tuningplugins/*.pyc + +.PHONY: clean archive srpm tag + |