Skip to content

Commit 1788444

Browse files
committed
added the "html" target to Makefile; also added gen-html-index-*.pl to the dependency list in the build system.
1 parent 164c6a7 commit 1788444

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

Makefile

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,19 @@
11
ver=$(shell date +'%Y.%m.%d')
22

3-
.PHONY: all zhcn en clean
3+
.PHONY: all zhcn en clean html
44

55
all: zhcn en
66

77
zhcn:
88
$(MAKE) -f ebooks.mk lang=$@ lang2=cn src=zh-cn title="agentzh的Nginx教程($(ver)版)"
9-
$(MAKE) -f ebooks.mk
109

1110
en:
1211
$(MAKE) -f ebooks.mk
1312

13+
html:
14+
$(MAKE) -f ebooks.mk lang=cn lang2=cn src=zh-cn title="agentzh的Nginx教程($(ver)版)" html
15+
$(MAKE) -f ebooks.mk html
16+
1417
clean:
1518
rm -rf html/ wiki/ index*.html *.mobi *.epub *.pdf agentzh-nginx-tutorials-*.html
1619

ebooks.mk

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,8 @@ html: $(name).html
4747
--title "$(title)" --publisher 'agentzh' \
4848
--language $(lang2) --authors 'agentzh'
4949

50-
$(name).html: $(htmlfiles)
51-
./utils/gen-html-index-$(lang2).pl -v $(ver) -o $@ $^
50+
$(name).html: $(htmlfiles) ./utils/gen-html-index-$(lang2).pl
51+
./utils/gen-html-index-$(lang2).pl -v $(ver) -o $@ $(htmlfiles)
5252

5353
html/%.html: wiki/%.wiki ./utils/wiki2html-$(lang2).pl
5454
mkdir -p $(dir $@)

0 commit comments

Comments
 (0)