[Python-modules-commits] r15762 - in packages/sphinx/trunk/debian (15 files)

jwilk at users.alioth.debian.org jwilk at users.alioth.debian.org
Fri Feb 18 16:16:59 UTC 2011


    Date: Friday, February 18, 2011 @ 16:16:49
  Author: jwilk
Revision: 15762

Merge branch 1.0.

Added:
  packages/sphinx/trunk/debian/patches/autosummary_1.0.6.patch
    (from rev 15761, packages/sphinx/branches/1.0/debian/patches/autosummary_1.0.6.patch)
  packages/sphinx/trunk/debian/patches/unversioned_grammar_pickle.diff
    (from rev 15761, packages/sphinx/branches/1.0/debian/patches/unversioned_grammar_pickle.diff)
  packages/sphinx/trunk/debian/sphinx-build-local.py
    (from rev 15761, packages/sphinx/branches/1.0/debian/sphinx-build-local.py)
Modified:
  packages/sphinx/trunk/debian/changelog
  packages/sphinx/trunk/debian/control
  packages/sphinx/trunk/debian/copyright
  packages/sphinx/trunk/debian/dirs
  packages/sphinx/trunk/debian/patches/move_static_files_outside_site-packages.patch
  packages/sphinx/trunk/debian/patches/series
  packages/sphinx/trunk/debian/rules
  packages/sphinx/trunk/debian/source/format
  packages/sphinx/trunk/debian/sphinx-autogen.1
  packages/sphinx/trunk/debian/sphinx-build.1
Deleted:
  packages/sphinx/trunk/debian/README.source
  packages/sphinx/trunk/debian/preinst

Deleted: packages/sphinx/trunk/debian/README.source
===================================================================
--- packages/sphinx/trunk/debian/README.source	2011-02-18 15:40:57 UTC (rev 15761)
+++ packages/sphinx/trunk/debian/README.source	2011-02-18 16:16:49 UTC (rev 15762)
@@ -1,57 +0,0 @@
-This package uses quilt to manage all modifications to the upstream
-source.  Changes are stored in the source package as diffs in
-debian/patches and applied during the build.
-
-To configure quilt to use debian/patches instead of patches, you want
-either to export QUILT_PATCHES=debian/patches in your environment
-or use this snippet in your ~/.quiltrc:
-
-    for where in ./ ../ ../../ ../../../ ../../../../ ../../../../../; do
-        if [ -e ${where}debian/rules -a -d ${where}debian/patches ]; then
-                export QUILT_PATCHES=debian/patches
-        fi
-    done
-
-To get the fully patched source after unpacking the source package, cd to
-the root level of the source package and run:
-
-    quilt push -a
-
-The last patch listed in debian/patches/series will become the current
-patch.
-
-To add a new set of changes, first run quilt push -a, and then run:
-
-    quilt new <patch>
-
-where <patch> is a descriptive name for the patch, used as the filename in
-debian/patches.  Then, for every file that will be modified by this patch,
-run:
-
-    quilt add <file>
-
-before editing those files.  You must tell quilt with quilt add what files
-will be part of the patch before making changes or quilt will not work
-properly.  After editing the files, run:
-
-    quilt refresh
-
-to save the results as a patch.
-
-Alternately, if you already have an external patch and you just want to
-add it to the build system, run quilt push -a and then:
-
-    quilt import -P <patch> /path/to/patch
-    quilt push -a
-
-(add -p 0 to quilt import if needed). <patch> as above is the filename to
-use in debian/patches.  The last quilt push -a will apply the patch to
-make sure it works properly.
-
-To remove an existing patch from the list of patches that will be applied,
-run:
-
-    quilt delete <patch>
-
-You may need to run quilt pop -a to unapply patches first before running
-this command.

Modified: packages/sphinx/trunk/debian/changelog
===================================================================
--- packages/sphinx/trunk/debian/changelog	2011-02-18 15:40:57 UTC (rev 15761)
+++ packages/sphinx/trunk/debian/changelog	2011-02-18 16:16:49 UTC (rev 15762)
@@ -1,8 +1,51 @@
-sphinx (0.6.6-4) UNRELEASED; urgency=low
+sphinx (1.0.7-3) UNRELEASED; urgency=low
 
