%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} %define srcname sqlalchemy-migrate Name: python-migrate Version: 0.4.4 Release: 2%{?dist} Summary: Schema migration tools for SQLAlchemy Group: Development/Languages License: MIT URL: http://code.google.com/p/sqlalchemy-migrate/ Source0: http://sqlalchemy-migrate.googlecode.com/files/%{srcname}-%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch BuildRequires: python-devel BuildRequires: python-setuptools-devel BuildRequires: py BuildRequires: python-sqlalchemy >= 0.3.10 # For running the tests BuildRequires: python-sqlite2 Requires: python-sqlalchemy >= 0.3.10 %description Schema migration tools for SQLAlchemy designed to support an agile approach to database design and make it easier to keep development and production databases in sync as schema changes are required. It allows you to manage atabase change sets and database repository versioning. %prep %setup -q -n %{srcname}-%{version} %build %{__python} setup.py build %install %{__rm} -rf %{buildroot} %{__python} setup.py install --skip-build --root %{buildroot} %clean %{__rm} -rf %{buildroot} %check echo "sqlite:///__tmp__" > test_db.cfg # py.test returns 0 on failure. Also, some tests require that the library is already installed. PYTHONPATH=%{buildroot}%{python_sitelib} py.test -x | grep -v "failed in" %files %defattr(-,root,root,-) %doc README CHANGELOG docs/ %{_bindir}/migrate %{python_sitelib}/* %changelog * Sat Jul 05 2007 Ricky Zhou 0.4.4-2 - Add BuildRequires on python-setuptools-devel. - Add Requires and BuildRequires on SQLAlchemy. - Add check section using python-sqlite2. * Sat Jun 21 2007 Toshio Kuratomi 0.4.4-1 - Initial Fedora Build.