Add workaround for symlink/directory conflict (bz 2097773).

Modify the jmol patch to timeout after 5 minutes.  This is a workaround
for recently observed jmol hangs, but is not a proper fix.
This commit is contained in:
Jerry James 2022-07-07 08:34:58 -06:00
parent aed4db5045
commit bbf8c7d8ee
2 changed files with 40 additions and 12 deletions

View file

@ -84,7 +84,7 @@
Name: sagemath
Summary: A free open-source mathematics software system
Version: 9.6
Release: 1%{?dist}
Release: 2%{?dist}
# The file ${SAGE_ROOT}/COPYING.txt is the upstream license breakdown file
# Additionally, every $files section has a comment with the license name
# before files with that license
@ -1030,6 +1030,9 @@ sed -i 's/3\.11\.0/3.12.0/g' configure
# Allow use of libfplll 5.4.2
sed -i 's/5\.4\.1/5.4.2/g' configure
# Allow use of eclib 20220621
sed -i 's/20210625/20220621/g' configure
# Do not build with -march=native
sed -i 's/CFLAGS_MARCH="-march=native"/CFLAGS_MARCH=""/' configure
@ -1037,7 +1040,6 @@ sed -i 's/CFLAGS_MARCH="-march=native"/CFLAGS_MARCH=""/' configure
########################################################################
%build
export LC_ALL=C.UTF-8
export CC=%{__cc}
export CPPFLAGS="-I%{_includedir}/4ti2 -I%{_includedir}/arb -I%{_includedir}/cddlib"
export ECMBIN=%{_bindir}/gmp-ecm
export SAGE_ROOT=%{buildroot}%{SAGE_ROOT}
@ -1678,10 +1680,9 @@ mkdir -p %{SAGE_LOCAL}/var/lib/sage/installed/database_cremona_ellcurve-%{cremon
rm -fr %{SAGE_LOCAL}/var/lib/sage/installed/database_cremona_ellcurve-%{cremona_ver}
%if %{with docs}
########################################################################
# Fix directory/symlink conflicts introduced by fix for bz 1875606.
# This can be removed when Fedora 36 reaches EOL.
%pretrans -n sagemath-doc-en -p <lua>
-- Fix directory/symlink conflicts introduced by fix for bz 1875606.
-- This can be removed when Fedora 36 reaches EOL.
paths = {
"%{SAGE_DOC}/html/en/_static/config",
"%{SAGE_DOC}/html/en/_static/extensions",
@ -1765,6 +1766,20 @@ for _, path in ipairs(paths) do
end
end
end
-- Fix directory/symlink conflicts introduced by sagemath 3.5 -> 3.6 upgrade.
-- This can be removed when Fedora 40 reaches EOL.
paths2 = {
"%{SAGE_DOC}/html/en/reference/plot3d/_static",
"%{SAGE_DOC}/html/en/reference/repl/_static"
}
for _, path in ipairs(paths2) do
st = posix.stat(path)
if st and st.type == "link" then
os.remove(path)
end
end
%endif
@ -2021,6 +2036,11 @@ end
########################################################################
%changelog
* Tue Jul 5 2022 Jerry James <loganjerry@gmail.com> - 9.6-2
- Add workaround for symlink/directory conflict (bz 2097773)
- Modify the jmol patch to timeout after 5 minutes. This is a workaround for
recently observed jmol hangs, but is not a proper fix.
* Wed Jun 1 2022 Jerry James <loganjerry@gmail.com> - 9.6-1
- Version 9.6
- Fix path to libSingular.so (bz 2073208)