+  [ Mikhail Gusarov ]
+  * Change my email address.
+
+  [ Jakub Wilk ]
+  * New upstream release.
+    + Refresh patches.
+    + Revert changes to the autosummary extension introduced in 1.0.7
+      (closes: #611078).
+  * Don't compress objects.inv. Thanks to Michael Fladischer for the bug
+    report.
+  * Remove *.egg-info in the clean target.
+  * Move pycode/Grammar.txt and ext/autosummary/templates/* out of
+    /usr/share/pyshared/ (closes: #609486).
+  * Stop embedding Python version in filename of grammar pickle.
+  * Ship grammar pickle in the binary package (closes: #613412). Thanks to
+    Frederic-Emmanuel Picca for the bug report.
+  * Drop preinst script to remove python-central leftovers; not needed
+    anymore.
+  * New upstream release.
+  * Update and significantly rewrite manual pages (closes: #593623).
+  * Switch to source format 3.0 (quilt).
+    + Drop README.source.
+    + Refresh patches.
+    + Update debian/rules.
+    + Drop quilt from build-depends.
+  * Update debian/copyright.
+  * Use DEP-3 format for patch headers.
+  * Run tests at build time.
+    + Add python-nose, python-simplejson and
+      texlive-{latex-{recommended,extra},fonts-recommended} to
+      Build-Depends-Indep.
+    + Patch test runner to import modules correctly and prevent it from
+      reading files in /usr/share/sphinx.
+    + Update debian/rules.
+  * Bump standards version to 3.9.1 (no changes needed).
+
+  [ Piotr Ożarowski ]
+  * Minimum required versions bumped:
+    - python-jinja2 >= 2.2
+    - python-docutils >= 0.5
+  * move_static_files_outside_site-packages.patch updated
+
+  [ Stefano Rivera ]
   * Improve language and clarify options in manpages.
 
- -- Stefano Rivera <stefano at rivera.za.net>  Mon, 30 Aug 2010 21:48:10 +0200
+ -- Jakub Wilk <jwilk at debian.org>  Thu, 17 Feb 2011 15:26:43 +0100
 
 sphinx (0.6.6-3) unstable; urgency=low
 

Modified: packages/sphinx/trunk/debian/control
===================================================================
--- packages/sphinx/trunk/debian/control	2011-02-18 15:40:57 UTC (rev 15761)
+++ packages/sphinx/trunk/debian/control	2011-02-18 16:16:49 UTC (rev 15762)
@@ -1,18 +1,20 @@
 Source: sphinx
 Section: python
 Priority: optional
-Maintainer: Mikhail Gusarov <dottedmag at dottedmag.net>
+Maintainer: Mikhail Gusarov <dottedmag at debian.org>
 Uploaders: Jakub Wilk <jwilk at debian.org>, Debian Python Modules Team <python-modules-team at lists.alioth.debian.org>
 Homepage: http://sphinx.pocoo.org/
-Build-Depends: debhelper (>= 7), python-all (>= 2.5.4-1~), python-setuptools (>= 0.6c5-1~), quilt (>= 0.40)
-Build-Depends-Indep: python-support (>= 0.6.4), python-docutils, python-pygments (>= 0.8), python-jinja2 (>= 2.1)
+Build-Depends: debhelper (>= 7), python-all (>= 2.5.4-1~), python-setuptools (>= 0.6c5-1~)
+Build-Depends-Indep: python-support (>= 0.6.4), python-docutils, python-pygments (>= 0.8), python-jinja2 (>= 2.1),
+  python-nose, python-simplejson,
+  texlive-latex-recommended, texlive-latex-extra, texlive-fonts-recommended
 Standards-Version: 3.9.1
 Vcs-Svn: svn://svn.debian.org/python-modules/packages/sphinx/trunk/
 Vcs-Browser: http://svn.debian.org/viewsvn/python-modules/packages/sphinx/trunk/
 
 Package: python-sphinx
 Architecture: all
-Depends: ${misc:Depends}, ${python:Depends}, python-docutils, python-pygments (>= 0.8), python-jinja2 (>= 2.1), libjs-jquery
+Depends: ${misc:Depends}, ${python:Depends}, python-docutils (>= 0.5), python-pygments (>= 0.8), python-jinja2 (>= 2.2), libjs-jquery
 Recommends: python (>= 2.6) | python-simplejson, python-imaging
 Suggests: jsmath
 Description: tool for producing documentation for Python projects

Modified: packages/sphinx/trunk/debian/copyright
===================================================================
--- packages/sphinx/trunk/debian/copyright	2011-02-18 15:40:57 UTC (rev 15761)
+++ packages/sphinx/trunk/debian/copyright	2011-02-18 16:16:49 UTC (rev 15762)
@@ -7,27 +7,23 @@
 <armin.ronacher at active-4.com>, Josip Dzolonga, Gerold Penz, Vivake Gupta
 <v at nano.com>
 
-License:
+License for Sphinx
+==================
 
-Copyright (c) 2007-2008 by the respective authors (see AUTHORS file).
+Copyright (c) 2007-2011 by the Sphinx team (see AUTHORS file).
 All rights reserved.
 
 Redistribution and use in source and binary forms, with or without
 modification, are permitted provided that the following conditions are
 met:
 
-    * Redistributions of source code must retain the above copyright
-      notice, this list of conditions and the following disclaimer.
+* Redistributions of source code must retain the above copyright
+  notice, this list of conditions and the following disclaimer.
 
-    * Redistributions in binary form must reproduce the above
-      copyright notice, this list of conditions and the following
-      disclaimer in the documentation and/or other materials provided
-      with the distribution.
+* Redistributions in binary form must reproduce the above copyright
+  notice, this list of conditions and the following disclaimer in the
+  documentation and/or other materials provided with the distribution.
 
-    * The names of the contributors may not be used to endorse or
-      promote products derived from this software without specific
-      prior written permission.
-
 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
 "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
 LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
@@ -40,36 +36,230 @@
 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
-AUTHORS file:
+Licenses for incorporated software
+==================================
 
-The doctools are written and maintained by Georg Brandl <georg at python.org>.
-Substantial parts of the templates and the web application were written by
-Armin Ronacher <armin.ronacher at active-4.com>.
+The pgen2 package, included in this distribution under the name
+sphinx.pycode.pgen2, is available in the Python 2.6 distribution under
+the PSF license agreement for Python:
 
-Other contributors are noted in the :copyright: fields within the docstrings
-of the respective files.
+| Copyright © 2001-2008 Python Software Foundation; All Rights Reserved.
+| 
+| PYTHON SOFTWARE FOUNDATION LICENSE VERSION 2
+| --------------------------------------------
+| 
+| 1. This LICENSE AGREEMENT is between the Python Software Foundation
+|    ("PSF"), and the Individual or Organization ("Licensee") accessing
+|    and otherwise using Python 2.6 software in source or binary form
+|    and its associated documentation.
+| 
+| 2. Subject to the terms and conditions of this License Agreement, PSF
+|    hereby grants Licensee a nonexclusive, royalty-free, world-wide
+|    license to reproduce, analyze, test, perform and/or display
+|    publicly, prepare derivative works, distribute, and otherwise use
+|    Python 2.6 alone or in any derivative version, provided, however,
+|    that PSF's License Agreement and PSF's notice of copyright, i.e.,
+|    "Copyright © 2001-2008 Python Software Foundation; All Rights
+|    Reserved" are retained in Python 2.6 alone or in any derivative
+|    version prepared by Licensee.
+| 
+| 3. In the event Licensee prepares a derivative work that is based on
+|    or incorporates Python 2.6 or any part thereof, and wants to make
+|    the derivative work available to others as provided herein, then
+|    Licensee hereby agrees to include in any such work a brief summary
+|    of the changes made to Python 2.6.
+| 
+| 4. PSF is making Python 2.6 available to Licensee on an "AS IS" basis.
+|    PSF MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR IMPLIED.  BY
+|    WAY OF EXAMPLE, BUT NOT LIMITATION, PSF MAKES NO AND DISCLAIMS ANY
+|    REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS FOR ANY
+|    PARTICULAR PURPOSE OR THAT THE USE OF PYTHON 2.6 WILL NOT INFRINGE
+|    ANY THIRD PARTY RIGHTS.
+| 
+| 5. PSF SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF PYTHON
+|    2.6 FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS
+|    AS A RESULT OF MODIFYING, DISTRIBUTING, OR OTHERWISE USING PYTHON
+|    2.6, OR ANY DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY
+|    THEREOF.
+| 
+| 6. This License Agreement will automatically terminate upon a material
+|    breach of its terms and conditions.
+| 
+| 7. Nothing in this License Agreement shall be deemed to create any
+|    relationship of agency, partnership, or joint venture between PSF
+|    and Licensee.  This License Agreement does not grant permission to
+|    use PSF trademarks or trade name in a trademark sense to endorse or
+|    promote products or services of Licensee, or any third party.
+| 
+| 8. By copying, installing or otherwise using Python 2.6, Licensee
+|    agrees to be bound by the terms and conditions of this License
+|    Agreement.
 
-Many thanks for all contributions!
+The included smartypants module, included as sphinx.util.smartypants,
+is available under the following license:
 
-Copyright strings:
+| SmartyPants license::
+| 
+|     Copyright (c) 2003 John Gruber
+|     (http://daringfireball.net/)
+|     All rights reserved.
+| 
+|     Redistribution and use in source and binary forms, with or without
+|     modification, are permitted provided that the following conditions
+|     are met:
+| 
+|     *   Redistributions of source code must retain the above copyright
+|         notice, this list of conditions and the following disclaimer.
+| 
+|     *   Redistributions in binary form must reproduce the above
+|         copyright notice, this list of conditions and the following
+|         disclaimer in the documentation and/or other materials
+|         provided with the distribution.
+| 
+|     *   Neither the name "SmartyPants" nor the names of its
+|         contributors may be used to endorse or promote products
+|         derived from this software without specific prior written
+|         permission.
+| 
+|     This software is provided by the copyright holders and
+|     contributors "as is" and any express or implied warranties,
+|     including, but not limited to, the implied warranties of
+|     merchantability and fitness for a particular purpose are
+|     disclaimed. In no event shall the copyright owner or contributors
+|     be liable for any direct, indirect, incidental, special,
+|     exemplary, or consequential damages (including, but not limited
+|     to, procurement of substitute goods or services; loss of use,
+|     data, or profits; or business interruption) however caused and on
+|     any theory of liability, whether in contract, strict liability, or
+|     tort (including negligence or otherwise) arising in any way out of
+|     the use of this software, even if advised of the possibility of
+|     such damage.
+| 
+| 
+| smartypants.py license::
+| 
+|     smartypants.py is a derivative work of SmartyPants.
+| 
+|     Redistribution and use in source and binary forms, with or without
+|     modification, are permitted provided that the following conditions
+|     are met:
+| 
+|     *   Redistributions of source code must retain the above copyright
+|         notice, this list of conditions and the following disclaimer.
+| 
+|     *   Redistributions in binary form must reproduce the above
+|         copyright notice, this list of conditions and the following
+|         disclaimer in the documentation and/or other materials
+|         provided with the distribution.
+| 
+|     This software is provided by the copyright holders and
+|     contributors "as is" and any express or implied warranties,
+|     including, but not limited to, the implied warranties of
+|     merchantability and fitness for a particular purpose are
+|     disclaimed. In no event shall the copyright owner or contributors
+|     be liable for any direct, indirect, incidental, special,
+|     exemplary, or consequential damages (including, but not limited
+|     to, procurement of substitute goods or services; loss of use,
+|     data, or profits; or business interruption) however caused and on
+|     any theory of liability, whether in contract, strict liability, or
+|     tort (including negligence or otherwise) arising in any way out of
+|     the use of this software, even if advised of the possibility of
+|     such damage.
 
-spinx/search.py,
-sphinx/web/{feed.py,antispam.py,userdb.py,wsgiutil.py,markup.py,}
+The ElementTree package, included in this distribution in
+test/etree13, is available under the following license:
 
-:copyright: 2007-2008 by Armin Ronacher.
+| The ElementTree toolkit is
+| 
+| Copyright (c) 1999-2007 by Fredrik Lundh
+| 
+| By obtaining, using, and/or copying this software and/or its
+| associated documentation, you agree that you have read, understood,
+| and will comply with the following terms and conditions:
+| 
+| Permission to use, copy, modify, and distribute this software and its
+| associated documentation for any purpose and without fee is hereby
+| granted, provided that the above copyright notice appears in all
+| copies, and that both that copyright notice and this permission notice
+| appear in supporting documentation, and that the name of Secret Labs
+| AB or the author not be used in advertising or publicity pertaining to
+| distribution of the software without specific, written prior
+| permission.
+| 
+| SECRET LABS AB AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO
+| THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANT- ABILITY
+| AND FITNESS.  IN NO EVENT SHALL SECRET LABS AB OR THE AUTHOR BE LIABLE
+| FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+| WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+| ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
+| OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
 
-sphinx/ext/coverage.py
+The included JQuery JavaScript library is available under the MIT
+license:
 
-:copyright: 2007 by Josip Dzolonga, Georg Brandl.
+| Copyright (c) 2008 John Resig, http://jquery.com/
+| 
+| Permission is hereby granted, free of charge, to any person obtaining
+| a copy of this software and associated documentation files (the
+| "Software"), to deal in the Software without restriction, including
+| without limitation the rights to use, copy, modify, merge, publish,
+| distribute, sublicense, and/or sell copies of the Software, and to
+| permit persons to whom the Software is furnished to do so, subject to
+| the following conditions:
+| 
+| The above copyright notice and this permission notice shall be
+| included in all copies or substantial portions of the Software.
+| 
+| THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+| EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+| MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+| NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+| LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+| OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+| WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
-sphinx/web/mail.py
+AUTHORS file
+============
 
-:copyright: 2004-2007 by Gerold Penz.
+Sphinx is written and maintained by Georg Brandl <georg at python.org>.
 
-sphinx/util/stemmer.py
+Substantial parts of the templates were written by Armin Ronacher
+<armin.ronacher at active-4.com>.
 
-:copyright: 2001 by Vivake Gupta <v at nano.com>
+Other contributors, listed alphabetically, are:
 
-All the other files:
+* Andi Albrecht -- agogo theme
+* Henrique Bastos -- SVG support for graphviz extension
+* Daniel Bültmann -- todo extension
+* Michael Droettboom -- inheritance_diagram extension
+* Charles Duffy -- original graphviz extension
+* Josip Dzolonga -- coverage builder
+* Horst Gutmann -- internationalization support
+* Martin Hans -- autodoc improvements
+* Dave Kuhlman -- original LaTeX writer
+* Thomas Lamb -- linkcheck builder
+* Dan MacKinlay -- metadata fixes
+* Martin Mahner -- nature theme
+* Will Maier -- directory HTML builder
+* Roland Meister -- epub builder
+* Ezio Melotti -- collapsible sidebar JavaScript
+* Daniel Neuhäuser -- JavaScript domain
+* Christopher Perkins -- autosummary integration
+* Benjamin Peterson -- unittests
+* T\. Powers -- HTML output improvements
+* Stefan Seefeld -- toctree improvements
+* Antonio Valentino -- qthelp builder
+* Pauli Virtanen -- autodoc improvements, autosummary extension
+* Stefan van der Walt -- autosummary extension
+* Barry Warsaw -- setup command improvements
+* Sebastian Wiesner -- image handling, distutils support
 
-:copyright: 2007-2008 by Georg Brandl <georg at python.org>
+Many thanks for all contributions!
+
+There are also a few modules or functions incorporated from other
+authors and projects:
+
+* sphinx.util.jsdump uses the basestring encoding from simplejson,
+  written by Bob Ippolito, released under the MIT license
+* sphinx.util.stemmer was written by Vivake Gupta, placed in the
+  Public Domain

Modified: packages/sphinx/trunk/debian/dirs
===================================================================
--- packages/sphinx/trunk/debian/dirs	2011-02-18 15:40:57 UTC (rev 15761)
+++ packages/sphinx/trunk/debian/dirs	2011-02-18 16:16:49 UTC (rev 15762)
@@ -1 +1,3 @@
 /usr/share/sphinx/locale
+/usr/share/sphinx/pycode
+/usr/share/sphinx/ext/autosummary

Copied: packages/sphinx/trunk/debian/patches/autosummary_1.0.6.patch (from rev 15761, packages/sphinx/branches/1.0/debian/patches/autosummary_1.0.6.patch)
===================================================================
--- packages/sphinx/trunk/debian/patches/autosummary_1.0.6.patch	                        (rev 0)
+++ packages/sphinx/trunk/debian/patches/autosummary_1.0.6.patch	2011-02-18 16:16:49 UTC (rev 15762)
@@ -0,0 +1,158 @@
+Description: Revert upstream commit 44d16909cf74 (“fix wrong generation of
+  directives of static methods in autosummary”).
+Bug-Debian: http://bugs.debian.org/611078
+Bug: https://bitbucket.org/birkenfeld/sphinx/issue/618
+Forwarded: not-needed
+
+--- a/CHANGES
++++ b/CHANGES
+@@ -1,9 +1,6 @@
+ Release 1.0.7 (Jan 15, 2011)
+ ============================
+ 
+-* #347: Fix wrong generation of directives of static methods in
+-  autosummary.
+-
+ * #599: Import PIL as ``from PIL import Image``.
+ 
+ * #558: Fix longtables with captions in LaTeX output.
+--- a/sphinx/ext/autosummary/__init__.py
++++ b/sphinx/ext/autosummary/__init__.py
+@@ -134,19 +134,27 @@
+         return False
+     isgetsetdescriptor = ismemberdescriptor
+ 
+-def get_documenter(obj, parent):
++def get_documenter(obj):
+     """
+     Get an autodoc.Documenter class suitable for documenting the given object
+     """
+-    from sphinx.ext.autodoc import AutoDirective, DataDocumenter
++    import sphinx.ext.autodoc as autodoc
+ 
+-    classes = [cls for cls in AutoDirective._registry.values()
+-               if cls.can_document_member(obj, '', False, parent)]
+-    if classes:
+-        classes.sort(key=lambda cls: cls.priority)
+-        return classes[-1]
++    if inspect.isclass(obj):
++        if issubclass(obj, Exception):
++            return autodoc.ExceptionDocumenter
++        return autodoc.ClassDocumenter
++    elif inspect.ismodule(obj):
++        return autodoc.ModuleDocumenter
++    elif inspect.ismethod(obj) or inspect.ismethoddescriptor(obj):
++        return autodoc.MethodDocumenter
++    elif (ismemberdescriptor(obj) or isgetsetdescriptor(obj)
++          or inspect.isdatadescriptor(obj)):
++        return autodoc.AttributeDocumenter
++    elif inspect.isroutine(obj):
++        return autodoc.FunctionDocumenter
+     else:
+-        return DataDocumenter
++        return autodoc.DataDocumenter
+ 
+ 
+ # -- .. autosummary:: ----------------------------------------------------------
+@@ -232,7 +240,7 @@
+                 display_name = name.split('.')[-1]
+ 
+             try:
+-                real_name, obj, parent = import_by_name(name, prefixes=prefixes)
++                obj, real_name = import_by_name(name, prefixes=prefixes)
+             except ImportError:
+                 self.warn('failed to import %s' % name)
+                 items.append((name, '', '', name))
+@@ -240,7 +248,7 @@
+ 
+             # NB. using real_name here is important, since Documenters
+             #     handle module prefixes slightly differently
+-            documenter = get_documenter(obj, parent)(self, real_name)
++            documenter = get_documenter(obj)(self, real_name)
+             if not documenter.parse_name():
+                 self.warn('failed to parse name %s' % real_name)
+                 items.append((display_name, '', '', real_name))
+@@ -380,8 +388,7 @@
+                 prefixed_name = '.'.join([prefix, name])
+             else:
+                 prefixed_name = name
+-            obj, parent = _import_by_name(prefixed_name)
+-            return prefixed_name, obj, parent
++            return _import_by_name(prefixed_name), prefixed_name
+         except ImportError:
+             tried.append(prefixed_name)
+     raise ImportError('no module named %s' % ' or '.join(tried))
+@@ -396,8 +403,7 @@
+         if modname:
+             try:
+                 __import__(modname)
+-                mod = sys.modules[modname]
+-                return getattr(mod, name_parts[-1]), mod
++                return getattr(sys.modules[modname], name_parts[-1])
+             except (ImportError, IndexError, AttributeError):
+                 pass
+ 
+@@ -415,14 +421,12 @@
+                 break
+ 
+         if last_j < len(name_parts):
+-            parent = None
+             obj = sys.modules[modname]
+             for obj_name in name_parts[last_j:]:
+-                parent = obj
+                 obj = getattr(obj, obj_name)
+-            return obj, parent
++            return obj
+         else:
+-            return sys.modules[modname], None
++            return sys.modules[modname]
+     except (ValueError, ImportError, AttributeError, KeyError), e:
+         raise ImportError(*e.args)
+ 
+@@ -445,7 +449,7 @@
+     prefixes = [None]
+     #prefixes.insert(0, inliner.document.settings.env.currmodule)
+     try:
+-        name, obj, parent = import_by_name(pnode['reftarget'], prefixes)
++        obj, name = import_by_name(pnode['reftarget'], prefixes)
+     except ImportError:
+         content = pnode[0]
+         r[0][0] = nodes.emphasis(rawtext, content[0].astext(),
+--- a/sphinx/ext/autosummary/generate.py
++++ b/sphinx/ext/autosummary/generate.py
+@@ -107,7 +107,7 @@
+         ensuredir(path)
+ 
+         try:
+-            name, obj, parent = import_by_name(name)
++            obj, name = import_by_name(name)
+         except ImportError, e:
+             warn('[autosummary] failed to import %r: %s' % (name, e))
+             continue
+@@ -123,7 +123,7 @@
+         f = open(fn, 'w')
+ 
+         try:
+-            doc = get_documenter(obj, parent)
++            doc = get_documenter(obj)
+ 
+             if template_name is not None:
+                 template = template_env.get_template(template_name)
+@@ -137,7 +137,7 @@
+             def get_members(obj, typ, include_public=[]):
+                 items = [
+                     name for name in dir(obj)
+-                    if get_documenter(getattr(obj, name), obj).objtype == typ
++                    if get_documenter(getattr(obj, name)).objtype == typ
+                 ]
+                 public = [x for x in items
+                           if x in include_public or not x.startswith('_')]
+@@ -211,7 +211,7 @@
+     See `find_autosummary_in_lines`.
+     """
+     try:
+-        real_name, obj, parent = import_by_name(name)
++        obj, real_name = import_by_name(name)
+         lines = pydoc.getdoc(obj).splitlines()
+         return find_autosummary_in_lines(lines, module=name, filename=filename)
+     except AttributeError:

Modified: packages/sphinx/trunk/debian/patches/move_static_files_outside_site-packages.patch
===================================================================
--- packages/sphinx/trunk/debian/patches/move_static_files_outside_site-packages.patch	2011-02-18 15:40:57 UTC (rev 15761)
+++ packages/sphinx/trunk/debian/patches/move_static_files_outside_site-packages.patch	2011-02-18 16:16:49 UTC (rev 15762)
@@ -1,41 +1,68 @@
-# move static files outside site-packages so that they can be shared between
-# different Python versions
---- a/sphinx/theming.py
-+++ b/sphinx/theming.py
-@@ -33,7 +33,7 @@
-     def init_themes(cls, builder):
-         """Search all theme paths for available themes."""
-         cls.themepath = list(builder.config.html_theme_path)
--        cls.themepath.append(path.join(package_dir, 'themes'))
-+        cls.themepath.append('/usr/share/sphinx/themes')
+Description: Move static files outside site-packages so that they can be shared
+  between different Python versions.
+Forwarded: not-needed
+Last-Update: 2011-01-10
+
+--- a/sphinx/__init__.py
++++ b/sphinx/__init__.py
+@@ -15,7 +15,7 @@
+ __version__  = '1.0.7'
+ __released__ = '1.0.7'  # used when Sphinx builds its own docs
  
-         for themedir in cls.themepath[::-1]:
-             themedir = path.join(builder.confdir, themedir)
---- a/sphinx/builders/changes.py
-+++ b/sphinx/builders/changes.py
-@@ -136,12 +136,10 @@
-                 f.close()
-         themectx = dict(('theme_' + key, val) for (key, val) in
-                         self.theme.get_options({}).iteritems())
--        copy_static_entry(path.join(package_dir, 'themes', 'default',
--                                    'static', 'default.css_t'),
-+        copy_static_entry('/usr/share/sphinx/themes/default/static/default.css_t',
-                           path.join(self.outdir, 'default.css_t'),
-                           self, themectx)
--        copy_static_entry(path.join(package_dir, 'themes', 'basic',
--                                    'static', 'basic.css'),
-+        copy_static_entry('/usr/share/sphinx/themes/basic/static/basic.css',
-                           path.join(self.outdir, 'basic.css'), self)
+-package_dir = path.abspath(path.dirname(__file__))
++package_dir = '/usr/share/sphinx/'
  
-     def hl(self, text, version):
---- a/sphinx/builders/latex.py
-+++ b/sphinx/builders/latex.py
-@@ -194,7 +194,7 @@
-                      path.join(self.outdir, logobase))
+ if '+' in __version__ or 'pre' in __version__:
+     # try to find out the changeset hash if checked out from hg, and append
+--- a/tests/run.py
++++ b/tests/run.py
+@@ -14,7 +14,10 @@
+ from os import path
  
-         self.info(bold('copying TeX support files... '), nonl=True)
--        staticdirname = path.join(package_dir, 'texinputs')
-+        staticdirname = '/usr/share/sphinx/texinputs'
-         for filename in os.listdir(staticdirname):
-             if not filename.startswith('.'):
-                 copyfile(path.join(staticdirname, filename),
+ # always test the sphinx package from this directory
+-sys.path.insert(0, path.join(path.dirname(__file__), path.pardir))
++sys.path.insert(0, path.abspath(path.join(path.dirname(__file__), path.pardir)))
++
++import sphinx
++sphinx.package_dir = path.join(sys.path[0], 'sphinx')
+ 
+ try:
+     import nose
+--- a/sphinx/pycode/__init__.py
++++ b/sphinx/pycode/__init__.py
+@@ -14,6 +14,7 @@
+ from os import path
+ from cStringIO import StringIO
+ 
++from sphinx import package_dir
+ from sphinx.errors import PycodeError
+ from sphinx.pycode import nodes
+ from sphinx.pycode.pgen2 import driver, token, tokenize, parse, literals
+@@ -22,7 +23,7 @@
+ 
+ 
+ # load the Python grammar
+-_grammarfile = path.join(path.dirname(__file__), 'Grammar.txt')
++_grammarfile = path.join(package_dir, 'pycode', 'Grammar.txt')
+ pygrammar = driver.load_grammar(_grammarfile)
+ pydriver = driver.Driver(pygrammar, convert=nodes.convert)
+ 
+--- a/sphinx/ext/autosummary/generate.py
++++ b/sphinx/ext/autosummary/generate.py
+@@ -26,6 +26,7 @@
+ from jinja2 import FileSystemLoader, TemplateNotFound
+ from jinja2.sandbox import SandboxedEnvironment
+ 
++from sphinx import package_dir
+ from sphinx.ext.autosummary import import_by_name, get_documenter
+ from sphinx.jinja2glue import BuiltinTemplateLoader
+ from sphinx.util.osutil import ensuredir
+@@ -76,7 +77,7 @@
+         sources = [os.path.join(base_path, filename) for filename in sources]
+ 
+     # create our own templating environment
+-    template_dirs = [os.path.join(os.path.dirname(__file__), 'templates')]
++    template_dirs = [os.path.join(package_dir, 'ext', 'autosummary', 'templates')]
+     if builder is not None:
+         # allow the user to override the templates
+         template_loader = BuiltinTemplateLoader()

Modified: packages/sphinx/trunk/debian/patches/series
===================================================================
--- packages/sphinx/trunk/debian/patches/series	2011-02-18 15:40:57 UTC (rev 15761)
+++ packages/sphinx/trunk/debian/patches/series	2011-02-18 16:16:49 UTC (rev 15762)
@@ -1 +1,3 @@
+autosummary_1.0.6.patch
 move_static_files_outside_site-packages.patch
+unversioned_grammar_pickle.diff

Copied: packages/sphinx/trunk/debian/patches/unversioned_grammar_pickle.diff (from rev 15761, packages/sphinx/branches/1.0/debian/patches/unversioned_grammar_pickle.diff)
===================================================================
--- packages/sphinx/trunk/debian/patches/unversioned_grammar_pickle.diff	                        (rev 0)
+++ packages/sphinx/trunk/debian/patches/unversioned_grammar_pickle.diff	2011-02-18 16:16:49 UTC (rev 15762)
@@ -0,0 +1,17 @@
+Description: Don't embed Python version in filename of grammar pickle.
+Author: Jakub Wilk <jwilk at debian.org>
+Bug: https://bitbucket.org/birkenfeld/sphinx/issue/641
+Forwarded: not-needed
+Last-Update: 2011-02-16
+
+--- a/sphinx/pycode/pgen2/driver.py
++++ b/sphinx/pycode/pgen2/driver.py
+@@ -120,7 +120,7 @@
+         head, tail = os.path.splitext(gt)
+         if tail == ".txt":
+             tail = ""
+-        gp = head + tail + ".".join(map(str, sys.version_info[:2])) + ".pickle"
++        gp = head + tail + ".pickle"
+     if force or not _newer(gp, gt):
+         logger.info("Generating grammar tables from %s", gt)
+         g = pgen.generate_grammar(gt)

Deleted: packages/sphinx/trunk/debian/preinst
===================================================================
--- packages/sphinx/trunk/debian/preinst	2011-02-18 15:40:57 UTC (rev 15761)
+++ packages/sphinx/trunk/debian/preinst	2011-02-18 16:16:49 UTC (rev 15762)
@@ -1,10 +0,0 @@
-#!/bin/sh
-# TODO: remove this file after releasing Squeeze
-set -e
-if [ "$1" = upgrade ] && dpkg --compare-versions "$2" lt-nl 0.6.6-2~;
-then
-	pycentral pkgremove python-sphinx || true
-	rm -rf /usr/lib/python2.*/*-packages/sphinx/
-fi
-
-#DEBHELPER#

Modified: packages/sphinx/trunk/debian/rules
===================================================================
--- packages/sphinx/trunk/debian/rules	2011-02-18 15:40:57 UTC (rev 15761)
+++ packages/sphinx/trunk/debian/rules	2011-02-18 16:16:49 UTC (rev 15762)
@@ -1,7 +1,6 @@
 #!/usr/bin/make -f
 # -*- makefile -*-
 
-include /usr/share/quilt/quilt.make
 include /usr/share/python/python.mk
 
 PACKAGE_NAME=python-sphinx
@@ -13,22 +12,25 @@
 build-stamp:
 	dh_testdir
 	mkdir -p _build/html
-	python sphinx-build.py doc _build/html
+	PYTHONPATH=. python debian/sphinx-build-local.py doc _build/html
+ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
+	set -e -x; \
+	for python in $(shell pyversions -r); do \
+		$$python tests/run.py; \
+	done
+endif
 	touch build-stamp
 
-clean: clean-patched unpatch
+clean:
 	dh_testdir
 	dh_testroot
+	python setup.py clean
 	find . -name '*.py[co]' -delete
-	rm -rf _build build
+	rm -rf _build build *.egg-info
 	dh_clean sphinx/pycode/*.pickle
 
-clean-patched: patch
+install: build
 	dh_testdir
-	python setup.py clean
-
-install: build patch
-	dh_testdir
 	dh_testroot
 	dh_installdirs
 	
@@ -36,6 +38,9 @@
 	# move static files outside {site,dist}-packages
 	mv $(SITE_PACKAGES_DIR)/sphinx/texinputs $(PACKAGE_DIR)/usr/share/sphinx/
 	mv $(SITE_PACKAGES_DIR)/sphinx/themes $(PACKAGE_DIR)/usr/share/sphinx/
+	mv $(SITE_PACKAGES_DIR)/sphinx/pycode/Grammar.txt $(PACKAGE_DIR)/usr/share/sphinx/pycode/
+	cp sphinx/pycode/Grammar.pickle $(PACKAGE_DIR)/usr/share/sphinx/pycode/
+	mv $(SITE_PACKAGES_DIR)/sphinx/ext/autosummary/templates $(PACKAGE_DIR)/usr/share/sphinx/ext/autosummary/
 	for lang in `find $(SITE_PACKAGES_DIR)/sphinx/locale\
 		-maxdepth 1 -mindepth 1 -type d -printf "%f "`;\
 	do\
@@ -66,7 +71,7 @@
 	dh_installexamples
 	dh_installman
 	dh_pysupport
-	dh_compress -X.py -X.js -X.rst -X.json -X.doctree -X.txt
+	dh_compress -X.py -X.js -X.rst -X.json -X.doctree -X.txt -Xobjects.inv
 	dh_link /usr/share/javascript/jquery/jquery.js \
 		/usr/share/doc/python-sphinx/html/_static/jquery.js
 	dh_fixperms

Modified: packages/sphinx/trunk/debian/source/format
===================================================================
--- packages/sphinx/trunk/debian/source/format	2011-02-18 15:40:57 UTC (rev 15761)
+++ packages/sphinx/trunk/debian/source/format	2011-02-18 16:16:49 UTC (rev 15762)
@@ -1 +1 @@
-1.0
+3.0 (quilt)

Modified: packages/sphinx/trunk/debian/sphinx-autogen.1
===================================================================
--- packages/sphinx/trunk/debian/sphinx-autogen.1	2011-02-18 15:40:57 UTC (rev 15761)
+++ packages/sphinx/trunk/debian/sphinx-autogen.1	2011-02-18 16:16:49 UTC (rev 15762)
@@ -1,4 +1,4 @@
-.TH sphinx\-autogen 1 "Sat, 28 Mar 2009" "Jan Dittberner" "User Commands"
+.TH sphinx\-autogen 1 "Aug 2010" "Jan Dittberner" "User Commands"
 
 .SH NAME
 sphinx\-autogen \- generate ReStructuredText using \fBautosummary\fR
@@ -12,11 +12,14 @@
 
 .SH OPTIONS
 .TP
-\fB\-o \fIoutput_dir\fR
+\fB\-o\fR, \fB--output-dir=\fIoutput_dir\fR, 
 the directory the output files should be written to
 .TP
-\fB\-s \fIsuffix\fR
+\fB\-s\fR, \fB--suffix=\fIsuffix\fR
 the suffix of the written files (defaults to rst)
+.TP
+\fB\-t\fR, \fB--templates=\fIdirectory\fR
+custom template directory
 
 .SH DESCRIPTION
 .B sphinx\-autogen

Copied: packages/sphinx/trunk/debian/sphinx-build-local.py (from rev 15761, packages/sphinx/branches/1.0/debian/sphinx-build-local.py)
===================================================================
--- packages/sphinx/trunk/debian/sphinx-build-local.py	                        (rev 0)
+++ packages/sphinx/trunk/debian/sphinx-build-local.py	2011-02-18 16:16:49 UTC (rev 15762)
@@ -0,0 +1,13 @@
+#!/usr/bin/python
+
+# Like /usr/bin/sphinx-build, but don't try to use system-wide static files.
+
+import os
+import sys
+import sphinx
+
+if __name__ == '__main__':
+    sphinx.package_dir = os.path.abspath(os.path.dirname(sphinx.__file__))
+    sys.exit(sphinx.main(sys.argv))
+
+# vim:ts=4 sw=4 et

Modified: packages/sphinx/trunk/debian/sphinx-build.1
===================================================================
--- packages/sphinx/trunk/debian/sphinx-build.1	2011-02-18 15:40:57 UTC (rev 15761)
+++ packages/sphinx/trunk/debian/sphinx-build.1	2011-02-18 16:16:49 UTC (rev 15762)
@@ -23,16 +23,22 @@
 \fBhtml\fR
 Build HTML pages. This is the default builder.
 .TP
+\fBsinglehtml\fR
+Build a single HTML with the whole content.
+.TP
 \fBdirhtml\fR
 Build HTML pages, but with a single directory per document.
 .TP
-\fBhtmlhelp\fR, \fBqthelp\fR
+\fBhtmlhelp\fR, \fBqthelp\fR, \fBdevhelp\fR, \fBepub\fR
 Build HTML pages with additional information for building a documentation collection in one of these formats.
 .TP
 \fBlatex\fR
 Build LaTeX sources that can be compiled to a PDF document using \fBpdflatex\fR.
 This builder uses the PAPER environment variable (e.g. PAPER=a4 or PAPER=letter) if available.
 .TP
+\fBman\fR
+Build manual pages in groff format for UNIX systems.
+.TP
 \fBtext\fR
 Build plain text files.
 .TP




More information about the Python-modules-commits mailing list