PKGBUILD 8.28 KB
Newer Older
1
# Contributions from Arch: https://projects.archlinux.org/svntogit/packages.git/tree/trunk?h=packages/texlive-bin
2

Ram-Z's avatar
Ram-Z committed
3
pkgname=('texlive-bin' 'libsynctex')
4
pkgver=2015.37497
Ram-Z's avatar
Ram-Z committed
5
pkgrel=6
6
_biber_ver=2.2
Manuel Tortosa's avatar
Manuel Tortosa committed
7
license=('GPL')
8
arch=('x86_64')
Ram-Z's avatar
Ram-Z committed
9 10 11 12 13
makedepends=('cairo' 'pixman' 'graphite' 't1lib' 'gd' 'poppler'
             'libsigsegv' 'zziplib' 'libpng' 'libjpeg' 'freetype2'
             'icu' 'harfbuzz' 'harfbuzz-icu' 'gmp' 'mpfr' 'potrace' 'libpaper'
             'perl' 'clisp' 'ffcall')
url='http://tug.org/texlive/'
14 15
source=("http://mirrors.kernel.org/archlinux/other/texlive/texlive-bin-source-${pkgver}.tar.xz"
        "http://downloads.sourceforge.net/project/biblatex-biber/biblatex-biber/${_biber_ver}/binaries/Linux/biber-linux_x86_64.tar.gz")
Samir Benmendil's avatar
Samir Benmendil committed
16
noextract=(biber-linux_x86_64.tar.gz)
17 18
md5sums=('20be644511704910151560a4d99f6995'
         '85e762642861eb6a75798cebe5d839f3')
19

Samir Benmendil's avatar
Samir Benmendil committed
20 21
prepare() {
  cd source
Samir Benmendil's avatar
Samir Benmendil committed
22
  true
Samir Benmendil's avatar
Samir Benmendil committed
23
}
Samir's avatar
Samir committed
24

Samir Benmendil's avatar
Samir Benmendil committed
25 26 27 28
build() {
  export CFLAGS="${CFLAGS} -fPIC"
  export CXXFLAGS="${CXXFLAGS} -fPIC"
  tar xf biber-linux_x86_64.tar.gz
Manuel Tortosa's avatar
Manuel Tortosa committed
29

Samir Benmendil's avatar
Samir Benmendil committed
30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47
  # t4ht expects to be un /usr/share/texmf/bin/t4ht
  sed -i s/SELFAUTOPARENT/TEXMFROOT/ source/texk/tex4htk/t4ht.c
  #############################################################
  ### configure
  cd source
  ## prevent compiling Xdvi with libXp
  sed -i~ 's|-lXp ||' texk/xdvik/configure
  test ! -d Work && mkdir Work
  cd Work
  echo "--> Initial configuration..."
  # we use temporary prefix to avoid messing the existing
  # $pkgdir/usr/share/texmf tree
  ../configure --prefix=/usr -C \
    --sysconfdir=/etc \
    --datarootdir=/usr/share \
    --datadir=/usr/share \
    --mandir=/usr/share/man \
    --disable-native-texlive-build \
48
    --with-banner-add="/Chakra" \
Samir Benmendil's avatar
Samir Benmendil committed
49 50 51 52 53 54
    --disable-multiplatform \
    --disable-dialog \
    --disable-psutils \
    --disable-t1utils \
    --disable-bibtexu \
    --disable-xz \
Samir Benmendil's avatar
Samir Benmendil committed
55 56
    --enable-shared \
    --disable-static \
Samir Benmendil's avatar
Samir Benmendil committed
57 58 59 60 61 62 63 64 65 66 67 68 69 70
    --with-system-zlib \
    --with-system-zziplib \
    --with-system-pnglib \
    --with-system-ncurses \
    --with-system-t1lib \
    --with-system-gd \
    --with-system-poppler \
    --with-system-xpdf \
    --with-system-freetype2 \
    --with-system-pixman \
    --with-system-cairo \
    --with-system-harfbuzz \
    --with-system-graphite \
    --with-system-icu \
71
    --with-system-gmp \
72 73
    --with-system-mpfr \
    --with-system-libpaper \
Samir Benmendil's avatar
Samir Benmendil committed
74 75 76 77 78 79 80 81 82 83 84 85 86 87
    --with-freetype2-libdir=/usr/lib \
    --with-freetype2-include=/usr/include/freetype2 \
    --with-xdvi-x-toolkit=xaw \
    --disable-dump-share \
    --disable-aleph \
    --enable-luatex \
    --with-clisp-runtime=default \
    --enable-xindy --disable-xindy-rules --disable-xindy-docs
  #############################################################
  ### make
  echo "-------------------------------------------------------"
  echo "--> Building the whole beast ..."
  echo "-------------------------------------------------------"
  make
philm's avatar
philm committed
88 89
}

