[Python-modules-commits] r18934 - in packages/sphinx/branches/1.1/debian (4 files)

jwilk at users.alioth.debian.org jwilk at users.alioth.debian.org
Sat Oct 15 15:22:10 UTC 2011


    Date: Saturday, October 15, 2011 @ 15:22:09
  Author: jwilk
Revision: 18934

Merge 1.0 -> 1.1.

Modified:
  packages/sphinx/branches/1.1/debian/changelog
  packages/sphinx/branches/1.1/debian/patches/move_static_files_outside_site-packages.patch
  packages/sphinx/branches/1.1/debian/rules
Deleted:
  packages/sphinx/branches/1.1/debian/sphinx-build-local.py

Modified: packages/sphinx/branches/1.1/debian/changelog
===================================================================
--- packages/sphinx/branches/1.1/debian/changelog	2011-10-15 15:12:20 UTC (rev 18933)
+++ packages/sphinx/branches/1.1/debian/changelog	2011-10-15 15:22:09 UTC (rev 18934)
@@ -41,8 +41,11 @@
   * Fix a typo in the package description.
   * Use a for loop in debian/rules to install all sphinx-* scripts.
   * Use ‘set -x’ for all for loops in debian/rules.
+  * Modify sphinx.package_dir directly in debian/rules, not via patch. This
+    makes move_static_files_outside_site-packages.patch fully forwardable
+    upstream, and makes running tests easier.
 
- -- Jakub Wilk <jwilk at debian.org>  Sat, 15 Oct 2011 15:39:46 +0200
+ -- Jakub Wilk <jwilk at debian.org>  Sat, 15 Oct 2011 15:51:21 +0200
 
 sphinx (1.0.8+dfsg-2) unstable; urgency=low
 

Modified: packages/sphinx/branches/1.1/debian/patches/move_static_files_outside_site-packages.patch
===================================================================
--- packages/sphinx/branches/1.1/debian/patches/move_static_files_outside_site-packages.patch	2011-10-15 15:12:20 UTC (rev 18933)
+++ packages/sphinx/branches/1.1/debian/patches/move_static_files_outside_site-packages.patch	2011-10-15 15:22:09 UTC (rev 18934)
@@ -1,33 +1,8 @@
 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
+Forwarded: no
+Last-Update: 2011-10-15
 
---- a/sphinx/__init__.py
-+++ b/sphinx/__init__.py
-@@ -18,7 +18,7 @@
- __version__  = '1.1'
- __released__ = '1.1'  # used when Sphinx builds its own docs
- 
--package_dir = path.abspath(path.dirname(__file__))
-+package_dir = '/usr/share/sphinx/'
- 
- 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
-@@ -24,7 +24,10 @@
-     chdir(newroot)
- 
- # 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
 @@ -11,6 +11,7 @@

Modified: packages/sphinx/branches/1.1/debian/rules
===================================================================
--- packages/sphinx/branches/1.1/debian/rules	2011-10-15 15:12:20 UTC (rev 18933)
+++ packages/sphinx/branches/1.1/debian/rules	2011-10-15 15:22:09 UTC (rev 18934)
@@ -22,10 +22,10 @@
 	dh_testdir
 	ln -sf /usr/share/javascript/jquery/jquery.js sphinx/themes/basic/static/
 	ln -sf /usr/share/javascript/underscore/underscore.js sphinx/themes/basic/static/
-	PYTHONPATH=. python debian/sphinx-build-local.py doc build/html/
+	python ./sphinx-build.py doc build/html/
 	rm -rf build/man
 	cp -rl build/html build/man
-	PYTHONPATH=. python debian/sphinx-build-local.py -b man doc build/man
+	python ./sphinx-build.py -b man doc build/man
 ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
 	set -e -x; \
 	for python in $(shell pyversions -r); do \
@@ -49,6 +49,8 @@
 	dh_installdirs
 	python setup.py install --no-compile --install-layout=deb --root $(debroot)
 	# move static files outside {site,dist}-packages
+	sed -i -e "s!^package_dir = .*!package_dir = '/usr/share/sphinx'!" \
+		$(debroot)$(site_packages)/sphinx/__init__.py
 	mkdir -p $(debroot)/usr/share/sphinx/
 	cd $(debroot) && mv -t usr/share/sphinx/ .$(site_packages)/sphinx/texinputs \
 		.$(site_packages)/sphinx/themes

Deleted: packages/sphinx/branches/1.1/debian/sphinx-build-local.py
===================================================================
--- packages/sphinx/branches/1.1/debian/sphinx-build-local.py	2011-10-15 15:12:20 UTC (rev 18933)
+++ packages/sphinx/branches/1.1/debian/sphinx-build-local.py	2011-10-15 15:22:09 UTC (rev 18934)
@@ -1,13 +0,0 @@
-#!/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




More information about the Python-modules-commits mailing list