Package: debhelper
Version: 8.9.4
Severity: wishlist
Tags: patch

Sphinx[0], the Python documentation generator, copies the documentation source into _sources subdirectory, so that the files can be later used by the JavaScript search function to display excerpts from the matching documents. If debhelper compresses these files, the function will be broken. (Currently about 60% of Sphinx-generated documentation packages are broken that way. :/)

Patch attached.

[0] http://packages.debian.org/sid/python-sphinx

--
Jakub Wilk
diff --git a/dh_compress b/dh_compress
--- a/dh_compress
+++ b/dh_compress
@@ -108,7 +108,9 @@
 				! -iname "*.gif" ! -iname "*.png" ! -iname "*.jpg" \\
 				! -iname "*.jpeg" \\
 				2>/dev/null || true;
-			find usr/share/doc -type f \\( -size +4k -or -name "changelog*" -or -name "NEWS*" \\) \\
+			find usr/share/doc \\
+				\\( -type d -name _sources -prune -false \\) -o \\
+				-type f \\( -size +4k -or -name "changelog*" -or -name "NEWS*" \\) \\
 				\\( -name changelog.html -or ! -iname "*.htm*" \\) \\
 				! -iname "*.gif" ! -iname "*.png" ! -iname "*.jpg" \\
 				! -iname "*.jpeg" ! -iname "*.gz" ! -iname "*.taz" \\

Reply via email to