summaryrefslogtreecommitdiffstats
path: root/share/mk/build/pdf
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 19:41:07 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 19:41:07 +0000
commit3af6d22bb3850ab2bac67287e3a3d3b0e32868e5 (patch)
tree3ee7a3ec64525911fa865bb984c86d997d855527 /share/mk/build/pdf
parentAdding debian version 6.05.01-1. (diff)
downloadmanpages-3af6d22bb3850ab2bac67287e3a3d3b0e32868e5.tar.xz
manpages-3af6d22bb3850ab2bac67287e3a3d3b0e32868e5.zip
Merging upstream version 6.7.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'share/mk/build/pdf')
-rw-r--r--share/mk/build/pdf/_.mk13
-rw-r--r--share/mk/build/pdf/eqn.mk27
-rw-r--r--share/mk/build/pdf/gropdf.mk25
-rw-r--r--share/mk/build/pdf/troff.mk75
4 files changed, 140 insertions, 0 deletions
diff --git a/share/mk/build/pdf/_.mk b/share/mk/build/pdf/_.mk
new file mode 100644
index 0000000..f6660aa
--- /dev/null
+++ b/share/mk/build/pdf/_.mk
@@ -0,0 +1,13 @@
+# Copyright 2021-2024, Alejandro Colomar <alx@kernel.org>
+# SPDX-License-Identifier: LGPL-3.0-only WITH LGPL-3.0-linking-exception
+
+
+ifndef MAKEFILE_BUILD_PDF_INCLUDED
+MAKEFILE_BUILD_PDF_INCLUDED := 1
+
+
+.PHONY: build-pdf
+build-pdf: build-pdf-gropdf;
+
+
+endif # include guard
diff --git a/share/mk/build/pdf/eqn.mk b/share/mk/build/pdf/eqn.mk
new file mode 100644
index 0000000..bb0598b
--- /dev/null
+++ b/share/mk/build/pdf/eqn.mk
@@ -0,0 +1,27 @@
+# Copyright 2021-2024, Alejandro Colomar <alx@kernel.org>
+# SPDX-License-Identifier: LGPL-3.0-only WITH LGPL-3.0-linking-exception
+
+
+ifndef MAKEFILE_BUILD_PDF_EQN_INCLUDED
+MAKEFILE_BUILD_PDF_EQN_INCLUDED := 1
+
+
+include $(MAKEFILEDIR)/build/pre/tbl.mk
+include $(MAKEFILEDIR)/configure/build-depends/grep.mk
+include $(MAKEFILEDIR)/configure/build-depends/groff-base.mk
+
+
+_PDFMAN_troff := $(patsubst %.eqn,%.pdf.troff,$(_MAN_eqn))
+
+
+$(_PDFMAN_troff): %.pdf.troff: %.eqn $(MK) | $$(@D)/
+ $(info $(INFO_)EQN $@)
+ ! ($(EQN) -Tpdf $(EQNFLAGS) <$< 2>&1 >$@) \
+ | $(GREP) ^ >&2
+
+
+.PHONY: build-pdf-eqn
+build-pdf-eqn: $(_PDFMAN_troff);
+
+
+endif # include guard
diff --git a/share/mk/build/pdf/gropdf.mk b/share/mk/build/pdf/gropdf.mk
new file mode 100644
index 0000000..0913122
--- /dev/null
+++ b/share/mk/build/pdf/gropdf.mk
@@ -0,0 +1,25 @@
+# Copyright 2021-2024, Alejandro Colomar <alx@kernel.org>
+# SPDX-License-Identifier: LGPL-3.0-only WITH LGPL-3.0-linking-exception
+
+
+ifndef MAKEFILE_BUILD_PDF_GROPDF_INCLUDED
+MAKEFILE_BUILD_PDF_GROPDF_INCLUDED := 1
+
+
+include $(MAKEFILEDIR)/build/pdf/troff.mk
+include $(MAKEFILEDIR)/configure/build-depends/groff.mk
+
+
+_PDFMAN := $(patsubst %.pdf.set,%.pdf,$(_PDFMAN_MAN_set) $(_PDFMAN_MDOC_set))
+
+
+$(_PDFMAN): %.pdf: %.pdf.set $(MK) | $$(@D)/
+ $(info $(INFO_)GROPDF $@)
+ $(GROPDF) $(GROPDFFLAGS) <$< >$@
+
+
+.PHONY: build-pdf-gropdf
+build-pdf-gropdf: $(_PDFMAN);
+
+
+endif # include guard
diff --git a/share/mk/build/pdf/troff.mk b/share/mk/build/pdf/troff.mk
new file mode 100644
index 0000000..5254d5d
--- /dev/null
+++ b/share/mk/build/pdf/troff.mk
@@ -0,0 +1,75 @@
+# Copyright 2021-2024, Alejandro Colomar <alx@kernel.org>
+# SPDX-License-Identifier: LGPL-3.0-only WITH LGPL-3.0-linking-exception
+
+
+ifndef MAKEFILE_BUILD_PDF_TROFF_INCLUDED
+MAKEFILE_BUILD_PDF_TROFF_INCLUDED := 1
+
+
+include $(MAKEFILEDIR)/build/_.mk
+include $(MAKEFILEDIR)/configure/build-depends/grep.mk
+include $(MAKEFILEDIR)/configure/build-depends/groff-base.mk
+include $(MAKEFILEDIR)/configure/src.mk
+include $(MAKEFILEDIR)/configure/xfail.mk
+include $(MAKEFILEDIR)/src.mk
+
+
+_XFAIL_PDFMAN_MAN_set := \
+ $(_MANDIR)/man1/iconv.1.pdf.set \
+ $(_MANDIR)/man2/fanotify_init.2.pdf.set \
+ $(_MANDIR)/man2/syscall.2.pdf.set \
+ $(_MANDIR)/man3/newlocale.3.pdf.set \
+ $(_MANDIR)/man7/address_families.7.pdf.set \
+ $(_MANDIR)/man7/armscii-8.7.pdf.set \
+ $(_MANDIR)/man7/ascii.7.pdf.set \
+ $(_MANDIR)/man7/bpf-helpers.7.pdf.set \
+ $(_MANDIR)/man7/charsets.7.pdf.set \
+ $(_MANDIR)/man7/cp1251.7.pdf.set \
+ $(_MANDIR)/man7/iso_8859-2.7.pdf.set \
+ $(_MANDIR)/man7/iso_8859-3.7.pdf.set \
+ $(_MANDIR)/man7/iso_8859-4.7.pdf.set \
+ $(_MANDIR)/man7/iso_8859-5.7.pdf.set \
+ $(_MANDIR)/man7/iso_8859-6.7.pdf.set \
+ $(_MANDIR)/man7/iso_8859-7.7.pdf.set \
+ $(_MANDIR)/man7/iso_8859-8.7.pdf.set \
+ $(_MANDIR)/man7/iso_8859-10.7.pdf.set \
+ $(_MANDIR)/man7/iso_8859-11.7.pdf.set \
+ $(_MANDIR)/man7/iso_8859-13.7.pdf.set \
+ $(_MANDIR)/man7/iso_8859-14.7.pdf.set \
+ $(_MANDIR)/man7/iso_8859-16.7.pdf.set \
+ $(_MANDIR)/man7/koi8-r.7.pdf.set \
+ $(_MANDIR)/man7/koi8-u.7.pdf.set \
+ $(_MANDIR)/man7/vdso.7.pdf.set
+
+
+_PDFMAN_MAN_set := $(patsubst $(MANDIR)/%,$(_MANDIR)/%.pdf.set,$(NONSO_MAN))
+_PDFMAN_MDOC_set := $(patsubst $(MANDIR)/%,$(_MANDIR)/%.pdf.set,$(NONSO_MDOC))
+
+
+ifeq ($(SKIP_XFAIL),yes)
+_PDFMAN_MAN_set := $(filter-out $(_XFAIL_PDFMAN_MAN_set), $(_PDFMAN_MAN_set))
+endif
+
+
+$(_PDFMAN_MAN_set): %.pdf.set: %.pdf.troff $(MK) | $$(@D)/
+ $(info $(INFO_)TROFF $@)
+ ! ($(TROFF) -man -Tpdf $(TROFFFLAGS) <$< 2>&1 >$@) \
+ | $(GREP) ^ >&2
+
+$(_PDFMAN_MDOC_set): %.pdf.set: %.pdf.troff $(MK) | $$(@D)/
+ $(info $(INFO_)TROFF $@)
+ ! ($(TROFF) -mdoc -Tpdf $(TROFFFLAGS) <$< 2>&1 >$@) \
+ | $(GREP) ^ >&2
+
+
+.PHONY: build-pdf-troff-man
+build-pdf-troff-man: $(_PDFMAN_MAN_set);
+
+.PHONY: build-pdf-troff-mdoc
+build-pdf-troff-mdoc: $(_PDFMAN_MDOC_set);
+
+.PHONY: build-pdf-troff
+build-pdf-troff: build-pdf-troff-man build-pdf-troff-mdoc;
+
+
+endif # include guard