summaryrefslogtreecommitdiff
path: root/guix/build/haskell-build-system.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2015-12-12 11:42:12 +0100
committerLudovic Courtès <ludo@gnu.org>2015-12-12 11:48:46 +0100
commite82e55e58c67b0215e768c4612ca542bc670f633 (patch)
tree856c4512fa1fbde59c1d9845c5a763ef8c4a14b4 /guix/build/haskell-build-system.scm
parent98bd851ee891ca4a84e061fe1e78ba78c292b096 (diff)
parente35dff973375266db253747140ddf25084ecddc2 (diff)
downloadguix-patches-e82e55e58c67b0215e768c4612ca542bc670f633.tar
guix-patches-e82e55e58c67b0215e768c4612ca542bc670f633.tar.gz
Merge branch 'master' into core-updates
Diffstat (limited to 'guix/build/haskell-build-system.scm')
-rw-r--r--guix/build/haskell-build-system.scm11
1 files changed, 11 insertions, 0 deletions
diff --git a/guix/build/haskell-build-system.scm b/guix/build/haskell-build-system.scm
index 34e5247e07..8e2aee381d 100644
--- a/guix/build/haskell-build-system.scm
+++ b/guix/build/haskell-build-system.scm
@@ -1,6 +1,7 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2015 Federico Beffa <beffa@fbengineering.ch>
;;; Copyright © 2015 Eric Bavier <bavier@member.fsf.org>
+;;; Copyright © 2015 Paul van der Walt <paul@denknerd.org>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -102,7 +103,17 @@ and parameters ~s~%"
;; Cabal errors if GHC_PACKAGE_PATH is set during 'configure', so unset
;; and restore it.
(unsetenv "GHC_PACKAGE_PATH")
+
+ ;; For packages where the Cabal build-type is set to "Configure",
+ ;; ./configure will be executed. In these cases, the following
+ ;; environment variable is needed to be able to find the shell executable.
+ ;; For other package types, the configure script isn't present. For more
+ ;; information, see the Build Information section of
+ ;; <https://www.haskell.org/cabal/users-guide/developing-packages.html>.
+ (when (file-exists? "configure")
+ (setenv "CONFIG_SHELL" "sh"))
(run-setuphs "configure" params)
+
(setenv "GHC_PACKAGE_PATH" ghc-path)))
(define* (build #:rest empty)