diff options
| author | 2013-01-06 14:36:51 +0100 | |
|---|---|---|
| committer | 2013-01-06 14:36:51 +0100 | |
| commit | 58a7c046d22579cc5156fb34429e5ea7ea5a5526 (patch) | |
| tree | b0c136e3bdf6ea2d0296d712197b108f074f6f49 | |
| parent | 8d9615f72aa090cf45f156400d7c02d33837c1af (diff) | |
| download | markam-58a7c046d22579cc5156fb34429e5ea7ea5a5526.tar.gz markam-58a7c046d22579cc5156fb34429e5ea7ea5a5526.zip | |
Add install target to Makefile
Installs everything under `DESTDIR', which is `/usr/local' by
default.
| -rw-r--r-- | Makefile | 10 | ||||
| -rw-r--r-- | conkeror/Makefile | 8 | ||||
| -rw-r--r-- | doc/Makefile | 8 | ||||
| -rw-r--r-- | doc/markam.texi | 5 | ||||
| -rw-r--r-- | src/Makefile | 13 |
5 files changed, 41 insertions, 3 deletions
@@ -1,7 +1,15 @@ -dirs = src doc +export DESTDIR ?= /usr/local + +dirs = src doc conkeror +install-dirs = $(addprefix install-,$(dirs)) .PHONY: all $(dirs) all: $(dirs) +install: $(install-dirs) + $(dirs): $(MAKE) -C $@ + +$(install-dirs): install-%: + $(MAKE) -C $*/ install diff --git a/conkeror/Makefile b/conkeror/Makefile new file mode 100644 index 0000000..0f9dbb4 --- /dev/null +++ b/conkeror/Makefile @@ -0,0 +1,8 @@ +DESTDIR ?= /usr/local + +.PHONY: all install + +all: +install: markam.js + install -Dm 655 markam.js \ + "$(DESTDIR)/share/conkeror/modules/markam.js" diff --git a/doc/Makefile b/doc/Makefile index 29d7269..7e798bf 100644 --- a/doc/Makefile +++ b/doc/Makefile @@ -1,4 +1,12 @@ +DESTDIR ?= /usr/local + .PHONY: all all: markam.info + +install: markam.info + install -Dm 655 markam.info "$(DESTDIR)/share/info/markam.info" + install-info --dir-file="$(DESTDIR)/share/info/dir" \ + "$(DESTDIR)/share/info/markam.info" + markam.info: markam.texi diff --git a/doc/markam.texi b/doc/markam.texi index 7687705..1f22b48 100644 --- a/doc/markam.texi +++ b/doc/markam.texi @@ -35,6 +35,11 @@ The document was typeset with @insertcopying @end titlepage +@dircategory Individual utilities +@direntry +* Markam: (markam). Keeps bookmarks. +@end direntry + @c Output the table of the contents at the beginning. @contents diff --git a/src/Makefile b/src/Makefile index d3882e3..c181d97 100644 --- a/src/Makefile +++ b/src/Makefile @@ -1,13 +1,22 @@ +DESTDIR ?= /usr/local + +binaries = markam markam-convert +install-binaries = $(addprefix install-,$(binaries)) objects = paths.o common.o -.PHONY: all +.PHONY: all install + +all: $(binaries) +install: $(install-binaries) -all: markam markam-convert markam: markam.scm $(objects) csc $^ -o $@ markam-convert: markam-convert.scm $(objects) csc $^ -o $@ +$(install-binaries): install-%: % + install -Dm 755 $* "$(DESTDIR)/bin/$*" + $(objects): %.o: %.scm csc -c $^ |
