rpms/python-sqlalchemy0.3/devel README.fedora, NONE, 1.1 python-sqlalchemy0.3.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2

Toshio Ernie Kuratomi (toshio) fedora-extras-commits at redhat.com
Fri Oct 5 23:48:35 UTC 2007


Author: toshio

Update of /cvs/pkgs/rpms/python-sqlalchemy0.3/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv29396

Modified Files:
	.cvsignore sources 
Added Files:
	README.fedora python-sqlalchemy0.3.spec 
Log Message:
* Import python-sqlalchemy0.3.



--- NEW FILE README.fedora ---
==============
SQLAlchemy 0.3
==============

SQLAlchemy 0.3 for Fedora is being provided so that apps written for
TurboGears 1.0.x and SQLAlchemy 0.3 can continue to run.  It relies on eggs
to enable multiple versions to be installed.

If you are using SQLAlchemy via TurboGears, everything should work out of the
box for new projects quickstarted with the Fedora 8 packages.  Older projects
will need a small adjustment to run correctly.  In your project's start-APP.py
script you need to change the commands that import TurboGears from this::

  import pkg_resources
  pkg_resources.require('TurboGears')

to this::

  __requires__ = 'TurboGears'
  import pkg_resources

with the packages provided by Fedora 8+.

If you are using SQLAlchemy via your own code and absolutely must use the 0.3
version rather than 0.4, you will need to do one of the following to make it
work in your code:

1) Manually change your python path to place the egg directory before
   site-packages.  Note that if you do it this way you will either have to
   change your code whenever a new version comes out (for instance, if a
   bugfix release, SQLAlchemy-0.3.11, is released.)  The codewould look
   something like this::

     import sys, os, distutils
     compatSAPath = os.path.join(
            distutils.sysconfig.get_python_lib(), 'SQLAlchemy-0.3.10-py2.5.egg')
     sys.path.insert(0, compatSAPath)
     import sqlalchemy

2) Use setuptools and entrypoints. To do this you have a function in a python
   module that is your main function.  You define this as an entry point in
   setup.py.  For instance, if you wanted your script to be called
   "nifty-foo" and the entry point was the main() function in the module
   nifty.foo, you would use this in setup.py::

     # List the versions of SQLAlhcemy that will work
     install_requires = [
        'SQLAlchemy >= 0.3,<0.4alpha'
        ]
     # Add the information necessary to create the script that requires
     # the SQLAlchemy version
     setup (
        name='Nifty',
        version='1.0',
        entry_points = '''
          [console_scripts]
          nifty-foo = nifty.foo:main
        ''',
     [...]

   When you use setup.py to install this script it will create a script that
   looks like this::
      
      #!/usr/bin/python
      __requires__ = 'Nifty==1.0'
      import sys
      from pkg_resources import load_entry_point

      sys.exit(
        load_entry_point('Nifty==1.0', 'console_scripts', 'nifty-foo')()
      )

   The script in turn, references the egg metadata for your module which
   lists the dependency from Nifty to SQLAlchemy>=0.3, < 0.4alpha.

Note that although there may be other methods of making this work in some
circumstances, these are the only methods that the setuptools author and
we are able to say will work in all circumstances in this environment.  Other
methods may not work reliably in some versions of setuptools.


--- NEW FILE python-sqlalchemy0.3.spec ---
%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
%{!?pyver: %define pyver %(%{__python} -c "import sys ; print sys.version[:3]")}

%define srcname SQLAlchemy

Name:           python-sqlalchemy0.3
Version:        0.3.10
Release:        4%{?dist}
Summary:        Modular and flexible ORM library for python

Group:          Development/Libraries
License:        MIT
URL:            http://www.sqlalchemy.org/
Source0:        http://downloads.sourceforge.net/sqlalchemy/%{srcname}-%{version}.tar.gz
Source1:        README.fedora
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

BuildArch:      noarch
BuildRequires:  python-devel
BuildRequires:  python-setuptools >= 0.6c3
%if 0%{?fedora} >= 8
BuildRequires: python-setuptools-devel
%else
BuildRequires: python-setuptools
%endif
# Require setuptools because the end user must have pkg_resources in order to
# use this.
Requires:       python-setuptools >= 0.6c3

%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 contains compatibility modules for the 0.3 version of SQLAlchemy.
If possible, new code should be written against the newest version of the
python-sqlalchemy package.

%prep
%setup -q -n %{srcname}-%{version}


%build
CFLAGS="$RPM_OPT_FLAGS" %{__python} setup.py bdist_egg
cp %{SOURCE1} .

%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT%{python_sitelib}
easy_install -m --prefix $RPM_BUILD_ROOT%{_usr} dist/*.egg
# remove unnecessary scripts for building documentation
rm -rf doc/build

%check
export PYTHONPATH=./test
%{__python} test/alltests.py

%clean
rm -rf $RPM_BUILD_ROOT


%files
%defattr(0644,root,root,0755)
%doc README LICENSE PKG-INFO CHANGES doc examples README.fedora
%{python_sitelib}/%{srcname}*egg

%changelog
* Fri Aug 24 2007 Toshio Kuratomi <a.badger at gmail.com> - 0.3.10-4
- Run test suite.
- Workaround setuptools but where all files extracted from an egg are
executable.

* Fri Aug 24 2007 Toshio Kuratomi <a.badger at gmail.com> - 0.3.10-3
- Create an 0.3 compatibility package.

* 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

* Tue May 16 2006 Shahms E. King <shahms at shahms.com> 0.1.7-1
- Update to new upstream version
- Point URL to direct link, not sourceforge redirect
- Remove unnecessary document build scripts

* Fri Apr 14 2006 Shahms E. King <shahms at shahms.com> 0.1.6-1
- Initial package


Index: .cvsignore
===================================================================
RCS file: /cvs/pkgs/rpms/python-sqlalchemy0.3/devel/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- .cvsignore	4 Oct 2007 23:34:06 -0000	1.1
+++ .cvsignore	5 Oct 2007 23:48:03 -0000	1.2
@@ -0,0 +1 @@
+SQLAlchemy-0.3.10.tar.gz


Index: sources
===================================================================
RCS file: /cvs/pkgs/rpms/python-sqlalchemy0.3/devel/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- sources	4 Oct 2007 23:34:06 -0000	1.1
+++ sources	5 Oct 2007 23:48:03 -0000	1.2
@@ -0,0 +1 @@
+1e91e7430b7ec64d5f5ff51e5a9ddf58  SQLAlchemy-0.3.10.tar.gz




More information about the fedora-extras-commits mailing list