Subject: [alpine-aports] [PATCH 1/2] testing/texmf-dist: Updated and completed texmf-dist

From: Marian Buschsieweke <[email-masked]>
Date: Fri, 15 Dec 2017 16:36:23 +0100

Now all texlive packages available in Arch Linux are also available in Alpine
Linux :-)
---
 testing/texmf-dist/APKBUILD           | 312 ++++++++++++++++++++++++++++++++--
 testing/texmf-dist/duplicates.txt     | 207 ++++++++++++++++++++++
 testing/texmf-dist/texmf-dist.trigger |   4 -
 3 files changed, 501 insertions(+), 22 deletions(-)
 create mode 100644 testing/texmf-dist/duplicates.txt
 delete mode 100644 testing/texmf-dist/texmf-dist.trigger

diff --git a/testing/texmf-dist/APKBUILD b/testing/texmf-dist/APKBUILD
index 593683f409..6c24c58005 100644
--- a/testing/texmf-dist/APKBUILD
+++ b/testing/texmf-dist/APKBUILD
@@ -1,21 +1,79 @@
 # Contributor: Marian Buschsieweke <[email-masked]>
 # Maintainer: Marian Buschsieweke <[email-masked]>
 pkgname=texmf-dist
-pkgver=2017.44907
-pkgrel=1
+_core=2017.45811
+_bibtexextra=2017.45810
+_fontsextra=2017.45939
+_formatsextra=2017.45678
+_games=2017.44131
+_humanities=2017.45709
+_langchinese=2017.45677
+_langcyrillic=2017.45692
+_langextra=2017.45591
+_langgreek=2017.44917
+_langjapanese=2017.45699
+_langkorean=2017.44467
+_latexextra=2017.45733
+_music=2017.45674
+_pictures=2017.45569
+_pstricks=2017.45644
+_publishers=2017.45734
+_science=2017.45707
+pkgver=${_core}
+pkgrel=0
 pkgdesc="TeX Live texmf core distribution"
 url="http://tug.org/texlive/"
 arch="noarch"
 license="GPL"
-depends="texlive"
+depends=""
 depends_dev=""
-makedepends="texlive-full xz"
+makedepends="unzip xz"
 install=""
-subpackages="${pkgname}-most"
-source="${pkgname}-${pkgver}.tar.xz::https://github.com/maribu/${pkgname}/raw/master/${pkgname}-${pkgver}.tar.xz
-	${pkgname}-most-${pkgver}.tar.xz::https://github.com/maribu/${pkgname}/raw/master/${pkgname}-most-${pkgver}.tar.xz"
+subpackages="
+	${pkgname}-most
+	${pkgname}-lang
+	${pkgname}-full
+	${pkgname}-bibtexextra
+	${pkgname}-fontsextra
+	${pkgname}-formatsextra
+	${pkgname}-games
+	${pkgname}-humanities
+	${pkgname}-langchinese
+	${pkgname}-langcyrillic
+	${pkgname}-langextra
+	${pkgname}-langgreek
+	${pkgname}-langjapanese
+	${pkgname}-langkorean
+	${pkgname}-latexextra
+	${pkgname}-music
+	${pkgname}-pictures
+	${pkgname}-pstricks
+	${pkgname}-publishers
+	${pkgname}-science
+	"
+source="
+	https://sources.archlinux.org/other/texlive/texlive-core-${_core}-src.zip
+	https://sources.archlinux.org/other/texlive/texlive-bibtexextra-${_bibtexextra}-src.zip
+	https://sources.archlinux.org/other/texlive/texlive-fontsextra-${_fontsextra}-src.zip
+	https://sources.archlinux.org/other/texlive/texlive-formatsextra-${_formatsextra}-src.zip
+	https://sources.archlinux.org/other/texlive/texlive-games-${_games}-src.zip
+	https://sources.archlinux.org/other/texlive/texlive-humanities-${_humanities}-src.zip
+	https://sources.archlinux.org/other/texlive/texlive-langchinese-${_langchinese}-src.zip
+	https://sources.archlinux.org/other/texlive/texlive-langcyrillic-${_langcyrillic}-src.zip
+	https://sources.archlinux.org/other/texlive/texlive-langextra-${_langextra}-src.zip
+	https://sources.archlinux.org/other/texlive/texlive-langgreek-${_langgreek}-src.zip
+	https://sources.archlinux.org/other/texlive/texlive-langjapanese-${_langjapanese}-src.zip
+	https://sources.archlinux.org/other/texlive/texlive-langkorean-${_langkorean}-src.zip
+	https://sources.archlinux.org/other/texlive/texlive-latexextra-${_latexextra}-src.zip
+	https://sources.archlinux.org/other/texlive/texlive-music-${_music}-src.zip
+	https://sources.archlinux.org/other/texlive/texlive-pictures-${_pictures}-src.zip
+	https://sources.archlinux.org/other/texlive/texlive-pstricks-${_pstricks}-src.zip
+	https://sources.archlinux.org/other/texlive/texlive-publishers-${_publishers}-src.zip
+	https://sources.archlinux.org/other/texlive/texlive-science-${_science}-src.zip
+	duplicates.txt
+	"
 options="!check"
