123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238 |
- # Maintainer (archarm): Kevin Mihelich <kevin@archlinuxarm.org>
- # Maintainer (arch): Antonio Rojas <arojas@archlinux.org>
- # Maintainer (arch): Caleb Maclennan <caleb@alerque.com>
- # Contributor: Rémy Oudompheng <remy@archlinux.org>
- # Contributor: francois <francois.archlinux.org>
- # Contributor: Omar Vega Ramos <ovruni@gnu.org.pe>
- # Contributor: André Silva <emulatorman@hyperbola.info>
- # Contributor: Michał Masłowski <mtjm@mtjm.eu>
- # Contributor: Isaac David <isacdaavid(at)isacdaavid!info>
- # Contributor: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>
- # Contrbutor: bill-auger <bill-auger@programmer.net>
- # Contributor: David P. <megver83@parabola.nu>
- # parabola changes and rationale:
- # technical:
- # - re-brand for parabola (due to changes in texlive-{core,fontsextra,latexextra})
- # - pin to strongly-coupled dependency versions
- # - disable texindy/xindy on armv7h
- # - build from upstream sourve-ball, rather than VCS
- # archarm changes:
- # -fPIC for v6 and v7
- # --disable-xindy, remove xindy stuff, segfaults with clisp
- # --disable-cxx-runtime-hack
- # drop clisp and ffcall makedepends
- pkgname=(texlive-bin libsynctex)
- pkgver=2024.2
- pkgrel=2
- pkgrel+=.parabola1
- license=(GPL-2.0-or-later)
- arch=(x86_64)
- arch+=(armv7h i686)
- makedepends=(bash
- cairo
- clisp
- ffcall
- fontconfig
- freetype2
- gcc-libs
- gd
- git
- glibc
- gmp
- graphite
- harfbuzz
- icu
- libjpeg
- libpaper
- libpng
- libsigsegv
- libunistring
- libx11
- libxaw
- libxcrypt
- libxmu
- libxpm
- libxt
- mpfr
- ncurses
- perl
- pixman
- potrace
- readline
- subversion
- t1lib
- zlib
- zziplib)
- url='https://tug.org/texlive/'
- _rev=svn70897 # tags/texlive-2024.2
- source=(texlive-bin-${_rev}.tar.gz::https://github.com/TeX-Live/texlive-source/archive/refs/tags/${_rev}.tar.gz # we use source-ball
- ptex-debug-print.patch)
- sha256sums=('a8e1f537febe4b4a5f98ee3e7fd4b6007421e66951ad0e27b8624e6ef6ce3a53'
- 'aa838f09003c62c2efb5770a8de66f99b409df049fbd65098d80fd1957d06c50')
- # Parabola: remove git, remove clisp and ffcall on armv7h
- unset makedepends[8]
- if [[ "$CARCH" == armv7h ]]; then
- unset makedepends[2] makedepends[3]
- fi
- prepare() {
- cd texlive-source-$_rev
- # bibtex-x needs kpathsea flags
- sed -i '/AC_SEARCH_LIBS/a KPSE_KPATHSEA_FLAGS' texk/bibtex-x/configure.ac
- (cd texk/bibtex-x && autoreconf)
- # t4ht expects to be un /usr/share/texmf/bin/t4ht (FS#27251)
- sed -i s/SELFAUTOPARENT/TEXMFROOT/ texk/tex4htk/t4ht.c
- # remove spurious ptex "guessed encoding" print
- patch -p1 -i ../ptex-debug-print.patch
- }
- build() {
- cd texlive-source-$_rev
- # HACK: Parabola: Define an array to set CARCH-specific arguments
- local carch_args
- case "$CARCH" in
- "armv7h") carch_args=(--disable-xindy --disable-cxx-runtime-hack) ;;
- *) carch_args=(--enable-xindy)
- esac
- mkdir -p build
- cd build
- CFLAGS+=" -Wno-incompatible-pointer-types" \
- ax_cv_c_float_words_bigendian=no \
- ../configure --prefix=/usr -C \
- --sysconfdir=/etc \
- --datarootdir=/usr/share \
- --datadir=/usr/share \
- --mandir=/usr/share/man \
- --disable-native-texlive-build \
- --with-banner-add="/Parabola GNU/Linux-libre" \
- --disable-multiplatform \
- --disable-dialog \
- --disable-psutils \
- --disable-t1utils \
- --disable-bibtexu \
- --disable-dvisvgm \
- --disable-xz \
- --enable-shared \
- --disable-static \
- --with-system-zlib \
- --with-system-zziplib \
- --with-system-pnglib \
- --with-system-ncurses \
- --with-system-t1lib \
- --with-system-gd \
- --with-system-freetype2 \
- --with-system-pixman \
- --with-system-cairo \
- --with-system-harfbuzz \
- --with-system-graphite \
- --with-system-icu \
- --with-system-gmp \
- --with-system-mpfr \
- --with-system-potrace \
- --with-system-libpaper \
- --with-freetype2-libdir=/usr/lib \
- --with-freetype2-include=/usr/include/freetype2 \
- --with-xdvi-x-toolkit=xaw \
- --disable-dump-share \
- --with-clisp-runtime=default \
- --disable-xindy-rules \
- --disable-xindy-docs "${carch_args[@]}"
- # prevent excessive overlinking due to libtool
- sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
- make
- }
- package_libsynctex() {
- pkgdesc='Library for synchronization between TeX files and resulting file'
- depends=(glibc zlib)
- provides=(libsynctex.so)
- cd texlive-source-$_rev/build
- make -C texk/web2c DESTDIR="$pkgdir" \
- install-data-am install-libLTLIBRARIES
- # remove docs included in texlive-doc
- rm -r "$pkgdir"/usr/share/man
- }
- package_texlive-bin() {
- pkgdesc='TeX Live binaries'
- depends=(bash
- cairo libcairo.so
- ffcall # libffcall.so
- fontconfig libfontconfig.so
- freetype2 libfreetype.so
- gcc-libs # libgcc_s.so libstdc++.so
- gd # libgd.so
- glibc # ld-linux-x86-64.so libc.so libm.so
- gmp
- graphite libgraphite2.so
- harfbuzz libharfbuzz.so
- icu libicui18n.so libicuuc.so
- libpaper # libpaper.so
- libpng libpng16.so
- libsigsegv # libsigsegv.so
- libsynctex libsynctex.so
- libunistring libunistring.so
- libx11 # libX11.so
- libxaw # libXaw.so
- libxcrypt libcrypt.so
- libxmu # libXmu.so
- libxpm # libXpm.so
- libxt # libXt.so
- mpfr libmpfr.so
- ncurses libncursesw.so
- perl
- pixman libpixman-1.so
- potrace # libpotrace.so
- readline libreadline.so
- zlib libz.so
- zziplib) # libzzip-0.so
- provides=(lcdf-typetools
- libptexenc.so
- libtexlua53.so
- libtexluajit.so
- kpathsea
- xindy
- )
- optdepends=('psutils: to manipulate the output of dvips')
- # Parabola: remove ffcall and xindy on armv7h
- if [[ "$CARCH" == armv7h ]]; then
- unset depends[3]
- unset provides[5]
- fi
- cd texlive-source-$_rev
- # fixes for xindy
- find utils/xindy -name Makefile -exec sed -i -e "s|^prefix =.\+$|prefix = $pkgdir/usr|" -e "s|^mandir =.\+$|mandir = \${prefix}/share/man|" -e "s|^datadir =.\+$|datadir = \${datarootdir}/texmf|" -e "s|^docdir =.\+$|docdir = \${datadir}/doc/xindy|" '{}' \;
- cd build
- make DESTDIR="$pkgdir" texmf="$pkgdir"/usr/share/texmf install
- LD_PRELOAD="$pkgdir"/usr/lib/libkpathsea.so.6 \
- make DESTDIR="$pkgdir" texlinks
- # remove stuff included in texlive-texmf
- rm -r "$pkgdir"/usr/share/texmf-dist
- # remove docs included in texlive-doc
- rm -r "$pkgdir"/usr/share/{info,man}
- # remove links to scripts
- for _link in $(ls "$pkgdir"/usr/bin); do
- [[ $(readlink -m "$pkgdir"/usr/bin/$_link) == */scripts/* ]] && _rmlinks+="$pkgdir/usr/bin/$_link "
- done
- rm $_rmlinks
- # remove libsynctex
- rm "$pkgdir"/usr/include/synctex/*
- rm "$pkgdir"/usr/lib/libsynctex.*
- rm "$pkgdir"/usr/lib/pkgconfig/synctex.pc
- }
|