Drop obsolete GHC versions 7.10.3, 8.0.2, and 8.4.3.
We keep the latest minor release of each one of the last 3 major releases, which currently are GHC versions 8.2.2, 8.4.4, and 8.6.1. We also have ghc-HEAD, but this doesn't count. Dropping these compilers implied that we have to drop the corresponding versions of ghcjs, too. We can also drop a shitload of obsolete compiler patches that newer versions no longer need. At some point, we can probably simplify the generic builder, too.
This commit is contained in:
@@ -1,194 +0,0 @@
|
||||
{ stdenv, targetPackages
|
||||
|
||||
# build-tools
|
||||
, bootPkgs
|
||||
, coreutils, fetchurl, perl
|
||||
, docbook_xsl, docbook_xml_dtd_45, docbook_xml_dtd_42, libxml2, libxslt
|
||||
|
||||
, libiconv ? null, ncurses
|
||||
|
||||
, useLLVM ? !stdenv.targetPlatform.isx86
|
||||
, # LLVM is conceptually a run-time-only depedendency, but for
|
||||
# non-x86, we need LLVM to bootstrap later stages, so it becomes a
|
||||
# build-time dependency too.
|
||||
buildLlvmPackages, llvmPackages
|
||||
|
||||
, # If enabled, GHC will be built with the GPL-free but slower integer-simple
|
||||
# library instead of the faster but GPLed integer-gmp library.
|
||||
enableIntegerSimple ? !(stdenv.lib.any (stdenv.lib.meta.platformMatch stdenv.hostPlatform) gmp.meta.platforms), gmp
|
||||
|
||||
, # If enabled, use -fPIC when compiling static libs.
|
||||
enableRelocatedStaticLibs ? stdenv.targetPlatform != stdenv.hostPlatform
|
||||
|
||||
, # Whether to build dynamic libs for the standard library (on the target
|
||||
# platform). Static libs are always built.
|
||||
enableShared ? true
|
||||
|
||||
, # What flavour to build. An empty string indicates no
|
||||
# specific flavour and falls back to ghc default values.
|
||||
ghcFlavour ? stdenv.lib.optionalString (stdenv.targetPlatform != stdenv.hostPlatform) "perf-cross"
|
||||
}:
|
||||
|
||||
let
|
||||
inherit (stdenv) buildPlatform hostPlatform targetPlatform;
|
||||
|
||||
inherit (bootPkgs) ghc;
|
||||
|
||||
# TODO(@Ericson2314) Make unconditional
|
||||
targetPrefix = stdenv.lib.optionalString
|
||||
(targetPlatform != hostPlatform)
|
||||
"${targetPlatform.config}-";
|
||||
|
||||
docFixes = fetchurl {
|
||||
url = "https://downloads.haskell.org/~ghc/7.10.3/ghc-7.10.3a.patch";
|
||||
sha256 = "1j45z4kcd3w1rzm4hapap2xc16bbh942qnzzdbdjcwqznsccznf0";
|
||||
};
|
||||
|
||||
buildMK = ''
|
||||
BuildFlavour = ${ghcFlavour}
|
||||
ifneq \"\$(BuildFlavour)\" \"\"
|
||||
include mk/flavours/\$(BuildFlavour).mk
|
||||
endif
|
||||
DYNAMIC_GHC_PROGRAMS = ${if enableShared then "YES" else "NO"}
|
||||
'' + stdenv.lib.optionalString enableIntegerSimple ''
|
||||
INTEGER_LIBRARY = integer-simple
|
||||
'' + stdenv.lib.optionalString (targetPlatform != hostPlatform) ''
|
||||
Stage1Only = YES
|
||||
HADDOCK_DOCS = NO
|
||||
'' + stdenv.lib.optionalString enableRelocatedStaticLibs ''
|
||||
GhcLibHcOpts += -fPIC
|
||||
GhcRtsHcOpts += -fPIC
|
||||
'';
|
||||
|
||||
# Splicer will pull out correct variations
|
||||
libDeps = platform: [ ncurses ]
|
||||
++ stdenv.lib.optional (!enableIntegerSimple) gmp
|
||||
++ stdenv.lib.optional (platform.libc != "glibc") libiconv;
|
||||
|
||||
toolsForTarget =
|
||||
if hostPlatform == buildPlatform then
|
||||
[ targetPackages.stdenv.cc ] ++ stdenv.lib.optional useLLVM llvmPackages.llvm
|
||||
else assert targetPlatform == hostPlatform; # build != host == target
|
||||
[ stdenv.cc ] ++ stdenv.lib.optional useLLVM buildLlvmPackages.llvm;
|
||||
|
||||
targetCC = builtins.head toolsForTarget;
|
||||
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
version = "7.10.3";
|
||||
name = "${targetPrefix}ghc-${version}";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://downloads.haskell.org/~ghc/${version}/ghc-${version}-src.tar.xz";
|
||||
sha256 = "1vsgmic8csczl62ciz51iv8nhrkm72lyhbz7p7id13y2w7fcx46g";
|
||||
};
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
outputs = [ "out" "doc" ];
|
||||
|
||||
patches = [
|
||||
docFixes
|
||||
./relocation.patch
|
||||
];
|
||||
|
||||
postPatch = "patchShebangs .";
|
||||
|
||||
# GHC is a bit confused on its cross terminology.
|
||||
preConfigure = ''
|
||||
for env in $(env | grep '^TARGET_' | sed -E 's|\+?=.*||'); do
|
||||
export "''${env#TARGET_}=''${!env}"
|
||||
done
|
||||
# GHC is a bit confused on its cross terminology, as these would normally be
|
||||
# the *host* tools.
|
||||
export CC="${targetCC}/bin/${targetCC.targetPrefix}cc"
|
||||
export CXX="${targetCC}/bin/${targetCC.targetPrefix}cxx"
|
||||
export LD="${targetCC.bintools}/bin/${targetCC.bintools.targetPrefix}ld"
|
||||
export AS="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}as"
|
||||
export AR="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}ar"
|
||||
export NM="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}nm"
|
||||
export RANLIB="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}ranlib"
|
||||
export READELF="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}readelf"
|
||||
export STRIP="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}strip"
|
||||
|
||||
echo -n "${buildMK}" > mk/build.mk
|
||||
sed -i -e 's|-isysroot /Developer/SDKs/MacOSX10.5.sdk||' configure
|
||||
'' + stdenv.lib.optionalString (!stdenv.isDarwin) ''
|
||||
export NIX_LDFLAGS+=" -rpath $out/lib/ghc-${version}"
|
||||
'' + stdenv.lib.optionalString stdenv.isDarwin ''
|
||||
export NIX_LDFLAGS+=" -no_dtrace_dof"
|
||||
'';
|
||||
|
||||
# TODO(@Ericson2314): Always pass "--target" and always prefix.
|
||||
configurePlatforms = [ "build" "host" ]
|
||||
++ stdenv.lib.optional (targetPlatform != hostPlatform) "target";
|
||||
# `--with` flags for libraries needed for RTS linker
|
||||
configureFlags = [
|
||||
"--datadir=$doc/share/doc/ghc"
|
||||
"--with-curses-includes=${ncurses.dev}/include" "--with-curses-libraries=${ncurses.out}/lib"
|
||||
] ++ stdenv.lib.optional (targetPlatform == hostPlatform && ! enableIntegerSimple) [
|
||||
"--with-gmp-includes=${gmp.dev}/include" "--with-gmp-libraries=${gmp.out}/lib"
|
||||
] ++ stdenv.lib.optional (targetPlatform == hostPlatform && hostPlatform.libc != "glibc") [
|
||||
"--with-iconv-includes=${libiconv}/include" "--with-iconv-libraries=${libiconv}/lib"
|
||||
] ++ stdenv.lib.optionals (targetPlatform != hostPlatform) [
|
||||
"--enable-bootstrap-with-devel-snapshot"
|
||||
] ++ stdenv.lib.optionals (targetPlatform.isDarwin && targetPlatform.isAarch64) [
|
||||
# fix for iOS: https://www.reddit.com/r/haskell/comments/4ttdz1/building_an_osxi386_to_iosarm64_cross_compiler/d5qvd67/
|
||||
"--disable-large-address-space"
|
||||
];
|
||||
|
||||
# Make sure we never relax`$PATH` and hooks support for compatability.
|
||||
strictDeps = true;
|
||||
|
||||
nativeBuildInputs = [
|
||||
perl libxml2 libxslt docbook_xsl docbook_xml_dtd_45 docbook_xml_dtd_42
|
||||
ghc bootPkgs.hscolour
|
||||
];
|
||||
|
||||
# For building runtime libs
|
||||
depsBuildTarget = toolsForTarget;
|
||||
|
||||
buildInputs = libDeps hostPlatform;
|
||||
|
||||
propagatedBuildInputs = [ targetPackages.stdenv.cc ]
|
||||
++ stdenv.lib.optional useLLVM llvmPackages.llvm;
|
||||
|
||||
depsTargetTarget = map stdenv.lib.getDev (libDeps targetPlatform);
|
||||
depsTargetTargetPropagated = map (stdenv.lib.getOutput "out") (libDeps targetPlatform);
|
||||
|
||||
# required, because otherwise all symbols from HSffi.o are stripped, and
|
||||
# that in turn causes GHCi to abort
|
||||
stripDebugFlags = [ "-S" ] ++ stdenv.lib.optional (!targetPlatform.isDarwin) "--keep-file-symbols";
|
||||
|
||||
hardeningDisable = [ "format" ];
|
||||
|
||||
postInstall = ''
|
||||
# Install the bash completion file.
|
||||
install -D -m 444 utils/completion/ghc.bash $out/share/bash-completion/completions/${targetPrefix}ghc
|
||||
|
||||
# Patch scripts to include "readelf" and "cat" in $PATH.
|
||||
for i in "$out/bin/"*; do
|
||||
test ! -h $i || continue
|
||||
egrep --quiet '^#!' <(head -n 1 $i) || continue
|
||||
sed -i -e '2i export PATH="$PATH:${stdenv.lib.makeBinPath [ targetPackages.stdenv.cc.bintools coreutils ]}"' $i
|
||||
done
|
||||
'';
|
||||
|
||||
passthru = {
|
||||
inherit bootPkgs targetPrefix;
|
||||
|
||||
inherit llvmPackages;
|
||||
inherit enableShared;
|
||||
|
||||
# Our Cabal compiler name
|
||||
haskellCompilerName = "ghc-7.10.3";
|
||||
};
|
||||
|
||||
meta = {
|
||||
homepage = http://haskell.org/ghc;
|
||||
description = "The Glasgow Haskell Compiler";
|
||||
maintainers = with stdenv.lib.maintainers; [ marcweber andres peti ];
|
||||
inherit (ghc.meta) license platforms;
|
||||
};
|
||||
|
||||
}
|
||||
@@ -1,201 +0,0 @@
|
||||
{ stdenv, targetPackages
|
||||
|
||||
# build-tools
|
||||
, bootPkgs
|
||||
, coreutils, fetchpatch, fetchurl, perl, sphinx
|
||||
|
||||
, libiconv ? null, ncurses
|
||||
|
||||
, useLLVM ? !stdenv.targetPlatform.isx86
|
||||
, # LLVM is conceptually a run-time-only depedendency, but for
|
||||
# non-x86, we need LLVM to bootstrap later stages, so it becomes a
|
||||
# build-time dependency too.
|
||||
buildLlvmPackages, llvmPackages
|
||||
|
||||
, # If enabled, GHC will be built with the GPL-free but slower integer-simple
|
||||
# library instead of the faster but GPLed integer-gmp library.
|
||||
enableIntegerSimple ? !(stdenv.lib.any (stdenv.lib.meta.platformMatch stdenv.hostPlatform) gmp.meta.platforms), gmp
|
||||
|
||||
, # If enabled, use -fPIC when compiling static libs.
|
||||
enableRelocatedStaticLibs ? stdenv.targetPlatform != stdenv.hostPlatform
|
||||
|
||||
, # Whether to build dynamic libs for the standard library (on the target
|
||||
# platform). Static libs are always built.
|
||||
enableShared ? true
|
||||
|
||||
, # What flavour to build. An empty string indicates no
|
||||
# specific flavour and falls back to ghc default values.
|
||||
ghcFlavour ? stdenv.lib.optionalString (stdenv.targetPlatform != stdenv.hostPlatform) "perf-cross"
|
||||
}:
|
||||
|
||||
assert !enableIntegerSimple -> gmp != null;
|
||||
|
||||
let
|
||||
inherit (stdenv) buildPlatform hostPlatform targetPlatform;
|
||||
|
||||
inherit (bootPkgs) ghc;
|
||||
|
||||
# TODO(@Ericson2314) Make unconditional
|
||||
targetPrefix = stdenv.lib.optionalString
|
||||
(targetPlatform != hostPlatform)
|
||||
"${targetPlatform.config}-";
|
||||
|
||||
buildMK = ''
|
||||
BuildFlavour = ${ghcFlavour}
|
||||
ifneq \"\$(BuildFlavour)\" \"\"
|
||||
include mk/flavours/\$(BuildFlavour).mk
|
||||
endif
|
||||
DYNAMIC_GHC_PROGRAMS = ${if enableShared then "YES" else "NO"}
|
||||
INTEGER_LIBRARY = ${if enableIntegerSimple then "integer-simple" else "integer-gmp"}
|
||||
'' + stdenv.lib.optionalString (targetPlatform != hostPlatform) ''
|
||||
Stage1Only = YES
|
||||
HADDOCK_DOCS = NO
|
||||
'' + stdenv.lib.optionalString enableRelocatedStaticLibs ''
|
||||
GhcLibHcOpts += -fPIC
|
||||
GhcRtsHcOpts += -fPIC
|
||||
'';
|
||||
|
||||
# Splicer will pull out correct variations
|
||||
libDeps = platform: [ ncurses ]
|
||||
++ stdenv.lib.optional (!enableIntegerSimple) gmp
|
||||
++ stdenv.lib.optional (platform.libc != "glibc") libiconv;
|
||||
|
||||
toolsForTarget =
|
||||
if hostPlatform == buildPlatform then
|
||||
[ targetPackages.stdenv.cc ] ++ stdenv.lib.optional useLLVM llvmPackages.llvm
|
||||
else assert targetPlatform == hostPlatform; # build != host == target
|
||||
[ stdenv.cc ] ++ stdenv.lib.optional useLLVM buildLlvmPackages.llvm;
|
||||
|
||||
targetCC = builtins.head toolsForTarget;
|
||||
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
version = "8.0.2";
|
||||
name = "${targetPrefix}ghc-${version}";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://downloads.haskell.org/~ghc/${version}/ghc-${version}-src.tar.xz";
|
||||
sha256 = "1c8qc4fhkycynk4g1f9hvk53dj6a1vvqi6bklqznns6hw59m8qhi";
|
||||
};
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
outputs = [ "out" "man" "doc" ];
|
||||
|
||||
patches = [
|
||||
./ghc-gold-linker.patch
|
||||
(fetchpatch { # Unreleased 1.24.x commit
|
||||
url = "https://github.com/haskell/cabal/commit/6394cb0b6eba91a8692a3d04b2b56935aed7cccd.patch";
|
||||
sha256 = "14xxjg0nb1j1pw0riac3v385ka92qhxxblfmwyvbghz7kry6axy0";
|
||||
stripLen = 1;
|
||||
extraPrefix = "libraries/Cabal/";
|
||||
})
|
||||
] ++ stdenv.lib.optional stdenv.isLinux ./ghc-no-madv-free.patch
|
||||
++ stdenv.lib.optional stdenv.isDarwin ./ghc-8.0.2-no-cpp-warnings.patch
|
||||
++ stdenv.lib.optional stdenv.isDarwin ./backport-dylib-command-size-limit.patch;
|
||||
|
||||
postPatch = "patchShebangs .";
|
||||
|
||||
# GHC is a bit confused on its cross terminology.
|
||||
preConfigure = ''
|
||||
for env in $(env | grep '^TARGET_' | sed -E 's|\+?=.*||'); do
|
||||
export "''${env#TARGET_}=''${!env}"
|
||||
done
|
||||
# GHC is a bit confused on its cross terminology, as these would normally be
|
||||
# the *host* tools.
|
||||
export CC="${targetCC}/bin/${targetCC.targetPrefix}cc"
|
||||
export CXX="${targetCC}/bin/${targetCC.targetPrefix}cxx"
|
||||
export LD="${targetCC.bintools}/bin/${targetCC.bintools.targetPrefix}ld"
|
||||
export AS="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}as"
|
||||
export AR="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}ar"
|
||||
export NM="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}nm"
|
||||
export RANLIB="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}ranlib"
|
||||
export READELF="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}readelf"
|
||||
export STRIP="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}strip"
|
||||
|
||||
echo -n "${buildMK}" > mk/build.mk
|
||||
sed -i -e 's|-isysroot /Developer/SDKs/MacOSX10.5.sdk||' configure
|
||||
'' + stdenv.lib.optionalString (!stdenv.isDarwin) ''
|
||||
export NIX_LDFLAGS+=" -rpath $out/lib/ghc-${version}"
|
||||
'' + stdenv.lib.optionalString stdenv.isDarwin ''
|
||||
export NIX_LDFLAGS+=" -no_dtrace_dof"
|
||||
'';
|
||||
|
||||
# TODO(@Ericson2314): Always pass "--target" and always prefix.
|
||||
configurePlatforms = [ "build" "host" ]
|
||||
++ stdenv.lib.optional (targetPlatform != hostPlatform) "target";
|
||||
# `--with` flags for libraries needed for RTS linker
|
||||
configureFlags = [
|
||||
"--datadir=$doc/share/doc/ghc"
|
||||
"--with-curses-includes=${ncurses.dev}/include" "--with-curses-libraries=${ncurses.out}/lib"
|
||||
] ++ stdenv.lib.optional (targetPlatform == hostPlatform && ! enableIntegerSimple) [
|
||||
"--with-gmp-includes=${targetPackages.gmp.dev}/include" "--with-gmp-libraries=${targetPackages.gmp.out}/lib"
|
||||
] ++ stdenv.lib.optional (targetPlatform == hostPlatform && hostPlatform.libc != "glibc") [
|
||||
"--with-iconv-includes=${libiconv}/include" "--with-iconv-libraries=${libiconv}/lib"
|
||||
] ++ stdenv.lib.optionals (targetPlatform != hostPlatform) [
|
||||
"--enable-bootstrap-with-devel-snapshot"
|
||||
] ++ stdenv.lib.optionals (targetPlatform.isDarwin && targetPlatform.isAarch64) [
|
||||
# fix for iOS: https://www.reddit.com/r/haskell/comments/4ttdz1/building_an_osxi386_to_iosarm64_cross_compiler/d5qvd67/
|
||||
"--disable-large-address-space"
|
||||
];
|
||||
|
||||
# Make sure we never relax`$PATH` and hooks support for compatability.
|
||||
strictDeps = true;
|
||||
|
||||
nativeBuildInputs = [
|
||||
perl sphinx
|
||||
ghc bootPkgs.hscolour
|
||||
];
|
||||
|
||||
# For building runtime libs
|
||||
depsBuildTarget = toolsForTarget;
|
||||
|
||||
buildInputs = libDeps hostPlatform;
|
||||
|
||||
propagatedBuildInputs = [ targetPackages.stdenv.cc ]
|
||||
++ stdenv.lib.optional useLLVM llvmPackages.llvm;
|
||||
|
||||
depsTargetTarget = map stdenv.lib.getDev (libDeps targetPlatform);
|
||||
depsTargetTargetPropagated = map (stdenv.lib.getOutput "out") (libDeps targetPlatform);
|
||||
|
||||
# required, because otherwise all symbols from HSffi.o are stripped, and
|
||||
# that in turn causes GHCi to abort
|
||||
stripDebugFlags = [ "-S" ] ++ stdenv.lib.optional (!targetPlatform.isDarwin) "--keep-file-symbols";
|
||||
|
||||
hardeningDisable = [ "format" ];
|
||||
|
||||
postInstall = ''
|
||||
for bin in "$out"/lib/${name}/bin/*; do
|
||||
isELF "$bin" || continue
|
||||
paxmark m "$bin"
|
||||
done
|
||||
|
||||
# Install the bash completion file.
|
||||
install -D -m 444 utils/completion/ghc.bash $out/share/bash-completion/completions/${targetPrefix}ghc
|
||||
|
||||
# Patch scripts to include "readelf" and "cat" in $PATH.
|
||||
for i in "$out/bin/"*; do
|
||||
test ! -h $i || continue
|
||||
egrep --quiet '^#!' <(head -n 1 $i) || continue
|
||||
sed -i -e '2i export PATH="$PATH:${stdenv.lib.makeBinPath [ targetPackages.stdenv.cc.bintools coreutils ]}"' $i
|
||||
done
|
||||
'';
|
||||
|
||||
passthru = {
|
||||
inherit bootPkgs targetPrefix;
|
||||
|
||||
inherit llvmPackages;
|
||||
inherit enableShared;
|
||||
|
||||
# Our Cabal compiler name
|
||||
haskellCompilerName = "ghc-8.0.2";
|
||||
};
|
||||
|
||||
meta = {
|
||||
homepage = http://haskell.org/ghc;
|
||||
description = "The Glasgow Haskell Compiler";
|
||||
maintainers = with stdenv.lib.maintainers; [ marcweber andres peti ];
|
||||
inherit (ghc.meta) license platforms;
|
||||
};
|
||||
|
||||
}
|
||||
@@ -1,247 +0,0 @@
|
||||
{ stdenv, targetPackages
|
||||
|
||||
# build-tools
|
||||
, bootPkgs
|
||||
, autoconf, automake, coreutils, fetchurl, fetchpatch, perl, python3, m4
|
||||
|
||||
, libiconv ? null, ncurses
|
||||
|
||||
, useLLVM ? !stdenv.targetPlatform.isx86 || (stdenv.targetPlatform.isMusl && stdenv.hostPlatform != stdenv.targetPlatform)
|
||||
, # LLVM is conceptually a run-time-only depedendency, but for
|
||||
# non-x86, we need LLVM to bootstrap later stages, so it becomes a
|
||||
# build-time dependency too.
|
||||
buildLlvmPackages, llvmPackages
|
||||
|
||||
, # If enabled, GHC will be built with the GPL-free but slower integer-simple
|
||||
# library instead of the faster but GPLed integer-gmp library.
|
||||
enableIntegerSimple ? !(stdenv.lib.any (stdenv.lib.meta.platformMatch stdenv.hostPlatform) gmp.meta.platforms), gmp
|
||||
|
||||
, # If enabled, use -fPIC when compiling static libs.
|
||||
enableRelocatedStaticLibs ? stdenv.targetPlatform != stdenv.hostPlatform
|
||||
|
||||
, # Whether to build dynamic libs for the standard library (on the target
|
||||
# platform). Static libs are always built.
|
||||
enableShared ? !stdenv.targetPlatform.isWindows && !stdenv.targetPlatform.useiOSPrebuilt
|
||||
|
||||
, # Whetherto build terminfo.
|
||||
enableTerminfo ? !stdenv.targetPlatform.isWindows
|
||||
|
||||
, # What flavour to build. An empty string indicates no
|
||||
# specific flavour and falls back to ghc default values.
|
||||
ghcFlavour ? stdenv.lib.optionalString (stdenv.targetPlatform != stdenv.hostPlatform) "perf-cross"
|
||||
, # Whether to backport https://phabricator.haskell.org/D4388 for
|
||||
# deterministic profiling symbol names, at the cost of a slightly
|
||||
# non-standard GHC API
|
||||
deterministicProfiling ? false
|
||||
}:
|
||||
|
||||
assert !enableIntegerSimple -> gmp != null;
|
||||
|
||||
let
|
||||
inherit (stdenv) buildPlatform hostPlatform targetPlatform;
|
||||
|
||||
inherit (bootPkgs) ghc;
|
||||
|
||||
# TODO(@Ericson2314) Make unconditional
|
||||
targetPrefix = stdenv.lib.optionalString
|
||||
(targetPlatform != hostPlatform)
|
||||
"${targetPlatform.config}-";
|
||||
|
||||
buildMK = ''
|
||||
BuildFlavour = ${ghcFlavour}
|
||||
ifneq \"\$(BuildFlavour)\" \"\"
|
||||
include mk/flavours/\$(BuildFlavour).mk
|
||||
endif
|
||||
DYNAMIC_GHC_PROGRAMS = ${if enableShared then "YES" else "NO"}
|
||||
INTEGER_LIBRARY = ${if enableIntegerSimple then "integer-simple" else "integer-gmp"}
|
||||
'' + stdenv.lib.optionalString (targetPlatform != hostPlatform) ''
|
||||
Stage1Only = ${if targetPlatform.system == hostPlatform.system then "NO" else "YES"}
|
||||
CrossCompilePrefix = ${targetPrefix}
|
||||
HADDOCK_DOCS = NO
|
||||
BUILD_SPHINX_HTML = NO
|
||||
BUILD_SPHINX_PDF = NO
|
||||
'' + stdenv.lib.optionalString enableRelocatedStaticLibs ''
|
||||
GhcLibHcOpts += -fPIC
|
||||
GhcRtsHcOpts += -fPIC
|
||||
'' + stdenv.lib.optionalString targetPlatform.useAndroidPrebuilt ''
|
||||
EXTRA_CC_OPTS += -std=gnu99
|
||||
'';
|
||||
|
||||
# Splicer will pull out correct variations
|
||||
libDeps = platform: stdenv.lib.optional enableTerminfo [ ncurses ]
|
||||
++ stdenv.lib.optional (!enableIntegerSimple) gmp
|
||||
++ stdenv.lib.optional (platform.libc != "glibc" && !targetPlatform.isWindows) libiconv;
|
||||
|
||||
toolsForTarget =
|
||||
if hostPlatform == buildPlatform then
|
||||
[ targetPackages.stdenv.cc ] ++ stdenv.lib.optional useLLVM llvmPackages.llvm
|
||||
else assert targetPlatform == hostPlatform; # build != host == target
|
||||
[ stdenv.cc ] ++ stdenv.lib.optional useLLVM buildLlvmPackages.llvm;
|
||||
|
||||
targetCC = builtins.head toolsForTarget;
|
||||
|
||||
in
|
||||
stdenv.mkDerivation (rec {
|
||||
version = "8.4.3";
|
||||
name = "${targetPrefix}ghc-${version}";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://downloads.haskell.org/~ghc/${version}/ghc-${version}-src.tar.xz";
|
||||
sha256 = "1mk046vb561j75saz05rghhbkps46ym5aci4264dwc2qk3dayixf";
|
||||
};
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
outputs = [ "out" "doc" ];
|
||||
|
||||
patches = [(fetchpatch {
|
||||
url = "https://git.haskell.org/hsc2hs.git/patch/738f3666c878ee9e79c3d5e819ef8b3460288edf";
|
||||
sha256 = "0plzsbfaq6vb1023lsarrjglwgr9chld4q3m99rcfzx0yx5mibp3";
|
||||
extraPrefix = "utils/hsc2hs/";
|
||||
stripLen = 1;
|
||||
}) (fetchpatch rec { # https://phabricator.haskell.org/D5123
|
||||
url = "http://tarballs.nixos.org/sha256/${sha256}";
|
||||
name = "D5123.diff";
|
||||
sha256 = "0nhqwdamf2y4gbwqxcgjxs0kqx23w9gv5kj0zv6450dq19rji82n";
|
||||
})] ++ stdenv.lib.optional deterministicProfiling
|
||||
(fetchpatch rec {
|
||||
url = "http://tarballs.nixos.org/sha256/${sha256}";
|
||||
name = "D4388.diff";
|
||||
sha256 = "0w6sdcvnqjlnlzpvnzw20b80v150ijjyjvs9548ildc1928j0w7s";
|
||||
})
|
||||
++ stdenv.lib.optional stdenv.isDarwin ./backport-dylib-command-size-limit.patch;
|
||||
|
||||
postPatch = "patchShebangs .";
|
||||
|
||||
# GHC is a bit confused on its cross terminology.
|
||||
preConfigure = ''
|
||||
for env in $(env | grep '^TARGET_' | sed -E 's|\+?=.*||'); do
|
||||
export "''${env#TARGET_}=''${!env}"
|
||||
done
|
||||
# GHC is a bit confused on its cross terminology, as these would normally be
|
||||
# the *host* tools.
|
||||
export CC="${targetCC}/bin/${targetCC.targetPrefix}cc"
|
||||
export CXX="${targetCC}/bin/${targetCC.targetPrefix}cxx"
|
||||
# Use gold to work around https://sourceware.org/bugzilla/show_bug.cgi?id=16177
|
||||
export LD="${targetCC.bintools}/bin/${targetCC.bintools.targetPrefix}ld${stdenv.lib.optionalString targetPlatform.isAarch32 ".gold"}"
|
||||
export AS="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}as"
|
||||
export AR="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}ar"
|
||||
export NM="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}nm"
|
||||
export RANLIB="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}ranlib"
|
||||
export READELF="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}readelf"
|
||||
export STRIP="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}strip"
|
||||
|
||||
echo -n "${buildMK}" > mk/build.mk
|
||||
sed -i -e 's|-isysroot /Developer/SDKs/MacOSX10.5.sdk||' configure
|
||||
'' + stdenv.lib.optionalString (!stdenv.isDarwin) ''
|
||||
export NIX_LDFLAGS+=" -rpath $out/lib/ghc-${version}"
|
||||
'' + stdenv.lib.optionalString stdenv.isDarwin ''
|
||||
export NIX_LDFLAGS+=" -no_dtrace_dof"
|
||||
'' + stdenv.lib.optionalString targetPlatform.useAndroidPrebuilt ''
|
||||
sed -i -e '5i ,("armv7a-unknown-linux-androideabi", ("e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64", "cortex-a8", ""))' llvm-targets
|
||||
'' + stdenv.lib.optionalString targetPlatform.isMusl ''
|
||||
echo "patching llvm-targets for musl targets..."
|
||||
echo "Cloning these existing '*-linux-gnu*' targets:"
|
||||
grep linux-gnu llvm-targets | sed 's/^/ /'
|
||||
echo "(go go gadget sed)"
|
||||
sed -i 's,\(^.*linux-\)gnu\(.*\)$,\0\n\1musl\2,' llvm-targets
|
||||
echo "llvm-targets now contains these '*-linux-musl*' targets:"
|
||||
grep linux-musl llvm-targets | sed 's/^/ /'
|
||||
|
||||
echo "And now patching to preserve '-musleabi' as done with '-gnueabi'"
|
||||
# (aclocal.m4 is actual source, but patch configure as well since we don't re-gen)
|
||||
for x in configure aclocal.m4; do
|
||||
substituteInPlace $x \
|
||||
--replace '*-android*|*-gnueabi*)' \
|
||||
'*-android*|*-gnueabi*|*-musleabi*)'
|
||||
done
|
||||
'';
|
||||
|
||||
# TODO(@Ericson2314): Always pass "--target" and always prefix.
|
||||
configurePlatforms = [ "build" "host" ]
|
||||
++ stdenv.lib.optional (targetPlatform != hostPlatform) "target";
|
||||
# `--with` flags for libraries needed for RTS linker
|
||||
configureFlags = [
|
||||
"--datadir=$doc/share/doc/ghc"
|
||||
"--with-curses-includes=${ncurses.dev}/include" "--with-curses-libraries=${ncurses.out}/lib"
|
||||
] ++ stdenv.lib.optional (targetPlatform == hostPlatform && !enableIntegerSimple) [
|
||||
"--with-gmp-includes=${targetPackages.gmp.dev}/include" "--with-gmp-libraries=${targetPackages.gmp.out}/lib"
|
||||
] ++ stdenv.lib.optional (targetPlatform == hostPlatform && hostPlatform.libc != "glibc" && !targetPlatform.isWindows) [
|
||||
"--with-iconv-includes=${libiconv}/include" "--with-iconv-libraries=${libiconv}/lib"
|
||||
] ++ stdenv.lib.optionals (targetPlatform != hostPlatform) [
|
||||
"--enable-bootstrap-with-devel-snapshot"
|
||||
] ++ stdenv.lib.optionals (targetPlatform.isAarch32) [
|
||||
"CFLAGS=-fuse-ld=gold"
|
||||
"CONF_GCC_LINKER_OPTS_STAGE1=-fuse-ld=gold"
|
||||
"CONF_GCC_LINKER_OPTS_STAGE2=-fuse-ld=gold"
|
||||
] ++ stdenv.lib.optionals (targetPlatform.isDarwin && targetPlatform.isAarch64) [
|
||||
# fix for iOS: https://www.reddit.com/r/haskell/comments/4ttdz1/building_an_osxi386_to_iosarm64_cross_compiler/d5qvd67/
|
||||
"--disable-large-address-space"
|
||||
];
|
||||
|
||||
# Make sure we never relax`$PATH` and hooks support for compatability.
|
||||
strictDeps = true;
|
||||
|
||||
nativeBuildInputs = [
|
||||
perl autoconf automake m4 python3
|
||||
ghc bootPkgs.alex bootPkgs.happy bootPkgs.hscolour
|
||||
];
|
||||
|
||||
# For building runtime libs
|
||||
depsBuildTarget = toolsForTarget;
|
||||
|
||||
buildInputs = libDeps hostPlatform;
|
||||
|
||||
propagatedBuildInputs = [ targetPackages.stdenv.cc ]
|
||||
++ stdenv.lib.optional useLLVM llvmPackages.llvm;
|
||||
|
||||
depsTargetTarget = map stdenv.lib.getDev (libDeps targetPlatform);
|
||||
depsTargetTargetPropagated = map (stdenv.lib.getOutput "out") (libDeps targetPlatform);
|
||||
|
||||
# required, because otherwise all symbols from HSffi.o are stripped, and
|
||||
# that in turn causes GHCi to abort
|
||||
stripDebugFlags = [ "-S" ] ++ stdenv.lib.optional (!targetPlatform.isDarwin) "--keep-file-symbols";
|
||||
|
||||
checkTarget = "test";
|
||||
|
||||
hardeningDisable = [ "format" ];
|
||||
|
||||
postInstall = ''
|
||||
for bin in "$out"/lib/${name}/bin/*; do
|
||||
isELF "$bin" || continue
|
||||
paxmark m "$bin"
|
||||
done
|
||||
|
||||
# Install the bash completion file.
|
||||
install -D -m 444 utils/completion/ghc.bash $out/share/bash-completion/completions/${targetPrefix}ghc
|
||||
|
||||
# Patch scripts to include "readelf" and "cat" in $PATH.
|
||||
for i in "$out/bin/"*; do
|
||||
test ! -h $i || continue
|
||||
egrep --quiet '^#!' <(head -n 1 $i) || continue
|
||||
sed -i -e '2i export PATH="$PATH:${stdenv.lib.makeBinPath [ targetPackages.stdenv.cc.bintools coreutils ]}"' $i
|
||||
done
|
||||
'';
|
||||
|
||||
passthru = {
|
||||
inherit bootPkgs targetPrefix;
|
||||
|
||||
inherit llvmPackages;
|
||||
inherit enableShared;
|
||||
|
||||
# Our Cabal compiler name
|
||||
haskellCompilerName = "ghc-8.4.3";
|
||||
};
|
||||
|
||||
meta = {
|
||||
homepage = http://haskell.org/ghc;
|
||||
description = "The Glasgow Haskell Compiler";
|
||||
maintainers = with stdenv.lib.maintainers; [ marcweber andres peti ];
|
||||
inherit (ghc.meta) license platforms;
|
||||
};
|
||||
|
||||
} // stdenv.lib.optionalAttrs targetPlatform.useAndroidPrebuilt {
|
||||
dontStrip = true;
|
||||
dontPatchELF = true;
|
||||
noAuditTmpdir = true;
|
||||
})
|
||||
@@ -1,23 +0,0 @@
|
||||
--- b/includes/rts/storage/ClosureMacros.h 2017-05-21 12:54:09.000000000 +0200
|
||||
+++ a/includes/rts/storage/ClosureMacros.h 2017-05-21 12:55:57.000000000 +0200
|
||||
@@ -499,8 +499,17 @@
|
||||
|
||||
-------------------------------------------------------------------------- */
|
||||
|
||||
-#define ZERO_SLOP_FOR_LDV_PROF (defined(PROFILING))
|
||||
-#define ZERO_SLOP_FOR_SANITY_CHECK (defined(DEBUG) && !defined(THREADED_RTS))
|
||||
+#if defined(PROFILING)
|
||||
+#define ZERO_SLOP_FOR_LDV_PROF 1
|
||||
+#else
|
||||
+#define ZERO_SLOP_FOR_LDV_PROF 0
|
||||
+#endif
|
||||
+
|
||||
+#if defined(DEBUG) && !defined(THREADED_RTS)
|
||||
+#define ZERO_SLOP_FOR_SANITY_CHECK 1
|
||||
+#else
|
||||
+#define ZERO_SLOP_FOR_SANITY_CHECK 0
|
||||
+#endif
|
||||
|
||||
#if ZERO_SLOP_FOR_LDV_PROF || ZERO_SLOP_FOR_SANITY_CHECK
|
||||
#define OVERWRITING_CLOSURE(c) overwritingClosure(c)
|
||||
|
||||
@@ -1,54 +0,0 @@
|
||||
From 46fe80ab7c0013a929d0934e61429820042a70a9 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Niklas=20Hamb=C3=BCchen?= <mail@nh2.me>
|
||||
Date: Fri, 21 Jul 2017 20:09:11 +0200
|
||||
Subject: [PATCH 1/2] base: Add `extra-libraries: m` because base uses libm
|
||||
functions.
|
||||
|
||||
Linking with gold needs this because in contrast to ld, gold
|
||||
doesn't implicitly link libm.
|
||||
|
||||
Found by Michael Bishop <cleverca22@gmail.com>.
|
||||
---
|
||||
libraries/base/base.cabal | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/libraries/base/base.cabal b/libraries/base/base.cabal
|
||||
index f00fb8768e5..fd91f268ffe 100644
|
||||
--- a/libraries/base/base.cabal
|
||||
+++ b/libraries/base/base.cabal
|
||||
@@ -342,6 +342,10 @@ Library
|
||||
WCsubst.h
|
||||
consUtils.h
|
||||
|
||||
+ -- Base uses libm functions. ld.bfd links libm implicitly when necessary.
|
||||
+ -- Other linkers, like gold, don't, so we have to declare it explicitly.
|
||||
+ extra-libraries: m
|
||||
+
|
||||
-- OS Specific
|
||||
if os(windows)
|
||||
-- Windows requires some extra libraries for linking because the RTS
|
||||
|
||||
From 900a8f4931e9bc6d3219d9263cfecfc6af8fc766 Mon Sep 17 00:00:00 2001
|
||||
From: michael bishop <cleverca22@gmail.com>
|
||||
Date: Sat, 22 Jul 2017 13:12:39 -0300
|
||||
Subject: [PATCH 2/2] also add -lm to ghc-prim
|
||||
|
||||
---
|
||||
libraries/ghc-prim/ghc-prim.cabal | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/libraries/ghc-prim/ghc-prim.cabal b/libraries/ghc-prim/ghc-prim.cabal
|
||||
index 00a029efedf..6db85dd69fc 100644
|
||||
--- a/libraries/ghc-prim/ghc-prim.cabal
|
||||
+++ b/libraries/ghc-prim/ghc-prim.cabal
|
||||
@@ -42,6 +42,10 @@ Library
|
||||
UnliftedFFITypes
|
||||
|
||||
build-depends: rts == 1.0.*
|
||||
+
|
||||
+ -- Base uses libm functions. ld.bfd links libm implicitly when necessary.
|
||||
+ -- Other linkers, like gold, don't, so we have to declare it explicitly.
|
||||
+ extra-libraries: m
|
||||
|
||||
exposed-modules:
|
||||
GHC.CString
|
||||
@@ -1,18 +0,0 @@
|
||||
diff --git a/rts/posix/OSMem.c b/rts/posix/OSMem.c
|
||||
index 99620ee..e052a84 100644
|
||||
--- a/rts/posix/OSMem.c
|
||||
+++ b/rts/posix/OSMem.c
|
||||
@@ -523,13 +523,7 @@ void osDecommitMemory(void *at, W_ size)
|
||||
sysErrorBelch("unable to make released memory unaccessible");
|
||||
#endif
|
||||
|
||||
-#ifdef MADV_FREE
|
||||
- // Try MADV_FREE first, FreeBSD has both and MADV_DONTNEED
|
||||
- // just swaps memory out
|
||||
- r = madvise(at, size, MADV_FREE);
|
||||
-#else
|
||||
r = madvise(at, size, MADV_DONTNEED);
|
||||
-#endif
|
||||
if(r < 0)
|
||||
sysErrorBelch("unable to decommit memory");
|
||||
}
|
||||
@@ -1,27 +0,0 @@
|
||||
Adding support for the R_X86_64_REX_GOTPCRELX relocation type.
|
||||
This relocation is treated by the linker the same as the R_X86_64_GOTPCRELX type
|
||||
G + GOT + A - P to generate relative offsets to the GOT.
|
||||
The REX prefix has no influence in this stage.
|
||||
|
||||
This caused breakage when enabling relro/bindnow hardening e.g. in ghcPaclages.vector
|
||||
|
||||
Source: https://phabricator.haskell.org/D2303#67070
|
||||
diff --git a/rts/Linker.c b/rts/Linker.c
|
||||
--- a/rts/Linker.c
|
||||
+++ b/rts/Linker.c
|
||||
@@ -5681,7 +5681,13 @@
|
||||
*(Elf64_Sword *)P = (Elf64_Sword)value;
|
||||
#endif
|
||||
break;
|
||||
-
|
||||
+/* These two relocations were introduced in glibc 2.23 and binutils 2.26.
|
||||
+ But in order to use them the system which compiles the bindist for GHC needs
|
||||
+ to have glibc >= 2.23. So only use them if they're defined. */
|
||||
+#if defined(R_X86_64_REX_GOTPCRELX) && defined(R_X86_64_GOTPCRELX)
|
||||
+ case R_X86_64_REX_GOTPCRELX:
|
||||
+ case R_X86_64_GOTPCRELX:
|
||||
+#endif
|
||||
case R_X86_64_GOTPCREL:
|
||||
{
|
||||
StgInt64 gotAddress = (StgInt64) &makeSymbolExtra(oc, ELF_R_SYM(info), S)->addr;
|
||||
|
||||
@@ -1,104 +0,0 @@
|
||||
diff --git a/src-bin/Boot.hs b/src-bin/Boot.hs
|
||||
index db8b12e..7b815c5 100644
|
||||
--- a/src-bin/Boot.hs
|
||||
+++ b/src-bin/Boot.hs
|
||||
@@ -540,9 +540,7 @@ initPackageDB :: B ()
|
||||
initPackageDB = do
|
||||
msg info "creating package databases"
|
||||
initDB "--global" <^> beLocations . blGlobalDB
|
||||
- traverseOf_ _Just initUser <^> beLocations . blUserDBDir
|
||||
where
|
||||
- initUser dir = rm_f (dir </> "package.conf") >> initDB "--user" (dir </> "package.conf.d")
|
||||
initDB dbName db = do
|
||||
rm_rf db >> mkdir_p db
|
||||
ghcjs_pkg_ ["init", toTextI db] `catchAny_` return ()
|
||||
@@ -566,29 +564,22 @@ installDevelopmentTree = subTop $ do
|
||||
msgD info $ "preparing development boot tree"
|
||||
checkpoint' "ghcjs-boot-git" "ghcjs-boot repository already cloned and prepared" $ do
|
||||
testGit "ghcjs-boot" >>= \case
|
||||
- Just False -> failWith "ghcjs-boot already exists and is not a git repository"
|
||||
- Just True -> do
|
||||
- msg info "ghcjs-boot repository already exists but checkpoint not reached, cleaning first, then cloning"
|
||||
- rm_rf "ghcjs-boot"
|
||||
+ Just _ -> do
|
||||
+ msg info "ghcjs-boot repository already exists; initializing ghcjs-boot"
|
||||
initGhcjsBoot
|
||||
Nothing -> do
|
||||
msgD info "cloning ghcjs-boot git repository"
|
||||
initGhcjsBoot
|
||||
checkpoint' "shims-git" "shims repository already cloned" $ do
|
||||
testGit "shims" >>= \case
|
||||
- Just False -> failWith "shims already exists and is not a git repository"
|
||||
- Just True -> do
|
||||
- msgD info "shims repository already exists but checkpoint not reached, cleaning first, then cloning"
|
||||
- rm_rf "shims"
|
||||
- cloneGit shimsDescr "shims" bsrcShimsDevBranch bsrcShimsDev
|
||||
+ Just _ -> do
|
||||
+ msgD info "shims repository already exists; moving on"
|
||||
Nothing -> do
|
||||
msgD info "cloning shims git repository"
|
||||
cloneGit shimsDescr "shims" bsrcShimsDevBranch bsrcShimsDev
|
||||
where
|
||||
initGhcjsBoot = sub $ do
|
||||
- cloneGit bootDescr "ghcjs-boot" bsrcBootDevBranch bsrcBootDev
|
||||
cd "ghcjs-boot"
|
||||
- git_ ["submodule", "update", "--init", "--recursive"]
|
||||
mapM_ patchPackage =<< allPackages
|
||||
preparePrimops
|
||||
buildGenPrim
|
||||
@@ -1141,7 +1132,7 @@ cabalStage1 pkgs = sub $ do
|
||||
globalFlags <- cabalGlobalFlags
|
||||
flags <- cabalInstallFlags (length pkgs == 1)
|
||||
let args = globalFlags ++ ("install" : pkgs) ++
|
||||
- [ "--solver=topdown" -- the modular solver refuses to install stage1 packages
|
||||
+ [ "--allow-boot-library-installs"
|
||||
] ++ map ("--configure-option="<>) configureOpts ++ flags
|
||||
checkInstallPlan pkgs args
|
||||
cabal_ args
|
||||
@@ -1162,7 +1153,7 @@ cabalInstall pkgs = do
|
||||
-- uses somewhat fragile parsing of --dry-run output, find a better way
|
||||
checkInstallPlan :: [Package] -> [Text] -> B ()
|
||||
checkInstallPlan pkgs opts = do
|
||||
- plan <- cabal (opts ++ ["-v2", "--dry-run"])
|
||||
+ plan <- cabal (opts ++ ["-vverbose+nowrap", "--dry-run"])
|
||||
when (hasReinstalls plan || hasUnexpectedInstalls plan || hasNewVersion plan) (err plan)
|
||||
where
|
||||
hasReinstalls = T.isInfixOf "(reinstall)" -- reject reinstalls
|
||||
@@ -1201,14 +1192,14 @@ cabalInstallFlags parmakeGhcjs = do
|
||||
, "--avoid-reinstalls"
|
||||
, "--builddir", "dist"
|
||||
, "--with-compiler", ghcjs ^. pgmLocText
|
||||
+ , "--with-gcc", "@CC@"
|
||||
, "--with-hc-pkg", ghcjsPkg ^. pgmLocText
|
||||
- , "--prefix", toTextI instDir
|
||||
+ , "--prefix", "@PREFIX@"
|
||||
+ , "--libdir", "$prefix/lib/$compiler"
|
||||
+ , "--libsubdir", "$pkgid"
|
||||
, bool haddock "--enable-documentation" "--disable-documentation"
|
||||
, "--haddock-html"
|
||||
--- workaround for hoogle support being broken in haddock for GHC 7.10RC1
|
||||
-#if !(__GLASGOW_HASKELL__ >= 709)
|
||||
, "--haddock-hoogle"
|
||||
-#endif
|
||||
, "--haddock-hyperlink-source"
|
||||
-- don't slow down Windows builds too much, on other platforms we get this more
|
||||
-- or less for free, thanks to dynamic-too
|
||||
diff --git a/src/Compiler/Info.hs b/src/Compiler/Info.hs
|
||||
index 33a401f..e2405a7 100644
|
||||
--- a/src/Compiler/Info.hs
|
||||
+++ b/src/Compiler/Info.hs
|
||||
@@ -48,13 +48,7 @@ compilerInfo nativeToo dflags = do
|
||||
|
||||
-- | the directory to use if started without -B flag
|
||||
getDefaultTopDir :: IO FilePath
|
||||
-getDefaultTopDir = do
|
||||
- appdir <- getAppUserDataDirectory "ghcjs"
|
||||
- return (appdir </> subdir </> "ghcjs")
|
||||
- where
|
||||
- targetARCH = arch
|
||||
- targetOS = os
|
||||
- subdir = targetARCH ++ '-':targetOS ++ '-':getFullCompilerVersion
|
||||
+getDefaultTopDir = return "@PREFIX@/lib/ghcjs-@VERSION@"
|
||||
|
||||
getDefaultLibDir :: IO FilePath
|
||||
getDefaultLibDir = getDefaultTopDir
|
||||
@@ -1,50 +0,0 @@
|
||||
{ fetchgit, fetchFromGitHub, bootPkgs, cabal-install }:
|
||||
|
||||
bootPkgs.callPackage ../base.nix {
|
||||
version = "0.2.0";
|
||||
|
||||
inherit bootPkgs cabal-install;
|
||||
|
||||
ghcjsSrc = fetchFromGitHub {
|
||||
owner = "ghcjs";
|
||||
repo = "ghcjs";
|
||||
rev = "689c7753f50353dd05606ed79c51cd5a94d3922a";
|
||||
sha256 = "076020a9gjv8ldj5ckm43sbzq9s6c5xj6lpd8v28ybpiama3m6b4";
|
||||
};
|
||||
ghcjsBootSrc = fetchgit {
|
||||
url = git://github.com/ghcjs/ghcjs-boot.git;
|
||||
rev = "8c549931da27ba9e607f77195208ec156c840c8a";
|
||||
sha256 = "0yg9bnabja39qysh9pg1335qbvbc0r2mdw6cky94p7kavacndfdv";
|
||||
fetchSubmodules = true;
|
||||
};
|
||||
|
||||
shims = import ./shims.nix { inherit fetchFromGitHub; };
|
||||
stage1Packages = [
|
||||
"array"
|
||||
"base"
|
||||
"binary"
|
||||
"bytestring"
|
||||
"containers"
|
||||
"deepseq"
|
||||
"directory"
|
||||
"filepath"
|
||||
"ghc-boot"
|
||||
"ghc-boot-th"
|
||||
"ghc-prim"
|
||||
"ghci"
|
||||
"ghcjs-prim"
|
||||
"ghcjs-th"
|
||||
"integer-gmp"
|
||||
"pretty"
|
||||
"primitive"
|
||||
"process"
|
||||
"rts"
|
||||
"template-haskell"
|
||||
"time"
|
||||
"transformers"
|
||||
"unix"
|
||||
];
|
||||
stage2 = import ./stage2.nix;
|
||||
|
||||
patches = [ ./boot.patch ];
|
||||
}
|
||||
@@ -1,7 +0,0 @@
|
||||
{ fetchFromGitHub }:
|
||||
fetchFromGitHub {
|
||||
owner = "ghcjs";
|
||||
repo = "shims";
|
||||
rev = "b97015229c58eeab7c1d0bb575794b14a9f6efca";
|
||||
sha256 = "1p5adkqvmb1gsv9hnn3if0rdpnaq3v9a1zkfdy282yw05jaaaggz";
|
||||
}
|
||||
@@ -1,344 +0,0 @@
|
||||
{ ghcjsBoot }: { callPackage }:
|
||||
|
||||
{
|
||||
async = callPackage
|
||||
({ mkDerivation, base, HUnit, stdenv, stm, test-framework
|
||||
, test-framework-hunit
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "async";
|
||||
version = "2.0.1.6";
|
||||
src = "${ghcjsBoot}/boot/async";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base stm ];
|
||||
testHaskellDepends = [
|
||||
base HUnit test-framework test-framework-hunit
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = https://github.com/simonmar/async;
|
||||
description = "Run IO operations asynchronously and wait for their results";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
aeson = callPackage
|
||||
({ mkDerivation, attoparsec, base, bytestring, containers, deepseq
|
||||
, dlist, ghc-prim, hashable, HUnit, mtl, QuickCheck, scientific
|
||||
, stdenv, syb, template-haskell, test-framework
|
||||
, test-framework-hunit, test-framework-quickcheck2, text, time
|
||||
, transformers, unordered-containers, vector
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "aeson";
|
||||
version = "0.9.0.1";
|
||||
src = "${ghcjsBoot}/boot/aeson";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [
|
||||
attoparsec base bytestring containers deepseq dlist ghc-prim
|
||||
hashable mtl scientific syb template-haskell text time transformers
|
||||
unordered-containers vector
|
||||
];
|
||||
testHaskellDepends = [
|
||||
attoparsec base bytestring containers ghc-prim HUnit QuickCheck
|
||||
template-haskell test-framework test-framework-hunit
|
||||
test-framework-quickcheck2 text time unordered-containers vector
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = https://github.com/bos/aeson;
|
||||
description = "Fast JSON parsing and encoding";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
attoparsec = callPackage
|
||||
({ mkDerivation, array, base, bytestring, containers, deepseq
|
||||
, QuickCheck, quickcheck-unicode, scientific, stdenv
|
||||
, test-framework, test-framework-quickcheck2, text, transformers
|
||||
, vector
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "attoparsec";
|
||||
version = "0.13.0.1";
|
||||
src = "${ghcjsBoot}/boot/attoparsec";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [
|
||||
array base bytestring containers deepseq scientific text
|
||||
transformers
|
||||
];
|
||||
testHaskellDepends = [
|
||||
array base bytestring containers deepseq QuickCheck
|
||||
quickcheck-unicode scientific test-framework
|
||||
test-framework-quickcheck2 text transformers vector
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = https://github.com/bos/attoparsec;
|
||||
description = "Fast combinator parsing for bytestrings and text";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
case-insensitive = callPackage
|
||||
({ mkDerivation, base, bytestring, deepseq, hashable, HUnit, stdenv
|
||||
, test-framework, test-framework-hunit, text
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "case-insensitive";
|
||||
version = "1.2.0.4";
|
||||
src = "${ghcjsBoot}/boot/case-insensitive";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base bytestring deepseq hashable text ];
|
||||
testHaskellDepends = [
|
||||
base bytestring HUnit test-framework test-framework-hunit text
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = https://github.com/basvandijk/case-insensitive;
|
||||
description = "Case insensitive string comparison";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
dlist = callPackage
|
||||
({ mkDerivation, base, Cabal, deepseq, QuickCheck, stdenv }:
|
||||
mkDerivation {
|
||||
pname = "dlist";
|
||||
version = "0.7.1.1";
|
||||
src = "${ghcjsBoot}/boot/dlist";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base deepseq ];
|
||||
testHaskellDepends = [ base Cabal QuickCheck ];
|
||||
jailbreak = true;
|
||||
homepage = https://github.com/spl/dlist;
|
||||
description = "Difference lists";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
extensible-exceptions = callPackage
|
||||
({ mkDerivation, base, stdenv }:
|
||||
mkDerivation {
|
||||
pname = "extensible-exceptions";
|
||||
version = "0.1.1.4";
|
||||
src = "${ghcjsBoot}/boot/extensible-exceptions";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base ];
|
||||
jailbreak = true;
|
||||
description = "Extensible exceptions";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
hashable = callPackage
|
||||
({ mkDerivation, base, bytestring, ghc-prim, HUnit, integer-gmp
|
||||
, QuickCheck, random, stdenv, test-framework, test-framework-hunit
|
||||
, test-framework-quickcheck2, text, unix
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "hashable";
|
||||
version = "1.2.3.2";
|
||||
src = "${ghcjsBoot}/boot/hashable";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [
|
||||
base bytestring ghc-prim integer-gmp text
|
||||
];
|
||||
testHaskellDepends = [
|
||||
base bytestring ghc-prim HUnit QuickCheck random test-framework
|
||||
test-framework-hunit test-framework-quickcheck2 text unix
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = https://github.com/tibbe/hashable;
|
||||
description = "A class for types that can be converted to a hash value";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
mtl = callPackage
|
||||
({ mkDerivation, base, stdenv, transformers }:
|
||||
mkDerivation {
|
||||
pname = "mtl";
|
||||
version = "2.2.1";
|
||||
src = "${ghcjsBoot}/boot/mtl";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base transformers ];
|
||||
jailbreak = true;
|
||||
homepage = https://github.com/ekmett/mtl;
|
||||
description = "Monad classes, using functional dependencies";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
old-time = callPackage
|
||||
({ mkDerivation, base, old-locale, stdenv }:
|
||||
mkDerivation {
|
||||
pname = "old-time";
|
||||
version = "1.1.0.3";
|
||||
src = "${ghcjsBoot}/boot/old-time";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base old-locale ];
|
||||
jailbreak = true;
|
||||
description = "Time library";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
parallel = callPackage
|
||||
({ mkDerivation, array, base, containers, deepseq, stdenv }:
|
||||
mkDerivation {
|
||||
pname = "parallel";
|
||||
version = "3.2.0.6";
|
||||
src = "${ghcjsBoot}/boot/parallel";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ array base containers deepseq ];
|
||||
jailbreak = true;
|
||||
description = "Parallel programming library";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
scientific = callPackage
|
||||
({ mkDerivation, array, base, bytestring, deepseq, ghc-prim
|
||||
, hashable, integer-gmp, QuickCheck, smallcheck, stdenv, tasty
|
||||
, tasty-ant-xml, tasty-hunit, tasty-quickcheck, tasty-smallcheck
|
||||
, text
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "scientific";
|
||||
version = "0.3.3.8";
|
||||
src = "${ghcjsBoot}/boot/scientific";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [
|
||||
array base bytestring deepseq ghc-prim hashable integer-gmp text
|
||||
];
|
||||
testHaskellDepends = [
|
||||
base bytestring QuickCheck smallcheck tasty tasty-ant-xml
|
||||
tasty-hunit tasty-quickcheck tasty-smallcheck text
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = https://github.com/basvandijk/scientific;
|
||||
description = "Numbers represented using scientific notation";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
stm = callPackage
|
||||
({ mkDerivation, array, base, stdenv }:
|
||||
mkDerivation {
|
||||
pname = "stm";
|
||||
version = "2.4.4";
|
||||
src = "${ghcjsBoot}/boot/stm";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ array base ];
|
||||
jailbreak = true;
|
||||
description = "Software Transactional Memory";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
syb = callPackage
|
||||
({ mkDerivation, base, containers, HUnit, mtl, stdenv }:
|
||||
mkDerivation {
|
||||
pname = "syb";
|
||||
version = "0.5.1";
|
||||
src = "${ghcjsBoot}/boot/syb";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base ];
|
||||
testHaskellDepends = [ base containers HUnit mtl ];
|
||||
jailbreak = true;
|
||||
homepage = http://www.cs.uu.nl/wiki/GenericProgramming/SYB;
|
||||
description = "Scrap Your Boilerplate";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
text = callPackage
|
||||
({ mkDerivation, array, base, binary, bytestring, deepseq, directory
|
||||
, ghc-prim, HUnit, integer-gmp, QuickCheck, quickcheck-unicode
|
||||
, random, stdenv, test-framework, test-framework-hunit
|
||||
, test-framework-quickcheck2
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "text";
|
||||
version = "1.2.1.1";
|
||||
src = "${ghcjsBoot}/boot/text";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [
|
||||
array base binary bytestring deepseq ghc-prim integer-gmp
|
||||
];
|
||||
testHaskellDepends = [
|
||||
array base binary bytestring deepseq directory ghc-prim HUnit
|
||||
integer-gmp QuickCheck quickcheck-unicode random test-framework
|
||||
test-framework-hunit test-framework-quickcheck2
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = https://github.com/bos/text;
|
||||
description = "An efficient packed Unicode text type";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
unordered-containers = callPackage
|
||||
({ mkDerivation, base, ChasingBottoms, containers, deepseq, hashable
|
||||
, HUnit, QuickCheck, stdenv, test-framework, test-framework-hunit
|
||||
, test-framework-quickcheck2
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "unordered-containers";
|
||||
version = "0.2.5.1";
|
||||
src = "${ghcjsBoot}/boot/unordered-containers";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base deepseq hashable ];
|
||||
testHaskellDepends = [
|
||||
base ChasingBottoms containers hashable HUnit QuickCheck
|
||||
test-framework test-framework-hunit test-framework-quickcheck2
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = https://github.com/tibbe/unordered-containers;
|
||||
description = "Efficient hashing-based container types";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
vector = callPackage
|
||||
({ mkDerivation, base, deepseq, ghc-prim, primitive, QuickCheck
|
||||
, random, stdenv, template-haskell, test-framework
|
||||
, test-framework-quickcheck2, transformers
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "vector";
|
||||
version = "0.11.0.0";
|
||||
src = "${ghcjsBoot}/boot/vector";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base deepseq ghc-prim primitive ];
|
||||
testHaskellDepends = [
|
||||
base QuickCheck random template-haskell test-framework
|
||||
test-framework-quickcheck2 transformers
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = https://github.com/haskell/vector;
|
||||
description = "Efficient Arrays";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
ghcjs-base = callPackage
|
||||
({ mkDerivation, aeson, array, attoparsec, base, bytestring
|
||||
, containers, deepseq, directory, dlist, ghc-prim, ghcjs-prim
|
||||
, hashable, HUnit, integer-gmp, primitive, QuickCheck
|
||||
, quickcheck-unicode, random, scientific, stdenv, test-framework
|
||||
, test-framework-hunit, test-framework-quickcheck2, text, time
|
||||
, transformers, unordered-containers, vector
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "ghcjs-base";
|
||||
version = "0.2.0.0";
|
||||
src = "${ghcjsBoot}/ghcjs/ghcjs-base";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [
|
||||
aeson attoparsec base bytestring containers deepseq dlist ghc-prim
|
||||
ghcjs-prim hashable integer-gmp primitive scientific text time
|
||||
transformers unordered-containers vector
|
||||
];
|
||||
testHaskellDepends = [
|
||||
array base bytestring deepseq directory ghc-prim ghcjs-prim HUnit
|
||||
primitive QuickCheck quickcheck-unicode random test-framework
|
||||
test-framework-hunit test-framework-quickcheck2 text
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = https://github.com/ghcjs/ghcjs-base;
|
||||
description = "Base library for GHCJS";
|
||||
license = stdenv.lib.licenses.mit;
|
||||
}) {};
|
||||
Cabal = callPackage
|
||||
({ mkDerivation, array, base, binary, bytestring, containers
|
||||
, deepseq, directory, extensible-exceptions, filepath, HUnit
|
||||
, old-time, pretty, process, QuickCheck, regex-posix, stdenv
|
||||
, test-framework, test-framework-hunit, test-framework-quickcheck2
|
||||
, time, unix
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "Cabal";
|
||||
version = "1.22.8.0";
|
||||
src = "${ghcjsBoot}/boot/cabal/Cabal";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [
|
||||
array base binary bytestring containers deepseq directory filepath
|
||||
pretty process time unix
|
||||
];
|
||||
testHaskellDepends = [
|
||||
base bytestring containers directory extensible-exceptions filepath
|
||||
HUnit old-time process QuickCheck regex-posix test-framework
|
||||
test-framework-hunit test-framework-quickcheck2 unix
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = http://www.haskell.org/cabal/;
|
||||
description = "A framework for packaging Haskell software";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
}
|
||||
@@ -1,86 +0,0 @@
|
||||
diff --git a/src-bin/Boot.hs b/src-bin/Boot.hs
|
||||
index db8b12e..7b815c5 100644
|
||||
--- a/src-bin/Boot.hs
|
||||
+++ b/src-bin/Boot.hs
|
||||
@@ -540,9 +540,7 @@ initPackageDB :: B ()
|
||||
initPackageDB = do
|
||||
msg info "creating package databases"
|
||||
initDB "--global" <^> beLocations . blGlobalDB
|
||||
- traverseOf_ _Just initUser <^> beLocations . blUserDBDir
|
||||
where
|
||||
- initUser dir = rm_f (dir </> "package.conf") >> initDB "--user" (dir </> "package.conf.d")
|
||||
initDB dbName db = do
|
||||
rm_rf db >> mkdir_p db
|
||||
ghcjs_pkg_ ["init", toTextI db] `catchAny_` return ()
|
||||
@@ -566,29 +564,22 @@ installDevelopmentTree = subTop $ do
|
||||
msgD info $ "preparing development boot tree"
|
||||
checkpoint' "ghcjs-boot-git" "ghcjs-boot repository already cloned and prepared" $ do
|
||||
testGit "ghcjs-boot" >>= \case
|
||||
- Just False -> failWith "ghcjs-boot already exists and is not a git repository"
|
||||
- Just True -> do
|
||||
- msg info "ghcjs-boot repository already exists but checkpoint not reached, cleaning first, then cloning"
|
||||
- rm_rf "ghcjs-boot"
|
||||
+ Just _ -> do
|
||||
+ msg info "ghcjs-boot repository already exists; initializing ghcjs-boot"
|
||||
initGhcjsBoot
|
||||
Nothing -> do
|
||||
msgD info "cloning ghcjs-boot git repository"
|
||||
initGhcjsBoot
|
||||
checkpoint' "shims-git" "shims repository already cloned" $ do
|
||||
testGit "shims" >>= \case
|
||||
- Just False -> failWith "shims already exists and is not a git repository"
|
||||
- Just True -> do
|
||||
- msgD info "shims repository already exists but checkpoint not reached, cleaning first, then cloning"
|
||||
- rm_rf "shims"
|
||||
- cloneGit shimsDescr "shims" bsrcShimsDevBranch bsrcShimsDev
|
||||
+ Just _ -> do
|
||||
+ msgD info "shims repository already exists; moving on"
|
||||
Nothing -> do
|
||||
msgD info "cloning shims git repository"
|
||||
cloneGit shimsDescr "shims" bsrcShimsDevBranch bsrcShimsDev
|
||||
where
|
||||
initGhcjsBoot = sub $ do
|
||||
- cloneGit bootDescr "ghcjs-boot" bsrcBootDevBranch bsrcBootDev
|
||||
cd "ghcjs-boot"
|
||||
- git_ ["submodule", "update", "--init", "--recursive"]
|
||||
mapM_ patchPackage =<< allPackages
|
||||
preparePrimops
|
||||
buildGenPrim
|
||||
@@ -1201,14 +1192,14 @@ cabalInstallFlags parmakeGhcjs = do
|
||||
, "--avoid-reinstalls"
|
||||
, "--builddir", "dist"
|
||||
, "--with-compiler", ghcjs ^. pgmLocText
|
||||
+ , "--with-gcc", "@CC@"
|
||||
, "--with-hc-pkg", ghcjsPkg ^. pgmLocText
|
||||
- , "--prefix", toTextI instDir
|
||||
+ , "--prefix", "@PREFIX@"
|
||||
+ , "--libdir", "$prefix/lib/$compiler"
|
||||
+ , "--libsubdir", "$pkgid"
|
||||
, bool haddock "--enable-documentation" "--disable-documentation"
|
||||
, "--haddock-html"
|
||||
--- workaround for hoogle support being broken in haddock for GHC 7.10RC1
|
||||
-#if !(__GLASGOW_HASKELL__ >= 709)
|
||||
, "--haddock-hoogle"
|
||||
-#endif
|
||||
, "--haddock-hyperlink-source"
|
||||
-- don't slow down Windows builds too much, on other platforms we get this more
|
||||
-- or less for free, thanks to dynamic-too
|
||||
diff --git a/src/Compiler/Info.hs b/src/Compiler/Info.hs
|
||||
index 33a401f..e2405a7 100644
|
||||
--- a/src/Compiler/Info.hs
|
||||
+++ b/src/Compiler/Info.hs
|
||||
@@ -48,13 +48,7 @@ compilerInfo nativeToo dflags = do
|
||||
|
||||
-- | the directory to use if started without -B flag
|
||||
getDefaultTopDir :: IO FilePath
|
||||
-getDefaultTopDir = do
|
||||
- appdir <- getAppUserDataDirectory "ghcjs"
|
||||
- return (appdir </> subdir </> "ghcjs")
|
||||
- where
|
||||
- targetARCH = arch
|
||||
- targetOS = os
|
||||
- subdir = targetARCH ++ '-':targetOS ++ '-':getFullCompilerVersion
|
||||
+getDefaultTopDir = return "@PREFIX@/lib/ghcjs-@VERSION@"
|
||||
|
||||
getDefaultLibDir :: IO FilePath
|
||||
getDefaultLibDir = getDefaultTopDir
|
||||
@@ -1,50 +0,0 @@
|
||||
{ fetchgit, fetchFromGitHub, bootPkgs, cabal-install }:
|
||||
|
||||
bootPkgs.callPackage ../base.nix {
|
||||
version = "0.2.020170323";
|
||||
|
||||
inherit bootPkgs cabal-install;
|
||||
|
||||
ghcjsSrc = fetchFromGitHub {
|
||||
owner = "ghcjs";
|
||||
repo = "ghcjs";
|
||||
rev = "2b3759942fb5b2fc1a58d314d9b098d4622fa6b6";
|
||||
sha256 = "15asapg0va8dvcdycsx8dgk4xcpdnhml4h31wka6vvxf5anzz8aw";
|
||||
};
|
||||
ghcjsBootSrc = fetchgit {
|
||||
url = git://github.com/ghcjs/ghcjs-boot.git;
|
||||
rev = "106e144cca6529a1b9612c11aea5d6ef65b96745";
|
||||
sha256 = "0gxg8iiwvm93x1dwhxypczn9qiz4m1xvj8i7cf4snfdy2jdyhi5l";
|
||||
fetchSubmodules = true;
|
||||
};
|
||||
|
||||
shims = import ./shims.nix { inherit fetchFromGitHub; };
|
||||
stage1Packages = [
|
||||
"array"
|
||||
"base"
|
||||
"binary"
|
||||
"bytestring"
|
||||
"containers"
|
||||
"deepseq"
|
||||
"directory"
|
||||
"filepath"
|
||||
"ghc-boot"
|
||||
"ghc-boot-th"
|
||||
"ghc-prim"
|
||||
"ghci"
|
||||
"ghcjs-prim"
|
||||
"ghcjs-th"
|
||||
"integer-gmp"
|
||||
"pretty"
|
||||
"primitive"
|
||||
"process"
|
||||
"rts"
|
||||
"template-haskell"
|
||||
"time"
|
||||
"transformers"
|
||||
"unix"
|
||||
];
|
||||
stage2 = import ./stage2.nix;
|
||||
|
||||
patches = [ ./boot.patch ];
|
||||
}
|
||||
@@ -1,7 +0,0 @@
|
||||
{ fetchFromGitHub }:
|
||||
fetchFromGitHub {
|
||||
owner = "ghcjs";
|
||||
repo = "shims";
|
||||
rev = "85395dce971e23a39e5f93af4ed139ca36d4e448";
|
||||
sha256 = "1kqgik75jx681s1kjx1s7dryigr3m940c3zb9vy0r3psxrw6sf2g";
|
||||
}
|
||||
@@ -1,545 +0,0 @@
|
||||
{ ghcjsBoot }: { callPackage }:
|
||||
|
||||
{
|
||||
async = callPackage
|
||||
({ mkDerivation, base, HUnit, stdenv, stm, test-framework
|
||||
, test-framework-hunit
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "async";
|
||||
version = "2.1.1";
|
||||
src = "${ghcjsBoot}/boot/async";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base stm ];
|
||||
testHaskellDepends = [
|
||||
base HUnit test-framework test-framework-hunit
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = "https://github.com/simonmar/async";
|
||||
description = "Run IO operations asynchronously and wait for their results";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
aeson = callPackage
|
||||
({ mkDerivation, attoparsec, base, base-compat, base-orphans
|
||||
, base16-bytestring, bytestring, containers, deepseq, directory
|
||||
, dlist, filepath, generic-deriving, ghc-prim, hashable
|
||||
, hashable-time, HUnit, integer-logarithms, QuickCheck
|
||||
, quickcheck-instances, scientific, stdenv, tagged
|
||||
, template-haskell, test-framework, test-framework-hunit
|
||||
, test-framework-quickcheck2, text, th-abstraction, time
|
||||
, time-locale-compat, unordered-containers, uuid-types, vector
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "aeson";
|
||||
version = "1.2.2.0";
|
||||
src = "${ghcjsBoot}/boot/aeson";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [
|
||||
attoparsec base base-compat bytestring containers deepseq dlist
|
||||
ghc-prim hashable scientific tagged template-haskell text
|
||||
th-abstraction time time-locale-compat unordered-containers
|
||||
uuid-types vector
|
||||
];
|
||||
testHaskellDepends = [
|
||||
attoparsec base base-compat base-orphans base16-bytestring
|
||||
bytestring containers directory dlist filepath generic-deriving
|
||||
ghc-prim hashable hashable-time HUnit integer-logarithms QuickCheck
|
||||
quickcheck-instances scientific tagged template-haskell
|
||||
test-framework test-framework-hunit test-framework-quickcheck2 text
|
||||
time time-locale-compat unordered-containers uuid-types vector
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = "https://github.com/bos/aeson";
|
||||
description = "Fast JSON parsing and encoding";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
attoparsec = callPackage
|
||||
({ mkDerivation, array, base, bytestring, case-insensitive
|
||||
, containers, criterion, deepseq, directory, filepath, ghc-prim
|
||||
, http-types, parsec, QuickCheck, quickcheck-unicode, scientific
|
||||
, stdenv, tasty, tasty-quickcheck, text, transformers
|
||||
, unordered-containers, vector
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "attoparsec";
|
||||
version = "0.13.1.0";
|
||||
src = "${ghcjsBoot}/boot/attoparsec";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [
|
||||
array base bytestring containers deepseq scientific text
|
||||
transformers
|
||||
];
|
||||
testHaskellDepends = [
|
||||
array base bytestring deepseq QuickCheck quickcheck-unicode
|
||||
scientific tasty tasty-quickcheck text transformers vector
|
||||
];
|
||||
benchmarkHaskellDepends = [
|
||||
array base bytestring case-insensitive containers criterion deepseq
|
||||
directory filepath ghc-prim http-types parsec scientific text
|
||||
transformers unordered-containers vector
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = "https://github.com/bos/attoparsec";
|
||||
description = "Fast combinator parsing for bytestrings and text";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
base-compat = callPackage
|
||||
({ mkDerivation, base, hspec, QuickCheck, stdenv, unix }:
|
||||
mkDerivation {
|
||||
pname = "base-compat";
|
||||
version = "0.9.3";
|
||||
src = "${ghcjsBoot}/boot/base-compat";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base unix ];
|
||||
testHaskellDepends = [ base hspec QuickCheck ];
|
||||
jailbreak = true;
|
||||
description = "A compatibility layer for base";
|
||||
license = stdenv.lib.licenses.mit;
|
||||
}) {};
|
||||
bytestring-builder = callPackage
|
||||
({ mkDerivation, base, bytestring, deepseq, stdenv }:
|
||||
mkDerivation {
|
||||
pname = "bytestring-builder";
|
||||
version = "0.10.8.1.0";
|
||||
src = "${ghcjsBoot}/boot/bytestring-builder";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base bytestring deepseq ];
|
||||
jailbreak = true;
|
||||
description = "The new bytestring builder, packaged outside of GHC";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
case-insensitive = callPackage
|
||||
({ mkDerivation, base, bytestring, criterion, deepseq, hashable
|
||||
, HUnit, stdenv, test-framework, test-framework-hunit, text
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "case-insensitive";
|
||||
version = "1.2.0.8";
|
||||
src = "${ghcjsBoot}/boot/case-insensitive";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base bytestring deepseq hashable text ];
|
||||
testHaskellDepends = [
|
||||
base bytestring HUnit test-framework test-framework-hunit text
|
||||
];
|
||||
benchmarkHaskellDepends = [ base bytestring criterion deepseq ];
|
||||
jailbreak = true;
|
||||
homepage = "https://github.com/basvandijk/case-insensitive";
|
||||
description = "Case insensitive string comparison";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
dlist = callPackage
|
||||
({ mkDerivation, base, Cabal, deepseq, QuickCheck, stdenv }:
|
||||
mkDerivation {
|
||||
pname = "dlist";
|
||||
version = "0.8.0.2";
|
||||
src = "${ghcjsBoot}/boot/dlist";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base deepseq ];
|
||||
testHaskellDepends = [ base Cabal QuickCheck ];
|
||||
jailbreak = true;
|
||||
homepage = "https://github.com/spl/dlist";
|
||||
description = "Difference lists";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
extensible-exceptions = callPackage
|
||||
({ mkDerivation, base, stdenv }:
|
||||
mkDerivation {
|
||||
pname = "extensible-exceptions";
|
||||
version = "0.1.1.4";
|
||||
src = "${ghcjsBoot}/boot/extensible-exceptions";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base ];
|
||||
jailbreak = true;
|
||||
description = "Extensible exceptions";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
fail = callPackage
|
||||
({ mkDerivation, stdenv }:
|
||||
mkDerivation {
|
||||
pname = "fail";
|
||||
version = "4.9.0.0";
|
||||
src = "${ghcjsBoot}/boot/fail";
|
||||
jailbreak = true;
|
||||
homepage = "https://prime.haskell.org/wiki/Libraries/Proposals/MonadFail";
|
||||
description = "Forward-compatible MonadFail class";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
hashable = callPackage
|
||||
({ mkDerivation, base, bytestring, criterion, ghc-prim, HUnit
|
||||
, integer-gmp, QuickCheck, random, siphash, stdenv, test-framework
|
||||
, test-framework-hunit, test-framework-quickcheck2, text, unix
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "hashable";
|
||||
version = "1.2.4.0";
|
||||
src = "${ghcjsBoot}/boot/hashable";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [
|
||||
base bytestring ghc-prim integer-gmp text
|
||||
];
|
||||
testHaskellDepends = [
|
||||
base bytestring ghc-prim HUnit QuickCheck random test-framework
|
||||
test-framework-hunit test-framework-quickcheck2 text unix
|
||||
];
|
||||
benchmarkHaskellDepends = [
|
||||
base bytestring criterion ghc-prim integer-gmp siphash text
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = "http://github.com/tibbe/hashable";
|
||||
description = "A class for types that can be converted to a hash value";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
integer-logarithms = callPackage
|
||||
({ mkDerivation, array, base, ghc-prim, integer-gmp, QuickCheck
|
||||
, smallcheck, stdenv, tasty, tasty-hunit, tasty-quickcheck
|
||||
, tasty-smallcheck
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "integer-logarithms";
|
||||
version = "1.0.2";
|
||||
src = "${ghcjsBoot}/boot/integer-logarithms";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ array base ghc-prim integer-gmp ];
|
||||
testHaskellDepends = [
|
||||
base QuickCheck smallcheck tasty tasty-hunit tasty-quickcheck
|
||||
tasty-smallcheck
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = "https://github.com/phadej/integer-logarithms";
|
||||
description = "Integer logarithms";
|
||||
license = stdenv.lib.licenses.mit;
|
||||
}) {};
|
||||
mtl = callPackage
|
||||
({ mkDerivation, base, stdenv, transformers }:
|
||||
mkDerivation {
|
||||
pname = "mtl";
|
||||
version = "2.2.1";
|
||||
src = "${ghcjsBoot}/boot/mtl";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base transformers ];
|
||||
jailbreak = true;
|
||||
homepage = "http://github.com/ekmett/mtl";
|
||||
description = "Monad classes, using functional dependencies";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
nats = callPackage
|
||||
({ mkDerivation, stdenv }:
|
||||
mkDerivation {
|
||||
pname = "nats";
|
||||
version = "1.1.1";
|
||||
src = "${ghcjsBoot}/boot/nats";
|
||||
jailbreak = true;
|
||||
homepage = "http://github.com/ekmett/nats/";
|
||||
description = "Natural numbers";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
old-time = callPackage
|
||||
({ mkDerivation, base, old-locale, stdenv }:
|
||||
mkDerivation {
|
||||
pname = "old-time";
|
||||
version = "1.1.0.3";
|
||||
src = "${ghcjsBoot}/boot/old-time";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base old-locale ];
|
||||
jailbreak = true;
|
||||
description = "Time library";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
parallel = callPackage
|
||||
({ mkDerivation, array, base, containers, deepseq, stdenv }:
|
||||
mkDerivation {
|
||||
pname = "parallel";
|
||||
version = "3.2.1.0";
|
||||
src = "${ghcjsBoot}/boot/parallel";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ array base containers deepseq ];
|
||||
jailbreak = true;
|
||||
description = "Parallel programming library";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
random = callPackage
|
||||
({ mkDerivation, base, stdenv, time }:
|
||||
mkDerivation {
|
||||
pname = "random";
|
||||
version = "1.1";
|
||||
src = "${ghcjsBoot}/boot/random";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base time ];
|
||||
testHaskellDepends = [ base ];
|
||||
jailbreak = true;
|
||||
description = "random number library";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
scientific = callPackage
|
||||
({ mkDerivation, base, binary, bytestring, containers, criterion
|
||||
, deepseq, ghc-prim, hashable, integer-gmp, integer-logarithms
|
||||
, QuickCheck, smallcheck, stdenv, tasty, tasty-ant-xml, tasty-hunit
|
||||
, tasty-quickcheck, tasty-smallcheck, text, vector
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "scientific";
|
||||
version = "0.3.4.10";
|
||||
src = "${ghcjsBoot}/boot/scientific";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [
|
||||
base binary bytestring containers deepseq ghc-prim hashable
|
||||
integer-gmp integer-logarithms text vector
|
||||
];
|
||||
testHaskellDepends = [
|
||||
base binary bytestring QuickCheck smallcheck tasty tasty-ant-xml
|
||||
tasty-hunit tasty-quickcheck tasty-smallcheck text
|
||||
];
|
||||
benchmarkHaskellDepends = [ base criterion ];
|
||||
jailbreak = true;
|
||||
homepage = "https://github.com/basvandijk/scientific";
|
||||
description = "Numbers represented using scientific notation";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
semigroups = callPackage
|
||||
({ mkDerivation, base, stdenv }:
|
||||
mkDerivation {
|
||||
pname = "semigroups";
|
||||
version = "0.18.3";
|
||||
src = "${ghcjsBoot}/boot/semigroups";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base ];
|
||||
jailbreak = true;
|
||||
homepage = "http://github.com/ekmett/semigroups/";
|
||||
description = "Anything that associates";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
stm = callPackage
|
||||
({ mkDerivation, array, base, stdenv }:
|
||||
mkDerivation {
|
||||
pname = "stm";
|
||||
version = "2.4.4.1";
|
||||
src = "${ghcjsBoot}/boot/stm";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ array base ];
|
||||
jailbreak = true;
|
||||
description = "Software Transactional Memory";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
syb = callPackage
|
||||
({ mkDerivation, base, containers, HUnit, mtl, stdenv }:
|
||||
mkDerivation {
|
||||
pname = "syb";
|
||||
version = "0.6";
|
||||
src = "${ghcjsBoot}/boot/syb";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base ];
|
||||
testHaskellDepends = [ base containers HUnit mtl ];
|
||||
jailbreak = true;
|
||||
homepage = "http://www.cs.uu.nl/wiki/GenericProgramming/SYB";
|
||||
description = "Scrap Your Boilerplate";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
tagged = callPackage
|
||||
({ mkDerivation, base, deepseq, stdenv, template-haskell
|
||||
, transformers, transformers-compat
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "tagged";
|
||||
version = "0.8.5";
|
||||
src = "${ghcjsBoot}/boot/tagged";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [
|
||||
base deepseq template-haskell transformers transformers-compat
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = "http://github.com/ekmett/tagged";
|
||||
description = "Haskell 98 phantom types to avoid unsafely passing dummy arguments";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
text = callPackage
|
||||
({ mkDerivation, array, base, binary, bytestring, deepseq, directory
|
||||
, ghc-prim, HUnit, integer-gmp, QuickCheck, quickcheck-unicode
|
||||
, random, stdenv, test-framework, test-framework-hunit
|
||||
, test-framework-quickcheck2
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "text";
|
||||
version = "1.2.2.1";
|
||||
src = "${ghcjsBoot}/boot/text";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [
|
||||
array base binary bytestring deepseq ghc-prim integer-gmp
|
||||
];
|
||||
testHaskellDepends = [
|
||||
array base binary bytestring deepseq directory ghc-prim HUnit
|
||||
integer-gmp QuickCheck quickcheck-unicode random test-framework
|
||||
test-framework-hunit test-framework-quickcheck2
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = "https://github.com/bos/text";
|
||||
description = "An efficient packed Unicode text type";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
th-abstraction = callPackage
|
||||
({ mkDerivation, base, containers, ghc-prim, stdenv
|
||||
, template-haskell
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "th-abstraction";
|
||||
version = "0.2.6.0";
|
||||
src = "${ghcjsBoot}/boot/th-abstraction";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [
|
||||
base containers ghc-prim template-haskell
|
||||
];
|
||||
testHaskellDepends = [ base containers template-haskell ];
|
||||
jailbreak = true;
|
||||
homepage = "https://github.com/glguy/th-abstraction";
|
||||
description = "Nicer interface for reified information about data types";
|
||||
license = stdenv.lib.licenses.isc;
|
||||
}) {};
|
||||
time-locale-compat = callPackage
|
||||
({ mkDerivation, base, old-locale, stdenv, time }:
|
||||
mkDerivation {
|
||||
pname = "time-locale-compat";
|
||||
version = "0.1.1.3";
|
||||
src = "${ghcjsBoot}/boot/time-locale-compat";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base old-locale time ];
|
||||
jailbreak = true;
|
||||
homepage = "https://github.com/khibino/haskell-time-locale-compat";
|
||||
description = "Compatibility of TimeLocale between old-locale and time-1.5";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
transformers-compat = callPackage
|
||||
({ mkDerivation, base, ghc-prim, stdenv, transformers }:
|
||||
mkDerivation {
|
||||
pname = "transformers-compat";
|
||||
version = "0.5.1.4";
|
||||
src = "${ghcjsBoot}/boot/transformers-compat";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base ghc-prim transformers ];
|
||||
jailbreak = true;
|
||||
homepage = "http://github.com/ekmett/transformers-compat/";
|
||||
description = "A small compatibility shim exposing the new types from transformers 0.3 and 0.4 to older Haskell platforms.";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
unordered-containers = callPackage
|
||||
({ mkDerivation, base, bytestring, ChasingBottoms, containers
|
||||
, criterion, deepseq, deepseq-generics, hashable, hashmap, HUnit
|
||||
, mtl, QuickCheck, random, stdenv, test-framework
|
||||
, test-framework-hunit, test-framework-quickcheck2
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "unordered-containers";
|
||||
version = "0.2.7.2";
|
||||
src = "${ghcjsBoot}/boot/unordered-containers";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base deepseq hashable ];
|
||||
testHaskellDepends = [
|
||||
base ChasingBottoms containers hashable HUnit QuickCheck
|
||||
test-framework test-framework-hunit test-framework-quickcheck2
|
||||
];
|
||||
benchmarkHaskellDepends = [
|
||||
base bytestring containers criterion deepseq deepseq-generics
|
||||
hashable hashmap mtl random
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = "https://github.com/tibbe/unordered-containers";
|
||||
description = "Efficient hashing-based container types";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
uuid-types = callPackage
|
||||
({ mkDerivation, base, binary, bytestring, containers, criterion
|
||||
, deepseq, hashable, HUnit, QuickCheck, random, stdenv, tasty
|
||||
, tasty-hunit, tasty-quickcheck, text, unordered-containers
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "uuid-types";
|
||||
version = "1.0.3";
|
||||
src = "${ghcjsBoot}/boot/uuid/uuid-types";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [
|
||||
base binary bytestring deepseq hashable random text
|
||||
];
|
||||
testHaskellDepends = [
|
||||
base bytestring HUnit QuickCheck tasty tasty-hunit tasty-quickcheck
|
||||
];
|
||||
benchmarkHaskellDepends = [
|
||||
base bytestring containers criterion deepseq random
|
||||
unordered-containers
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = "https://github.com/hvr/uuid";
|
||||
description = "Type definitions for Universally Unique Identifiers";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
vector = callPackage
|
||||
({ mkDerivation, base, deepseq, ghc-prim, primitive, QuickCheck
|
||||
, random, stdenv, template-haskell, test-framework
|
||||
, test-framework-quickcheck2, transformers
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "vector";
|
||||
version = "0.11.0.0";
|
||||
src = "${ghcjsBoot}/boot/vector";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [ base deepseq ghc-prim primitive ];
|
||||
testHaskellDepends = [
|
||||
base QuickCheck random template-haskell test-framework
|
||||
test-framework-quickcheck2 transformers
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = "https://github.com/haskell/vector";
|
||||
description = "Efficient Arrays";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
ghcjs-base = callPackage
|
||||
({ mkDerivation, aeson, array, attoparsec, base, bytestring
|
||||
, containers, deepseq, directory, dlist, ghc-prim, ghcjs-prim
|
||||
, hashable, HUnit, integer-gmp, primitive, QuickCheck
|
||||
, quickcheck-unicode, random, scientific, stdenv, test-framework
|
||||
, test-framework-hunit, test-framework-quickcheck2, text, time
|
||||
, transformers, unordered-containers, vector
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "ghcjs-base";
|
||||
version = "0.2.0.0";
|
||||
src = "${ghcjsBoot}/ghcjs/ghcjs-base";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [
|
||||
aeson attoparsec base bytestring containers deepseq dlist ghc-prim
|
||||
ghcjs-prim hashable integer-gmp primitive scientific text time
|
||||
transformers unordered-containers vector
|
||||
];
|
||||
testHaskellDepends = [
|
||||
array base bytestring deepseq directory ghc-prim ghcjs-prim HUnit
|
||||
primitive QuickCheck quickcheck-unicode random test-framework
|
||||
test-framework-hunit test-framework-quickcheck2 text
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = "http://github.com/ghcjs/ghcjs-base";
|
||||
description = "base library for GHCJS";
|
||||
license = stdenv.lib.licenses.mit;
|
||||
}) {};
|
||||
Cabal = callPackage
|
||||
({ mkDerivation, array, base, binary, bytestring, containers
|
||||
, deepseq, directory, exceptions, filepath, old-time, pretty
|
||||
, process, QuickCheck, regex-posix, stdenv, tagged, tasty
|
||||
, tasty-hunit, tasty-quickcheck, time, transformers, unix
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "Cabal";
|
||||
version = "1.24.0.0";
|
||||
src = "${ghcjsBoot}/boot/cabal/Cabal";
|
||||
doCheck = false;
|
||||
libraryHaskellDepends = [
|
||||
array base binary bytestring containers deepseq directory filepath
|
||||
pretty process time unix
|
||||
];
|
||||
testHaskellDepends = [
|
||||
base bytestring containers directory exceptions filepath old-time
|
||||
pretty process QuickCheck regex-posix tagged tasty tasty-hunit
|
||||
tasty-quickcheck transformers unix
|
||||
];
|
||||
jailbreak = true;
|
||||
homepage = "http://www.haskell.org/cabal/";
|
||||
description = "A framework for packaging Haskell software";
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
}) {};
|
||||
}
|
||||
Reference in New Issue
Block a user