chiark / gitweb /
Progress.
[qpweb] / Makefile
index 084e6dd0b4842f438cff56a474301ddb7a6e3fa9..3a5f6455c7691e3d5fa6d5e995c383b2202c9230 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,3 +1,5 @@
+### -*-makefile-*-
+
 all:
 clean::
 .PHONY: all clean
@@ -5,13 +7,6 @@ clean::
 TARGETS                         =
 CLEAN                   =
 
-V                       = 0
-V_AT                    = $(V_AT.$V)
-V_AT.0                  = @
-
-v-tag                   = $(call v-tag.$V,$1,$2)
-v-tag.0                         = @printf "  %-8s %s\n" '$1' '$2';
-
 CTANGLE                         = ctangle
 CWEAVE                  = cweave
 LATEX                   = pdflatex
@@ -21,6 +16,14 @@ WARNINGS              = -pedantic -Wall
 CFLAGS                  = -std=gnu99 $(OPTIMIZE) $(WARNINGS)
 LD                      = gcc
 LDFLAGS                         =
+-include local.mk
+
+V                       = 0
+V_AT                    = $(V_AT.$V)
+V_AT.0                  = @
+
+v-tag                   = $(call v-tag.$V,$1,$2)
+v-tag.0                         = @printf "  %-8s %s\n" '$1' '$2';
 
 SRCEXT                  =
 objify                  = $(addsuffix .o, \
@@ -68,6 +71,7 @@ $$(firstword $$($1_WEBSRCS)): $1.w
        $$(call v-tag,CTANGLE,$$<)$$(CTANGLE) $$<
 endef
 $(foreach w,$(WEBS:.w=), $(eval $(call tangle-web,$w)))
+%.c: %.w # don't use implicit rule
 
 TARGETS                        += qptoy fntoy