2007-10-19 17:24:29 +04:00
|
|
|
{stdenv, fetchurl, readline, ghc, perl, m4, gmp, ncurses}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation (rec {
|
2009-01-18 17:04:34 +03:00
|
|
|
version = "6.8.2";
|
|
|
|
name = "ghc-${version}";
|
2007-10-19 17:24:29 +04:00
|
|
|
homepage = "http://www.haskell.org/ghc";
|
|
|
|
|
|
|
|
src = map fetchurl [
|
2009-01-18 17:04:34 +03:00
|
|
|
{ url = "${homepage}/dist/${version}/${name}-src.tar.bz2";
|
|
|
|
sha256 = "2d10f973c35e8d7d9f62b53e26fef90177a9a15105cda4b917340ba7696a22d9";
|
2007-10-19 17:24:29 +04:00
|
|
|
}
|
2009-01-18 17:04:34 +03:00
|
|
|
{ url = "${homepage}/dist/${version}/${name}-src-extralibs.tar.bz2";
|
2007-12-14 01:49:32 +03:00
|
|
|
md5 = "d199c50814188fb77355d41058b8613c";
|
2007-10-19 17:24:29 +04:00
|
|
|
}
|
|
|
|
];
|
|
|
|
|
2007-12-15 00:30:03 +03:00
|
|
|
buildInputs = [ghc readline perl m4 gmp];
|
2007-10-19 17:24:29 +04:00
|
|
|
|
|
|
|
meta = {
|
2007-12-14 01:49:32 +03:00
|
|
|
description = "The Glasgow Haskell Compiler";
|
2013-03-23 16:05:43 +04:00
|
|
|
inherit (ghc.meta) license platforms;
|
2007-10-19 17:24:29 +04:00
|
|
|
};
|
|
|
|
|
2008-01-08 11:45:39 +03:00
|
|
|
configureFlags=[
|
|
|
|
"--with-gmp-libraries=${gmp}/lib"
|
|
|
|
"--with-gmp-includes=${gmp}/include"
|
2008-06-04 13:40:17 +04:00
|
|
|
"--with-readline-libraries=${readline}/lib"
|
2009-04-16 23:25:22 +04:00
|
|
|
"--with-gcc=${stdenv.gcc}/bin/gcc"
|
2008-01-08 11:45:39 +03:00
|
|
|
];
|
2007-10-19 17:24:29 +04:00
|
|
|
|
|
|
|
preConfigure = "
|
2007-12-11 22:00:56 +03:00
|
|
|
# still requires a hack for ncurses
|
|
|
|
sed -i \"s|^\\\(ld-options.*$\\\)|\\\1 -L${ncurses}/lib|\" libraries/readline/readline.buildinfo.in
|
2007-10-19 17:24:29 +04:00
|
|
|
";
|
|
|
|
})
|