libgcrypt/cross: Fix build for mingw-w64.

Especially for the 64bit mingw target, because libgcrypt contains
protected mode assembly.

Also, this adds gettext to the crossAttrs of libgpg-error, because it
tries to regenerate the MO files.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
This commit is contained in:
aszlig 2014-03-03 22:22:12 +01:00
parent c5ab2bfd25
commit ae0b5d6813
No known key found for this signature in database
GPG Key ID: D0EBD0EC8C2DC961
2 changed files with 11 additions and 1 deletions

View File

@ -24,6 +24,12 @@ stdenv.mkDerivation rec {
make check
'';
crossAttrs = let
isCross64 = stdenv.cross.config == "x86_64-w64-mingw32";
in stdenv.lib.optionalAttrs isCross64 {
configureFlags = [ "--disable-asm" "--disable-padlock-support" ];
};
meta = {
description = "GNU Libgcrypt, a general-pupose cryptographic library";

View File

@ -1,4 +1,4 @@
{ stdenv, fetchurl, bash }:
{ stdenv, fetchurl, bash, gettext }:
stdenv.mkDerivation (rec {
name = "libgpg-error-1.12";
@ -8,6 +8,10 @@ stdenv.mkDerivation (rec {
sha256 = "0pz58vr12qihq2f0bypjxsb6cf6ajq5258fmfm8s6lvwm3b9xz6a";
};
# If architecture-dependant MO files aren't available, they're generated
# during build, so we need gettext for cross-builds.
crossAttrs.buildInputs = [ gettext ];
doCheck = true;
meta = {