Update to 3.4.2.
This commit is contained in:
commit
6617c32387
|
@ -6,7 +6,7 @@
|
|||
# Octave Package Directories
|
||||
%octshareprefix %{_datadir}/octave
|
||||
%octprefix %{octshareprefix}/packages
|
||||
%octarchprefix %{_libexecdir}/octave/packages
|
||||
%octarchprefix %{_libdir}/octave/packages
|
||||
%octpkgdir %{octprefix}/%{octpkg}-%{version}
|
||||
%octpkglibdir %{octarchprefix}/%{octpkg}-%{version}
|
||||
|
||||
|
@ -14,7 +14,7 @@
|
|||
%octave_cmd() octave -H -q --no-site-file --eval "%*";
|
||||
|
||||
# Build Source0 into a package tar file in a temporary location
|
||||
%octave_pkg_build %octave_cmd pkg build '-verbose' %{_tmppath}/%{name}-%{version}-%{release}.%{_arch} %SOURCE0
|
||||
%octave_pkg_build %octave_cmd pkg build '-verbose' %{_tmppath}/%{name}-%{version}-%{release}.%{_arch} %{_builddir}/%{buildsubdir}
|
||||
|
||||
# Install a package. We use the octave pkg install command to install the
|
||||
# built package into the buildroot. We also put a note to prevent the root
|
||||
|
@ -34,7 +34,7 @@ echo "endfunction" >> %{buildroot}%{octpkgdir}/packinfo/on_uninstall.m \
|
|||
|
||||
# preun script - we need to remove our uninstall protection and perhaps
|
||||
# run the package's own uninstall script.
|
||||
%_octave_pkg_preun \
|
||||
%octave_pkg_preun \
|
||||
rm %{octpkgdir}/packinfo/on_uninstall.m \
|
||||
if [ -e %{octpkgdir}/packinfo/on_uninstall.m.orig ]; then \
|
||||
mv %{octpkgdir}/packinfo/on_uninstall.m.orig %{octpkgdir}/packinfo/on_uninstall.m \
|
||||
|
|
|
@ -0,0 +1,41 @@
|
|||
--- octave-3.4.0/scripts/pkg/pkg.m.pkgbuilddir 2011-02-08 03:00:51.000000000 -0700
|
||||
+++ octave-3.4.0/scripts/pkg/pkg.m 2011-03-18 09:31:24.670165643 -0600
|
||||
@@ -644,7 +644,14 @@
|
||||
for i = 1:length (files)
|
||||
tgz = files{i};
|
||||
|
||||
- if (exist (tgz, "file"))
|
||||
+ ## The filename pointed to an uncompressed package to begin with.
|
||||
+ if (exist (tgz, "dir"))
|
||||
+ if (tgz(1) == '/')
|
||||
+ packdir = tgz;
|
||||
+ else
|
||||
+ packdir = fullfile (pwd(), tgz);
|
||||
+ endif
|
||||
+ elseif (exist (tgz, "file"))
|
||||
## Create a temporary directory.
|
||||
tmpdir = tmpnam ();
|
||||
tmpdirs{end+1} = tmpdir;
|
||||
@@ -671,20 +678,12 @@
|
||||
if (length (dirlist) > 3)
|
||||
error ("bundles of packages are not allowed");
|
||||
endif
|
||||
- endif
|
||||
|
||||
- ## The filename pointed to an uncompressed package to begin with.
|
||||
- if (exist (tgz, "dir"))
|
||||
- dirlist = {".", "..", tgz};
|
||||
+ ## The two first entries of dirlist are "." and "..".
|
||||
+ packdir = fullfile (tmpdir, dirlist{3});
|
||||
endif
|
||||
|
||||
if (exist (tgz, "file") || exist (tgz, "dir"))
|
||||
- ## The two first entries of dirlist are "." and "..".
|
||||
- if (exist (tgz, "file"))
|
||||
- packdir = fullfile (tmpdir, dirlist{3});
|
||||
- else
|
||||
- packdir = fullfile (pwd(), dirlist{3});
|
||||
- endif
|
||||
packdirs{end+1} = packdir;
|
||||
|
||||
## Make sure the package contains necessary files.
|
90
octave.spec
90
octave.spec
|
@ -10,6 +10,9 @@ Group: Applications/Engineering
|
|||
License: GPLv3+
|
||||
Source0: ftp://ftp.gnu.org/gnu/octave/octave-%{version}.tar.bz2
|
||||
Source1: macros.octave
|
||||
# https://savannah.gnu.org/bugs/index.php?32839
|
||||
# Fix building packages from directories
|
||||
Patch2: octave-3.4.0-pkgbuilddir.patch
|
||||
URL: http://www.octave.org
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||
|
||||
|
@ -21,7 +24,7 @@ BuildRequires: readline-devel glibc-devel fftw-devel gperf ghostscript
|
|||
BuildRequires: curl-devel pcre-devel texinfo-tex arpack-devel libX11-devel
|
||||
BuildRequires: suitesparse-devel glpk-devel gnuplot desktop-file-utils
|
||||
BuildRequires: GraphicsMagick-c++-devel fltk-devel ftgl-devel qrupdate-devel
|
||||
BuildRequires: %{_bindir}/dvips
|
||||
BuildRequires: tex(dvips)
|
||||
|
||||
Requires: gnuplot gnuplot-common less info texinfo
|
||||
Requires(post): info
|
||||
|
@ -67,6 +70,7 @@ This package contains documentation for Octave.
|
|||
|
||||
%prep
|
||||
%setup -q
|
||||
%patch2 -p1 -b .pkgbuilddir
|
||||
|
||||
# Check permissions
|
||||
find -name *.cc -exec chmod 644 {} \;
|
||||
|
@ -100,10 +104,10 @@ rm -f %{buildroot}%{_infodir}/dir
|
|||
|
||||
# Make library links
|
||||
mkdir -p %{buildroot}%{_sysconfdir}/ld.so.conf.d
|
||||
echo "%{_libdir}/octave-%{version}" > %{buildroot}%{_sysconfdir}/ld.so.conf.d/octave-%{_arch}.conf
|
||||
echo "%{_libdir}/octave/%{version}" > %{buildroot}%{_sysconfdir}/ld.so.conf.d/octave-%{_arch}.conf
|
||||
|
||||
# Remove RPM_BUILD_ROOT from ls-R files
|
||||
perl -pi -e "s,%{buildroot},," %{buildroot}%{_libexecdir}/%{name}/ls-R
|
||||
perl -pi -e "s,%{buildroot},," %{buildroot}%{_libdir}/%{name}/ls-R
|
||||
perl -pi -e "s,%{buildroot},," %{buildroot}%{_datadir}/%{name}/ls-R
|
||||
# Make sure ls-R exists
|
||||
touch %{buildroot}%{_datadir}/%{name}/ls-R
|
||||
|
@ -116,14 +120,66 @@ desktop-file-install --vendor fedora --remove-category Development --add-categor
|
|||
|
||||
# Create directories for add-on packages
|
||||
HOST_TYPE=`%{buildroot}%{_bindir}/octave-config -p CANONICAL_HOST_TYPE`
|
||||
mkdir -p %{buildroot}%{_libexecdir}/%{name}/site/oct/%{octave_api}/$HOST_TYPE
|
||||
mkdir -p %{buildroot}%{_libexecdir}/%{name}/site/oct/$HOST_TYPE
|
||||
mkdir -p %{buildroot}%{_libdir}/%{name}/site/oct/%{octave_api}/$HOST_TYPE
|
||||
mkdir -p %{buildroot}%{_libdir}/%{name}/site/oct/$HOST_TYPE
|
||||
mkdir -p %{buildroot}%{_datadir}/%{name}/packages
|
||||
mkdir -p %{buildroot}%{_libdir}/%{name}/packages
|
||||
touch %{buildroot}%{_datadir}/%{name}/octave_packages
|
||||
|
||||
# work-around broken pre-linking (bug 524493)
|
||||
install -d %{buildroot}%{_sysconfdir}/prelink.conf.d
|
||||
echo "-b %{_bindir}/octave-%{version}" > %{buildroot}%{_sysconfdir}/prelink.conf.d/octave.conf
|
||||
#install -d %{buildroot}%{_sysconfdir}/prelink.conf.d
|
||||
#echo "-b %{_bindir}/octave-%{version}" > %{buildroot}%{_sysconfdir}/prelink.conf.d/octave.conf
|
||||
|
||||
# Fix multilib installs
|
||||
for include in config defaults oct-conf
|
||||
do
|
||||
mv %{buildroot}%{_includedir}/%{name}-%{version}/%{name}/${include}.h \
|
||||
%{buildroot}%{_includedir}/%{name}-%{version}/%{name}/${include}-%{__isa_bits}.h
|
||||
cat > %{buildroot}%{_includedir}/%{name}-%{version}/%{name}/${include}.h <<EOF
|
||||
#include <bits/wordsize.h>
|
||||
|
||||
#if __WORDSIZE == 32
|
||||
#include "${include}-32.h"
|
||||
#elif __WORDSIZE == 64
|
||||
#include "${include}-64.h"
|
||||
#else
|
||||
#error "Unknown word size"
|
||||
#endif
|
||||
EOF
|
||||
done
|
||||
for script in octave-config-%{version} mkoctfile-%{version}
|
||||
do
|
||||
mv %{buildroot}%{_bindir}/${script} %{buildroot}%{_libdir}/%{name}/%{version}/${script}
|
||||
cat > %{buildroot}%{_bindir}/${script} <<EOF
|
||||
#!/bin/bash
|
||||
ARCH=\$(uname -m)
|
||||
|
||||
case \$ARCH in
|
||||
x86_64 | ia64 | s390x) LIB_DIR=/usr/lib64
|
||||
SECONDARY_LIB_DIR=/usr/lib
|
||||
;;
|
||||
* )
|
||||
LIB_DIR=/usr/lib
|
||||
SECONDARY_LIB_DIR=/usr/lib64
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ ! -x \$LIB_DIR/%{name}/%{version}/${script} ] ; then
|
||||
if [ ! -x \$SECONDARY_LIB_DIR/%{name}/%{version}/${script} ] ; then
|
||||
echo "Error: \$LIB_DIR/%{name}/%{version}/${script} not found"
|
||||
if [ -d \$SECONDARY_LIB_DIR ] ; then
|
||||
echo " and \$SECONDARY_LIB_DIR/%{name}/%{version}/${script} not found"
|
||||
fi
|
||||
exit 1
|
||||
fi
|
||||
LIB_DIR=\$SECONDARY_LIB_DIR
|
||||
fi
|
||||
exec \$LIB_DIR/%{name}/%{version}/${script} "\$@"
|
||||
EOF
|
||||
chmod +x %{buildroot}%{_bindir}/${script}
|
||||
done
|
||||
# remove timestamp from doc-cache
|
||||
sed -i -e '/^# Created by Octave/d' %{buildroot}%{_datadir}/%{name}/%{version}/etc/doc-cache
|
||||
|
||||
# rpm macros
|
||||
mkdir -p %{buildroot}%{_sysconfdir}/rpm
|
||||
|
@ -168,7 +224,7 @@ fi
|
|||
%ghost %{_datadir}/octave/octave_packages
|
||||
%{_datadir}/octave/packages/
|
||||
%{_datadir}/octave/site/
|
||||
%{_sysconfdir}/prelink.conf.d/octave.conf
|
||||
#%{_sysconfdir}/prelink.conf.d/octave.conf
|
||||
|
||||
%files devel
|
||||
%defattr(-,root,root,-)
|
||||
|
@ -188,6 +244,24 @@ fi
|
|||
* Sat Aug 06 2011 Jussi Lehtola <jussilehtola@fedoraproject.org> - 6:3.4.2-1
|
||||
- Update to 6.4.2.
|
||||
|
||||
* Fri May 27 2011 Orion Poplawski <orion[AT]cora.nwra com> - 6:3.4.0-8
|
||||
- Add patch to fix Fl_File_Chooser.H location
|
||||
- Add BR tex(dvips)
|
||||
|
||||
* Thu May 26 2011 Orion Poplawski <orion[AT]cora.nwra com> - 6:3.4.0-7
|
||||
- Rebuild for fltk 1.3.0
|
||||
|
||||
* Tue May 17 2011 Orion Poplawski <orion[AT]cora.nwra com> - 6:3.4.0-6
|
||||
- Rebuild for hdf5 1.8.7
|
||||
|
||||
* Fri Mar 18 2011 Orion Poplawski <orion[AT]cora.nwra com> - 6:3.4.0-5
|
||||
- Use libdir instead of libexecdir
|
||||
- Rename octave_pkg_preun macro
|
||||
- Fix multilib installs
|
||||
- Re-enable prelinking, seems to work
|
||||
- Add patch to enable building packages from directories
|
||||
>>>>>>> c9d48722b5642ad74c3504a69163771eb4b11d9d
|
||||
|
||||
* Wed Feb 23 2011 Orion Poplawski <orion[AT]cora.nwra com> - 6:3.4.0-4
|
||||
- Update rpm macros per FPC comments
|
||||
|
||||
|
|
Loading…
Reference in New Issue