acdw.net/Makefile

35 lines
661 B
Makefile

# acdw.net
BUILD:= nef/nef
LHTML:= hell/hell
NEF = G # Generator (shell functions and generator loop)
NEF+= R # Renderer (awk script to convert to compliant HTML)
NEF+= L # Layout (template script expanded by X)
INPUT = $(wildcard I/*) # regular files
INPUT+= $(wildcard I/.??*) # hidden files (for the footer)
STATIC = $(wildcard S/*) # static files
OUTPUT =$(patsubst I/%,O/%,$(INPUT))
OUTPUT+=$(patsubst S/%,O/S/%,$(STATIC))
.PHONY: all clean
all: $(OUTPUT)
clean:
rm -rf O
O:; mkdir -p O
O/S: O; mkdir -p O/S
O/S/%: S/% O/S
cp $< $@
O/%: I/% $(NEF)
$(BUILD) $<
# submodules
$(BUILD) $(LHTML):
git submodule update --init --recursive