summary refs log tree commit diff
path: root/pkgs/development/interpreters/guile
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2012-05-09 13:42:46 +0000
committerLudovic Courtès <ludo@gnu.org>2012-05-09 13:42:46 +0000
commitc1dd4327dc55b7530f181b5ad83b5b3c9f1a6862 (patch)
tree590cc452a047dfde5cb0cf957aaa1ce90188f42f /pkgs/development/interpreters/guile
parent5930e47068bad707665ea67e2f9f08789f8a933e (diff)
downloadnixlib-c1dd4327dc55b7530f181b5ad83b5b3c9f1a6862.tar
nixlib-c1dd4327dc55b7530f181b5ad83b5b3c9f1a6862.tar.gz
nixlib-c1dd4327dc55b7530f181b5ad83b5b3c9f1a6862.tar.bz2
nixlib-c1dd4327dc55b7530f181b5ad83b5b3c9f1a6862.tar.lz
nixlib-c1dd4327dc55b7530f181b5ad83b5b3c9f1a6862.tar.xz
nixlib-c1dd4327dc55b7530f181b5ad83b5b3c9f1a6862.tar.zst
nixlib-c1dd4327dc55b7530f181b5ad83b5b3c9f1a6862.zip
GNU Guile 2.0: Fix cross-GNU builds.
svn path=/nixpkgs/trunk/; revision=34029
Diffstat (limited to 'pkgs/development/interpreters/guile')
-rw-r--r--pkgs/development/interpreters/guile/default.nix11
1 files changed, 10 insertions, 1 deletions
diff --git a/pkgs/development/interpreters/guile/default.nix b/pkgs/development/interpreters/guile/default.nix
index 19b9d26c7deb..127e49087d36 100644
--- a/pkgs/development/interpreters/guile/default.nix
+++ b/pkgs/development/interpreters/guile/default.nix
@@ -1,5 +1,5 @@
 { fetchurl, stdenv, libtool, readline, gmp, pkgconfig, boehmgc, libunistring
-, libffi, gawk, makeWrapper, coverageAnalysis ? null }:
+, libffi, gawk, makeWrapper, coverageAnalysis ? null, gnu ? null }:
 
 # Do either a coverage analysis build or a standard build.
 (if coverageAnalysis != null
@@ -48,6 +48,15 @@
 
   setupHook = ./setup-hook.sh;
 
+  crossAttrs.preConfigure =
+    stdenv.lib.optionalString (stdenv.cross.config == "i586-pc-gnu")
+       # On GNU, libgc depends on libpthread, but the cross linker doesn't
+       # know where to find libpthread, which leads to erroneous test failures
+       # in `configure', where `-pthread' and `-lpthread' aren't explicitly
+       # passed.  So it needs some help (XXX).
+       "export LDFLAGS=-Wl,-rpath-link=${gnu.libpthreadCross}/lib";
+
+
   meta = {
     description = "GNU Guile 2.0, an embeddable Scheme implementation";