Package: haskell-devscripts Version: 0.16.27 Severity: normal Tags: patch User: ubuntu-de...@lists.ubuntu.com Usertags: origin-ubuntu kinetic ubuntu-patch
As discussed on #debian-haskell, several problems with arch-specific package builds failing during doc generation can be circumvented by not calling haddock from the binary-arch target. Attached please find a patch (imperfect though it is) that refactors some of the hlibrary.mk targets to allow binary-arch builds to skip the doc generation. This has been uploaded to Ubuntu, where it will hopefully let pandoc/armhf complete a build and unblock the ghc transition, rather than failing on an inactivity timeout on the builders. -- Steve Langasek Give me a lever long enough and a Free OS Debian Developer to set it on, and I can move the world. Ubuntu Developer https://www.debian.org/ slanga...@ubuntu.com vor...@debian.org
diff -Nru haskell-devscripts-0.16.27ubuntu1/hlibrary.mk haskell-devscripts-0.16.27ubuntu2/hlibrary.mk --- haskell-devscripts-0.16.27ubuntu1/hlibrary.mk 2022-08-22 14:38:06.000000000 -0700 +++ haskell-devscripts-0.16.27ubuntu2/hlibrary.mk 2022-09-02 13:47:46.000000000 -0700 @@ -114,8 +114,6 @@ endif endif -DEB_BUILD_DEPENDENCIES = build-arch - # We call the shell for most things, so make our variables available to it export DEB_SETUP_BIN_NAME export CABAL_PACKAGE @@ -177,13 +175,20 @@ build/%-doc:: build-haddock-stamp -# FIXME: For now, we have a single install recipe, which means we have -# to build both arch and indep (haddock) artifacts, even if we need only -# one of them. We should split the install recipe into two. -debian/tmp-inst-%: $(DEB_SETUP_BIN_NAME) check-ghc-stamp build-haddock-stamp +install-%-base:: perl -d:Confess -MDebian::Debhelper::Buildsystem::Haskell::Recipes=/.*/ \ - -E 'install_recipe($$ARGV[0])' "$@" - ln --symbolic --force "$@" debian/tmp + -E 'install_recipe($$ARGV[0])' "$(patsubst install-%-base,debian/tmp-inst-%,$@)" + ln --symbolic --force "$(patsubst install-%-base,debian/tmp-inst-%,$@)" debian/tmp + +install-%-arch: $(DEB_SETUP_BIN_NAME) check-ghc-stamp install-%-base + : + +# FIXME: the install_recipe doesn't work for indep-only builds, so our +# indep target depends on the arch target for now. +install-%-indep: $(DEB_SETUP_BIN_NAME) check-ghc-stamp build-haddock-stamp install-%-base + : + +debian/tmp-inst-%:: $(DEB_SETUP_BIN_NAME) check-ghc-stamp build-haddock-stamp install-%-base dist-hugs: $(DEB_SETUP_BIN_NAME) $(DEB_SETUP_BIN_NAME) configure --hugs --prefix=/usr -v2 \ @@ -192,7 +197,7 @@ build/libhugs-$(CABAL_PACKAGE):: dist-hugs $(DEB_SETUP_BIN_NAME) build --builddir=dist-hugs -install/libghc-$(CABAL_PACKAGE)-dev:: debian/tmp-inst-ghc +install/libghc-$(CABAL_PACKAGE)-dev:: install-ghc-arch dh_haskell_install_ghc_registration --package=$(notdir $@) dh_haskell_install_development_libs --package=$(notdir $@) --source-dir="$<" dh_haskell_provides_ghc --package=$(notdir $@) @@ -201,13 +206,13 @@ dh_haskell_shlibdeps --package=$(notdir $@) dh_haskell_blurbs --package=$(notdir $@) --type=dev -install/libghc-$(CABAL_PACKAGE)-prof:: debian/tmp-inst-ghc +install/libghc-$(CABAL_PACKAGE)-prof:: install-ghc-arch dh_haskell_install_profiling_libs --package=$(notdir $@) --source-dir="$<" dh_haskell_provides_ghc --package=$(notdir $@) --config-shipper="libghc-$(CABAL_PACKAGE)-dev" dh_haskell_depends_cabal --package=$(notdir $@) --config-shipper="libghc-$(CABAL_PACKAGE)-dev" dh_haskell_blurbs --package=$(notdir $@) --type=prof -install/libghc-$(CABAL_PACKAGE)-doc:: debian/tmp-inst-ghc +install/libghc-$(CABAL_PACKAGE)-doc:: install-ghc-indep dh_haskell_install_htmldocs --package=$(notdir $@) --source-dir="$<" dh_haskell_install_haddock --package=$(notdir $@) --source-dir="$<" dh_haskell_depends_haddock --package=$(notdir $@) @@ -215,7 +220,7 @@ dh_haskell_suggests --package=$(notdir $@) dh_haskell_blurbs --package=$(notdir $@) --type=doc -install/libghcjs-$(CABAL_PACKAGE)-dev:: debian/tmp-inst-ghcjs +install/libghcjs-$(CABAL_PACKAGE)-dev:: install-ghcjs-arch dh_haskell_install_ghc_registration --package=$(notdir $@) dh_haskell_install_development_libs --package=$(notdir $@) --source-dir="$<" dh_haskell_provides_ghc --package=$(notdir $@) @@ -224,13 +229,13 @@ dh_haskell_shlibdeps --package=$(notdir $@) dh_haskell_blurbs --package=$(notdir $@) --type=dev -install/libghcjs-$(CABAL_PACKAGE)-prof:: debian/tmp-inst-ghcjs +install/libghcjs-$(CABAL_PACKAGE)-prof:: install-ghcjs-arch dh_haskell_install_profiling_libs --package=$(notdir $@) --source-dir="$<" dh_haskell_provides_ghc --package=$(notdir $@) --config-shipper="libghcjs-$(CABAL_PACKAGE)-dev" dh_haskell_depends_cabal --package=$(notdir $@) --config-shipper="libghc-$(CABAL_PACKAGE)-dev" dh_haskell_blurbs --package=$(notdir $@) --type=prof -install/libghcjs-$(CABAL_PACKAGE)-doc:: debian/tmp-inst-ghcjs +install/libghcjs-$(CABAL_PACKAGE)-doc:: install-ghcjs-indep dh_haskell_install_htmldocs --package=$(notdir $@) --source-dir="$<" dh_haskell_install_haddock --package=$(notdir $@) --source-dir="$<" dh_haskell_depends_haddock --package=$(notdir $@)