diff options
author | Alexander Sulfrian <alexander@sulfrian.net> | 2012-04-24 23:19:57 +0200 |
---|---|---|
committer | Alexander Sulfrian <alexander@sulfrian.net> | 2012-04-24 23:21:40 +0200 |
commit | 96f48ebd97c19384f487c8a9c4cf474705ce1e37 (patch) | |
tree | f042516a671b1bf8502ef46ed3040c5775168692 /emacs.d/lisp/magit/Makefile | |
parent | fc1c79470a57357da25aed54aa1a04471b343aff (diff) | |
download | dotfiles-96f48ebd97c19384f487c8a9c4cf474705ce1e37.tar.gz dotfiles-96f48ebd97c19384f487c8a9c4cf474705ce1e37.tar.xz dotfiles-96f48ebd97c19384f487c8a9c4cf474705ce1e37.zip |
emacs.d/lisp/magit: version bump
Diffstat (limited to '')
-rw-r--r-- | emacs.d/lisp/magit/Makefile | 91 | ||||
-rw-r--r-- | emacs.d/lisp/magit/Makefile.am | 24 |
2 files changed, 91 insertions, 24 deletions
diff --git a/emacs.d/lisp/magit/Makefile b/emacs.d/lisp/magit/Makefile new file mode 100644 index 0000000..7d94041 --- /dev/null +++ b/emacs.d/lisp/magit/Makefile @@ -0,0 +1,91 @@ +VERSION=$(shell git describe --tags --dirty) +EMACS=emacs +PREFIX=/usr/local +SYSCONFDIR=/etc +ELS=magit.el magit-svn.el magit-topgit.el magit-stgit.el magit-key-mode.el magit-bisect.el +ELS_CONTRIB=contrib/magit-simple-keys.el contrib/magit-classic-theme.el +ELCS=$(ELS:.el=.elc) +ELCS_CONTRIB=$(ELS_CONTRIB:.el=.elc) +DIST_FILES=$(ELS) Makefile magit.texi magit.info README.md magit.spec.in magit-pkg.el.in 50magit.el +DIST_FILES_CONTRIB=$(ELS_CONTRIB) contrib/magit +ELPA_FILES=$(ELS) magit.info magit-pkg.el + +.PHONY=install + +BATCH=$(EMACS) -batch -q -no-site-file -eval \ + "(setq load-path (cons (expand-file-name \".\") load-path))" + +%.elc: %.el + $(BATCH) --eval '(byte-compile-file "$<")' + +all: core docs contrib + +core: $(ELCS) magit.spec magit-pkg.el + +docs: magit.info + +contrib: $(ELCS_CONTRIB) + +magit.spec: magit.spec.in + sed -e s/@VERSION@/$(VERSION)/ < $< > $@ + +magit-pkg.el: magit-pkg.el.in + sed -e s/@VERSION@/$(VERSION)/ < $< > $@ + +magit.elc: magit.el + sed -e "s/@GIT_DEV_VERSION@/$(VERSION)/" < magit.el > magit.tmp.el #NO_DIST + $(BATCH) --eval '(byte-compile-file "magit.tmp.el")' #NO_DIST + mv magit.tmp.elc magit.elc #NO_DIST + rm magit.tmp.el #NO_DIST +magit-key-mode.elc: +magit-svn.elc: +magit-topgit.elc: +magit-stgit.elc: +magit.info: + +dist: magit-$(VERSION).tar.gz + +magit-$(VERSION).tar.gz: $(DIST_FILES) $(DIST_FILES_CONTRIB) + mkdir -p magit-$(VERSION)/contrib + cp --preserve=timestamps $(DIST_FILES) magit-$(VERSION) + cp --preserve=timestamps $(DIST_FILES_CONTRIB) magit-$(VERSION)/contrib + sed -i -e "1 s/=.*/=$(VERSION)/" magit-$(VERSION)/Makefile #NO_DIST + sed -i -e "/NO_DIST/d" magit-$(VERSION)/Makefile #NO_DIST + sed -i -e "s/@GIT_DEV_VERSION@/$(VERSION)/" magit-$(VERSION)/magit.el #NO_DIST + tar -cvzf magit-$(VERSION).tar.gz magit-$(VERSION) + rm -rf magit-$(VERSION) + +elpa: magit-$(VERSION).tar + +magit-$(VERSION).tar: $(ELPA_FILES) + mkdir magit-$(VERSION) + cp --preserve=timestamps $(ELPA_FILES) magit-$(VERSION) + sed -i -e "s/@GIT_DEV_VERSION@/$(VERSION)/" magit-$(VERSION)/magit.el #NO_DIST + tar -cvf magit-$(VERSION).tar magit-$(VERSION) + rm -rf magit-$(VERSION) + +install: install_core install_docs + +install_core: core + mkdir -p $(DESTDIR)$(PREFIX)/share/emacs/site-lisp + install -m 644 $(ELS) $(ELCS) $(DESTDIR)$(PREFIX)/share/emacs/site-lisp + sed -i -e "s/@GIT_DEV_VERSION@/$(VERSION)/" $(DESTDIR)$(PREFIX)/share/emacs/site-lisp/magit.el #NO_DIST + mkdir -p $(DESTDIR)$(SYSCONFDIR)/emacs/site-start.d + install -m 644 50magit.el $(DESTDIR)$(SYSCONFDIR)/emacs/site-start.d/50magit.el + +install_docs: docs + mkdir -p $(DESTDIR)$(PREFIX)/share/info + install -m 644 magit.info $(DESTDIR)$(PREFIX)/share/info + install-info --info-dir=$(DESTDIR)$(PREFIX)/share/info $(DESTDIR)$(PREFIX)/share/info/magit.info + +install_contrib: contrib + mkdir -p $(DESTDIR)$(PREFIX)/share/emacs/site-lisp + install -m 644 $(ELS_CONTRIB) $(ELCS_CONTRIB) $(DESTDIR)$(PREFIX)/share/emacs/site-lisp + mkdir -p $(DESTDIR)$(PREFIX)/bin + install -m 755 contrib/magit $(DESTDIR)$(PREFIX)/bin + +install_all: install install_contrib + +clean: + rm -f magit.info #NO_DIST + rm -fr magit-pkg.el magit.spec $(ELCS) $(ELCS_CONTRIB) *.tar.gz magit-$(VERSION) diff --git a/emacs.d/lisp/magit/Makefile.am b/emacs.d/lisp/magit/Makefile.am deleted file mode 100644 index 8ae4192..0000000 --- a/emacs.d/lisp/magit/Makefile.am +++ /dev/null @@ -1,24 +0,0 @@ -lispdir = $(datadir)/emacs/site-lisp -sitestartdir = $(sysconfdir)/emacs/site-start.d - -lisp_DATA = magit.el magit.elc -sitestart_DATA = 50magit.el - -info_TEXINFOS = magit.texi - -CLEANFILES = magit.elc -EXTRA_DIST = magit.el 50magit.el - -%.elc: %.el - @if [ $(builddir) != $(srcdir) ]; then ln $(srcdir)/$*.el .; fi - emacs --batch --eval '(byte-compile-file "$*.el")' - @if [ $(builddir) != $(srcdir) ]; then rm -f $*.el; fi - - -elpa: magit-pkg.el info - -@rm -rf magit-$(VERSION) - mkdir magit-$(VERSION) - cp magit.el magit-pkg.el magit.info magit-$(VERSION) - (cd magit-$(VERSION); ginstall-info --dir-file=dir magit.info) - tar cf magit-$(VERSION).tar magit-$(VERSION) - @rm -rf magit-$(VERSION) |