[arch-commits] Commit in texlive-core/repos (3 files)
François Charette
francois at archlinux.org
Mon Aug 17 20:26:41 UTC 2009
Date: Monday, August 17, 2009 @ 16:26:41
Author: francois
Revision: 49956
Merged revisions 49955 via svnmerge from
svn+ssh://archlinux.org/srv/svn-packages/texlive-core/trunk
........
r49955 | francois | 2009-08-17 22:25:42 +0200 (Mon, 17 Aug 2009) | 1 line
update + new handling of maps in texlive.install
........
Modified:
texlive-core/repos/testing-any/ (properties)
texlive-core/repos/testing-any/PKGBUILD
texlive-core/repos/testing-any/texlive.install
-----------------+
PKGBUILD | 8 +++--
texlive.install | 84 ++++++++++++++++++++++++++++++------------------------
2 files changed, 53 insertions(+), 39 deletions(-)
Property changes on: texlive-core/repos/testing-any
___________________________________________________________________
Modified: svnmerge-integrated
- /texlive-core/trunk:1-47908
+ /texlive-core/trunk:1-49955
Modified: testing-any/PKGBUILD
===================================================================
--- testing-any/PKGBUILD 2009-08-17 20:25:42 UTC (rev 49955)
+++ testing-any/PKGBUILD 2009-08-17 20:26:41 UTC (rev 49956)
@@ -1,7 +1,7 @@
# Maintainer: Firmicus <firmicus ατ gmx δοτ net>
pkgname=texlive-core
-pkgver=2009.14473
+pkgver=2009.14685
pkgrel=1
pkgdesc="TeX Live core distribution"
license=('GPL')
@@ -13,10 +13,11 @@
provides=('tetex')
replaces=('tetex')
url='http://tug.org/texlive/'
-source=("ftp://ftp.archlinux.org/other/texlive/$pkgname-$pkgver-src.zip")
+source=("ftp://ftp.archlinux.org/other/texlive/$pkgname-$pkgver-src.zip" "$pkgname.maps")
install=texlive.install
backup=(usr/share/texmf-config/tex/context/config/cont-usr.tex)
-md5sums=('992aacde7f6384ae9484e0e4f724ff62')
+md5sums=('f3223dbf0685ca98769fd59aa39d80d3'
+ '088bf643ad1853f40cdf8cccf62b6e18')
build() {
cd $srcdir
@@ -24,6 +25,7 @@
sed -i '/^#/d' CONTENTS || return 1
_revnr=`echo $pkgver | sed 's/2009\.//'`
install -m644 CONTENTS $pkgdir/usr/share/texmf-var/arch/installedpkgs/${pkgname}_${_revnr}.pkgs || return 1
+ install -m644 $pkgname.maps $pkgdir/usr/share/texmf-var/arch/installedpkgs/ || return 1
echo -n " --> extracting all packages... "
for p in *.tar.xz; do
bsdtar -xf $p || return 1
Modified: testing-any/texlive.install
===================================================================
--- testing-any/texlive.install 2009-08-17 20:25:42 UTC (rev 49955)
+++ testing-any/texlive.install 2009-08-17 20:26:41 UTC (rev 49956)
@@ -1,5 +1,8 @@
-pre_install() {
- cat >> /usr/share/texmf-config/web2c/updmap.cfg <<EOF
+PKGNAME="texlive-core"
+UPDMAP="/usr/share/texmf-config/web2c/updmap.cfg"
+SYNCWITHTREES=''
+NEWMAPS=`mktemp`
+cat <<EOF > $NEWMAPS
Map euler.map
Map charter.map
Map fpls.map
@@ -39,49 +42,58 @@
MixedMap wasy.map
MixedMap yhmath.map
EOF
+
+pre_install() {
+ cat $NEWMAPS >> $UPDMAP
}
post_install() {
- echo -n "updating the filename database..."
- mktexlsr --quiet
- echo " done"
- echo -n "creating the fontmap files with updmap..."
+ echo ">>> texlive: updating the filename database..."
+ texconfig-sys rehash
+ echo ">>> texlive: updating the fontmap files with updmap..."
updmap-sys --quiet --nohash
- echo " done"
- echo -n "creating all formats..."
- fmtutil-sys --all 1>/dev/null
- echo " done."
- echo " (logs are under /usr/share/texmf-var/web2c/<engine>/<formatname>.log)"
- echo "------------------------------------------------------------------"
- echo " PLEASE read the TeXLive documentation at"
- echo " http://wiki.archlinux.org/index.php/TeXLive"
- echo "------------------------------------------------------------------"
+ echo " done."
}
+
pre_upgrade() {
- updmapfile="/usr/share/texmf-config/web2c/updmap.cfg"
- if [[ ! -f $updmapfile ]]; then
- echo " WARNING: Can't find $updmapfile !"
- else
- noofmaps=`grep -c -e "^Map" $updmapfile`
- noofmixedmaps=`grep -c -e "^MixedMap" $updmapfile`
- totalmaps=$(($noofmaps+$noofmixedmaps))
- if [[ $totalmaps == 0 ]] ; then
- pre_install
- fi
- fi
+ OLDMAPS="/usr/share/texmf-var/arch/installedpkgs/$PKGNAME.maps"
+ if [ -f $OLDMAPS ] ; then
+ MAPSDIFF=`mktemp`
+ TOADD=`mktemp`
+ diff -B $OLDMAPS $NEWMAPS | sed 's/\s\+/ /g' > $MAPSDIFF
+ TOREMOVE=`cat $MAPSDIFF | egrep '^<' | cut -d' ' -f3`
+ cat $MAPSDIFF | egrep '^>' | sed 's/^> //' > $TOADD
+ if [ "x$TOREMOVE" != "x" ]; then
+ for map in $TOREMOVE; do
+ sed -i "/\s$map/d" $UPDMAP
+ done
+ fi
+ if [ -s $TOADD ]; then
+ cat $TOADD >> $UPDMAP
+ fi
+ else
+ echo "Warning: file $PKGNAME.maps not found"
+ echo "(ignore the above if updating from TL2008 or from TL2009 in testing)"
+ SYNCWITHTREES="--syncwithtrees"
+ fi
}
+
post_upgrade() {
- echo -n "updating the filename database..."
- mktexlsr --quiet
- echo " done"
- if [[ $totalmaps == 0 ]] ; then
- echo -n "updating the fontmap files with updmap..."
- updmap-sys --syncwithtrees --quiet --nohash
- echo " done"
- fi
- echo "If updating from TeXLive 2008, it is advisable to rebuild the formats with"
- echo " sudo fmtutil-sys --all"
+ echo ">>> texlive: updating the filename database..."
+ texconfig-sys rehash
+ echo ">>> texlive: updating the fontmap files with updmap..."
+ updmap-sys --quiet --nohash $SYNCWITHTREES
+ echo " done."
}
+pre_remove() {
+for m in `cut -d' ' -f2 $NEWMAPS`; do
+ sed -i "/\s$m/d" $UPDMAP ;
+done
+}
+
+post_remove() {
+ post_install
+}
More information about the arch-commits
mailing list