idrisPackages.idris: 1.0 -> 1.1.1

This commit is contained in:
Thomas Tuegel 2017-08-22 19:49:25 -05:00
parent ca381067e7
commit b438d394ce
No known key found for this signature in database
GPG Key ID: 22CBF5249D4B4D59
4 changed files with 32 additions and 9 deletions

View File

@ -697,6 +697,11 @@ self: super: {
# test suite cannot find its own "idris" binary
idris = doJailbreak (dontCheck super.idris);
idris_1_1_1 = overrideCabal (doJailbreak (dontCheck super.idris_1_1_1)) (drv: {
# The standard libraries are compiled separately
configureFlags = (drv.configureFlags or []) ++ [ "-fexeconly" ];
});
# https://github.com/bos/math-functions/issues/25
math-functions = dontCheck super.math-functions;

View File

@ -13,8 +13,11 @@ build-idris-package {
inherit (idris) src;
postUnpack = ''
mv $sourceRoot/libs/${name} $IDRIS_LIBRARY_PATH
sourceRoot=$IDRIS_LIBRARY_PATH/${name}
sourceRoot=$sourceRoot/libs/${name}
'';
postPatch = ''
sed -i ${name}.ipkg -e "/^opts/ s|-i \\.\\./|-i $IDRIS_LIBRARY_PATH/|g"
'';
meta = idris.meta // {

View File

@ -4,8 +4,13 @@
# name and src.
{ stdenv, idris, gmp }: args: stdenv.mkDerivation ({
preHook = ''
mkdir idris-libs
# Library import path
export IDRIS_LIBRARY_PATH=$PWD/idris-libs
mkdir -p $IDRIS_LIBRARY_PATH
# Library install path
export IBCSUBDIR=$out/lib/${idris.name}
mkdir -p $IBCSUBDIR
addIdrisLibs () {
if [ -d $1/lib/${idris.name} ]; then
@ -16,10 +21,6 @@
envHooks+=(addIdrisLibs)
'';
configurePhase = ''
export TARGET=$out/lib/${idris.name}
'';
buildPhase = ''
${idris}/bin/idris --build *.ipkg
'';
@ -33,7 +34,7 @@
'';
installPhase = ''
${idris}/bin/idris --install *.ipkg
${idris}/bin/idris --install *.ipkg --ibcsubdir $IBCSUBDIR
'';
buildInputs = [ gmp ];

View File

@ -5646,7 +5646,21 @@ with pkgs;
icedtea_web = icedtea8_web;
idrisPackages = callPackage ../development/idris-modules {
inherit (haskellPackages) idris;
idris =
let
inherit (self.haskell) lib;
haskellPackages = self.haskellPackages.override {
overrides = self: super: {
binary = lib.dontCheck self.binary_0_8_5_1;
cheapskate = self.cheapskate_0_1_1;
idris = self.idris_1_1_1;
parsers = lib.dontCheck super.parsers;
semigroupoids = lib.dontCheck super.semigroupoids;
trifecta = lib.dontCheck super.trifecta;
};
};
in
haskellPackages.idris;
};
intercal = callPackage ../development/compilers/intercal { };