From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jan Nieuwenhuizen Subject: [PATCH 12/12] gnu: guile-2.0: support mingw. Date: Thu, 18 Aug 2016 08:08:51 +0200 Message-ID: <20160818060851.2853-13-janneke@gnu.org> References: <20160818060851.2853-1-janneke@gnu.org> Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:49744) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1baGW9-00008G-4s for guix-devel@gnu.org; Thu, 18 Aug 2016 02:09:32 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1baGW7-0008W3-41 for guix-devel@gnu.org; Thu, 18 Aug 2016 02:09:28 -0400 In-Reply-To: <20160818060851.2853-1-janneke@gnu.org> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: guix-devel@gnu.org * gnu/packages/guile.scm (guile-2.0): Support MinGW. --- gnu/packages/guile.scm | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/gnu/packages/guile.scm b/gnu/packages/guile.scm index f26cc22..ee84c05 100644 --- a/gnu/packages/guile.scm +++ b/gnu/packages/guile.scm @@ -143,8 +143,8 @@ without requiring the source code to be rewritten.") (native-inputs `(("pkgconfig" ,pkg-config))) (inputs `(("libffi" ,libffi) ("readline" ,readline) - ("bash" ,bash))) - + ,@(libiconv-if-needed) + ,@(if (target-mingw?) '() `(("bash" ,bash))))) (propagated-inputs `( ;; These ones aren't normally needed here, but since `libguile-2.0.la' ;; reads `-lltdl -lunistring', adding them here will add the needed @@ -173,8 +173,15 @@ without requiring the source code to be rewritten.") ;; Tell (ice-9 popen) the file name of Bash. (let ((bash (assoc-ref inputs "bash"))) (substitute* "module/ice-9/popen.scm" + ;; If bash is #f allow fallback for user to provide + ;; "bash" in PATH. This happens when cross-building to + ;; MinGW for which we do not have Bash yet. (("/bin/sh") - (string-append bash "/bin/bash"))))) + ,@(if (target-mingw?) + '((if bash + (string-append bash "/bin/bash") + "bash")) + '((string-append bash "/bin/bash"))))))) %standard-phases))) (native-search-paths -- 2.9.2