summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortv <tv@shackspace.de>2015-02-20 12:15:51 +0100
committertv <tv@shackspace.de>2015-02-20 12:15:51 +0100
commit42547dc1c81411c9ae6ffa62d00249060b48021b (patch)
tree2ca5018bfe3ce7d37ee041edcaaed8fcc81e08a2
parentda7bf1ca587f66857b496f707bc3271cf366fcd3 (diff)
use haskell-ng
-rw-r--r--default.nix5
-rw-r--r--env.nix20
-rw-r--r--nix/email-header.nix28
-rw-r--r--nix/friendly-time/default.nix17
-rw-r--r--nix/mime-mail.nix26
5 files changed, 35 insertions, 61 deletions
diff --git a/default.nix b/default.nix
index 4b9bff1..3953722 100644
--- a/default.nix
+++ b/default.nix
@@ -3,11 +3,12 @@
, name ? "much"
}:
let
- inherit (pkgs.haskellPackages) buildLocalCabalWithArgs callPackage;
+ inherit (pkgs.haskellngPackages) buildLocalCabalWithArgs callPackage;
in
buildLocalCabalWithArgs {
inherit src name;
args = {
- friendlyTime = callPackage ./nix/friendly-time {};
+ email-header = callPackage ./nix/email-header.nix {};
+ mime-mail = callPackage ./nix/mime-mail.nix {};
};
}
diff --git a/env.nix b/env.nix
index 4309cc0..9a38cfe 100644
--- a/env.nix
+++ b/env.nix
@@ -1,8 +1,8 @@
{ nixpkgs ? import <nixpkgs> {} }:
let
- name = "much";
- version = "1";
+ pname = "much";
+ version = "2";
buildInputs = with pkgs; [
hsEnv
@@ -15,12 +15,11 @@ let
'';
# ghcWithPackagesOld b/c terminfo collision
- hsEnv = hsPkgs.ghcWithPackagesOld (self: with self;
- terminfo.nativeBuildInputs ++
+ hsEnv = hsPkgs.ghcWithPackages (self: with self;
[
- cabalInstall
aeson
- caseInsensitive
+ cabal-install
+ case-insensitive
email-header
friendly-time
mime
@@ -29,14 +28,13 @@ let
rosezipper
safe
split
- terminalSize
+ terminal-size
]
);
- hsPkgs = pkgs.haskellPackages_ghc783_profiling.override {
- extension = self: super: with self; {
+ hsPkgs = pkgs.haskellngPackages.override {
+ overrides = self: super: with self; {
email-header = callPackage ./nix/email-header.nix {};
- friendly-time = callPackage ./nix/friendly-time {};
mime-mail = callPackage ./nix/mime-mail.nix {};
};
};
@@ -58,7 +56,7 @@ let
#}}}
in pkgs.myEnvFun {
- name = "${name}-${version}";
+ name = "${pname}-${version}";
inherit buildInputs extraCmds;
}
# vim: set fdm=marker :
diff --git a/nix/email-header.nix b/nix/email-header.nix
index 10e1c79..a6caea2 100644
--- a/nix/email-header.nix
+++ b/nix/email-header.nix
@@ -1,10 +1,8 @@
-# This file was auto-generated by cabal2nix. Please do NOT edit manually!
-
-{ cabal, attoparsec, base64Bytestring, caseInsensitive, exceptions
-, fetchgit, QuickCheck, tasty, tastyQuickcheck, text, textIcu, time
+{ mkDerivation, attoparsec, base, base64-bytestring, bytestring
+, case-insensitive, containers, exceptions, fetchgit, QuickCheck
+, stdenv, tasty, tasty-quickcheck, text, text-icu, time
}:
-
-cabal.mkDerivation (self: {
+mkDerivation {
pname = "email-header";
version = "0.3.0";
src = fetchgit {
@@ -13,17 +11,15 @@ cabal.mkDerivation (self: {
rev = "3ba16e71cf1fff92fd86199f893d89a40ca1275d";
};
buildDepends = [
- attoparsec base64Bytestring caseInsensitive exceptions text textIcu
- time
+ attoparsec base base64-bytestring bytestring case-insensitive
+ containers exceptions text text-icu time
];
testDepends = [
- caseInsensitive QuickCheck tasty tastyQuickcheck text time
+ base bytestring case-insensitive containers QuickCheck tasty
+ tasty-quickcheck text time
];
jailbreak = true;
- meta = {
- homepage = "http://github.com/knrafto/email-header";
- description = "Parsing and rendering of email and MIME headers";
- license = self.stdenv.lib.licenses.bsd3;
- platforms = self.ghc.meta.platforms;
- };
-})
+ homepage = "http://github.com/knrafto/email-header";
+ description = "Parsing and rendering of email and MIME headers";
+ license = stdenv.lib.licenses.bsd3;
+}
diff --git a/nix/friendly-time/default.nix b/nix/friendly-time/default.nix
deleted file mode 100644
index 75f3309..0000000
--- a/nix/friendly-time/default.nix
+++ /dev/null
@@ -1,17 +0,0 @@
-# This file was auto-generated by cabal2nix. Please do NOT edit manually!
-
-{ cabal, HUnit, testFramework, testFrameworkHunit, time }:
-
-cabal.mkDerivation (self: {
- pname = "friendly-time";
- version = "0.3";
- sha256 = "10p78qbb1c87d0ag6cwc7blgwaw8r5sbs00gp5qg3sh9x7n9l3nj";
- buildDepends = [ time ];
- testDepends = [ HUnit testFramework testFrameworkHunit time ];
- meta = {
- homepage = "http://github.com/pbrisbin/friendly-time";
- description = "Print time information in friendly ways";
- license = self.stdenv.lib.licenses.bsd3;
- platforms = self.ghc.meta.platforms;
- };
-})
diff --git a/nix/mime-mail.nix b/nix/mime-mail.nix
index 96c097e..e855038 100644
--- a/nix/mime-mail.nix
+++ b/nix/mime-mail.nix
@@ -1,10 +1,8 @@
-# This file was auto-generated by cabal2nix. Please do NOT edit manually!
-
-{ cabal, base64Bytestring, blazeBuilder, fetchgit, filepath, hspec
-, random, sendmail ? "sendmail", text
+{ mkDerivation, base, base64-bytestring, blaze-builder, bytestring
+, fetchgit, filepath, hspec, process, random, sendmail ? "sendmail"
+, stdenv, text
}:
-
-cabal.mkDerivation (self: {
+mkDerivation {
pname = "mime-mail";
version = "0.4.6.2";
src = fetchgit {
@@ -13,14 +11,12 @@ cabal.mkDerivation (self: {
rev = "3d0f060fb4c58b69c72ce3b4911bff32df7329a7";
};
buildDepends = [
- base64Bytestring blazeBuilder filepath random text
+ base base64-bytestring blaze-builder bytestring filepath process
+ random text
];
- testDepends = [ blazeBuilder hspec text ];
+ testDepends = [ base blaze-builder bytestring hspec text ];
configureFlags = "--ghc-option=-DMIME_MAIL_SENDMAIL_PATH=\"${sendmail}\"";
- meta = {
- homepage = "http://github.com/snoyberg/mime-mail";
- description = "Compose MIME email messages";
- license = self.stdenv.lib.licenses.mit;
- platforms = self.ghc.meta.platforms;
- };
-})
+ homepage = "http://github.com/snoyberg/mime-mail";
+ description = "Compose MIME email messages";
+ license = stdenv.lib.licenses.mit;
+}