b8d25e296642b5ee39d32c864962c47e6c8ff821
[termux-packages] / packages / texlive / build.sh
1 TERMUX_PKG_HOMEPAGE=https://www.tug.org/texlive/
2 TERMUX_PKG_DESCRIPTION="TeX Live is a distribution of the TeX typesetting system."
3 TERMUX_PKG_VERSION=20160523
4 TERMUX_PKG_SRCURL=ftp://tug.org/historic/systems/texlive/${TERMUX_PKG_VERSION:0:4}/texlive-${TERMUX_PKG_VERSION}b-source.tar.xz
5 TERMUX_PKG_SHA256="a8b32ca47f0a403661a09e202f4567a995beb718c18d8f81ca6d76daa1da21ed"
6 TERMUX_PKG_DEPENDS="libpng,libgd,freetype,poppler,libluajit,libicu"
7 TERMUX_PKG_FOLDERNAME=texlive-${TERMUX_PKG_VERSION}-source
8 TERMUX_PKG_EXTRA_CONFIGURE_ARGS="\
9 AR=ar \
10 RANLIB=ranlib \
11 BUILDAR=ar \
12 BUILDRANLIB=ranlib \
13 --prefix=$TERMUX_PREFIX/local/texlive/${TERMUX_PKG_VERSION:0:4} \
14 --bindir=$TERMUX_PREFIX/local/texlive/${TERMUX_PKG_VERSION:0:4}/bin/pkg \
15 --libdir=$TERMUX_PREFIX/lib \
16 --build=$TERMUX_BUILD_TUPLE \
17 --disable-native-texlive-build \
18 --without-x \
19 --disable-multiplatform \
20 --disable-dialog \
21 --disable-psutils \
22 --disable-t1utils \
23 --disable-bibtexu \
24 --disable-xz \
25 --without-texinfo \
26 --without-xdvipdfmx \
27 --without-texi2html \
28 --with-system-icu \
29 --with-system-poppler \
30 --with-system-gd \
31 --with-system-luajit \
32 --with-system-xpdf \
33 --enable-luatex \
34 --enable-ttfdump=no \
35 --enable-makeindexk=no --enable-makejvf=no --enable-mendexk=no --enable-musixtnt=no --enable-ps2pk=no \
36 --enable-seetexk=no --enable-gregorio=no \
37 --with-banner-add=/termux \
38 "
39
40 termux_step_post_extract_package () {
41 rm -r $TERMUX_PKG_SRCDIR/utils/pmx
42 }
43
44 termux_step_post_make_install () {
45 cp $TERMUX_PKG_BUILDER_DIR/termux-install-tl $TERMUX_PREFIX/bin
46 chmod +x $TERMUX_PREFIX/bin/termux-install-tl
47 sed -E -i "s@/bin/sh@$PREFIX/bin/sh@" "$TERMUX_PREFIX/local/texlive/${TERMUX_PKG_VERSION:0:4}/bin/pkg/tlmgr"
48 }
49
50 termux_step_create_debscripts () {
51 echo 'echo "retrieving texlive..."' > postinst
52 echo "termux-install-tl" >> postinst
53 echo "exit 0" >> postinst
54 chmod 0755 postinst
55 }