.
OBS-URL: https://build.opensuse.org/package/show/Publishing:TeXLive/texlive-filesystem?expand=0&rev=70
This commit is contained in:
parent
f0d76853bf
commit
0f175d59a1
@ -1,3 +1,9 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Jul 18 11:02:31 UTC 2017 - werner@suse.de
|
||||||
|
|
||||||
|
- Make update.texlive faster and remove specific tag file after
|
||||||
|
creating specific format
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Wed Jul 12 07:41:21 UTC 2017 - werner@suse.de
|
Wed Jul 12 07:41:21 UTC 2017 - werner@suse.de
|
||||||
|
|
||||||
|
130
update.texlive
130
update.texlive
@ -178,15 +178,16 @@ do
|
|||||||
mf|mfw|mf-nowin) fmt="$format.base"; kpse=mf; engine=metafont ;;
|
mf|mfw|mf-nowin) fmt="$format.base"; kpse=mf; engine=metafont ;;
|
||||||
*) fmt="$format.fmt"; kpse=tex; engine=$engine ;;
|
*) fmt="$format.fmt"; kpse=tex; engine=$engine ;;
|
||||||
esac
|
esac
|
||||||
inifile=$(kpsewhich -progname=$format -format=$kpse $inifile 2>/dev/null) || continue
|
test -d ${WEB2C}/$engine || mkdir -p ${WEB2C}/$engine
|
||||||
fmt="$(find ${WEB2C}/$engine -name $fmt)"
|
fmt="${WEB2C}/$engine/$fmt"
|
||||||
if test -z "$fmt"
|
if test ! -e "$fmt"
|
||||||
then
|
then
|
||||||
# init=true
|
# init=true
|
||||||
# > /var/run/texlive/run-fmtutil
|
# > /var/run/texlive/run-fmtutil
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
test "$fmt" -nt "$TEXMFCNFFILE" || init=true
|
test "$fmt" -nt "$TEXMFCNFFILE" || init=true
|
||||||
|
inifile=$(kpsewhich -progname=$format -format=$kpse $inifile 2>/dev/null) || continue
|
||||||
test "$fmt" -nt "$inifile" && continue
|
test "$fmt" -nt "$inifile" && continue
|
||||||
case "$engine" in
|
case "$engine" in
|
||||||
mpost) fmtutil-sys --byfmt "$egine" < /dev/null 1>&4 2>&4 ;;
|
mpost) fmtutil-sys --byfmt "$egine" < /dev/null 1>&4 2>&4 ;;
|
||||||
@ -209,10 +210,11 @@ if test -n "${cnf_ldat}" -a -n "${cnf_ldef}" -a -n "${cnf_llua}" ; then
|
|||||||
fi
|
fi
|
||||||
mv -f ${OLDMD5DIR}${cfg} ${MD5DIR}${cfg}
|
mv -f ${OLDMD5DIR}${cfg} ${MD5DIR}${cfg}
|
||||||
done
|
done
|
||||||
|
|
||||||
#
|
#
|
||||||
# Handle hyphens
|
# Handle hyphens
|
||||||
#
|
#
|
||||||
|
typeset -i refresh=0
|
||||||
for run in /var/run/texlive/run-hyphen* ; do
|
for run in /var/run/texlive/run-hyphen* ; do
|
||||||
test -e "$run" || break
|
test -e "$run" || break
|
||||||
tmp=${cnf_ldat}.$RANDOM
|
tmp=${cnf_ldat}.$RANDOM
|
||||||
@ -224,6 +226,7 @@ if test -n "${cnf_ldat}" -a -n "${cnf_ldef}" -a -n "${cnf_llua}" ; then
|
|||||||
cat "$dat"
|
cat "$dat"
|
||||||
done >> $tmp
|
done >> $tmp
|
||||||
mv -f $tmp ${cnf_ldat}
|
mv -f $tmp ${cnf_ldat}
|
||||||
|
let refresh++
|
||||||
#
|
#
|
||||||
tmp=${cnf_ldef}.$RANDOM
|
tmp=${cnf_ldef}.$RANDOM
|
||||||
cat ${TEXMFDIST}/tex/generic/config/language.us.def >> $tmp
|
cat ${TEXMFDIST}/tex/generic/config/language.us.def >> $tmp
|
||||||
@ -235,6 +238,7 @@ if test -n "${cnf_ldat}" -a -n "${cnf_ldef}" -a -n "${cnf_llua}" ; then
|
|||||||
echo >> $tmp
|
echo >> $tmp
|
||||||
echo '\uselanguage {USenglish} %%% This MUST be the last line of the file.' >> $tmp
|
echo '\uselanguage {USenglish} %%% This MUST be the last line of the file.' >> $tmp
|
||||||
mv -f $tmp ${cnf_ldef}
|
mv -f $tmp ${cnf_ldef}
|
||||||
|
let refresh++
|
||||||
#
|
#
|
||||||
tmp=${cnf_llua}.$RANDOM
|
tmp=${cnf_llua}.$RANDOM
|
||||||
echo "-- Generated by ${TEXMFDIST}/texconfig/update on $(date)" > $tmp
|
echo "-- Generated by ${TEXMFDIST}/texconfig/update on $(date)" > $tmp
|
||||||
@ -246,70 +250,78 @@ if test -n "${cnf_ldat}" -a -n "${cnf_ldef}" -a -n "${cnf_llua}" ; then
|
|||||||
# Silent editor {
|
# Silent editor {
|
||||||
echo '}' >> $tmp
|
echo '}' >> $tmp
|
||||||
mv -f $tmp ${cnf_llua}
|
mv -f $tmp ${cnf_llua}
|
||||||
|
let refresh++
|
||||||
set +C
|
set +C
|
||||||
rm -f /var/run/texlive/run-hyphen*
|
rm -f /var/run/texlive/run-hyphen*
|
||||||
done
|
done
|
||||||
|
|
||||||
#
|
if ((refresh > 0))
|
||||||
# New md5 sums
|
then
|
||||||
#
|
#
|
||||||
md5_ldat=${MD5DIR}${cnf_ldat}
|
# New md5 sums
|
||||||
md5_ldef=${MD5DIR}${cnf_ldef}
|
#
|
||||||
md5_llua=${MD5DIR}${cnf_llua}
|
md5_ldat=${MD5DIR}${cnf_ldat}
|
||||||
set -- $(md5sum < ${cnf_ldat}) ; md5ldat="$1"
|
md5_ldef=${MD5DIR}${cnf_ldef}
|
||||||
set -- $(md5sum < ${cnf_ldef}) ; md5ldef="$1"
|
md5_llua=${MD5DIR}${cnf_llua}
|
||||||
set -- $(md5sum < ${cnf_llua}) ; md5llua="$1"
|
set -- $(md5sum < ${cnf_ldat}) ; md5ldat="$1"
|
||||||
|
set -- $(md5sum < ${cnf_ldef}) ; md5ldef="$1"
|
||||||
|
set -- $(md5sum < ${cnf_llua}) ; md5llua="$1"
|
||||||
|
|
||||||
#
|
#
|
||||||
# Previous md5 sums
|
# Previous md5 sums
|
||||||
#
|
#
|
||||||
omd5ldat=0
|
omd5ldat=0
|
||||||
omd5ldef=0
|
omd5ldef=0
|
||||||
omd5llua=0
|
omd5llua=0
|
||||||
if test -e ${md5_ldat} -a -r ${md5_ldat} ; then
|
if test -e ${md5_ldat} -a -r ${md5_ldat} ; then
|
||||||
set -- $(cat ${md5_ldat}) ; omd5ldat="$1"
|
set -- $(cat ${md5_ldat}) ; omd5ldat="$1"
|
||||||
elif test ! -d ${md5_ldat%/*} ; then
|
elif test ! -d ${md5_ldat%/*} ; then
|
||||||
mkdir -p ${md5_ldat%/*}
|
mkdir -p ${md5_ldat%/*}
|
||||||
fi
|
fi
|
||||||
if test -e ${md5_ldef} -a -r ${md5_ldef} ; then
|
echo "$md5ldat" > $md5_ldat
|
||||||
set -- $(cat ${md5_ldef}) ; omd5ldef="$1"
|
if test -e ${md5_ldef} -a -r ${md5_ldef} ; then
|
||||||
elif test ! -d ${md5_ldef%/*} ; then
|
set -- $(cat ${md5_ldef}) ; omd5ldef="$1"
|
||||||
mkdir -p ${md5_ldef%/*}
|
elif test ! -d ${md5_ldef%/*} ; then
|
||||||
fi
|
mkdir -p ${md5_ldef%/*}
|
||||||
if test -e ${md5_llua} -a -r ${md5_llua} ; then
|
fi
|
||||||
|
echo "$md5ldef" > $md5_ldef
|
||||||
|
if test -e ${md5_llua} -a -r ${md5_llua} ; then
|
||||||
set -- $(cat ${md5_llua}) ; omd5llua="$1"
|
set -- $(cat ${md5_llua}) ; omd5llua="$1"
|
||||||
elif test ! -d ${md5_llua%/*} ; then
|
elif test ! -d ${md5_llua%/*} ; then
|
||||||
mkdir -p ${md5_llua%/*}
|
mkdir -p ${md5_llua%/*}
|
||||||
fi
|
fi
|
||||||
|
echo "$md5llua" > $md5_llua
|
||||||
|
|
||||||
#
|
#
|
||||||
# Create new formats for new language.dat and/or language.def if needed
|
# Refresh formats for new language.dat and/or language.def if needed
|
||||||
#
|
#
|
||||||
while read format engine language rest
|
while read format engine language rest
|
||||||
do
|
|
||||||
line=($rest)
|
|
||||||
last=${line[-1]}
|
|
||||||
inifile=${last#\*}
|
|
||||||
case "$engine" in
|
|
||||||
mpost) continue ;;
|
|
||||||
mf|mfw|mf-nowin) continue ;;
|
|
||||||
*) fmt="$format.fmt"; kpse=tex; engine=$engine ;;
|
|
||||||
esac
|
|
||||||
inifile=$(kpsewhich -progname=$format -format=$kpse $inifile 2>/dev/null) || continue
|
|
||||||
fmt="$(find ${WEB2C}/$engine -name $fmt)"
|
|
||||||
test -z "$fmt" && continue
|
|
||||||
for lang in ${language//,/ }
|
|
||||||
do
|
do
|
||||||
for cfg in ${cnf_ldat} ${cnf_ldef} ${cnf_llua}
|
line=($rest)
|
||||||
|
last=${line[-1]}
|
||||||
|
inifile=${last#\*}
|
||||||
|
case "$engine" in
|
||||||
|
mpost) continue ;;
|
||||||
|
mf|mfw|mf-nowin) continue ;;
|
||||||
|
*) fmt="$format.fmt"; kpse=tex; engine=$engine ;;
|
||||||
|
esac
|
||||||
|
test -d ${WEB2C}/$engine || mkdir -p ${WEB2C}/$engine
|
||||||
|
fmt="${WEB2C}/$engine/$fmt"
|
||||||
|
test -e "$fmt" || continue
|
||||||
|
inifile=$(kpsewhich -progname=$format -format=$kpse $inifile 2>/dev/null) || continue
|
||||||
|
for lang in ${language//,/ }
|
||||||
do
|
do
|
||||||
test $lang = "${cfg##*/}" || continue
|
for cfg in ${cnf_ldat} ${cnf_ldef} ${cnf_llua}
|
||||||
test $fmt -nt $cfg && continue
|
do
|
||||||
> /var/run/texlive/run-fmtutil.language
|
test $lang = "${cfg##*/}" || continue
|
||||||
break 3
|
test $fmt -nt $cfg && continue
|
||||||
|
> /var/run/texlive/run-fmtutil.language
|
||||||
|
break 3
|
||||||
|
done
|
||||||
done
|
done
|
||||||
done
|
done < <(sed -r "/^(\#.*|[[:blank:]]*)$/d" "$cnf_fmtu")
|
||||||
done < <(sed -r "/^(\#.*|[[:blank:]]*)$/d" "$cnf_fmtu")
|
unset format engine language lang rest line last inifile fmt kpse engine
|
||||||
unset format engine language lang rest line last inifile fmt kpse engine
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
tcfmgr ()
|
tcfmgr ()
|
||||||
@ -428,7 +440,7 @@ for run in /var/run/texlive/run-fmtutil* ; do
|
|||||||
fmtutil-sys ${option:+$option} --byfmt "${run#*fmtutil.}" < /dev/null 1>&4 2>&4
|
fmtutil-sys ${option:+$option} --byfmt "${run#*fmtutil.}" < /dev/null 1>&4 2>&4
|
||||||
let rc+=$?
|
let rc+=$?
|
||||||
test $VERBOSE = true && echo
|
test $VERBOSE = true && echo
|
||||||
((rc != 0)) || rm -f /var/run/texlive/run-fmtutil
|
((rc != 0)) || rm -f "${run}"
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user