Fixed EPEL5 build by disabling swig generated octave support and texinfo

This commit is contained in:
mycae 2009-10-11 14:50:03 +00:00
parent 6aad23a72d
commit 9909405bb0
3 changed files with 81 additions and 66 deletions

View File

@ -1,8 +0,0 @@
--- texinfo/Makefile.am 2009-07-01 09:50:10.000000000 -0600
+++ texinfo/Makefile.am.new 2009-09-14 06:10:13.000000000 -0600
@@ -23,4 +23,4 @@
uninstall-local:
rm -rf $(mglpng)
-all-local: html pdf
+all-local: pdf

13
mathgl-notexinfo.patch Normal file
View File

@ -0,0 +1,13 @@
--- Makefile.am 2009-10-11 07:50:30.000000000 -0600
+++ Makefile.am.new 2009-10-11 07:50:45.000000000 -0600
@@ -4,8 +4,8 @@
doctargets =
if USE_DOCS
-SUBDIRS += texinfo
-doctargets += install-html install-pdf
+SUBDIRS +=
+doctargets +=
endif
mgldest=$(DESTDIR)$(datadir)/$(PACKAGE)/fonts

View File

@ -1,7 +1,7 @@
%{!?octave_api:%global octave_api %(octave-config -p API_VERSION || echo 0)}
Name: mathgl
Version: 1.9
Release: 6%{?dist}
Release: 7%{?dist}
Summary: Cross-platform library for making high-quality scientific graphics
Summary(ru): MathGL - это библиотека для осуществления высококачественной визуализации данных
License: GPLv2+
@ -19,8 +19,8 @@ Patch2: %{name}-info.patch
Patch3: %{name}-no-mglwx.patch
#Allow autoconf 2.59 to work
Patch4: %{name}-allow-autoconf-2p59.patch
#disable texi2html (which crashes)
Patch5: %{name}-disable-texinfo-html.patch
#disable texi2html (which crashes, newer texinfo (at least F10+) is OK)
Patch5: %{name}-notexinfo.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@ -62,17 +62,18 @@ developing applications that use %{name}.
Пакет %{name}-devel содержит библиотеки и файлы заголовков необходимые
для разработки приложений с использованием %{name}.
%package doc
Group: Documentation
Summary: HTML documentation and tutorial for the %{name} applications
BuildArch: noarch
BuildRequires: texi2html texinfo-tex
%description doc
This package contains the documentation in the HTML format of the %{name}
package.
#Doc package disabled pedning texi2html update to non-crashing version
#%package doc
#Group: Documentation
#Summary: HTML documentation and tutorial for the %{name} applications
#
#BuildArch: noarch
#BuildRequires: texi2html texinfo-tex
#
#
#%description doc
#This package contains the documentation in the HTML format of the %{name}
#package.
%prep
%setup -q
@ -121,46 +122,52 @@ make install DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p"
#Trash the .la files that get generated anyway (faulty configure? Doesn't appear up without --disable-ltdtl-install)
rm -f $RPM_BUILD_ROOT/%{_libdir}/*.la
#OCTAVE IS DISABLED pending EPEL SWIG support (eg 1.3.39)
#====
#Fix up octave .oct file install
mkdir -p temp-octave
pushd .
cd temp-octave
#Decompress tarballed "oct" file and remove tarball
tar -zxf $RPM_BUILD_ROOT/%{_datadir}/%{name}/octave/%{name}.tar.gz
rm $RPM_BUILD_ROOT/%{_datadir}/%{name}/octave/%{name}.tar.gz
#Copy the .oct file and supporting files to octave packages dir
mkdir -p $RPM_BUILD_ROOT/%{_prefix}/libexec/octave/packages/%{name}-1.9.0/
#Remove empty INDEX file
rm %{name}/INDEX
#We cannot use version macro with octave package search,
# as pkg.m assumes a x.y.z format for packages. Failing
# to do this renders the plugin inoperable
cp -pR %{name}/inst/* $RPM_BUILD_ROOT/%{_prefix}/libexec/octave/packages/%{name}-1.9.0/
#packinfo dir is required, or octave will not find the dir in recursive search
mkdir -p $RPM_BUILD_ROOT/%{_datadir}/octave/packages/%{name}-1.9.0/packinfo
cp -p %{name}/[A-Z]* $RPM_BUILD_ROOT/%{_datadir}/octave/packages/%{name}-1.9.0/packinfo
popd
##Fix up octave .oct file install
#mkdir -p temp-octave
#
#pushd .
#cd temp-octave
##Decompress tarballed "oct" file and remove tarball
#tar -zxf $RPM_BUILD_ROOT/%{_datadir}/%{name}/octave/%{name}.tar.gz
#rm $RPM_BUILD_ROOT/%{_datadir}/%{name}/octave/%{name}.tar.gz
#
##Copy the .oct file and supporting files to octave packages dir
#mkdir -p $RPM_BUILD_ROOT/%{_prefix}/libexec/octave/packages/%{name}-1.9.0/
##Remove empty INDEX file
#rm %{name}/INDEX
#
##We cannot use version macro with octave package search,
## as pkg.m assumes a x.y.z format for packages. Failing
## to do this renders the plugin inoperable
#cp -pR %{name}/inst/* $RPM_BUILD_ROOT/%{_prefix}/libexec/octave/packages/%{name}-1.9.0/
#
##packinfo dir is required, or octave will not find the dir in recursive search
#mkdir -p $RPM_BUILD_ROOT/%{_datadir}/octave/packages/%{name}-1.9.0/packinfo
#cp -p %{name}/[A-Z]* $RPM_BUILD_ROOT/%{_datadir}/octave/packages/%{name}-1.9.0/packinfo
#
#popd
#=====
pushd .
#Lets build a "docs" dir to maintain the dir relationships needed for html files
mkdir -p texinfo/docs
cd texinfo/docs/
cp -pr ../mathgl.html .
cp -pr ../png_static .
cp -pr ../png/ .
#remove zero length faux PNG file
rm -f png/all.png
popd
#DOCS disabled pending texinfo update
#====
#pushd .
##Lets build a "docs" dir to maintain the dir relationships needed for html files
#mkdir -p texinfo/docs
#cd texinfo/docs/
#cp -pr ../mathgl.html .
#cp -pr ../png_static .
#cp -pr ../png/ .
#
##remove zero length faux PNG file
#rm -f png/all.png
#
#popd
#
#====
#remove installed docs, which we are installing via doc macro
rm -rf $RPM_BUILD_ROOT/%{_docdir}/%{name}
@ -192,9 +199,9 @@ rm -rf $RPM_BUILD_ROOT
%{_libdir}/*.so.*
%{_bindir}/mgl*
%{_datadir}/%{name}/
%{_prefix}/libexec/octave/packages/%{name}-1.9.0/
%{_datadir}/octave/packages/%{name}-1.9.0/
%{_infodir}/%{name}.*.gz
#%{_prefix}/libexec/octave/packages/%{name}-1.9.0/
#%{_datadir}/octave/packages/%{name}-1.9.0/
#%{_infodir}/%{name}.*.gz
%files devel
@ -202,11 +209,14 @@ rm -rf $RPM_BUILD_ROOT
%{_includedir}/mgl/
%{_libdir}/*.so
%files doc
%defattr(-,root,root,-)
%doc texinfo/docs/*
#%files doc
#%defattr(-,root,root,-)
#%doc texinfo/docs/*
#
%changelog
* Mon Oct 12 2009 <mycae(a!t)yahoo.com> 1.9-7
- Fixed EPEL 5 build by disabling octave (swig too old) and texi generation
* Mon Sep 14 2009 <mycae(a!t)yahoo.com> 1.9-6
- Add COPYING to doc