Ram-Z's avatar
Ram-Z committed
90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112
package_libsynctex() {
  pkgdesc='Library for synchronization between TeX files and resulting file'
  depends=('glibc' 'zlib')

  install -d "$pkgdir"/usr/lib

  for lib in "$srcdir"/source/Work/texk/web2c/.libs/libsynctex.so*; do
    cp -P $lib "$pkgdir"/usr/lib/
  done
}

package_texlive-bin() {
  pkgdesc="TeX Live binaries"
  makedepends=('cairo' 'pixman' 'graphite' 't1lib' 'gd' 'poppler'
              'libsigsegv' 'zziplib' 'libpng' 'libjpeg' 'freetype2'
              'icu' 'harfbuzz' 'harfbuzz-icu' 'gmp' 'mpfr' 'potrace' 'libpaper'
              'libsynctex')
  provides=('lcdf-typetools' 'kpathsea' 'xindy' 'pdfjam')
  conflicts=('pdfjam')
  optdepends=('ed: for texconfig')
  install="texlive.install"
  options=('!strip')

Samir Benmendil's avatar
Samir Benmendil committed
113 114 115 116 117 118 119 120 121 122
  cd "$srcdir"
  #############################################################
  ### install
  cd source
  # 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|" '{}' \;
Manuel Tortosa's avatar
Manuel Tortosa committed
123

Samir Benmendil's avatar
Samir Benmendil committed
124 125 126 127 128 129
  echo "-------------------------------------------------------"
  echo "--> Proceeding with make install ..."
  echo "-------------------------------------------------------"
  cd Work
  make DESTDIR="${pkgdir}" texmf="$pkgdir"/usr/share/texmf install
  rm -rf "${pkgdir}"/usr/{texmf,share/texmf-dist}
philm's avatar
philm committed
130

Samir Benmendil's avatar
Samir Benmendil committed
131
  ## install biber
132
  install -m755 "${srcdir}"/biber "${pkgdir}/usr/bin/biber"
Manuel Tortosa's avatar
Manuel Tortosa committed
133

Samir Benmendil's avatar
Samir Benmendil committed
134 135 136 137 138 139 140
  ## symlink engines by hand. texlinks has moved to texlive-core...
  mkdir -p ${pkgdir}/usr/bin
  ln -s eptex ${pkgdir}/usr/bin/platex
  ln -s euptex ${pkgdir}/usr/bin/uplatex
  ln -s luatex ${pkgdir}/usr/bin/dvilualatex
  ln -s luatex ${pkgdir}/usr/bin/dviluatex
  ln -s luatex ${pkgdir}/usr/bin/lualatex
Samir Benmendil's avatar
Samir Benmendil committed
141
  ln -s luatex ${pkgdir}/usr/bin/lualollipop
Samir Benmendil's avatar
Samir Benmendil committed
142 143 144 145 146 147 148 149
  ln -s luatex ${pkgdir}/usr/bin/pdfcsplain
  ln -s pdftex ${pkgdir}/usr/bin/amstex
  ln -s pdftex ${pkgdir}/usr/bin/cslatex
  ln -s pdftex ${pkgdir}/usr/bin/csplain
  ln -s pdftex ${pkgdir}/usr/bin/eplain
  ln -s pdftex ${pkgdir}/usr/bin/etex
  ln -s pdftex ${pkgdir}/usr/bin/jadetex
  ln -s pdftex ${pkgdir}/usr/bin/latex
Samir Benmendil's avatar
Samir Benmendil committed
150
  ln -s pdftex ${pkgdir}/usr/bin/lollipop
Samir Benmendil's avatar
Samir Benmendil committed
151 152 153 154 155 156 157 158 159 160 161 162
  ln -s pdftex ${pkgdir}/usr/bin/mex
  ln -s pdftex ${pkgdir}/usr/bin/mllatex
  ln -s pdftex ${pkgdir}/usr/bin/mltex
  ln -s pdftex ${pkgdir}/usr/bin/pdfetex
  ln -s pdftex ${pkgdir}/usr/bin/pdfjadetex
  ln -s pdftex ${pkgdir}/usr/bin/pdflatex
  ln -s pdftex ${pkgdir}/usr/bin/pdfmex
  ln -s pdftex ${pkgdir}/usr/bin/pdfxmltex
  ln -s pdftex ${pkgdir}/usr/bin/texsis
  ln -s pdftex ${pkgdir}/usr/bin/utf8mex
  ln -s pdftex ${pkgdir}/usr/bin/xmltex
  ln -s xetex ${pkgdir}/usr/bin/xelatex
Samir Benmendil's avatar
Samir Benmendil committed
163
  ln -s xetex ${pkgdir}/usr/bin/xelollipop
Samir's avatar
Samir committed
164

Samir Benmendil's avatar
Samir Benmendil committed
165 166 167
  #############################################################
  # remove dangling symlinks
  _bibtexextra_scripts="
168
bibexport
169 170
bibdoiadd
bibzbladd
Samir's avatar
Samir committed
171
listbib
172
ltx2crossrefxml
Samir's avatar
Samir committed
173
multibibliography
174 175
urlbst
"
Samir Benmendil's avatar
Samir Benmendil committed
176
  _core_scripts="
Samir's avatar
Samir committed
177 178 179
a2ping
a5toa4
adhocfilelist
180
afm2afm
Samir's avatar
Samir committed
181 182 183 184
allcm
allec
allneeded
arara
185 186 187
arlatex
autoinst
bundledoc
Samir's avatar
Samir committed
188
checkcites
189 190
chkweb
cjk-gs-integrate
Samir's avatar
Samir committed
191
context
Samir Benmendil's avatar
Samir Benmendil committed
192
contextjit
193 194 195
ctanify
ctanupload
de-macro
Samir Benmendil's avatar
Samir Benmendil committed
196
depythontex
Samir's avatar
Samir committed
197
deweb
198
dosepsbin
Samir's avatar
Samir committed
199 200
dtxgen
dvi2fax
201
dviasm
Samir's avatar
Samir committed
202 203
dvired
e2pall
204 205
epstopdf
findhyph
Samir's avatar
Samir committed
206 207 208
fmtutil
fmtutil-sys
fontinst
209 210
fragmaster
installfont-tl
Samir's avatar
Samir committed
211 212 213 214
kpsepath
kpsetool
kpsewhere
kpsexpand
Samir Benmendil's avatar
Samir Benmendil committed
215
latex-git-log
216 217 218
latex2man
latexdiff
latexdiff-vc
Samir's avatar
Samir committed
219
latexfileversion
Samir Benmendil's avatar
Samir Benmendil committed
220
latexindent
221
latexmk
Samir's avatar
Samir committed
222
latexpand
223 224
latexrevise
listings-ext.sh
Samir's avatar
Samir committed
225
ltxfileinfo
Samir Benmendil's avatar
Samir Benmendil committed
226
ltximg
Samir's avatar
Samir committed
227 228 229
lua2dox_filter
luaotfload-tool
luatools
230 231 232 233
match_parens
mf2pt1
mkjobtexmf
mkt1font
Samir's avatar
Samir committed
234
mktexfmt
235
mptopdf
Samir's avatar
Samir committed
236
mtxrun
Samir Benmendil's avatar
Samir Benmendil committed
237
mtxrunjit
238 239 240 241 242 243 244 245 246 247 248 249 250 251 252
ot2kpx
pdf180
pdf270
pdf90
pdfatfi
pdfbook
pdfcrop
pdfflip
pdfjam
pdfjam-pocketmod
pdfjam-slides3up
pdfjam-slides6up
pdfjoin
pdfnup
pdfpun
Samir's avatar
Samir committed
253
pfarrei
254 255
pkfix
pkfix-helper
Samir's avatar
Samir committed
256 257 258
ps2eps
ps2frag
pslatex
259
purifyeps
Samir Benmendil's avatar
Samir Benmendil committed
260
pythontex
261 262
repstopdf
rpdfcrop
Samir's avatar
Samir committed
263 264
rungs
simpdftex
265
sty2dtx
Samir's avatar
Samir committed
266 267 268
texconfig
texconfig-dialog
texconfig-sys
269 270 271 272
texcount
texdef
texdiff
texdirflatten
Samir's avatar
Samir committed
273 274 275
texdoc
texdoctk
texexec
Samir Benmendil's avatar
Samir Benmendil committed
276
texfot
Samir's avatar
Samir committed
277 278
texindy
texlinks
279 280
texliveonfly
texloganalyser
Samir's avatar
Samir committed
281
texmfstart
282
thumbpdf
Samir's avatar
Samir committed
283
typeoutfileinfo
Samir's avatar
Samir committed
284
updmap
Samir's avatar
Samir committed
285
updmap-sys
286 287
vpl2ovp
vpl2vpl
Samir's avatar
Samir committed
288
xindy
289
"
Samir Benmendil's avatar
Samir Benmendil committed
290
  _games_scripts="rubikrotation"
Samir Benmendil's avatar
Samir Benmendil committed
291 292
  _htmlxml_scripts="ht htcontext htlatex htmex httex httexi htxelatex htxetex mk4ht"
  _langcyrillic_scripts="rubibtex rumakeindex"
Samir Benmendil's avatar
Samir Benmendil committed
293 294 295
  _langextra_scripts="ebong"
  _langgreek_scripts="mkgrkindex"
  _langjapanese_scripts="convbkmk ptex2pdf
Samir's avatar
Samir committed
296 297 298 299
kanji-fontmap-creator
kanji-config-updmap
kanji-config-updmap-sys
"
300
  _langkorean_scripts="jamo-normalize komkindex ttf2kotexfont"
Samir Benmendil's avatar
Samir Benmendil committed
301
  _latexextra_scripts="
Samir's avatar
Samir committed
302 303 304 305 306 307 308 309
authorindex
exceltex
makeglossaries
pdfannotextractor
perltex
ps4pdf
splitindex
svn-multi
310 311
vpe
yplan"
Samir Benmendil's avatar
Samir Benmendil committed
312 313
  _music_scripts="lily-glyph-commands lily-image-commands lily-rebuild-pdfs
m-tx musixtex musixflx pmx2pdf pmxchords"
314
  _pictures_scripts="cachepic epspdf epspdftk fig4latex getmapdl mathspic mkpic"
Samir Benmendil's avatar
Samir Benmendil committed
315
  _pstricks_scripts="pedigree pst2pdf"
316
  _science_scripts="pygmentex ulqda"
Samir Benmendil's avatar
Samir Benmendil committed
317 318 319
  for s in \
    ${_bibtexextra_scripts} \
      ${_core_scripts}       \
Samir Benmendil's avatar
Samir Benmendil committed
320
      ${_games_scripts}      \
Samir Benmendil's avatar
Samir Benmendil committed
321 322 323 324
      ${_htmlxml_scripts}    \
      ${_langcyrillic_scripts} \
      ${_langextra_scripts}  \
      ${_langgreek_scripts}  \
Samir Benmendil's avatar
Samir Benmendil committed
325 326
      ${_langjapanese_scripts} \
      ${_langkorean_scripts} \
Samir Benmendil's avatar
Samir Benmendil committed
327 328 329 330 331 332 333 334 335
      ${_latexextra_scripts} \
      ${_music_scripts}      \
      ${_pictures_scripts}   \
      ${_pstricks_scripts}   \
      ${_science_scripts}    \
      tlmgr; do
      ! readlink -e "$pkgdir"/usr/bin/$s && rm "$pkgdir"/usr/bin/$s
  done
  ###################################################################
Ram-Z's avatar
Ram-Z committed
336 337 338

  # rm libsynctex
  rm -f "$pkgdir"/usr/lib/libsynctex.*
Manuel Tortosa's avatar
Manuel Tortosa committed
339
}