summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile30
1 files changed, 22 insertions, 8 deletions
diff --git a/Makefile b/Makefile
index 3c7a46c..08a3354 100644
--- a/Makefile
+++ b/Makefile
@@ -8,6 +8,7 @@ ikiwiki_LOCALES = da
#dummy_MODULES = content_dummy
+# uncomment this when ikiwiki.setup is configured for the local environment
#CONFIGS = ikiwiki.setup
# Everything after this is generic
@@ -19,13 +20,6 @@ podir = po
all: $(SOURCES)
-install:
-ifneq ($(strip $(CONFIGS)),)
- $(CONFIGS:%=ikiwiki --setup % --rebuild)
-else
- $(error FIXME: you need to adjust ikiwiki.setup first!)
-endif
-
# 1:source 2:locales
@@ -130,10 +124,30 @@ $(foreach module,$(dummy_MODULES),$(eval $(call DUMMYMODULE_template,$(masterdir
+# 1:configfile
+define CONFIG_template
+$(1):
+ mkdir -p $$@
+
+# WARNING: this may wipe unrelated files too!
+install::
+ ikiwiki --setup $(1) --rebuild
+endef
+$(foreach config,$(CONFIGS),$(eval $(call CONFIG_template,$(config))))
+
+
+
+install:
+ifneq ($(strip $(CONFIGS)),)
+ $(error Please configure ikiwiki.setup and then uncomment it at the top of the Makefile!)
+endif
+
+
+
pot: $(ALL_POTFILES)
po: $(ALL_POFILES)
translations: $(ALL_L10NFILES)
-.PHONY: all $(SOURCES) pot po translations
+.PHONY: all $(SOURCES) pot po translations install ultraclean