# makefile PUB_SOURCE="/" PUB_TARGET="$(PWD)/TARGET" PUB_BUILD="$(PWD)/BUILD" # files XTMPL_FILES="$(shell find $(PUB_BUILD) -name '*.xtmpl')" HTML_FILES="$(shell find $(PUB_BUILD) -name '*.html')" # targets all : before-all mkbuild preprocess export postprocess after-all install : all echo "install" export : cms/export.sh "$(PUB_TARGET)" "$(PUB_BUILD)" "$(PUB_SOURCE)" mkbuild :: if test -d $(PUB_BUILD); then\ rm -rf $(PUB_BUILD);\ fi mkdir $(PUB_BUILD) cms/mkbuild.sh "$(PUB_BUILD)" before-all :: after-all :: validatetemplates :: cms/validate.sh "$(XTMPL_FILES)" validatehtml :: cms/validatehtml.sh "$(HTML_FILES)" validate :: validatetemplates # validatehtml echo "validation done." preprocess :: validate echo "preprocess $(PUB_TARGET) ..." if ! test -d $(PUB_TARGET); then\ mkdir $(PUB_TARGET);\ fi postprocess :: sh cms/cleanup-result.sh "$(PUB_TARGET)" cms/fixup.sh "$(PUB_TARGET)" pack-all :: cms/pack-www.sh "$(PUB_TARGET)" "$(PWD)/groupdav" pack :: cms/pack-www-noimgs.sh "$(PUB_TARGET)" "$(PWD)/groupdav" clean :: rm -rf $(PUB_TARGET)/* rm -rf $(PUB_BUILD)