-triggers="texmf-dist.trigger=/usr/share/texmf-dist"
+
 unpack() {
 	# Prevent unpacking by overwriting the unpack() function
 	return 0
@@ -26,18 +84,236 @@ build(){
 }
 	
 package() {
-	mkdir -p "${pkgdir}/usr/share"
-	cd "${pkgdir}/usr/share"
-	tar xJf "${srcdir}/${pkgname}-${pkgver}.tar.xz"
+	# Packages are packed in .tar.xz archives, which in turn are bundled into a
+	# zip. We will unzip each bundle into pkgs-packed and untar all packages of
+	# that bundle into pkgs-unpacked. Since some packages are expected to
+	# be unpacked into /usr/share and others into /usr/shared/texmf-dist, this
+	# will create a mess. We will later copy all folders beginning with texmf
+	# into /usr/share, and merge every remaining file into
+	# /usr/share/texmf-dist to clean up this mess.
+	
+	mkdir -p "${pkgdir}/usr/share/"
+	mkdir -p "${srcdir}/pkgs-packed"
+	mkdir -p "${srcdir}/pkgs-unpacked"
+	cd "${srcdir}/pkgs-packed"
+	unzip "${srcdir}/texlive-core-${_core}-src.zip" > /dev/null
+	cd "${srcdir}/pkgs-unpacked"
+	find "${srcdir}/pkgs-packed" -name '*.tar.xz' -exec tar -xf {} \;
+	find . -maxdepth 1 -name 'texmf*' -exec mv {} "${pkgdir}/usr/share/" \;
+	find . -type d -mindepth 1 -exec mkdir -p "${pkgdir}/usr/share/texmf-dist/"{} \;
+	find . -type f -exec mv {} "${pkgdir}/usr/share/texmf-dist/"{} \;
+
+	# Remove files already provided by texlive* packages
+	cd "${pkgdir}/usr/share/texmf-dist"
+	for file in $(cat "${srcdir}/duplicates.txt"); do
+		rm -f $file
+	done
+
+	rm -rf "${srcdir}/pkgs-packed" "${srcdir}/pkgs-unpacked"
+}
+
+pack_subpkg() {
+	# See comment in package(), same applies here
+	mkdir -p "${subpkgdir}/usr/share/"
+	mkdir -p "${srcdir}/pkgs-packed"
+	mkdir -p "${srcdir}/pkgs-unpacked"
+	cd "${srcdir}/pkgs-packed"
+	unzip "${srcdir}/texlive-${subpkgname#texmf-dist-}-${pkgver}-src.zip" > /dev/null
+	cd "${srcdir}/pkgs-unpacked"
+	find "${srcdir}/pkgs-packed" -name '*.tar.xz' -exec tar -xf {} \;
+	find . -maxdepth 1 -name 'texmf*' -exec mv {} "${subpkgdir}/usr/share/" \;
+	find . -type d -mindepth 1 -exec mkdir -p "${subpkgdir}/usr/share/texmf-dist/"{} \;
+	find . -type f -exec mv {} "${subpkgdir}/usr/share/texmf-dist/"{} \;
+
+	# Remove files already provided by texlive* packages
+	cd "${subpkgdir}/usr/share/texmf-dist"
+	for file in $(cat "${srcdir}/duplicates.txt"); do
+		rm -f $file
+	done
+
+	rm -rf "${srcdir}/pkgs-packed" "${srcdir}/pkgs-unpacked"
 }
 
 most() {
-	pkgdesc="TeX Live texmf distribution including most of the TeX Live distribution"
-	depends="${pkgname}"
-	mkdir -p "${subpkgdir}/usr/share"
-	cd "${subpkgdir}/usr/share"
-	tar xJf "${srcdir}/${pkgname}-most-${pkgver}.tar.xz"
+	pkgdesc="TeX Live texmf distribution including most packages"
+	pkgver="2017"
+	pkgrel=0
+	depends="
+		${pkgname}
+		${pkgname}-bibtexextra
+		${pkgname}-fontsextra
+		${pkgname}-formatsextra
+		${pkgname}-games
+		${pkgname}-humanities
+		${pkgname}-latexextra
+		${pkgname}-music
+		${pkgname}-pictures
+		${pkgname}-pstricks
+		${pkgname}-publishers
+		${pkgname}-science
+		"
+	mkdir -p "${subpkgdir}"
+}
+
+lang() {
+	pkgdesc="TeX Live texmf distribution: Additional languages"
+	pkgver="2017"
+	pkgrel=0
+	depends="
+		${pkgname}
+		${pkgname}-langchinese
+		${pkgname}-langcyrillic
+		${pkgname}-langextra
+		${pkgname}-langgreek
+		${pkgname}-langjapanese
+		${pkgname}-langkorean
+		"
+	mkdir -p "${subpkgdir}"
+}
+
+full() {
+	pkgdesc="Full TeX Live texmf distribution"
+	pkgver="2017"
+	pkgrel=0
+	depends="${pkgname}-most ${pkgname}-lang"
+	mkdir -p "${subpkgdir}"
+}
+
+bibtexextra() {
+	pkgdesc="TeX Live texmf distribution: Additional BibTeX styles and bibliography DBs"
+	pkgver="${_bibtexextra}"
+	pkgrel=0
+	pack_subpkg
+}
+
+fontsextra() {
+	pkgdesc="TeX Live texmf distribution: Additional fonts"
+	pkgver="${_fontsextra}"
+	pkgrel=0
+	pack_subpkg
+}
+
+formatsextra() {
+	pkgdesc="TeX Live texmf distribution: Additional TeX formats"
+	pkgver="${_formatsextra}"
+	pkgrel=0
+	pack_subpkg
+}
+
+games() {
+	pkgdesc="TeX Live texmf distribution: Typesetting board games including chess"
+	pkgver="${_games}"
+	pkgrel=0
+	pack_subpkg
+}
+
+humanities() {
+	pkgdesc="TeX Live texmf distribution: Packages for humanities, law, linguistics, ..."
+	pkgver="${_humanities}"
+	pkgrel=0
+	pack_subpkg
+}
+
+langchinese() {
+	pkgdesc="TeX Live texmf distribution: Support for Chinese"
+	pkgver="${_langchinese}"
+	pkgrel=0
+	pack_subpkg
+}
+
+langcyrillic() {
+	pkgdesc="TeX Live texmf distribution: Support for Cyrillic languages"
+	pkgver="${_langcyrillic}"
+	pkgrel=0
+	pack_subpkg
+}
+
+langextra() {
+	pkgdesc="TeX Live texmf distribution: Additional languages"
+	pkgver="${_langextra}"
+	pkgrel=0
+	pack_subpkg
+}
+
+langgreek() {
+	pkgdesc="TeX Live texmf distribution: Support for Greek"
+	pkgver="${_langgreek}"
+	pkgrel=0
+	pack_subpkg
+}
+
+langjapanese() {
+	pkgdesc="TeX Live texmf distribution: Support for Japanese"
+	pkgver="${_langjapanese}"
+	pkgrel=0
+	pack_subpkg
+}
+
+langkorean() {
+	pkgdesc="TeX Live texmf distribution: Support for Korean"
+	pkgver="${_langkorean}"
+	pkgrel=0
+	pack_subpkg
+}
+
+latexextra() {
+	pkgdesc="TeX Live texmf distribution: Add-onpackages for LaTeX"
+	pkgver="${_latexextra}"
+	pkgrel=0
+	pack_subpkg
+}
+
+music() {
+	pkgdesc="TeX Live texmf distribution: Music typesetting packages"
+	pkgver="${_music}"
+	pkgrel=0
+	pack_subpkg
+}
+
+pictures() {
+	pkgdesc="TeX Live texmf distribution: Packages for drawing graphics"
+	pkgver="${_pictures}"
+	pkgrel=0
+	pack_subpkg
+}
+
+pstricks() {
+	pkgdesc="TeX Live texmf distribution: Additional PSTricks packages"
+	pkgver="${_pstricks}"
+	pkgrel=0
+	pack_subpkg
+}
+
+publishers() {
+	pkgdesc="TeX Live texmf distribution: LaTeX packages for specific publishers"
+	pkgver="${_publishers}"
+	pkgrel=0
+	pack_subpkg
+}
+
+science() {
+	pkgdesc="TeX Live texmf distribution: Typesetting for math and sciences"
+	pkgver="${_science}"
+	pkgrel=0
+	pack_subpkg
 }
 
-sha512sums="9d08aa5850f89bd7a1327a0a2e4aef117ea05cc71d074fc95d3cba4494414426124976703b85c5a2d58b4358d74e9f23bd97b5668c6fa872acf4daf9fb92be27  texmf-dist-2017.44907.tar.xz
-c53926b9a9c1092a35cc1d32593ab46828877ab2faf4f582910a62bda7de6f81d9db61b5c508e768c68a80fa7a0c6470b05f3114a8ff98512fe811198230a8cd  texmf-dist-most-2017.44907.tar.xz"
+sha512sums="85823ca890894ea58a118519301ed836000ace5217dcb79cd6f099d0a8e239087beb81aa85bd514a7af9ed1462973f5562d3e07e22f9625ef232330a904efecf  texlive-core-2017.45811-src.zip
+49d8ee283797038b76bdaa0a819e8707fd4b5cd73deea7e6b3e14c0363ba9f708935b13b4251dc9b8ace6b606b9e6927d8674495c22fa857b905e0fb0278e07f  texlive-bibtexextra-2017.45810-src.zip
+d65cfc8917ceef5c899b012a02df2d139bf1b772c2e932edbf121ae6e5f4b0a4e9c0c9e7118f90f394e47bf5d34bb2c51df1375c5504fb61af13cbd0ee0518fb  texlive-fontsextra-2017.45939-src.zip
+9228a2da8a4e3b28b06243acb2fb243c6d8927e1847d1421d2478263d1e654ec1a0735027eef74f2dcd41369b1b07edde84765117985f2116d3bc2585c65ebbd  texlive-formatsextra-2017.45678-src.zip
+829d7fb5330cafeb4615b6c072bfa4f31b825108884b568c57e597ecd7daede01cc3f4de09dfb763a83b4bdc345bba2b59da0f67658414c26b66a7ebee700302  texlive-games-2017.44131-src.zip
+141dad84db77e24bd4ab877f983f343bf8242fe68aa7a5fef1b7bd2653e4d77185e272585a10c2e081b046579a87a148be2c0fa346cf59f8166a3ce35dd56d3e  texlive-humanities-2017.45709-src.zip
+083d5d086b6e6c57f2be8172198fbb7b79a88c2a5c4b79a7c5ec1f3be50362453f566d0daa9d957c047f46104240dc2f79f636d31e45afdfd9785866ded8f37e  texlive-langchinese-2017.45677-src.zip
+b430c60c9a766324f32094370a98b737b87963b5365cefdade312099745b8681256de2f5b671d9f91112f6111316799d6e84fcec557ddab5f7380f40f37ec0cc  texlive-langcyrillic-2017.45692-src.zip
+c64288db823bf11b7fbbf5638fc578c244e0ea81d688715608b769b87cfe372d19ac47df43a889dce894405381bf319c2f13ad314198013a9058de3d6919a39f  texlive-langextra-2017.45591-src.zip
+fb3ab88a39e357039faeffc4311fa9d20d38746ff4c29c2aef297a806881c21423a4f3be5712955ba5c7f39c390b7906c2bbe16ba73133075c845f8a0d9d5e49  texlive-langgreek-2017.44917-src.zip
+345a7962949ac481db62d65afb783c4d32478eb8525043998ed1714645875f7f2ea292a2606a3d08935e7a9e2c0f6e3263d58f329dd6e4ad97d29b6d4d75fd33  texlive-langjapanese-2017.45699-src.zip
+cca9fba7cd3b0888949e0ed9799052be9c8957ff6784ea65f26306bce0c6812f15b94a919b3f2ecb197650a976bca2d41b52d74ddbfecdecfa4b61aed33516a0  texlive-langkorean-2017.44467-src.zip
+b2b0cbd057b864bea1ce182fdd17153f09a716aa8254ca3ea6cd9b5a426e37631c9844be75f85a0c85f4fa1f340466555359c5a0d58433e752851cecea3afa92  texlive-latexextra-2017.45733-src.zip
+3dcb9375d39615b0c983238d98cb2289f13bd31c6b42eddbfe8c10a2c5710cea33e42171e16534b19abe158c4124a6654d6306db69a0d889520ae9b5fa6c4033  texlive-music-2017.45674-src.zip
+ee73f93bacde12c742eac451923a2749448e122b347c6de0242a027d8a318063e3ee556415895bd7297411188e0ae787123e25ce384b6d193cdb9f0246421cde  texlive-pictures-2017.45569-src.zip
+8ef6902a22ba407b42128b7e4e48a91d592c58abb8324460afb8e02ea12e328f1023b6d1657530cac5be29c6610055e2a7fe4725fe9a55e402e7106bc911f8bd  texlive-pstricks-2017.45644-src.zip
+4168ce44f866b5b7eaf600978887d1431f10ce0c75a406aa11340b70f1b44bbf800a95bd3b313a74921adc8f7b1400af04645d8bdb59f64e5d973ff57c15266e  texlive-publishers-2017.45734-src.zip
+823eb038665f70431da91058ac430ecced6d0f5fda1dde6dc583e55ea35540dafa0fe45ca54ecc17dd8438e34e057e77db0edd60eae22213d07869c7ea89b84f  texlive-science-2017.45707-src.zip
+795df101ccb6708cb197df3785f033140bfe47ff041a375d469826e0d6217775a40e58e7c5a752229d40bb7b3fd36a297617137089752d24b7999d2d17d15339  duplicates.txt"
diff --git a/testing/texmf-dist/duplicates.txt b/testing/texmf-dist/duplicates.txt
new file mode 100644
index 0000000000..ecf87f3478
--- /dev/null
+++ b/testing/texmf-dist/duplicates.txt
@@ -0,0 +1,207 @@
+./dvipdfmx/dvipdfmx.cfg
+./dvips/base/texps.pro
+./dvips/base/hps.pro
+./dvips/base/crop.pro
+./dvips/base/color.pro
+./dvips/base/special.pro
+./dvips/base/texc.pro
+./dvips/base/finclude.pro
+./dvips/base/tex.pro
+./dvips/config/config.xdvi
+./dvips/gsftopk/render.ps
+./xdvi/pixmap/toolbar2.xpm
+./xdvi/pixmap/toolbar.xpm
+./xdvi/XDvi
+./web2c/mktexdir.opt
+./web2c/fmtutil.cnf
+./web2c/mktexnam.opt
+./web2c/mktexnam
+./web2c/mktexupd
+./web2c/mktex.opt
+./web2c/mktexdir
+./web2c/texmf.cnf
+./scripts/latex-git-log/latex-git-log
+./scripts/mf2pt1/mf2pt1.pl
+./scripts/urlbst/urlbst
+./scripts/petri-nets/pn2pdf
+./scripts/getmap/getmapdl.lua
+./scripts/epspdf/epspdf.tlu
+./scripts/epspdf/epspdftk.tcl
+./scripts/texdirflatten/texdirflatten
+./scripts/latex2man/latex2man
+./scripts/epstopdf/epstopdf.pl
+./scripts/oberdiek/pdfatfi.pl
+./scripts/sty2dtx/sty2dtx.pl
+./scripts/purifyeps/purifyeps
+./scripts/mathspic/mathspic.pl
+./scripts/typeoutfileinfo/typeoutfileinfo.sh
+./scripts/crossrefware/bbl2bib.pl
+./scripts/crossrefware/bibzbladd.pl
+./scripts/crossrefware/ltx2crossrefxml.pl
+./scripts/crossrefware/bibmradd.pl
+./scripts/crossrefware/bibdoiadd.pl
+./scripts/dtxgen/dtxgen
+./scripts/tex4ebook/tex4ebook
+./scripts/convbkmk/convbkmk.rb
+./scripts/accfonts/vpl2ovp
+./scripts/accfonts/vpl2vpl
+./scripts/accfonts/mkt1font
+./scripts/fontools/afm2afm
+./scripts/fontools/autoinst
+./scripts/fontools/ot2kpx
+./scripts/texfot/texfot.pl
+./scripts/lilyglyphs/lily-rebuild-pdfs.py
+./scripts/lilyglyphs/lily-glyph-commands.py
+./scripts/lilyglyphs/lily-image-commands.py
+./scripts/texosquery/texosquery-jre5.sh
+./scripts/texosquery/texosquery-jre8.sh
+./scripts/texosquery/texosquery.sh
+./scripts/checkcites/checkcites.lua
+./scripts/ulqda/ulqda.pl
+./scripts/pst2pdf/pst2pdf.pl
+./scripts/texdef/texdef.pl
+./scripts/kotex-utils/komkindex.pl
+./scripts/kotex-utils/ttf2kotexfont.pl
+./scripts/kotex-utils/jamo-normalize.pl
+./scripts/ctanupload/ctanupload.pl
+./scripts/ltxfileinfo/ltxfileinfo
+./scripts/fragmaster/fragmaster.pl
+./scripts/dosepsbin/dosepsbin.pl
+./scripts/texlive/kpsewhere.sh
+./scripts/texlive/allcm.sh
+./scripts/texlive/rumakeindex.sh
+./scripts/texlive/dvired.sh
+./scripts/texlive/texlinks.sh
+./scripts/texlive/texconfig-dialog.sh
+./scripts/texlive/dvi2fax.sh
+./scripts/texlive/e2pall.pl
+./scripts/texlive/rungs.tlu
+./scripts/texlive/updmap.pl
+./scripts/texlive/pslatex.sh
+./scripts/texlive/fmtutil-sys.sh
+./scripts/texlive/tlmgr.pl
+./scripts/texlive/rubibtex.sh
+./scripts/texlive/ps2frag.sh
+./scripts/texlive/kpsetool.sh
+./scripts/texlive/updmap-user.sh
+./scripts/texlive/fmtutil.pl
+./scripts/texlive/updmap-sys.sh
+./scripts/texlive/texconfig-sys.sh
+./scripts/texlive/texconfig.sh
+./scripts/texlive/allneeded.sh
+./scripts/texlive/fontinst.sh
+./scripts/texlive/fmtutil-user.sh
+./scripts/texlive/TeXLive/TLConfig.pm
+./scripts/texlive/TeXLive/TLUtils.pm
+./scripts/checklistings/checklistings.sh
+./scripts/glossaries/makeglossaries-lite.lua
+./scripts/glossaries/makeglossaries
+./scripts/ltximg/ltximg.pl
+./scripts/ptex2pdf/ptex2pdf.lua
+./scripts/bundledoc/bundledoc
+./scripts/bundledoc/arlatex
+./scripts/make4ht/make4ht
+./scripts/simpdftex/simpdftex
+./scripts/latex-papersize/latex-papersize.py
+./scripts/ctanify/ctanify
+./scripts/a2ping/a2ping.pl
+./scripts/texcount/texcount.pl
+./scripts/ptex-fontmaps/kanji-config-updmap-sys.sh
+./scripts/ptex-fontmaps/kanji-fontmap-creator.pl
+./scripts/ptex-fontmaps/kanji-config-updmap.pl
+./scripts/ptex-fontmaps/kanji-config-updmap-user.sh
+./scripts/match_parens/match_parens
+./scripts/pdflatexpicscale/pdflatexpicscale.pl
+./scripts/luaotfload/luaotfload-tool.lua
+./scripts/yplan/yplan
+./scripts/latexfileversion/latexfileversion
+./scripts/arara/arara.sh
+./scripts/latex2nemeth/latex2nemeth
+./scripts/pmxchords/pmxchords.lua
+./scripts/splitindex/splitindex.pl
+./scripts/texdoc/texdoc.tlu
+./scripts/exceltex/exceltex
+./scripts/adhocfilelist/adhocfilelist.sh
+./scripts/pythontex/depythontex.py
+./scripts/pythontex/pythontex.py
+./scripts/perltex/perltex.pl
+./scripts/mkjobtexmf/mkjobtexmf.pl
+./scripts/m-tx/m-tx.lua
+./scripts/texloganalyser/texloganalyser
+./scripts/latexmk/latexmk.pl
+./scripts/texdiff/texdiff
+./scripts/multibibliography/multibibliography.pl
+./scripts/context/perl/mptopdf.pl
+./scripts/context/stubs/unix/mtxrun
+./scripts/context/stubs/unix/texmfstart
+./scripts/context/stubs/unix/mtxrunjit
+./scripts/context/stubs/unix/luatools
+./scripts/context/stubs/unix/contextjit
+./scripts/context/stubs/unix/context
+./scripts/context/stubs/unix/texexec
+./scripts/authorindex/authorindex
+./scripts/pdfjam/pdfjam-pocketmod
+./scripts/pdfjam/pdfnup
+./scripts/pdfjam/pdfbook
+./scripts/pdfjam/pdf180
+./scripts/pdfjam/pdfjam-slides6up
+./scripts/pdfjam/pdfflip
+./scripts/pdfjam/pdfjam
+./scripts/pdfjam/pdf90
+./scripts/pdfjam/pdfjoin
+./scripts/pdfjam/pdf270
+./scripts/pdfjam/pdfjam-slides3up
+./scripts/pdfjam/pdfpun
+./scripts/fig4latex/fig4latex
+./scripts/svn-multi/svn-multi.pl
+./scripts/pst-pdf/ps4pdf
+./scripts/latexpand/latexpand
+./scripts/diadia/diadia.lua
+./scripts/pdfbook2/pdfbook2
+./scripts/latexdiff/latexdiff-vc.pl
+./scripts/latexdiff/latexdiff.pl
+./scripts/latexdiff/latexrevise.pl
+./scripts/cjk-gs-integrate/cjk-gs-integrate.pl
+./scripts/bibexport/bibexport.sh
+./scripts/pedigree-perl/pedigree.pl
+./scripts/mkgrkindex/mkgrkindex
+./scripts/pygmentex/pygmentex.py
+./scripts/mkpic/mkpic
+./scripts/pax/pdfannotextractor.pl
+./scripts/listings-ext/listings-ext.sh
+./scripts/ebong/ebong.py
+./scripts/rubik/rubikrotation.pl
+./scripts/pkfix-helper/pkfix-helper
+./scripts/texdoctk/texdoctk.pl
+./scripts/pdfcrop/pdfcrop.pl
+./scripts/dviasm/dviasm.py
+./scripts/makedtx/makedtx.pl
+./scripts/listbib/listbib
+./scripts/pkfix/pkfix.pl
+./scripts/pfarrei/pfarrei.tlu
+./scripts/pfarrei/a5toa4.tlu
+./scripts/pdfxup/pdfxup
+./scripts/findhyph/findhyph
+./scripts/de-macro/de-macro
+./scripts/lua2dox/lua2dox_filter
+./scripts/texliveonfly/texliveonfly.py
+./scripts/psutils/extractres.pl
+./scripts/psutils/psjoin.pl
+./scripts/psutils/includeres.pl
+./scripts/installfont/installfont-tl
+./scripts/cachepic/cachepic.tlu
+./scripts/lwarp/lwarpmk.lua
+./scripts/musixtex/musixflx.lua
+./scripts/musixtex/musixtex.lua
+./scripts/ps2eps/ps2eps.pl
+./scripts/thumbpdf/thumbpdf.pl
+./scripts/vpe/vpe.pl
+./scripts/srcredact/srcredact.pl
+./scripts/latexindent/latexindent.pl
+./fonts/map/dvipdfmx/cid-x.map
+./fonts/map/glyphlist/glyphlist.txt
+./fonts/map/glyphlist/pdfglyphlist.txt
+./fonts/cmap/dvipdfmx/EUC-UCS2
+./texconfig/tcfmgr.map
+./texconfig/tcfmgr
+./psutils/paper.cfg
diff --git a/testing/texmf-dist/texmf-dist.trigger b/testing/texmf-dist/texmf-dist.trigger
deleted file mode 100644
index d549354929..0000000000
--- a/testing/texmf-dist/texmf-dist.trigger
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/sh
-texhash
-fmtutil-sys --all
-exit 0
-- 
2.15.0

---
Unsubscribe:  [email-masked]
Help:         [email-masked]
---

---

From: Marian Buschsieweke <[email-masked]>
Date: Fri, 15 Dec 2017 16:36:24 +0100

- Added trigger to recreate *everything* on changes in /usr/share/texmf-dist.
   (This will skip formats/fonts/... not installed and report a warning/error
   on every missing font/format/... Nontheless, this trigger brings texlive
   in a useable state
 - Added dependency on texmf-dist, so a fully working texlive will be obtained
 - Added package providing tools required for a plain LaTeX workflow (not
   using pdflatex/xetex/luatex/...), like dvips. Some conferences and publishers
   still require old plain LaTeX workflow :-(
---
 testing/texlive/APKBUILD        | 28 +++++++++++++++++++---------
 testing/texlive/texlive.trigger |  4 ++++
 2 files changed, 23 insertions(+), 9 deletions(-)
 create mode 100644 testing/texlive/texlive.trigger

diff --git a/testing/texlive/APKBUILD b/testing/texlive/APKBUILD
index cb5f837f3e..5ffecee249 100644
--- a/testing/texlive/APKBUILD
+++ b/testing/texlive/APKBUILD
@@ -1,5 +1,5 @@
 # Contributor: Isaac Dunham <[email-masked]>
-# Maintainer:
+# Maintainer: Marian Buschsieweke <[email-masked]>
 pkgname=texlive
 pkgver=20170524
 pkgrel=2
@@ -7,15 +7,16 @@ pkgdesc="Comprehensive TeX document production system"
 url="http://tug.org/texlive/"
 arch="all"
 license="GPL"
-depends="perl"
+depends="perl texmf-dist"
 depends_dev=""
 makedepends="freetype-dev libpng-dev poppler-dev icu-dev harfbuzz-dev
 	cairo-dev pixman-dev zziplib-dev libpaper-dev graphite2-dev
 	libxmu-dev fontconfig-dev libxaw-dev motif-dev"
 install=""
-subpackages="$pkgname-dev $pkgname-doc xdvik:xdvi $pkgname-xetex:xetex $pkgname-luatex:lua $pkgname-full:meta"
+subpackages="$pkgname-dev $pkgname-doc xdvik:xdvi $pkgname-xetex:xetex $pkgname-luatex:lua $pkgname-plaintools:plaintools $pkgname-full:meta"
 source="ftp://ftp.tug.org/texlive/historic/${pkgver:0:4}/texlive-$pkgver-source.tar.xz"
 builddir="$srcdir"/texlive-${pkgver}-source
+triggers="$pkgname.trigger=/usr/share/texmf-dist"
 
 _luatex="dvilualatex dviluatex lualollipop"
 _pdftex="amstex cslatex csplain eplain etex jadetex latex lollipop mex
@@ -55,17 +56,17 @@ build() {
 		--disable-detex \
 		--disable-dialog \
 		--disable-dvi2tty \
-		--disable-dvipng \
-		--disable-dvipsk \
+		--enable-dvipng \
+		--enable-dvipsk \
 		--disable-dvisvgm \
 		--disable-largefile \
 		--disable-lcdf-typetools \
 		--disable-multiplatform \
 		--disable-native-texlive-build \
 		--disable-pdfopen \
-		--disable-ps2eps \
+		--enable-ps2eps \
 		--disable-ps2pkm \
-		--disable-psutils \
+		--enable-psutils \
 		--disable-t1utils \
 		--disable-tex4htk \
 		--disable-ttf2pk2 \
@@ -95,7 +96,6 @@ package() {
 	cd "$builddir"/build
 
 	make DESTDIR="$pkgdir" install
-
 	cp -rf ../texk/tests/TeXLive \
 		"$pkgdir"/usr/share/texmf-dist/scripts/texlive
 
@@ -126,7 +126,7 @@ xetex() {
 
 meta() {
 	pkgdesc="A complete TeX distribution"
-	depends="$pkgname $pkgname-doc $pkgname-luatex $pkgname-xetex xdvik"
+	depends="$pkgname $pkgname-doc $pkgname-luatex $pkgname-xetex xdvik $pkgname-plaintools texmf-dist-full"
 
 	mkdir -p "$subpkgdir"
 }
@@ -181,4 +181,14 @@ xdvi() {
 	mv "$pkgdir"/usr/share/texmf-dist/xdvi usr/share/texmf-dist/
 }
 
+plaintools() {
+	pkgdesc="Additional tools useful for a plain LaTeX (!= pdflatex) workflow"
+	depends="$pkgname"
+
+	install -d -m 0755 "$subpkgdir"/usr/bin
+	for tool in afm2tfm bbox dvigif dvipng dvips epsffit extractres includeres ps2eps psbook psjoin psnup psresize psselect pstops; do
+		mv "${pkgdir}/usr/bin/${tool}" "${subpkgdir}/usr/bin/"
+	done
+}
+
 sha512sums="18c18940992ab94ce22e22ccd4ad798253ea14ac2ab296a10ea5e9a8da9f33989f2e2641b42b564d1d5fb53bd371da3e68726b676d706b469016ad146cd19daa  texlive-20170524-source.tar.xz"
diff --git a/testing/texlive/texlive.trigger b/testing/texlive/texlive.trigger
new file mode 100644
index 0000000000..d549354929
--- /dev/null
+++ b/testing/texlive/texlive.trigger
@@ -0,0 +1,4 @@
+#!/bin/sh
+texhash
+fmtutil-sys --all
+exit 0
-- 
2.15.0

---