Blame python-egenix-mx-base.spec

46f5562
Summary:  A collection of Python software tools
46f5562
Name: python-egenix-mx-base
46f5562
Version: 3.2.4
85fc5cf
Release: 2%{?dist}
46f5562
URL: http://www.egenix.com/products/python/mxBase/
46f5562
Source0: http://downloads.egenix.com/python/egenix-mx-base-%{version}.tar.gz
46f5562
License: eGenix
46f5562
Group: Development/Libraries
46f5562
BuildRequires: Distutils
46f5562
BuildRequires: python2-devel >= 2.7
46f5562
46f5562
# For name change from mx to python-mx
46f5562
Provides: mx = %{version}-%{release}
85fc5cf
Obsoletes: mx < %{version}-%{release}
46f5562
46f5562
# Install to platform lib directory
46f5562
Patch1: mx-3.1.1-lib64.patch
46f5562
46f5562
# we don't want to provide private python extension libs
46f5562
%{?filter_setup:
46f5562
%filter_provides_in %{python_sitearch}/.*\.so$
46f5562
%filter_setup
46f5562
}
46f5562
46f5562
%description
46f5562
The mx extensions for Python are a collection of Python software tools
46f5562
which enhance Python's usability in many areas.
46f5562
46f5562
%package devel
46f5562
Summary: Development files for %{name}
46f5562
Group: Development/Libraries
46f5562
Requires: %{name}%{?_isa} = %{version}-%{release}
46f5562
Provides: mx-devel = %{version}-%{release}
46f5562
Obsoletes: mx-devel < 3.2.3-2
46f5562
46f5562
%description devel
46f5562
Development files for %{name}
46f5562
46f5562
%package doc
46f5562
Summary: Documentation for %{name}
46f5562
Group: Documentation
46f5562
46f5562
%description doc
46f5562
The mx extensions for Python are a collection of Python software tools
46f5562
which enhance Python's usability in many areas. This package contains
46f5562
the documentation.
46f5562
46f5562
%prep
46f5562
%setup -q -n egenix-mx-base-%{version}
46f5562
%patch1 -p1 -b .lib64
46f5562
46f5562
# alter /usr/local/bin/python
46f5562
find mx/ -name "*.py" -exec sed -i -e 's:^#!.*python:#!%{_bindir}/python:' {} \;
46f5562
46f5562
# These just have test cases and aren't meant to be run
46f5562
for file in mx/Log.py mx/BeeBase/FileLock.py mx/BeeBase/mxBeeBase/testernesto.py \
46f5562
        mx/Misc/OrderedMapping.py mx/Misc/Daemon.py mx/Misc/FileLock.py; do
46f5562
    sed -i -e '/^#!.*python/d' ${file}
46f5562
done
46f5562
46f5562
%build
46f5562
CFLAGS="%{optflags}" python setup.py build
46f5562
46f5562
%install
46f5562
python setup.py install --skip-build --root=%{buildroot}
46f5562
46f5562
pushd %{buildroot}%{python_sitearch}
46f5562
for I in `find . -name '*.h'`; do
46f5562
    mkdir -p %{buildroot}%{_includedir}/`dirname $I`
46f5562
    mv $I %{buildroot}%{_includedir}/`dirname $I`
