Makefile v0.3
[henge/apc.git] / Makefile
index 1bc47b8..a1e743f 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -36,7 +36,7 @@ hGEN  := $(ySRC:%.y=%.tab.h)
 cGEN  := $(strip $(ySRC:%.y=%.tab.c) $(rlSRC:%.rl=%.c))
 
 # Functions
-cGENDEP = $(if $(wildcard $1),$(subst src/,,$(filter-out $1 \ %:,$(shell $(CC) -MM -MG $1))),$(info fnf $1))
+cGENDEP = $(if $(wildcard $1),$(subst src/,,$(filter-out $1 \ %:,$(shell $(CC) -MM -MG $1))),$(info <$1>))
 ldFLAGS = $(strip $(LDFLAGS) $(LDLIBS) $(VA_ARGS))
 
 # Rules
@@ -57,3 +57,6 @@ apc-d apc: $$($$@SRC) | $(hGEN)
 
 %.c: %.rl
        $(strip $(RLCMD))
+
+clean: $(wildcard $(cGEN) $(hGEN) $(apcSRC) $(apc-dSRC))
+       rm $^