Package python-module-nipy: Specfile

%define oname nipy
Name: python-module-%oname
Version: 0.1.2
Release: alt1.git20110404
Summary: The neuroimaging in python (NIPY) project
License: MIT
Group: Development/Python
Url: http://neuroimaging.scipy.org/
Packager: Eugeny A. Rostovtsev (REAL) <real at altlinux.org>

# git://github.com/nipy/nipy.git
Source: %oname-%version.tar.gz

Requires: %oname-data Mayavi

BuildPreReq: python-devel python-module-nifti python-module-scipy
BuildPreReq: python-module-sympy liblapack-goto-devel
BuildPreReq: /proc gcc-fortran %oname-data libnumpy-devel sympy
BuildPreReq: python-module-sympy dvipng libniftilib-devel
BuildPreReq: python-module-nibabel python-module-Cython
BuildPreReq: python-module-sphinx-devel python-module-Pygments
BuildPreReq: texlive-latex-extra graphviz ghostscript-utils
%setup_python_module %oname

%description
The neuroimaging in python (NIPY) project is an environment for the
analysis of structural and functional neuroimaging data. It currently
has a full system for general linear modeling of functional magnetic
resonance imaging (fMRI).

%package examples
Summary: Examples for neuroimaging in python (NIPY) project
Group: Development/Documentation
Requires: %name = %version-%release

%description examples
The neuroimaging in python (NIPY) project is an environment for the
analysis of structural and functional neuroimaging data. It currently
has a full system for general linear modeling of functional magnetic
resonance imaging (fMRI).

This package contains examples for NIPY.

%package tests
Summary: Tests for neuroimaging in python (NIPY) project
Group: Development/Python
Requires: %name = %version-%release

%description tests
The neuroimaging in python (NIPY) project is an environment for the
analysis of structural and functional neuroimaging data. It currently
has a full system for general linear modeling of functional magnetic
resonance imaging (fMRI).

This package contains tests for NIPY.

%package docs
Summary: Documentation for neuroimaging in python (NIPY) project
Group: Development/Documentation
BuildArch: noarch

%description docs
The neuroimaging in python (NIPY) project is an environment for the
analysis of structural and functional neuroimaging data. It currently
has a full system for general linear modeling of functional magnetic
resonance imaging (fMRI).

This package contains documentation for NIPY.

%package pickles
Summary: Pickles for neuroimaging in python (NIPY) project
Group: Development/Python

%description pickles
The neuroimaging in python (NIPY) project is an environment for the
analysis of structural and functional neuroimaging data. It currently
has a full system for general linear modeling of functional magnetic
resonance imaging (fMRI).

This package contains pickles for NIPY.

%prep
%setup

sed -i 's|@PYVER@|%_python_version|g' doc/Makefile
%prepare_sphinx .

%build
%python_build_debug

%install
%python_install
export PYTHONPATH=%buildroot%python_sitelibdir

mkdir -p ~/.matplotlib
cp %python_sitelibdir/matplotlib/mpl-data/matplotlibrc ~/.matplotlib/
sed -i 's|^\(backend\).*|\1 : PDF|' ~/.matplotlib/matplotlibrc

%make -C doc pickle
#make -C doc html
#make -C doc pdf

install fff2.py %buildroot%python_sitelibdir
cp -fR examples %buildroot%python_sitelibdir/%oname/

#mkdir -p doc/pdf
#for i in $(find doc -name '*.pdf'); do
#	cp -f $i doc/pdf/
#done

cp -fR doc/build/pickle %buildroot%python_sitelibdir/%oname/

%files
%doc LICENSE README THANKS
%_bindir/*
%python_sitelibdir/*
%exclude %python_sitelibdir/%oname/pickle
%exclude %python_sitelibdir/*/examples
%exclude %python_sitelibdir/*/testing
%exclude %python_sitelibdir/*/*/tests
%exclude %python_sitelibdir/*/*/*/tests
#exclude %python_sitelibdir/*/*/*/testing
%exclude %python_sitelibdir/*/*/*/*/tests
%exclude %python_sitelibdir/*/*/*/*/*/tests
%exclude %python_sitelibdir/*/*/*/test

#files docs
#doc doc/build/html
#doc doc/pdf

%files pickles
%dir %python_sitelibdir/%oname
%python_sitelibdir/%oname/pickle

%files examples
%python_sitelibdir/*/examples

%files tests
%python_sitelibdir/*/*/*/test
%python_sitelibdir/*/testing
%python_sitelibdir/*/*/tests
%python_sitelibdir/*/*/*/tests
#python_sitelibdir/*/*/*/testing
%python_sitelibdir/*/*/*/*/tests
%python_sitelibdir/*/*/*/*/*/tests

%changelog
* Sat Apr 09 2011 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 0.1.2-alt1.git20110404
- New snapshot
- Build with GotoBLAS2 instead of ATLAS

* Tue Apr 05 2011 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 0.1.2-alt1.git20101104.2
- Rebuilt with python-module-sphinx-devel

* Sat Mar 26 2011 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 0.1.2-alt1.git20101104.1
- Rebuilt for debuginfo

* Wed Nov 24 2010 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 0.1.2-alt1.git20101104
- New snapshot

* Mon Oct 18 2010 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 0.1.2-alt1.git20100828.2
- Fixed underlinking

* Tue Sep 28 2010 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 0.1.2-alt1.git20100828.1
- Moved all tests into tests package

* Mon Sep 27 2010 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 0.1.2-alt1.git20100828
- New snapshot
- Fixed build of docs

* Tue Jun 15 2010 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 0.1.2-alt1.git20100601
- New snapshot

* Sun Mar 07 2010 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 0.1.2-alt1.bzr20100301
- New snapshot
- Extracted examples and tests into separate packages
- Added docs and pickles packages

* Mon Jan 11 2010 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 0.1.2-alt1.bzr20090924.3
- Rebuilt with new NumPy

* Thu Nov 19 2009 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 0.1.2-alt1.bzr20090924.2
- Rebuilt with python 2.6

* Fri Oct 02 2009 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 0.1.2-alt1.bzr20090924.1
- Added necessary requitements: nipy-data, python2.x(enthought)

* Fri Sep 25 2009 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 0.1.2-alt1.bzr20090924
- Initial build for Sisyphus