24 lines
571 B
Makefile
24 lines
571 B
Makefile
EMACS = emacs
|
|
|
|
files = init.el init.elc
|
|
install-files = $(addprefix install-,$(files))
|
|
submodules = eshell
|
|
install-submodules = $(addprefix install-,$(submodules))
|
|
|
|
.PHONY: all $(submodules) install $(install-submodules) $(install-files)
|
|
|
|
all: $(files) $(submodules)
|
|
|
|
$(submodules):
|
|
$(MAKE) -C $@/
|
|
|
|
$(filter %.elc,$(files)): %.elc: %.el
|
|
$(EMACS) -batch -eval "(byte-compile-file \"$^\")"
|
|
|
|
install: $(install-files) $(install-submodules)
|
|
|
|
$(install-files): install-%: $*
|
|
install -Dm 444 $* ${HOME}/.emacs.d/$*
|
|
|
|
$(install-submodules): install-%:
|
|
$(MAKE) -C $*/ install
|