[python-sqlalchemy0.8] Initial import (#997966)

Ralph Bean ralph at fedoraproject.org
Fri Aug 30 18:32:15 UTC 2013


commit e4bfa9d3e173d169d2393addc8dd8cc86afc4194
Author: Ralph Bean <rbean at redhat.com>
Date:   Fri Aug 30 14:32:02 2013 -0400

    Initial import (#997966)

 .gitignore                  |    1 +
 README.Fedora               |   57 +++++++
 SQLAlchemy0.8-nose1.1.patch |   28 ++++
 python-sqlalchemy0.8.spec   |  361 +++++++++++++++++++++++++++++++++++++++++++
 sources                     |    1 +
 5 files changed, 448 insertions(+), 0 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e69de29..5ce417e 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/SQLAlchemy-0.8.2.tar.gz
diff --git a/README.Fedora b/README.Fedora
new file mode 100644
index 0000000..99bbe68
--- /dev/null
+++ b/README.Fedora
@@ -0,0 +1,57 @@
+To use version 0.8.2 of python SqlAlchemy it is nescesary
+to explicitly load it so as not to get the system version
+of SQLAlchemy.
+
+The prefered method is to auto adjust the import path as follows
+(which needs a Requires: added for python-setuptools):
+
+>>> import __main__; __main__.__requires__ = __requires__ = []
+>>> __requires__.append('SQLAlchemy >= 0.8.2')
+>>> import pkg_resources; pkg_resources.require(__requires__)
+>>> import webob
+
+Note __requires__ may already be initialised, so if you need to
+update it, you can do something like:
+
+>>> try:
+>>>     from __main__ import __requires__
+>>> except ImportError:
+>>>     import __main__
+>>>     __main__.__requires__ = []
+>>>     __requires__ = __main__.__requires__
+>>> else:
+>>>     if isinstance(basestring, __requires__):
+>>>         __requires__ = [__requires__]
+
+Note also, that if something has already loaded pkg_resources,
+then any changes to __requires__ are ignored. This is the
+case for modules loaded by sphinx-build for example.
+To fix that, one can run a locally modified version of sphinx-build,
+or instead delve a bit deeper into pkg_resources to force it
+to load the parallel installed egg, like:
+
+>>> import sys
+>>> import pkg_resources
+>>> 
+>>> # If there is a conflicting non egg module,
+>>> # i.e. an older standard system module installed,
+>>> # then replace it with this requirement
+>>> def replace_dist(requirement):
+>>>     try:
+>>>         return pkg_resources.require(requirement)
+>>>     except pkg_resources.VersionConflict:
+>>>         e = sys.exc_info()[1]
+>>>         dist=e.args[0]
+>>>         req=e.args[1]
+>>>         if dist.key == req.key and not dist.location.endswith('.egg'):
+>>>             del pkg_resources.working_set.by_key[dist.key]
+>>>             # We assume there is no need to adjust sys.path
+>>>             # and the associated pkg_resources.working_set.entries
+>>>             return pkg_resources.require(requirement)
+>>> 
+>>> print replace_dist("SQLALchemy >= 0.8.2")
+
+One can also resort to manually modifying sys.path with a hardcoded path like:
+
+>>> import sys
+>>> sys.path.insert(0, '/usr/lib64/python2.6/site-packages/SQLAlchemy-0.8.2-py2.6.egg')
diff --git a/SQLAlchemy0.8-nose1.1.patch b/SQLAlchemy0.8-nose1.1.patch
new file mode 100644
index 0000000..a48c034
--- /dev/null
+++ b/SQLAlchemy0.8-nose1.1.patch
@@ -0,0 +1,28 @@
+From 771356899a2f7cd43aeed8856382ebd9fe248e73 Mon Sep 17 00:00:00 2001
+From: Ralph Bean <rbean at redhat.com>
+Date: Fri, 16 Aug 2013 11:32:19 -0400
+Subject: [PATCH] Force latest python-nose.
+
+---
+ sqla_nose.py | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+diff --git a/sqla_nose.py b/sqla_nose.py
+index 3e3540c..d87179f 100755
+--- a/sqla_nose.py
++++ b/sqla_nose.py
+@@ -6,6 +6,11 @@ This script is a front-end to "nosetests" which
+ installs SQLAlchemy's testing plugin into the local environment.
+ 
+ """
++
++import __main__; __main__.__requires__ = __requires__ = []
++__requires__.append('nose >= 1.0')
++import pkg_resources; pkg_resources.require(__requires__)
++
+ import sys
+ import imp
+ import nose
+-- 
+1.8.3.1
+
diff --git a/python-sqlalchemy0.8.spec b/python-sqlalchemy0.8.spec
new file mode 100644
index 0000000..3ded48f
--- /dev/null
+++ b/python-sqlalchemy0.8.spec
@@ -0,0 +1,361 @@
+%if ! (0%{?fedora} > 12 || 0%{?rhel} > 5)
+%{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
+%endif
+
+# python3 not needed for now
+%global with_python3 0
+
+%global srcname SQLAlchemy
+
+Name:           python-sqlalchemy0.8
+Version:        0.8.2
+Release:        4%{?dist}
+Summary:        Modular and flexible ORM library for python
+
+Group:          Development/Libraries
+License:        MIT
+URL:            http://www.sqlalchemy.org/
+Source0:        http://pypi.python.org/packages/source/S/%{srcname}/%{srcname}-%{version}.tar.gz
+Source1:        README.Fedora
+Patch0:         SQLAlchemy0.8-nose1.1.patch
+BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+
+BuildRequires:  python2-devel
+%if 0%{?fedora} && 0%{?fedora} < 13
+BuildRequires:  python-setuptools-devel >= 0.6c3
+%else
+BuildRequires:  python-setuptools
+%endif
+BuildRequires:  python-nose1.1
+BuildRequires:  python-mock
+
+%if 0%{?with_python3}
+BuildRequires:  python3-devel
+BuildRequires:  python3-setuptools
+BuildRequires:  python3-nose1.1
+BuildRequires:  python3-mock
+%endif
+
+%description
+SQLAlchemy is an Object Relational Mappper (ORM) that provides a flexible,
+high-level interface to SQL databases.  Database and domain concepts are
+decoupled, allowing both sides maximum flexibility and power. SQLAlchemy
+provides a powerful mapping layer that can work as automatically or as manually
+as you choose, determining relationships based on foreign keys or letting you
+define the join conditions explicitly, to bridge the gap between database and
+domain.
+
+This package includes the python 2 version of the module.
+
+%if 0%{?with_python3}
+%package -n python3-sqlalchemy0.8
+Summary:        Modular and flexible ORM library for python
+Group:          Development/Libraries
+
+%description -n python3-sqlalchemy0.8
+SQLAlchemy is an Object Relational Mappper (ORM) that provides a flexible,
+high-level interface to SQL databases.  Database and domain concepts are
+decoupled, allowing both sides maximum flexibility and power. SQLAlchemy
+provides a powerful mapping layer that can work as automatically or as manually
+as you choose, determining relationships based on foreign keys or letting you
+define the join conditions explicitly, to bridge the gap between database and
+domain.
+
+This package includes the python 3 version of the module.
+%endif # with_python3
+
+# Filter unnecessary dependencies
+%{?filter_setup:
+%filter_provides_in %{python_sitearch}.*\.so$
+%filter_provides_in %{python3_sitearch}.*\.so$
+%filter_setup
+}
+
+%prep
+%setup -q -n %{srcname}-%{version}
+
+# Delete the first line w/ shebang at the top of this file.
+sed -i '0,/.*/d' lib/sqlalchemy/testing/runner.py
+
+%patch0 -p1 -b .nose1.1
+cp -p %{SOURCE1} .
+
+%if 0%{?with_python3}
+rm -rf %{py3dir}
+cp -a . %{py3dir}
+%endif # with_python3
+
+%build
+CFLAGS="%{optflags}" %{__python} setup.py --with-cextensions build bdist_egg
+
+%if 0%{?with_python3}
+pushd %{py3dir}
+# Convert tests, examples, source to python3
+%{__python3} sa2to3.py --no-diffs -w lib test examples
+# Currently the cextension doesn't work with py3
+CFLAGS="%{optflags}" %{__python3} setup.py build bdist_egg
+popd
+%endif
+
+%install
+rm -rf %{buildroot}
+
+mkdir -p %{buildroot}%{python_sitearch}
+easy_install -m --install-dir %{buildroot}%{python_sitearch} dist/*.egg #TODO what about c-extensions
+find %{buildroot}%{python_sitearch}/SQLAlchemy-%{version}-*.egg/sqlalchemy/ -name '*.py' |
+ xargs chmod 0644
+
+
+%if 0%{?with_python3}
+pushd %{py3dir}
+mkdir -p %{buildroot}%{python3_sitearch}
+easy_install -m --install-dir %{buildroot}%{python3_sitearch} dist/*.egg #TODO what about c-extensions
+find %{buildroot}%{python3_sitearch}/SQLAlchemy-%{version}-*.egg/sqlalchemy/ -name '*.py' |
+ xargs chmod 0644
+popd
+%endif
+
+# remove unnecessary scripts for building documentation
+rm -rf doc/build
+
+%clean
+rm -rf %{buildroot}
+
+%check
+%{__python} ./sqla_nose.py
+
+%if 0%{?with_python3}
+pushd %{py3dir}
+%{__python3} ./sqla_nose.py
+popd
+%endif
+
+
+%files
+%defattr(-,root,root,-)
+%doc README.rst README.Fedora LICENSE PKG-INFO CHANGES doc examples
+%{python_sitearch}/*
+
+%if 0%{?with_python3}
+%files -n python3-sqlalchemy0.8
+%defattr(-,root,root,-)
+%doc README.Fedora LICENSE PKG-INFO doc examples
+%{python3_sitelib}/*
+%endif # with_python3
+
+%changelog
+* Wed Aug 28 2013 Ralph Bean <rbean at redhat.com> - 0.8.2-4
+- Fixed incorrect sed line in %%prep section.
+
+* Mon Aug 26 2013 Ralph Bean <rbean at redhat.com> - 0.8.2-3
+- Fixed bogus date in changelog.
+- Delete first line with shebang and the top of the test runner.
+
+* Fri Aug 16 2013 Ralph Bean <rbean at redhat.com> - 0.8.2-2
+- Updated README.Fedora to include the correct version number.
+- Re-enabled the test suite.
+- Updated nose1.1 patch to use the right paths.
+- Added BuildReq on python-mock
+
+* Tue Aug 13 2013 Ricky Elrod <codeblock at fedoraproject.org> - 0.8.2-1
+- Update to 0.8.2
+
+* Fri Aug 31 2012 Pádraig Brady <P at draigBrady.com> - 0.7.8-1
+- Update to 0.7.8
+
+* Mon Jul 23 2012 Pádraig Brady <P at draigBrady.com> - 0.7.3-7
+- Fix build issues on non python 2.6 systems
+
+* Sat Jul 21 2012 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 0.7.3-6
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
+
+* Sat Jan 14 2012 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 0.7.3-5
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
+
+* Mon Nov 28 2011 Pádraig Brady <P at draigBrady.com> - 0.7.3-4
+- Correctly name the python3 package versions
+- chmod 0644 all py files, as some trigger rpmlint warnings
+
+* Mon Nov 21 2011 Pádraig Brady <P at draigBrady.com> - 0.7.3-3
+- Add README.Fedora
+- Add Build dep and patch to use python-nose1.1
+
+* Fri Nov 18 2011 Pádraig Brady <P at draigBrady.com> - 0.7.3-2
+- Rename to parallel installable version for el6
+
+* Mon Oct 17 2011 Toshio Kuratomi <toshio at fedoraproject.org> - 0.7.3-1
+- Upstream bugfix release
+
+* Mon Aug 1 2011 Toshio Kuratomi <toshio at fedoraproject.org> - 0.7.2-1
+- Upstream bugfix release
+
+* Mon Jun 06 2011 Nils Philippsen <nils at redhat.com> - 0.7.1-1
+- 0.7.1 Upstream release
+- no need to fix examples/dynamic_dict/dynamic_dict.py anymore
+- use sqla_nose.py to fix %%check
+
+* Wed Feb 09 2011 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 0.6.6-2
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
+
+* Mon Jan 17 2011 Toshio Kuratomi <toshio at fedoraproject.org> - 0.6.6-1
+- 0.6.6 Upstream release
+
+* Fri Dec 3 2010 Toshio Kuratomi <toshio at fedoraproject.org> - 0.6.5-1
+- 0.6.5 Upstream release
+
+* Wed Sep 29 2010 Toshio Kuratomi <toshio at fedoraproject.org> - 0.6.4-2
+- Filter out the C extensions from provides
+
+* Tue Sep 07 2010 Luke Macken <lmacken at redhat.com> - 0.6.4-1
+- 0.6.4 upstream release
+
+* Mon Aug 23 2010 Toshio Kuratomi <toshio at fedoraproject.org> - 0.6.3-1
+- 0.6.3 upstream release
+
+* Thu Jul 22 2010 David Malcolm <dmalcolm at redhat.com>
+- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
+
+* Thu Jun 24 2010 Nils Philippsen <nils at redhat.com> - 0.6.1-1
+- 0.6.1 upstream release
+
+* Tue Apr 13 2010 Toshio Kuratomi <toshio at fedoraproject.org> - 0.6-0.4.beta3
+- Build beta3
+
+* Fri Mar 19 2010 Toshio Kuratomi <toshio at fedoraproject.org> - 0.6-0.3.beta2
+- Build beta2 with cextension
+
+* Sun Mar 7 2010 Toshio Kuratomi <toshio at fedoraproject.org> - 0.6-0.2.beta1
+- Build python3 package
+
+* Tue Mar 2 2010 Toshio Kuratomi <toshio at fedoraproject.org> - 0.6-0.1.beta1
+- 0.6 beta1 upstream release
+
+* Tue Feb 2 2010 Toshio Kuratomi <toshio at fedoraproject.org> - 0.5.8-3
+- One last cleanup
+
+* Tue Feb 2 2010 Toshio Kuratomi <toshio at fedoraproject.org> - 0.5.8-2
+- just some cleanups to older styles of building packages.
+
+* Mon Feb 1 2010 Toshio Kuratomi <toshio at fedoraproject.org> - 0.5.8-1
+- Upstream bugfix release 0.5.8
+
+* Fri Aug 14 2009 Toshio Kuratomi <toshio at fedoraproject.org> - 0.5.5-2
+- Upstream bugfix release 0.5.5
+
+* Sun Jul 26 2009 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 0.5.4-2.p2
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
+
+* Fri Jun 12 2009 Toshio Kuratomi <toshio at fedoraproject.org> - 0.5.4-1.p2
+- Upstream bugfix release 0.5.4p2.
+
+* Thu Apr 16 2009 Toshio Kuratomi <toshio at fedoraproject.org> - 0.5.3-1
+- Upstream bugfix release.
+
+* Thu Feb 26 2009 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 0.5.2-2
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
+
+* Wed Feb 11 2009 Toshio Kuratomi <toshio at fedoraproject.org> - 0.5.2-1
+- Update to 0.5.2
+
+* Wed Jan 21 2009 Toshio Kuratomi <toshio at fedoraproject.org> - 0.5.1-1
+- Update to 0.5.1.
+
+* Mon Dec 1 2008 Toshio Kuratomi <toshio at fedoraproject.org> - 0.5-0.1.rc4
+- Update to 0.5.0rc4 which works with the new pysqlite
+- And update test cases to work with the new pysqlite
+
+* Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm at gmail.com> - 0.4.7-2
+- Rebuild for Python 2.6
+
+* Sun Jul 27 2008 Toshio Kuratomi <toshio at fedoraproject.org> 0.4.7-1
+- Update to 0.4.7.
+
+* Sun Jun 1 2008 Toshio Kuratomi <toshio at fedoraproject.org> 0.4.6-1
+- Update to 0.4.6.
+
+* Tue Apr 8 2008 Toshio Kuratomi <toshio at fedoraproject.org> 0.4.5-1
+- Update to 0.4.5.
+
+* Fri Feb 22 2008 Toshio Kuratomi <toshio at fedoraproject.org> 0.4.3-1
+- Update to 0.4.3.
+
+* Tue Dec 11 2007 Toshio Kuratomi <a.badger at gmail.com> 0.4.2-1.p3
+- Update to 0.4.2p3.
+
+* Tue Dec 11 2007 Toshio Kuratomi <a.badger at gmail.com> 0.4.1-1
+- Update to 0.4.1.
+
+* Wed Oct 17 2007 Toshio Kuratomi <a.badger at gmail.com> 0.4.0-1
+- SQLAlchemy-0.4.0 final
+- Run the testsuite
+
+* Wed Oct  3 2007 Luke Macken <lmacken at redhat.com> 0.4.0-0.4.beta6
+- SQLAlchemy-0.4.0beta6
+
+* Tue Sep 11 2007 Toshio Kuratomi <a.badger at gmail.com> - 0.4.0-0.4.beta5
+- Update to 0.4beta5.
+
+* Thu Sep 06 2007 Toshio Kuratomi <a.badger at gmail.com> - 0.4.0-0.4.beta4
+- setuptools has been fixed.
+
+* Fri Aug 31 2007 Toshio Kuratomi <a.badger at gmail.com> - 0.4.0-0.3.beta4
+- setuptools seems to be broken WRT having an active and inactive version
+  of an egg.  Have to make both versions inactive and manually setup a copy
+  that can be started via import. (Necessary for the sqlalchemy0.3 compat
+  package.)
+
+* Tue Aug 28 2007 Toshio Kuratomi <a.badger at gmail.com> - 0.4.0-0.2.beta4
+- Modify setuptools to handle the -devel subpackage split in F-8.
+
+* Mon Aug 27 2007 Toshio Kuratomi <toshio at tiki-lounge.com> - 0.4.0-0.1.beta4
+- Update to 0.4 beta4.
+
+* Tue Jul 24 2007 Toshio Kuratomi <toshio at tiki-lounge.com> - 0.3.10-2
+- Remove python-abi Requires.  This is automatic since FC4+.
+
+* Tue Jul 24 2007 Toshio Kuratomi <toshio at tiki-lounge.com> - 0.3.10-1
+- Update to new upstream version 0.3.10
+
+* Fri Mar 23 2007 Toshio Kuratomi <toshio at tiki-lounge.com> - 0.3.6-1
+- Update to new upstream version 0.3.6
+
+* Sat Mar 10 2007 Toshio Kuratomi <toshio at tiki-lounge.com> - 0.3.5-1
+- Update to new upstream version 0.3.5
+- Simplify the files listing
+
+* Tue Jan 23 2007 Toshio Kuratomi <toshio at tiki-lounge.com> - 0.3.4-2
+- Remember to upload the source tarball to the lookaside cache.
+
+* Tue Jan 23 2007 Toshio Kuratomi <toshio at tiki-lounge.com> - 0.3.4-1
+- Update to new upstream version 0.3.4
+
+* Mon Jan 01 2007 Toshio Kuratomi <toshio at tiki-lounge.com> - 0.3.3-1
+- Update to new upstream version 0.3.3
+
+* Sat Dec 09 2006 Toshio Kuratomi <toshio at tiki-lounge.com> - 0.3.1-2
+- Bump and rebuild for python 2.5 on devel.
+- BuildRequire: python-devel as a header is missing otherwise.
+
+* Fri Nov 24 2006 Toshio Kuratomi <toshio at tiki-lounge.com> - 0.3.1-1
+- Update to new upstream version 0.3.1
+
+* Sat Sep 16 2006 Shahms E. King <shahms at shahms.com> 0.2.7-2
+- Rebuild for FC6
+
+* Thu Aug 17 2006 Shahms E. King <shahms at shahms.com> 0.2.7-1
+- Update to new upstream version
+
+* Fri Aug 11 2006 Shahms E. King <shahms at shahms.com> 0.2.6-2
+- Include, don't ghost .pyo files per new guidelines
+
+* Tue Aug 08 2006 Shahms E. King <shahms at shahms.com> 0.2.6-1
+- Update to new upstream version
+
+* Fri Jul 07 2006 Shahms E. King <shahms at shahms.com> 0.2.4-1
+- Update to new upstream version
+
+* Mon Jun 26 2006 Shahms E. King <shahms at shahms.com> 0.2.3-1
+- Update to new upstream version
+
+* Wed May 31 2006 Shahms E. King <shahms at shahms.com> 0.2.1-1
+- Update to new upstream version
diff --git a/sources b/sources
index e69de29..2bee87b 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+5a33fb43dea93468dbb2a6562ee80b54  SQLAlchemy-0.8.2.tar.gz


More information about the scm-commits mailing list