classabbyamp 9ab1405894
*: remove unnecessary execute permissions
* INSTALL scripts don't need to be executable
* anything installed by vbin is set to 755
* many of these files were otherwise marked executable in the template
  (vinstall, chmod, etc)
* some had no business being executable, like the smattering of patches
  and other files
* remove files from chroot-distcc no longer used in the template
  (46ce787b63d467d9b8e5ef8821e2ddefea4b980a)
2024-08-02 13:24:47 -04:00

49 lines
984 B
Bash

#!/bin/sh
#
# Updates texmf-dist hashes and format library.
#
# Arguments: $ACTION = [run/targets]
# $TARGET = [post-install/post-remove]
# $PKGNAME
# $VERSION
# $UPDATE = [yes/no]
#
ACTION="$1"
TARGET="$2"
PKGNAME="$3"
VERSION="$4"
UPDATE="$5"
texhash=usr/bin/texhash
fmtutil=usr/bin/fmtutil-sys
updmap=usr/bin/updmap-sys
optional_engines="luahbtex,luajithbtex,luajittex,luatex,xetex"
case "$ACTION" in
targets)
echo "post-install post-remove"
;;
run)
if [ -x ${texhash} ]; then
echo "Updating texmf-dist hashes..."
${texhash} 2>&1 >/dev/null || true # silence strange errors
fi
if [ -x ${fmtutil} ]; then
echo "Updating texmf-dist formats..."
${fmtutil} --no-error-if-no-engine="${optional_engines}" \
--quiet --all >/dev/null || true
fi
if [ -x ${updmap} ]; then
echo "Syncing font map files..."
yes y | ${updmap} --quiet --syncwithtrees >/dev/null
echo "Updating font map files..."
${updmap} --quiet >/dev/null
fi
;;
*)
exit 1
;;
esac
exit 0