Skip to content
This repository was archived by the owner on Feb 4, 2024. It is now read-only.

Commit 9ecf3ce

Browse files
committed
docs: Use htmldoc for pdf generation
Htmldoc [1] preserves links in the generated PDF document. [1]: https://www.msweet.org/htmldoc/
1 parent 597d50d commit 9ecf3ce

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

Makefile

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11

2-
VERSION = 3.2a
2+
VERSION = $(shell git describe --long)
3+
-include version.mk
34

45
#CC ?= gcc
56
CPPFLAGS += -DVERSION_STR=\"$(VERSION)\"
@@ -72,16 +73,18 @@ picocom.1 : picocom.1.md
7273
-Vfooter="Picocom $(VERSION)" \
7374
-Vadjusting='l' \
7475
-Vhyphenate='' \
75-
-o $@ $?
76+
-o $@ $<
7677

7778
picocom.1.html : picocom.1.md
79+
# modern pandoc wants --embed-resources --standalone, but
80+
# pandoc in github ci is too old.
7881
pandoc -s -t html \
79-
--embed-resources --standalone \
82+
--standalone \
8083
-Vversion="v$(VERSION)" \
81-
-o $@ $?
84+
-o $@ $<
8285

83-
picocom.1.pdf : picocom.1
84-
groff -man -Tpdf $? > $@
86+
picocom.1.pdf : picocom.1.html
87+
htmldoc -f $@ $<
8588

8689

8790
clean:

0 commit comments

Comments
 (0)