[Python-modules-commits] r17606 - in packages/sphinx/trunk/debian (changelog control rules)

jwilk at users.alioth.debian.org jwilk at users.alioth.debian.org
Fri Jun 24 18:49:08 UTC 2011


    Date: Friday, June 24, 2011 @ 18:49:06
  Author: jwilk
Revision: 17606

* Include Underscore.js source (closes: #631535).
* Use Underscore.js from Debian package, not the embedded copy.
* Unify multiple calls to dh_link.

Modified:
  packages/sphinx/trunk/debian/changelog
  packages/sphinx/trunk/debian/control
  packages/sphinx/trunk/debian/rules

Modified: packages/sphinx/trunk/debian/changelog
===================================================================
--- packages/sphinx/trunk/debian/changelog	2011-06-24 15:14:54 UTC (rev 17605)
+++ packages/sphinx/trunk/debian/changelog	2011-06-24 18:49:06 UTC (rev 17606)
@@ -1,3 +1,15 @@
+sphinx (1.0.7-6) UNRELEASED; urgency=low
+
+  * Include Underscore.js source (closes: #631535).
+    + Check at build time if versions of both Underscore.js copies match.
+  * Use Underscore.js from Debian package, not the embedded copy:
+    - Add dependency on libjs-underscore,
+    - Replace underscore.js with symlink to
+      /usr/share/javascript/underscore/underscore.js.
+  * Unify multiple calls to dh_link.
+
+ -- Jakub Wilk <jwilk at debian.org>  Fri, 24 Jun 2011 20:46:37 +0200
+
 sphinx (1.0.7-5) unstable; urgency=low
 
   [ Jakub Wilk ]

Modified: packages/sphinx/trunk/debian/control
===================================================================
--- packages/sphinx/trunk/debian/control	2011-06-24 15:14:54 UTC (rev 17605)
+++ packages/sphinx/trunk/debian/control	2011-06-24 18:49:06 UTC (rev 17606)
@@ -14,7 +14,8 @@
 
 Package: python-sphinx
 Architecture: all
-Depends: ${misc:Depends}, ${python:Depends}, python-docutils (>= 0.5), python-pygments (>= 0.8), python-jinja2 (>= 2.2), libjs-jquery (>= 1.4)
+Depends: ${misc:Depends}, ${python:Depends}, python-docutils (>= 0.5), python-pygments (>= 0.8), python-jinja2 (>= 2.2),
+  libjs-jquery (>= 1.4), libjs-underscore
 Recommends: python (>= 2.6) | python-simplejson, python-imaging
 Suggests: jsmath
 Description: tool for producing documentation for Python projects

Modified: packages/sphinx/trunk/debian/rules
===================================================================
--- packages/sphinx/trunk/debian/rules	2011-06-24 15:14:54 UTC (rev 17605)
+++ packages/sphinx/trunk/debian/rules	2011-06-24 18:49:06 UTC (rev 17606)
@@ -7,6 +7,10 @@
 jquery_version_debian = $(call jquery_version,$(wildcard debian/jquery-*.js))
 jquery_version_upstream = $(call jquery_version,sphinx/themes/basic/static/jquery.js)
 
+underscore_version = $(shell tr '"' "'" < $(1) | grep -Eo "VERSION *= *'[0-9.]+'" | tr -dc 0-9.)
+underscore_version_debian = $(call underscore_version,$(wildcard debian/underscore-*.js))
+underscore_version_upstream = $(call underscore_version,sphinx/themes/basic/static/underscore.js)
+
 PACKAGE_NAME=python-sphinx
 PACKAGE_DIR=$(CURDIR)/debian/$(PACKAGE_NAME)
 SITE_PACKAGES_DIR=$(PACKAGE_DIR)$(call py_libdir,$(shell pyversions -d))
@@ -21,6 +25,12 @@
 ifneq "$(jquery_version_debian)" "$(jquery_version_upstream)"
 	$(error Debian and upstream versions of jQuery do not match ($(jquery_version_debian) != $(jquery_version_upstream)))
 endif
+ifeq "$(underscore_version_upstream)" ""
+	$(error Unable to dermine upstream version of Underscore.js)
+endif
+ifneq "$(underscore_version_debian)" "$(underscore_version_upstream)"
+	$(error Debian and upstream versions of Underscore.js do not match ($(underscore_version_debian) != $(underscore_version_upstream)))
+endif
 	mkdir -p _build/html
 	PYTHONPATH=. python debian/sphinx-build-local.py doc _build/html
 ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
@@ -64,9 +74,6 @@
 		rm -rf $(SITE_PACKAGES_DIR)/sphinx/locale/$$lang;\
 	done
 	rm -f $(SITE_PACKAGES_DIR)/sphinx/locale/sphinx.pot
-	# use packaged jQuery
-	dh_link /usr/share/javascript/jquery/jquery.js \
-		/usr/share/sphinx/themes/basic/static/jquery.js
 	# install scripts not touched by easy install
 	install -m 755 $(CURDIR)/sphinx-build.py $(PACKAGE_DIR)/usr/bin/sphinx-build
 	install -m 755 $(CURDIR)/sphinx-quickstart.py $(PACKAGE_DIR)/usr/bin/sphinx-quickstart
@@ -78,13 +85,11 @@
 	dh_installchangelogs CHANGES
 	dh_installdocs
 	rm -rf $(PACKAGE_DIR)/usr/share/doc/python-sphinx/html/.doctrees
-	dh_link /usr/share/doc/python-sphinx/html/_sources/ /usr/share/doc/python-sphinx/rst
 	dh_installexamples
 	dh_installman
 	dh_pysupport
 	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_link
 	dh_fixperms
 	dh_installdeb
 	dh_gencontrol




More information about the Python-modules-commits mailing list