Compare commits

...

2 Commits

Author SHA1 Message Date
Achim D. Brucker c3ecbc8a24 Improve behaviour if md5sum is not installed.
HOL-OCL/Isabelle_DOF/master There was a failure building this commit Details
2019-02-06 09:46:01 +00:00
Achim D. Brucker 04377e6727 Fixed bug causing the installation to halt during the registration of AFP entries. 2019-02-06 09:30:43 +00:00
1 changed files with 6 additions and 3 deletions

View File

@ -98,7 +98,8 @@ check_afp_entries() {
if curl -s -L $AFP_URL | tar zxf - -C .afp $extract; then
for e in $missing; do
echo " Registering $e in $ISABELLE_HOME_USER/ROOTS"
grep -q $PWD/.afp/afp-2018-08-14/thys/$e || echo "$PWD/.afp/afp-2018-08-14/thys/$e" >> $ISABELLE_HOME_USER/ROOTS
touch $ISABELLE_HOME_USER/ROOTS
grep -q $PWD/.afp/afp-2018-08-14/thys/$e $ISABELLE_HOME_USER/ROOTS || echo "$PWD/.afp/afp-2018-08-14/thys/$e" >> $ISABELLE_HOME_USER/ROOTS
done
echo " AFP installation successful."
else
@ -116,14 +117,16 @@ check_isa_dof_patch() {
echo "* Check availabilty of Isabelle/DOF patch:"
src="patches/thy_output.ML"
dst="$ISABELLE_HOME/src/Pure/Thy/thy_output.ML"
if [[ $(md5sum "$src" | cut -d' ' -f1) = $(md5sum "$dst" | cut -d' ' -f1) ]]; then
if command -v md5sum > /dev/null 2>&1 && [[ $(md5sum "$src" | cut -d' ' -f1) = $(md5sum "$dst" | cut -d' ' -f1) ]]; then
echo " Success: latest Isabelle/DOF patch already applied"
if isabelle process -e 'Thy_Output.set_meta_args_parser' &> /dev/null ; then
true
else
echo " Success: Warning: Isabelle/HOL needs to be rebuild to activate patch."
echo " Warning: Isabelle/HOL needs to be rebuild to activate patch."
fi
else
command -v md5sum >/dev/null 2>&1 || echo " Warning: md5sum not available, cannot check if patch is already applied."
echo " Warning: Isabelle/DOF patch is not available or outdated."
echo " Trying to patch system ...."
if (cp $dst $dst.backup-by-isadof-installer && cp -f $src $dst) &> /dev/null; then