rpms/python-cherrypy2/devel README.fedora, NONE, 1.1 python-cherrypy-2.3.0-EINTR.patch, NONE, 1.1 python-cherrypy-regression-test.patch, NONE, 1.1 python-cherrypy-tutorial-doc.patch, NONE, 1.1 python-cherrypy2.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
Toshio くらとみ (toshio)
fedora-extras-commits at redhat.com
Mon Jan 21 21:07:05 UTC 2008
Author: toshio
Update of /cvs/pkgs/rpms/python-cherrypy2/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv15690
Modified Files:
.cvsignore sources
Added Files:
README.fedora python-cherrypy-2.3.0-EINTR.patch
python-cherrypy-regression-test.patch
python-cherrypy-tutorial-doc.patch python-cherrypy2.spec
Log Message:
Initial import of python-cherrypy2.
--- NEW FILE README.fedora ---
============
CherryPy 2.x
============
CherryPy 2.x for Fedora is being provided so that apps written for
TurboGears 1.x can continue to run. It relies on eggs to enable multiple
versions to be installed.
If you are using CherryPy via TurboGears, everything should work out of the
box for new projects quickstarted with the Fedora 8 packages. Existing 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 CherryPY via your own code and absolutely must use the 2.x
version rather than 3.x, 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, CherryPy-2.2.2, is released.) The code would look
something like this::
import sys, os, distutils
compatCherryPyPath = os.path.join(
distutils.sysconfig.get_python_lib(), 'CherryPy-2.2.1-py2.5.egg')
sys.path.insert(0, compatCherryPyPath)
import cherrypy
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 CherryPy that will work
install_requires = [
'CherryPy >= 2.2,<3.0alpha'
]
# Add the information necessary to create the script that requires
# the CherryPy 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 CherryPy>=2.2, < 3.0alpha.
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.
python-cherrypy-2.3.0-EINTR.patch:
--- NEW FILE python-cherrypy-2.3.0-EINTR.patch ---
diff -up CherryPy-2.3.0/cherrypy/_cpwsgiserver.py.bak CherryPy-2.3.0/cherrypy/_cpwsgiserver.py
--- CherryPy-2.3.0/cherrypy/_cpwsgiserver.py.bak 2008-01-17 15:57:48.000000000 -0800
+++ CherryPy-2.3.0/cherrypy/_cpwsgiserver.py 2008-01-17 15:59:32.000000000 -0800
@@ -404,6 +404,13 @@ class CherryPyWSGIServer(object):
# accept() by default
return
except socket.error, x:
+ if hasattr(errno, "EINTR") and x.args[0] == errno.EINTR:
+ # I *think* this is right. EINTR should occur when a signal
+ # is received during the accept() call; all docs say retry
+ # the call, and I *think* I'm reading it right that Python
+ # will then go ahead and poll for and handle the signal
+ # elsewhere. See http://www.cherrypy.org/ticket/707.
+ return
msg = x.args[1]
if msg == "Bad file descriptor":
# Our socket was closed
python-cherrypy-regression-test.patch:
--- NEW FILE python-cherrypy-regression-test.patch ---
Index: CherryPy-2.3.0/cherrypy/test/test.py
===================================================================
--- CherryPy-2.3.0.orig/cherrypy/test/test.py
+++ CherryPy-2.3.0/cherrypy/test/test.py
@@ -328,7 +328,6 @@ def run():
success = clp.run()
if clp.interactive:
print
- raw_input('hit enter')
sys.exit(success)
python-cherrypy-tutorial-doc.patch:
--- NEW FILE python-cherrypy-tutorial-doc.patch ---
diff -up CherryPy-2.3.0/setup.py.bak CherryPy-2.3.0/setup.py
--- CherryPy-2.3.0/setup.py.bak 2008-01-17 14:37:31.000000000 -0800
+++ CherryPy-2.3.0/setup.py 2008-01-17 14:38:06.000000000 -0800
@@ -36,23 +36,11 @@ url="http://www.cherrypy.org"
cp_license="BSD"
packages=[
"cherrypy", "cherrypy.lib", "cherrypy.lib.filter",
- "cherrypy.tutorial", "cherrypy.test", "cherrypy.filters",
+ "cherrypy.filters",
]
download_url="http://download.cherrypy.org/cherrypy/2.3.0/"
data_files=[
- ('cherrypy/tutorial',
- [
- 'cherrypy/tutorial/tutorial.conf',
- 'cherrypy/tutorial/README.txt',
- 'cherrypy/tutorial/pdf_file.pdf',
- 'cherrypy/tutorial/custom_error.html',
- ]
- ),
('cherrypy', ['cherrypy/favicon.ico',]),
- ('cherrypy/test', ['cherrypy/test/style.css',]),
- ('cherrypy/test/static', ['cherrypy/test/static/index.html',
- 'cherrypy/test/static/has space.html',
- 'cherrypy/test/static/dirback.jpg',]),
]
###############################################################################
# end arguments for setup
--- NEW FILE python-cherrypy2.spec ---
%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
Name: python-cherrypy2
Version: 2.3.0
Release: 3%{?dist}
Summary: A pythonic, object-oriented web development framework
Group: Development/Libraries
License: BSD
URL: http://www.cherrypy.org/
Source0: http://download.cherrypy.org/cherrypy/%{version}/CherryPy-%{version}.tar.gz
Source1: README.fedora
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Patch0: python-cherrypy-tutorial-doc.patch
Patch1: python-cherrypy-regression-test.patch
Patch2: python-cherrypy-2.3.0-EINTR.patch
BuildArch: noarch
BuildRequires: python-devel
%if 0%{?fedora} >= 8
BuildRequires: python-setuptools-devel
%else
BuildRequires: python-setuptools
%endif
Requires: python-setuptools
%description
CherryPy allows developers to build web applications in much the same way
they would build any other object-oriented Python program. This usually
results in smaller source code developed in less time.
This is a compat package for programs which still need the 2.x branch of
CherryPy.
%prep
%setup -q -n CherryPy-%{version}
%patch0 -p1
%patch1 -p1
%patch2 -p1
%{__sed} -i 's/\r//' CHANGELOG.txt README.txt CHERRYPYTEAM.txt cherrypy/tutorial/README.txt
cp -p %{SOURCE1} .
%build
CFLAGS="$RPM_OPT_FLAGS" %{__python} -c 'import setuptools; execfile("setup.py")' bdist_egg
%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT%{python_sitelib}
easy_install -m --prefix $RPM_BUILD_ROOT%{_usr} dist/*.egg
find $RPM_BUILD_ROOT%{python_sitelib}/ -type f -exec chmod -x \{\} \;
%check
cd cherrypy/test
%{__python} test.py
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root,-)
%doc CHANGELOG.txt CHERRYPYTEAM.txt README.txt README.fedora
%doc cherrypy/tutorial
%{python_sitelib}/*
%changelog
* Wed Jan 16 2008 Toshio Kuratomi <toshio at fedoraproject.org> 2.3.0-3
- Merge changes from current python-cherrypy package.
- Update to 2.3.0.
* Wed Jan 16 2008 Toshio Kuratomi <toshio at fedoraproject.org> 2.2.1-9
- Initial cherrypy2 build.
* Sun Jan 6 2008 Toshio Kuratomi <toshio at fedoraproject.org> 2.2.1-8
- Fix a security bug with a backport of http://www.cherrypy.org/changeset/1775
- Include the egginfo files as well as the python files.
* Sat Nov 3 2007 Luke Macken <lmacken at redhat.com> 2.2.1-7
- Apply backported fix from http://www.cherrypy.org/changeset/1766
to improve CherryPy's SIGSTOP/SIGCONT handling (Bug #364911).
Thanks to Nils Philippsen for the patch.
* Mon Feb 19 2007 Luke Macken <lmacken at redhat.com> 2.2.1-6
- Disable regression tests until we can figure out why they
are dying in mock.
* Sun Dec 10 2006 Luke Macken <lmacken at redhat.com> 2.2.1-5
- Add python-devel to BuildRequires
* Sun Dec 10 2006 Luke Macken <lmacken at redhat.com> 2.2.1-4
- Rebuild for python 2.5
* Mon Sep 18 2006 Luke Macken <lmacken at redhat.com> 2.2.1-3
- Rebuild for FC6
- Include pyo files instead of ghosting them
* Thu Jul 13 2006 Luke Macken <lmacken at redhat.com> 2.2.1-2
- Rebuild
* Thu Jul 13 2006 Luke Macken <lmacken at redhat.com> 2.2.1-1
- Update to 2.2.1
- Remove unnecessary python-abi requirement
* Sat Apr 22 2006 Gijs Hollestelle <gijs at gewis.nl> 2.2.0-1
- Update to 2.2.0
* Wed Feb 22 2006 Gijs Hollestelle <gijs at gewis.nl> 2.1.1-1
- Update to 2.1.1 (Security fix)
* Tue Nov 1 2005 Gijs Hollestelle <gijs at gewis.nl> 2.1.0-1
- Updated to 2.1.0
* Sat May 14 2005 Gijs Hollestelle <gijs at gewis.nl> 2.0.0-2
- Added dist tag
* Sun May 8 2005 Gijs Hollestelle <gijs at gewis.nl> 2.0.0-1
- Updated to 2.0.0 final
- Updated python-cherrypy-tutorial-doc.patch to match new version
* Wed Apr 6 2005 Ignacio Vazquez-Abrams <ivazquez at ivazquez.net> 2.0.0-0.2.b
- Removed CFLAGS
* Wed Mar 23 2005 Gijs Hollestelle <gijs[AT]gewis.nl> 2.0.0-0.1.b
- Initial Fedora Package
Index: .cvsignore
===================================================================
RCS file: /cvs/pkgs/rpms/python-cherrypy2/devel/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- .cvsignore 21 Jan 2008 17:22:10 -0000 1.1
+++ .cvsignore 21 Jan 2008 21:06:31 -0000 1.2
@@ -0,0 +1 @@
+CherryPy-2.3.0.tar.gz
Index: sources
===================================================================
RCS file: /cvs/pkgs/rpms/python-cherrypy2/devel/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- sources 21 Jan 2008 17:22:10 -0000 1.1
+++ sources 21 Jan 2008 21:06:31 -0000 1.2
@@ -0,0 +1 @@
+80ce0f666f2899d4e681432e4061db16 CherryPy-2.3.0.tar.gz
More information about the fedora-extras-commits
mailing list