[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#894627: htmldoc FTCBFS: runs just built htmldoc



Source: htmldoc
Version: 1.9.2-1
Tags: patch
User: helmutg@debian.org
Usertags: rebootstrap

htmldoc fails to cross build from source, because it runs the built
htmldoc and fails with an Exec format error. Now the interesting
observation is that this is only needed for building the documentation.
As it happens, the htmldoc source package nicely splits documentation
into htmldoc-common, which happens to be an Architecture: all package.
If we could somehow avoid building the doc/ subdirectory, that'd fix it.
Indeed, this is doable as the attached patch demonstrates. I hope the
patch is acceptable, but it does add some fragility. Please consider
applying it. Oh and it actually makes htmldoc cross build successfully.

Helmut
diff --minimal -Nru htmldoc-1.9.2/debian/changelog htmldoc-1.9.2/debian/changelog
--- htmldoc-1.9.2/debian/changelog	2018-03-27 18:22:33.000000000 +0200
+++ htmldoc-1.9.2/debian/changelog	2018-04-02 17:06:01.000000000 +0200
@@ -1,3 +1,10 @@
+htmldoc (1.9.2-1.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Do not build documentation during arch-only build. (Closes: #-1)
+
+ -- Helmut Grohne <helmut@subdivi.de>  Mon, 02 Apr 2018 17:06:01 +0200
+
 htmldoc (1.9.2-1) unstable; urgency=medium
 
   * QA upload.
diff --minimal -Nru htmldoc-1.9.2/debian/rules htmldoc-1.9.2/debian/rules
--- htmldoc-1.9.2/debian/rules	2018-03-26 04:27:55.000000000 +0200
+++ htmldoc-1.9.2/debian/rules	2018-04-02 17:06:01.000000000 +0200
@@ -6,3 +6,14 @@
 
 %:
 	dh $@
+
+# skip documentation in arch-only build
+DO_PACKAGES = $(shell dh_listpackages)
+DIRS=htmldoc $(if $(filter htmldoc-common,$(DO_PACKAGES)),doc)
+INSTALLDIRS=fonts data desktop $(if $(filter htmldoc-common,$(DO_PACKAGES)),doc) htmldoc
+
+override_dh_auto_build:
+	dh_auto_build -- DIRS="$(DIRS)"
+
+override_dh_auto_install:
+	dh_auto_install -- DIRS="$(DIRS)" INSTALLDIRS="$(INSTALLDIRS)"

Reply to: