summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Shumaker <LukeShu@sbcglobal.net>2013-05-12 02:22:16 -0400
committerLuke Shumaker <LukeShu@sbcglobal.net>2013-05-12 02:22:16 -0400
commitb2c326dc625c0ee7cdfb5763b036db6893db9efd (patch)
treefd91e3d97fd2dd900975b7d55ac3a02eb8bab533
parente498fed9f196c50f79ddd395688689d8761ae134 (diff)
clean up Makefile
* use $(bindir) * use $(pkgdatadir) * remove jh-mksource
-rw-r--r--Makefile14
1 files changed, 9 insertions, 5 deletions
diff --git a/Makefile b/Makefile
index e1de0a3..33307fe 100644
--- a/Makefile
+++ b/Makefile
@@ -1,5 +1,9 @@
-subcommands = help list-commands mvn-basename mvn-install mvn-localrepo mksource checksource
-dirs = $(DESTDIR)/usr/share/jh $(DESTDIR)/usr/bin
+prefix = /usr
+bindir = $(prefix)/bin
+pkgdatadir = /usr/share/jh # hardcoded into jh.sh
+
+subcommands = help list-commands mvn-basename mvn-install mvn-localrepo checksource
+dirs = $(DESTDIR)$(bindir) $(DESTDIR)$(pkgdatadir)
####
@@ -11,14 +15,14 @@ all: PHONY build
####
build: PHONY jh $(subcommand_files)
-install: PHONY $(DESTDIR)/usr/bin/jh $(addprefix $(DESTDIR)/usr/share/jh/,$(subcommand_files) $(help_files))
+install: PHONY $(DESTDIR)$(bindir)/jh $(addprefix $(DESTDIR)$(pkgdatadir)/,$(subcommand_files) $(help_files))
clean: PHONY
rm -f jh $(subcommand_files)
-$(DESTDIR)/usr/share/jh/%: % | $(DESTDIR)/usr/share/jh
+$(DESTDIR)$(pkgdaradir)/%: % | $(DESTDIR)$(pkgdatadir)
cp '$<' '$@'
-$(DESTDIR)/usr/bin/jh: jh | $(DESTDIR)/usr/bin
+$(DESTDIR)$(bindir)/jh: jh | $(DESTDIR)$(bindir)
cp '$<' '$@'
$(dirs):