From 29021ae262d76cb7f5aef90259007a24bb81a67d Mon Sep 17 00:00:00 2001 From: Orion Poplawski Date: Dec 08 2016 21:28:22 +0000 Subject: Add patch to prevent gzip from deleting target file, instead emit warning Drop debug code Disable segfaulting osmesa_print and pltopt tests --- diff --git a/macros.octave b/macros.octave index ca5db35..3b7391d 100644 --- a/macros.octave +++ b/macros.octave @@ -30,12 +30,9 @@ print(rpm.expand("mkdir -p %{_builddir}/%{buildsubdir}/build\\n")) -- This fails to keep the arguments to %octave_cmd for some reason -- print(rpm.expand("%octave_cmd pkg build -verbose -nodeps %{_builddir}/%{buildsubdir} "..octpkg_tarfile).."\\n") - print(rpm.expand("strace -f -s 1024 -o octave.strace octave -H -V --no-window-system --no-site-file --eval 'pkg build -verbose -nodeps %{_builddir}/%{buildsubdir}/build "..octpkg_tarfile).."'\\n") - print("ls -l *\\n") + print(rpm.expand("octave -H -q --no-window-system --no-site-file --eval 'pkg build -verbose -nodeps %{_builddir}/%{buildsubdir}/build "..octpkg_tarfile).."'\\n") -- Extract the source tarball for debuginfo generation print(rpm.expand("tar xf "..octpkg_tarfile.." -C %{_builddir}/%{buildsubdir}/build\\n")) - print("ls -l *\\n") - print("cat octave.strace\\n") } # Install a package. We use the octave pkg install command to install the diff --git a/octave-gzip.patch b/octave-gzip.patch new file mode 100644 index 0000000..bc33a03 --- /dev/null +++ b/octave-gzip.patch @@ -0,0 +1,21 @@ +diff -up octave-4.2.0/libinterp/dldfcn/gzip.cc.gzip octave-4.2.0/libinterp/dldfcn/gzip.cc +--- octave-4.2.0/libinterp/dldfcn/gzip.cc.gzip 2016-11-13 08:16:10.000000000 -0700 ++++ octave-4.2.0/libinterp/dldfcn/gzip.cc 2016-12-08 13:23:56.325297196 -0700 +@@ -449,14 +449,15 @@ namespace octave + { + X::zip (path, dest_path); + } +- catch (...) ++ catch ( const std::exception & ex ) + { ++ warning ("gzip: zip threw exception %s", ex.what()); + // Error "handling" is not including filename on the output list. + // Also remove created file which maybe was not even created + // in the first place. Note that it is possible for the file + // to exist in the first place and for X::zip to not have + // clobber it yet but we remove it anyway by design. +- octave::sys::unlink (dest_path); ++ //octave::sys::unlink (dest_path); + return; + } + dest_paths.push_front (dest_path); diff --git a/octave.spec b/octave.spec index 042da02..7bf6f66 100644 --- a/octave.spec +++ b/octave.spec @@ -14,7 +14,7 @@ Name: octave Epoch: 6 Version: 4.2.0 -Release: 7%{?rcver:.rc%{rcver}}%{?dist} +Release: 8%{?rcver:.rc%{rcver}}%{?dist} Summary: A high-level language for numerical computations Group: Applications/Engineering License: GPLv3+ @@ -33,6 +33,8 @@ Patch1: octave-implicit.patch # Remove project_group from appdata.xml file # https://bugzilla.redhat.com/show_bug.cgi?id=1293561 Patch2: octave-appdata.patch +# Do not have gzip delete target file, emit warning message +Patch3: octave-gzip.patch # Add needed #include to bring in gnulib Patch4: octave-gnulib.patch @@ -166,7 +168,6 @@ Group: Development/Libraries Requires: %{name} = %{epoch}:%{version}-%{release} Requires: readline-devel fftw-devel hdf5-devel zlib-devel Requires: atlas-devel gcc-c++ gcc-gfortran -Requires: strace %description devel The octave-devel package contains files needed for developing @@ -185,6 +186,7 @@ This package contains documentation for Octave. %setup -q -n %{name}-%{version}%{?rctag} %patch1 -p1 -b .implicit %patch2 -p1 -b .appdata +%patch3 -p1 -b .gzip %patch4 -p1 -b .gnulib # __osmesa_print__ test is triggering a crash in libgcc, disable it # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78409 @@ -201,6 +203,11 @@ find -name *.cc -exec chmod 644 {} \; # Remove unused fftpack sed -i -e '/fftpack/d' liboctave/cruft/module.mk rm -r liboctave/cruft/fftpack + +# libinterp/dldfcn/__osmesa_print__.cc-tst is segfaulting +# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78409 +sed -i -e '/^%/d' libinterp/dldfcn/__osmesa_print__.cc scripts/plot/util/__pltopt__.m + autoreconf -i %build @@ -423,7 +430,12 @@ fi %{_pkgdocdir}/refcard*.pdf %changelog -* Thu Dec 07 2016 Orion Poplawski - 6:4.2.0-7 +* Thu Dec 08 2016 Orion Poplawski - 6:4.2.0-8 +- Add patch to prevent gzip from deleting target file, instead emit warning +- Drop debug code +- Disable segfaulting osmesa_print and pltopt tests + +* Thu Dec 08 2016 Orion Poplawski - 6:4.2.0-7 - Fix version option * Wed Dec 07 2016 Orion Poplawski - 6:4.2.0-6