[DHG_packages] 01/01: Run /usr/lib/ghc-doc/gen_contents_index from ghc-doc.postinst with HOME set to a temporary directory, so that it doesn't pick up stray user configuration and so that it works reliably in autopkgtests.
Colin Watson
cjwatson at moszumanska.debian.org
Fri Jan 29 15:57:32 UTC 2016
This is an automated email from the git hooks/post-receive script.
cjwatson pushed a commit to branch master
in repository DHG_packages.
commit e03850adc13e0887e3e45f666b05b4be1e4f5b8d
Author: Colin Watson <cjwatson at debian.org>
Date: Fri Jan 29 15:57:12 2016 +0000
Run /usr/lib/ghc-doc/gen_contents_index from ghc-doc.postinst with HOME set to a temporary directory, so that it doesn't pick up stray user configuration and so that it works reliably in autopkgtests.
---
p/ghc/debian/changelog | 5 +++++
p/ghc/debian/ghc-doc.postinst | 5 ++++-
2 files changed, 9 insertions(+), 1 deletion(-)
diff --git a/p/ghc/debian/changelog b/p/ghc/debian/changelog
index 14cf940..e1d6eb4 100644
--- a/p/ghc/debian/changelog
+++ b/p/ghc/debian/changelog
@@ -5,6 +5,11 @@ ghc (7.10.3-7) UNRELEASED; urgency=medium
* Tighten build-depends on ghc; this does not build against 7.6 any more, so
let's use the 7.8 already in backports.
+ [ Colin Watson ]
+ * Run /usr/lib/ghc-doc/gen_contents_index from ghc-doc.postinst with HOME
+ set to a temporary directory, so that it doesn't pick up stray user
+ configuration and so that it works reliably in autopkgtests.
+
-- Gianfranco Costamagna <locutusofborg at debian.org> Thu, 28 Jan 2016 12:58:01 +0100
ghc (7.10.3-6) unstable; urgency=medium
diff --git a/p/ghc/debian/ghc-doc.postinst b/p/ghc/debian/ghc-doc.postinst
index 95df9aa..4b0760d 100644
--- a/p/ghc/debian/ghc-doc.postinst
+++ b/p/ghc/debian/ghc-doc.postinst
@@ -23,7 +23,10 @@ set -e
case "$1" in
triggered|configure)
if test -x /usr/bin/ghc-pkg; then /usr/bin/ghc-pkg recache --global; fi
- /usr/lib/ghc-doc/gen_contents_index
+ tmpdir="$(mktemp -d)"
+ cleanup () { rmdir "$tmpdir"; }
+ trap cleanup EXIT
+ HOME="$tmpdir" /usr/lib/ghc-doc/gen_contents_index
;;
abort-upgrade|abort-remove|abort-deconfigure)
;;
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-haskell/DHG_packages.git
More information about the Pkg-haskell-commits
mailing list