Add dotfiles2.mk

This should replace dotfiles.mk soon
This commit is contained in:
Tom Willemse 2013-05-26 17:55:03 +02:00
parent 99b4ee7cd9
commit a3ee1cf373

17
dotfiles2.mk Normal file
View file

@ -0,0 +1,17 @@
DESTDIR?=$(HOME)
DESTDIR:=$(DESTDIR)/$(SUBDIR)
RSYNC=rsync
RFLAGS=--links --perms --times --group --owner --dirs --verbose \
--update --delete --exclude=Makefile --exclude=.gitignore \
$(addprefix --exclude=,$(EXCLUDE))
install-modules=$(addprefix install-,$(MODULES))
install: $(install-modules)
@echo "Syncing $(CURDIR)/ with $(DESTDIR)"
@$(RSYNC) $(RFLAGS) $(CURDIR)/ $(DESTDIR)
@echo
$(install-modules): install-%:
@DESTDIR=$(DESTDIR) $(MAKE) -s -C $* install