Trying to make nixUnstable cross-build.

It fails because it builds bin2c for the host system, instead of the build system.
I will wait for a fix upstream.

svn path=/nixpkgs/trunk/; revision=20445
This commit is contained in:
Lluís Batlle i Rossell 2010-03-05 23:22:36 +00:00
parent 3b54414f31
commit 997723ec9b
3 changed files with 33 additions and 8 deletions

View File

@ -1,5 +1,11 @@
{ stdenv, fetchurl, perl }:
let
opensslCrossSystem = stdenv.lib.attrByPath [ "openssl" "system" ]
(throw "openssl needs its platform name cross building" null)
stdenv.cross;
in
stdenv.mkDerivation rec {
name = "openssl-0.9.8l";
@ -10,12 +16,24 @@ stdenv.mkDerivation rec {
patches = [ ./darwin-arch.patch ];
buildInputs = [ perl ];
buildNativeInputs = [ perl ];
configureScript = "./config";
configureFlags = "shared";
crossAttrs = {
configurePhase = ''
export cross=$crossSystem-
./Configure --prefix=$out ${opensslCrossSystem} shared
'';
buildPhase = ''
make CC=$crossConfig-gcc \
AR="$crossConfig-ar r" \
RANLIB=$crossConfig-ranlib
'';
};
meta = {
homepage = http://www.openssl.org/;
description = "A cryptographic library that implements the SSL and TLS protocols";

View File

@ -11,7 +11,8 @@ stdenv.mkDerivation rec {
sha256 = "844e5878d55a68ae2aac657718a1960dcfc943f6738ebdfb2bc93e8c462d0ad7";
};
buildInputs = [perl curl openssl];
buildNativeInputs = [perl];
buildInputs = [curl openssl];
configureFlags = ''
--with-store-dir=${storeDir} --localstatedir=${stateDir}

View File

@ -710,6 +710,7 @@ let
float = "soft";
withTLS = true;
platform = pkgs.platforms.sheevaplug;
openssl.system = "linux-generic32";
};
nativePlatforms = linux;
in {
@ -722,6 +723,7 @@ in {
xorg = {
#xorgserver = nativePlatforms;
};
nixUnstable = linux;
linuxPackages_2_6_32.kernel = linux;
linuxPackages_2_6_33.kernel = linux;
gdbCross = nativePlatforms;
@ -745,6 +747,7 @@ let
kernelAutoModules = false;
kernelTarget = "vmlinux.bin";
};
openssl.system = "linux-generic32";
};
nativePlatforms = linux;
in {
@ -757,6 +760,7 @@ in {
xorg = {
#xorgserver = nativePlatforms;
};
nixUnstable = linux;
linuxPackages_2_6_32.kernel = linux;
linuxPackages_2_6_33.kernel = linux;
gdbCross = nativePlatforms;
@ -781,6 +785,7 @@ let
kernelTarget = "zImage";
uboot = null;
};
openssl.system = "linux64-sparcv9";
};
nativePlatforms = linux;
in {
@ -793,6 +798,7 @@ in {
xorg = {
#xorgserver = nativePlatforms;
};
nixUnstable = linux;
linuxPackages_2_6_32.kernel = linux;
linuxPackages_2_6_33.kernel = linux;
gdbCross = nativePlatforms;