updated on Mon Jan 23 12:00:23 UTC 2012
[aur-mirror.git] / minionpro / minionpro.install
blobb0aed6b2a834f1553996831c4d09c3a9e1620e11
1 PKGNAME="minionpro"
2 UPDMAP="etc/texmf/web2c/updmap.cfg"
3 UPDMAPLOCAL="etc/texmf/web2c/updmap-local.cfg"
4 MAPFILE="var/lib/texmf/arch/installedpkgs/$PKGNAME.maps"
6 post_install() {
7   TMPFILE=`mktemp`
8   echo    ">>> texlive: saving updmap.cfg as $TMPFILE..."
9   cp "$UPDMAP" "$TMPFILE"
10   echo    ">>> texlive: regenerating updmap.cfg (custom additions shoud go"
11   echo    "             into /etc/texmf/web2c/updmap-local.cfg"
12   cp usr/share/texmf/web2c/updmap-hdr.cfg $UPDMAP
13   cat var/lib/texmf/arch/installedpkgs/*.maps >> $UPDMAP
14   [ -f "$UPDMAPLOCAL" ] && cat "$UPDMAPLOCAL" >> $UPDMAP
15   echo    ">>> texlive: updating the filename database..."
16   usr/bin/mktexlsr
17   echo    ">>> texlive: updating the fontmap files with updmap..."
18   usr/bin/updmap-sys --quiet --nohash
19   echo    " done."
21 post_upgrade() {
22                post_install    
24 pre_remove() {
25 for m in `cut -d' ' -f2 $MAPFILE`; do
26   sed -i "/\s$m/d" $UPDMAP ;
27 done
29 post_remove() {
30   echo    ">>> texlive: updating the filename database..."
31   usr/bin/mktexlsr
32   echo    ">>> texlive: updating the fontmap files with updmap..."
33   usr/bin/updmap-sys --quiet --nohash
34   echo    " done."