Skip to content
Snippets Groups Projects

community/texmf-dist: allow installing duplicate man pages

1 file
+ 9
58
Compare changes
  • Side-by-side
  • Inline
  • This tries to be a maintainable solution for the issue that both the
    source repo for the texlive package and the sources for texmf-dist
    contain man pages for the applications provided by the texlive
    package.
    
    It adds a postfix to the man pages of texmf-dist, so that they can
    be installed at the same time. This wastes storage space for the
    duplicates. Especially since the man pages provided by `texlive-doc`
    should be considered the single source of truth for the man pages, it
    is suboptimal to have the duplicates. However, is absence of any
    obvious clean way to remove the duplicates, this may be a sensible
    alternative.
@@ -3,7 +3,7 @@
pkgname=texmf-dist
pkgver=2024.0
_release=20240312
pkgrel=3
pkgrel=4
pkgdesc="TeX Live texmf core distribution"
url="https://tug.org/texlive/"
# texlive
@@ -180,11 +180,11 @@ _pack_collection() {
;;
texmf-dist/doc/man/*.1)
mkdir -p "$docdir/usr/share/man/man1"
cp "$builddir/$path" "$docdir/usr/share/man/man1/"
cp "$builddir/$path" "$docdir/usr/share/man/man1/${path##*/}texmf-dist"
;;
texmf-dist/doc/man/*.5)
mkdir -p "$docdir/usr/share/man/man5"
cp "$builddir/$path" "$docdir/usr/share/man/man5/"
cp "$builddir/$path" "$docdir/usr/share/man/man5/${path##*/}texmf-dist"
;;
*)
mkdir -p "$docdir/usr/share/$(dirname "$path")"
@@ -276,60 +276,6 @@ package() {
mkdir -p "$pkgdir"/usr/share/tlpkg
cp -r "$srcdir/install-tl-$_release/tlpkg/TeXLive" \
"$pkgdir"/usr/share/tlpkg/
# Remove man pages already provided by texlive-doc.
local duplicates="
man1/afm2tfm.1
man1/bibtex.1
man1/dviluatex.1
man1/dvipdfm.1
man1/dvipdfmx.1
man1/dvipdft.1
man1/dvips.1
man1/ebb.1
man1/extractbb.1
man1/fmtutil-sys.1
man1/fmtutil.1
man1/gftodvi.1
man1/gftopk.1
man1/gftype.1
man1/inimf.1
man1/initex.1
man1/kpseaccess.1
man1/kpsereadlink.1
man1/kpsestat.1
man1/kpsewhich.1
man1/luahbtex.1
man1/luatex.1
man1/makeindex.1
man1/mf-nowin.1
man1/mf.1
man1/mft.1
man1/mkindex.1
man1/mktexfmt.1
man1/mktexlsr.1
man1/mktexmf.1
man1/mktexpk.1
man1/mktextfm.1
man1/pdfetex.1
man1/pdftex.1
man1/pktogf.1
man1/pktype.1
man1/tex.1
man1/texhash.1
man1/texlua.1
man1/texluac.1
man1/updmap-sys.1
man1/updmap.1
man1/xdvi.1
man1/xdvipdfmx.1
man5/fmtutil.cnf.5
man5/updmap.cfg.5
"
for duplicate in $duplicates; do
rm "${pkgdir%/}-doc/usr/share/man/$duplicate"
done
}
_subpkg() {
@@ -341,11 +287,16 @@ _subpkg() {
}
_subpkgdoc() {
local base
base="${subpkgname%-doc}"
local collection
collection="${base#texmf-dist-}"
# We cannot use default_doc, as this does not work for subpackges
pkgdesc="texmf-dist: $(_tlpdb_get_values "collection-$collection" shortdesc) (documentation)"
install_if="docs ${subpkgname%-doc}=$pkgver-r$pkgrel"
# compress man pages, if the doc packages contains some
# compress man pages, if the doc packages contains some uncompressed ones
if [ -d "$subpkgdir"/usr/share/man ]; then
find "$subpkgdir"/usr/share/man -type f ! -name "*.gz" \
-exec gzip -9 {} \;
Loading