46f5562
done
46f5562
popd
46f5562
46f5562
# Examples, tests, benchmarks
46f5562
BASEDIR=%{buildroot}%{python_sitearch}
46f5562
mkdir examples
46f5562
mv ${BASEDIR}/mx/TextTools/mxTextTools/testkj.p* examples/
46f5562
mv ${BASEDIR}/mx/Stack/stackbench.p* examples/
46f5562
mv ${BASEDIR}/mx/Queue/queuebench.p* examples/
46f5562
mv ${BASEDIR}/mx/DateTime/mxDateTime/test.p* examples/
46f5562
# This is a utility.  If it's deemed useful to the general public it should
46f5562
# be installed in %{_bindir} instead of examples
46f5562
mv ${BASEDIR}/mx/BeeBase/showBeeDict.p* examples/
46f5562
46f5562
# These files are documentation, and are in a bad location
46f5562
mkdir docs
46f5562
mv -f ${BASEDIR}/mx/{LICENSE,COPYRIGHT} docs/
46f5562
rm -rf ${BASEDIR}/mx/Doc
46f5562
DESTDIR=`pwd`/docs
46f5562
pushd ${BASEDIR}/mx
46f5562
cp -pr --parents */Doc/* ${DESTDIR}/
46f5562
cp -pr --parents */Examples/* ${DESTDIR}/
46f5562
popd
46f5562
46f5562
# Cleanup
46f5562
rm -rf ${BASEDIR}/mx/*/Doc/
46f5562
rm -rf ${BASEDIR}/mx/*/Examples
46f5562
rm -rf docs/*/Examples/*.pyc
46f5562
rm -rf docs/*/Examples/*.pyo
46f5562
rm -rf examples/*.pyc
46f5562
rm -rf examples/*.pyo
46f5562
46f5562
# Fixup permissions
46f5562
find %{buildroot}%{python_sitearch}/mx/ -name \*.so -exec chmod 755 {} \;
46f5562
46f5562
%files 
46f5562
%doc COPYRIGHT LICENSE README
46f5562
%{python_sitearch}/mx/
46f5562
%{python_sitearch}/egenix_mx_base*.egg-info
46f5562
46f5562
%files devel
46f5562
%{_includedir}/mx/
46f5562
46f5562
%files doc
46f5562
%doc docs/*
46f5562
46f5562
%changelog
85fc5cf
* Thu Jan 10 2013 Nils Philippsen <nils@redhat.com> 3.2.4-2
85fc5cf
- ensure updated mx packages are obsoleted
85fc5cf
46f5562
* Fri Aug 03 2012 Brian C. Lane <bcl@redhat.com> 3.2.4-1
46f5562
- Changed package name to python-egenix-mx-base (#726841)
46f5562
- cleaned up spec file
46f5562
46f5562
* Fri Jul 29 2011 Brian C. Lane <bcl@redhat.com> - 3.2.0-2
46f5562
- Changing package name to python-mx
46f5562
46f5562
* Fri Jul 29 2011 Brian C. Lane <bcl@redhat.com> - 3.2.0-1
46f5562
- Upstream v3.2.0
46f5562
- Removed long year patch, now in upstream
46f5562
- Support for Python 2.3 dropped
46f5562
46f5562
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.1.1-7
46f5562
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
46f5562
46f5562
* Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 3.1.1-6
46f5562
- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
46f5562
46f5562
* Sat Jul 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.1.1-5
46f5562
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
46f5562
46f5562
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.1.1-4
46f5562
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
46f5562
46f5562
* Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 3.1.1-3
46f5562
- Rebuild for Python 2.6
46f5562
46f5562
* Mon Sep 15 2008 Toshio Kuratomi <toshio@fedoraproject.org> 3.1.1-2
46f5562
- Restore debug package
46f5562
- Clean up the python site-packages handling
46f5562
- Clean up handling of documentation, examples, scripts
46f5562
46f5562
* Mon Sep 15 2008 Paul F. Johnson <paul@all-the-johnsons.co.uk> 3.1.1-1
46f5562
- bump to newest release
46f5562
- patch fixes
46f5562
- spec file fixes
46f5562
- branch new devel sub package
46f5562
- fixes to permissions
46f5562
- removed debug-package (empty)
46f5562
46f5562
* Thu Dec  7 2006 Jeremy Katz <katzj@redhat.com> - 2.0.6-3
46f5562
- rebuild against python 2.5
46f5562
46f5562
* Wed Jul 12 2006 Jesse Keating <jkeating@redhat.com> - 2.0.6-2.2.2
46f5562
- rebuild
46f5562
46f5562
* Fri Feb 10 2006 Jesse Keating <jkeating@redhat.com> - 2.0.6-2.2.1
46f5562
- bump again for double-long bug on ppc(64)
46f5562
46f5562
* Tue Feb 07 2006 Jesse Keating <jkeating@redhat.com> - 2.0.6-2.2
46f5562
- rebuilt for new gcc4.1 snapshot and glibc changes
46f5562
46f5562
* Fri Dec 09 2005 Jesse Keating <jkeating@redhat.com>
46f5562
- rebuilt
46f5562
46f5562
* Mon Mar 14 2005 Mihai Ibanescu <misa@redhat.com> 2.0.6-2
46f5562
- Rebuilt
46f5562
46f5562
* Wed Feb 02 2005 Elliot Lee <sopwith@redhat.com> 2.0.6-1
46f5562
- Rebuild with python 2.4
46f5562
46f5562
* Tue Jun 15 2004 Elliot Lee <sopwith@redhat.com>
46f5562
- rebuilt
46f5562
46f5562
* Tue Mar 02 2004 Elliot Lee <sopwith@redhat.com>
46f5562
- rebuilt
46f5562
46f5562
* Fri Feb 13 2004 Elliot Lee <sopwith@redhat.com>
46f5562
- rebuilt
46f5562
46f5562
* Sun Nov 23 2003 Florian La Roche <Florian.LaRoche@redhat.de>
46f5562
- update to 2.0.5
46f5562
- recompile with python 2.3
46f5562
46f5562
* Wed Jun 04 2003 Elliot Lee <sopwith@redhat.com>
46f5562
- rebuilt
46f5562
46f5562
* Wed Jan 22 2003 Tim Powers <timp@redhat.com>
46f5562
- rebuilt
46f5562
46f5562
* Wed Dec 11 2002 Tim Powers <timp@redhat.com> 2.0.3-7
46f5562
- lib64'ize
46f5562
46f5562
* Tue Aug 06 2002 Elliot Lee <sopwith@redhat.com> 2.0.3-6
46f5562
- Provide mx2 dep
46f5562
46f5562
* Fri Jun 21 2002 Tim Powers <timp@redhat.com>
46f5562
- automated rebuild
46f5562
46f5562
* Wed May 29 2002 Trond Eivind Glomsrød <teg@redhat.com> 2.0.3-4
46f5562
- Make it require python >= 2.2, < 2.3
46f5562
46f5562
* Sun May 26 2002 Tim Powers <timp@redhat.com>
46f5562
- automated rebuild
46f5562
46f5562
* Thu May 23 2002 Trond Eivind Glomsrød <teg@redhat.com> 2.0.3-2
46f5562
- Move to python 2.2
46f5562
46f5562
* Wed Mar 13 2002 Trond Eivind Glomsrød <teg@redhat.com> 2.0.3-1
46f5562
- 2.0.3
46f5562
46f5562
* Wed Feb 27 2002 Trond Eivind Glomsrød <teg@redhat.com> 2.0.2-5
46f5562
- Rebuild (and no, it wasn't broken. It just used /usr/bin/python
46f5562
  as the version to build for)
46f5562
46f5562
* Mon Jan 21 2002 Elliot Lee <sopwith@redhat.com> 2.0.2-4
46f5562
- Remove pyver autodetection (it's broken!) and install header files
46f5562
46f5562
* Wed Jan 09 2002 Tim Powers <timp@redhat.com>
46f5562
- automated rebuild
46f5562
46f5562
* Mon Oct  1 2001 Trond Eivind Glomsrød <teg@redhat.com> 2.0.2-2
46f5562
- detect python version when building
46f5562
- 64bit fix mxDateTime
46f5562
46f5562
* Fri Sep 14 2001 Trond Eivind Glomsrød <teg@redhat.com> 2.0.2-1
46f5562
- 2.0.2
46f5562
- Build for Python 2.2
46f5562
46f5562
* Tue Jun 19 2001 Trond Eivind Glomsrød <teg@redhat.com>
46f5562
- Initial build. Needed for python DB API