Don't hardcode as much
authorRoy Marples <roy@marples.name>
Mon, 19 Nov 2007 20:25:40 +0000 (20:25 +0000)
committerRoy Marples <roy@marples.name>
Mon, 19 Nov 2007 20:25:40 +0000 (20:25 +0000)
Makefile

index 71097ca03d77855f305f545c501da44bdd31f68b..fb0191eebe82f39c3e160395cf481331d94abb92 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,7 @@
+NAME = openresolv 
 VERSION = 1.0
+PKG = $(NAME)-$(VERSION)
+
 DESTDIR =
 PREFIX =
 MANPREFIX ?= /usr/share
@@ -40,10 +43,10 @@ install: $(TARGET)
        ln -snf /var/run/resolvconf $(ETCDIR)/run
 
 dist:
-       $(INSTALL) -d /tmp/openresolv-$(VERSION)
-       cp -RPp . /tmp/openresolv-$(VERSION)
-       (cd /tmp/openresolv-$(VERSION); $(MAKE) clean)
-       rm -rf /tmp/openresolv-$(VERSION)/*.bz2 /tmp/openresolv-$(VERSION)/.git
-       tar cvjpf openresolv-$(VERSION).tar.bz2 -C /tmp openresolv-$(VERSION)
-       rm -rf /tmp/openresolv-$(VERSION)
-       ls -l openresolv-$(VERSION).tar.bz2
+       $(INSTALL) -d /tmp/$(PKG)
+       cp -RPp . /tmp/$(PKG)
+       (cd /tmp/$(PKG); $(MAKE) clean)
+       rm -rf /tmp/$(PKG)/*.bz2 /tmp/$(PKG)/.git
+       tar cvjpf $(PKG).tar.bz2 -C /tmp $(PKG) 
+       rm -rf /tmp/$(PKG) 
+       ls -l $(PKG).tar.bz2