Blob Blame History Raw

# Fedora package review
# http://bugzilla.redhat.com/459705

%define _with_check -DEIGEN_BUILD_TESTS:BOOL=ON

Name:    eigen2
Summary: A lightweight C++ template library for vector and matrix math
Version: 2.0.3
Release: 1%{?dist}
Group:   System Environment/Libraries
License: GPLv2+ or LGPLv3+
URL:     http://eigen.tuxfamily.org/
%if 0%{?snap:1}
Source0: http://bitbucket.org/eigen/eigen2/get/default.tar.bz2
%else
Source0: http://bitbucket.org/eigen/eigen2/get/%{version}%{?pre:-%{pre}}.tar.bz2
%endif
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch

BuildRequires: cmake
#docs
BuildRequires: doxygen graphviz

#BuildRequires: %{_bindir}/latex
%if 0%{?fedora} > 8
BuildRequires: tex(latex)
%else
BuildRequires: tetex-latex
%endif

%if 0%{?_with_check:1}
BuildRequires: blas-devel
BuildRequires: gsl-devel
# can't use until undefined symbols are fixed: http://bugzilla.redhat.com/475411
%if 0%{?fedora} > 10
BuildRequires: suitesparse-devel
%endif
BuildRequires: qt4-devel
#-- Could NOT find TAUCS  (missing:  TAUCS_INCLUDES TAUCS_LIBRARIES)
#-- Could NOT find SUPERLU  (missing:  SUPERLU_INCLUDES SUPERLU_LIBRARIES)
#-- Could NOT find GOOGLEHASH  (missing:  GOOGLEHASH_INCLUDES)
%endif

%description
%{summary}

%package devel
Summary: A lightweight C++ template library for vector and matrix math
Group:   Development/Libraries
# -devel subpkg only atm, compat with other distros
Provides: %{name} = %{version}-%{release}
%description devel
%{summary}


%prep
%setup -q -n eigen2


%build

mkdir -p %{_target_platform}
pushd %{_target_platform}
%{cmake} %{?_with_check}  ..
popd

# when building _with_check, memory usage is quite large, skip
# using smp_mflags in that case
make %{!?_with_check:%{?_smp_mflags}} -C %{_target_platform}

# docs
doxygen


%install
rm -rf %{buildroot}

make install DESTDIR=%{buildroot} -C %{_target_platform}


%check
%if 0%{?_with_check:1}
( cd %{_target_platform}/test; ctest )
%endif


%clean 
rm -rf %{buildroot}


%files devel
%defattr(-,root,root,-)
%doc COPYING COPYING.LESSER
%doc html/
%{_includedir}/eigen2/


%changelog
* Mon Jun 22 2009 Rex Dieter <rdieter@fedoraproject.org> 2.0.3-1
- eigen-2.0.3

* Tue May 19 2009 Rex Dieter <rdieter@fedoraproject.org> 2.0.1-1.1
- disable build tests (temporarily) to bootstrap secondary archs (s309)

* Mon Apr 15 2009 Rex Dieter <rdieter@fedoraproject.org> 2.0.1-1
- eigen-2.0.1

* Tue Feb 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild

* Mon Feb 02 2009 Rex Dieter <rdieter@fedoraproject.org> 2.0-1
- eigen-2.0.0 (final)

* Wed Jan 28 2009 Rex Dieter <rdieter@fedoraproject.org> 2.0-0.10.rc1
- eigen-2.0-rc1

* Thu Jan 22 2009 Rex Dieter <rdieter@fedoraproject.org> 2.0-0.9.beta6
- eigen-2.0-beta6

* Fri Jan 09 2009 Rex Dieter <rdieter@fedoraproject.org> 2.0-0.8.20090109svn
- eigen2-20090109svn snapshot

* Tue Jan 06 2009 Rex Dieter <rdieter@fedoraproject.org> 2.0-0.7.beta5
- eigen-2.0-beta5

* Sun Jan 04 2009 Rex Dieter <rdieter@fedoraproject.org> 2.0-0.6.beta4
- eigen-2.0-beta4

* Mon Dec 08 2008 Rex Dieter <rdieter@fedoraproject.org> 2.0-0.5.beta2
- eigen-2.0-beta2
- (re)enable buildtime test

* Mon Sep 22 2008 Rex Dieter <rdieter@fedoraproject.org> 2.0-0.4.beta1
- eigen-2.0-beta1

* Mon Aug 25 2008 Rex Dieter <rdieter@fedoraproject.org> 2.0-0.3.alpha7
- disable buildtime tests, which tickle gcc bugs

* Fri Aug 22 2008 Rex Dieter <rdieter@fedoraproject.org> 2.0-0.2.alpha7
- add working %%check

* Wed Aug 20 2008 Rex Dieter <rdieter@fedoraproject.org> 2.0-0.1.alpha7
- eigen-2.0-alpha7