From 0be3dae42fb5cd0744e5fea3c9fc72039eef8da0 Mon Sep 17 00:00:00 2001 From: Peter Simons Date: Tue, 9 Aug 2011 07:41:10 +0000 Subject: [PATCH] pkgs/development/compilers/ghc/*-binary.nix: added a meta.platforms attribute to all ghc bootstrap versions svn path=/nixpkgs/trunk/; revision=28408 --- pkgs/development/compilers/ghc/6.10.1-binary.nix | 8 ++++++-- pkgs/development/compilers/ghc/6.10.2-binary.nix | 7 ++++++- pkgs/development/compilers/ghc/6.12.1-binary.nix | 7 ++++++- pkgs/development/compilers/ghc/6.4.2-binary.nix | 7 ++++++- 4 files changed, 24 insertions(+), 5 deletions(-) diff --git a/pkgs/development/compilers/ghc/6.10.1-binary.nix b/pkgs/development/compilers/ghc/6.10.1-binary.nix index c43f8525a33f..5a15cc0dff7e 100644 --- a/pkgs/development/compilers/ghc/6.10.1-binary.nix +++ b/pkgs/development/compilers/ghc/6.10.1-binary.nix @@ -1,6 +1,10 @@ {stdenv, fetchurl, perl, libedit, ncurses, gmp}: -assert stdenv.system == "i686-darwin" || stdenv.system == "x86_64-linux" || stdenv.system == "i686-linux"; +let + supportedPlatforms = ["i686-darwin" "x86_64-linux" "i686-linux"]; +in + +assert stdenv.lib.elem stdenv.system supportedPlatforms; stdenv.mkDerivation rec { version = "6.10.1"; @@ -100,5 +104,5 @@ stdenv.mkDerivation rec { [ $(./main) == "yes" ] ''; - meta.platforms = stdenv.lib.platforms.haskellPlatforms; + meta.platforms = supportedPlatforms; } diff --git a/pkgs/development/compilers/ghc/6.10.2-binary.nix b/pkgs/development/compilers/ghc/6.10.2-binary.nix index 1f917d3029a1..bd80a4cab1a1 100644 --- a/pkgs/development/compilers/ghc/6.10.2-binary.nix +++ b/pkgs/development/compilers/ghc/6.10.2-binary.nix @@ -1,6 +1,10 @@ {stdenv, fetchurl, perl, libedit, ncurses, gmp}: -assert stdenv.system == "i686-darwin" || stdenv.system == "x86_64-linux" || stdenv.system == "i686-linux"; +let + supportedPlatforms = ["i686-darwin" "x86_64-linux" "i686-linux"]; +in + +assert stdenv.lib.elem stdenv.system supportedPlatforms; stdenv.mkDerivation rec { version = "6.10.2"; @@ -99,4 +103,5 @@ stdenv.mkDerivation rec { [ $(./main) == "yes" ] ''; + meta.platforms = supportedPlatforms; } diff --git a/pkgs/development/compilers/ghc/6.12.1-binary.nix b/pkgs/development/compilers/ghc/6.12.1-binary.nix index b0a0bae890c9..6394780eb68c 100644 --- a/pkgs/development/compilers/ghc/6.12.1-binary.nix +++ b/pkgs/development/compilers/ghc/6.12.1-binary.nix @@ -1,6 +1,10 @@ {stdenv, fetchurl, perl, ncurses, gmp}: -assert stdenv.system == "i686-darwin" || stdenv.system == "x86_64-linux" || stdenv.system == "i686-linux"; +let + supportedPlatforms = ["x86_64-linux" "i686-linux"]; +in + +assert stdenv.lib.elem stdenv.system supportedPlatforms; stdenv.mkDerivation rec { version = "6.12.1"; @@ -101,4 +105,5 @@ stdenv.mkDerivation rec { [ $(./main) == "yes" ] ''; + meta.platforms = supportedPlatforms; } diff --git a/pkgs/development/compilers/ghc/6.4.2-binary.nix b/pkgs/development/compilers/ghc/6.4.2-binary.nix index 50a49b728d78..63cc08db34b1 100644 --- a/pkgs/development/compilers/ghc/6.4.2-binary.nix +++ b/pkgs/development/compilers/ghc/6.4.2-binary.nix @@ -1,6 +1,10 @@ {stdenv, fetchurl, perl, readline, ncurses, gmp}: -assert stdenv.system == "i686-darwin" || stdenv.system == "x86_64-linux" || stdenv.system == "i686-linux"; +let + supportedPlatforms = ["i686-darwin" "x86_64-linux" "i686-linux"]; +in + +assert stdenv.lib.elem stdenv.system supportedPlatforms; stdenv.mkDerivation { name = if stdenv.system == "i686-darwin" then "ghc-6.6.1-binary" else "ghc-6.4.2-binary"; @@ -64,4 +68,5 @@ stdenv.mkDerivation { '' else ""; + meta.platforms = supportedPlatforms; }