PKGBUILDs/extra/latex2html/PKGBUILD

46 lines
1.4 KiB
Bash
Raw Normal View History

2009-10-10 02:23:22 +00:00
# $Id: PKGBUILD 20303 2008-12-02 10:46:41Z ronald $
# Maintainer: Ronald van Haren <ronald.archlinux.org>
# Contributor: Jochem Kossen <j.kossen@home.nl>
# Contributor: Jason Chu <jason.archlinux.org>
pkgname=latex2html
pkgver=2008
pkgrel=1
pkgdesc="latex2html is a convertor written in Perl that converts LaTeX documents to HTML."
arch=('i686' 'x86_64')
url="http://saftsack.fs.uni-bayreuth.de/~latex2ht/"
depends=('perl' 'ghostscript' 'texlive-core' 'libpng' 'giflib' 'netpbm')
install=$pkgname.install
license=('GPL2')
source=(http://saftsack.fs.uni-bayreuth.de/~latex2ht/current/$pkgname-$pkgver.tar.gz)
build() {
cd $srcdir/$pkgname-$pkgver
./configure --prefix=$startdir/pkg/usr \
--shlibdir=$startdir/pkg/usr/lib/$pkgname \
--with-texpath=$startdir/pkg/usr/share/texmf/tex/latex/html \
--enable-wrapper \
--enable-gif \
--enable-png || return 1
make || return 1
make install || return 1
find $startdir/pkg/usr -type f -print | while read filename; do
if [ ! -z '`grep "$startdir" "$filename"`' ]; then
mv $filename $filename.mkpkg
sed -e "s#$pkgdir##g" -e "s#$srcdir##g" < $filename.mkpkg > $filename
rm $filename.mkpkg
fi
done
# move files to FHS location
mv $startdir/pkg/usr/cfgcache.pm $startdir/pkg/usr/l2hconf.pm $startdir/pkg/usr/lib/$pkgname/
# set correct permission on executables
chmod 755 $pkgdir/usr/bin/pstoimg \
$pkgdir/usr/bin/$pkgname \
$pkgdir/usr/bin/texexpand
}