DISTDIR ?= $(shell pwd) TEMPLATE_DIR ?= $(DISTDIR)/templates SCRIPT_DIR ?= $(DISTDIR)/scripts BUILDDIR ?= $(DISTDIR)/build export PAGES := $(wildcard pages/*) all: $(PAGES) static $(PAGES): $(MAKE) -C $@ static: @mkdir -p $(BUILDDIR) cp -r static $(BUILDDIR) .PHONY: all $(PAGES) static