@@ -1,5 +1,5 @@
1−{ stdenv, fetchurl, fetchpatch, scons, boost, gperftools, pcre-cpp, snappy
2−, zlib, libyamlcpp, sasl, openssl, libpcap, Security
1+{ stdenv, fetchurl, fetchpatch, scons, boost, gperftools, pcre-cpp, snappy, zlib,
2+ libyamlcpp, sasl, openssl, libpcap, wiredtiger, Security, python27, libtool, curl
33}:
44
55# Note:
@@ -7,7 +7,8 @@
77
88with stdenv.lib;
99
10−let version = "3.4.10";
10+let version = "4.0.4";
11+ python = python27.withPackages (ps: with ps; [ pyyaml typing cheetah ]);
1112 system-libraries = [
1213 "pcre"
1314 #"asio" -- XXX use package?
@@ -19,6 +20,7 @@ let version = "3.4.10";
1920 #"stemmer" -- not nice to package yet (no versioning, no makefile, no shared libs).
2021 "yaml"
2122 ] ++ optionals stdenv.isLinux [ "tcmalloc" ];
23+ inherit (stdenv.lib) systems subtractLists;
2224
2325in stdenv.mkDerivation {
2426 pname = "mongodb";
@@ -26,14 +28,14 @@ in stdenv.mkDerivation {
2628
2729 src = fetchurl {
2830 url = "https://fastdl.mongodb.org/src/mongodb-src-r${version}.tar.gz";
29− sha256 = "1wz2mhl9z0b1bdkg6m8v8mvw9k60mdv5ybq554xn3yjj9z500f24";
31+ sha256 = "1qycwr9f99b5cy4nf54yv2y724xis3lwd2h6iv2pfp36qnhsvfh2";
3032 };
3133
3234 nativeBuildInputs = [ scons ];
3335 buildInputs = [
3436 sasl boost gperftools pcre-cpp snappy
35− zlib libyamlcpp sasl openssl.dev openssl.out libpcap
36− ] ++ stdenv.lib.optionals stdenv.isDarwin [ Security ];
37+ zlib libyamlcpp sasl openssl.dev openssl.out libpcap python curl
38+ ] ++ stdenv.lib.optionals stdenv.isDarwin [ Security libtool ];
3739
3840 patches =
3941 [
@@ -41,11 +43,6 @@ in stdenv.mkDerivation {
4143 # keeping dependencies to build inputs in the final output.
4244 # We remove the build flags from buildInfo data.
4345 ./forget-build-dependencies.patch
44− (fetchpatch {
45− url = https://projects.archlinux.org/svntogit/community.git/plain/trunk/boost160.patch?h=packages/mongodb;
46− name = "boost160.patch";
47− sha256 = "0bvsf3499zj55pzamwjmsssr6x63w434944w76273fr5rxwzcmh8";
48− })
4946 ];
5047
5148 postPatch = ''
@@ -89,6 +86,11 @@ in stdenv.mkDerivation {
8986 preInstall = ''
9087 mkdir -p $out/lib
9188 '';
89+
90+ postInstall = ''
91+ rm $out/bin/install_compass
92+ '';
93+
9294 prefixKey = "--prefix=";
9395
9496 enableParallelBuilding = true;
@@ -98,9 +100,10 @@ in stdenv.mkDerivation {
98100 meta = {
99101 description = "A scalable, high-performance, open source NoSQL database";
100102 homepage = http://www.mongodb.org;
101− license = licenses.agpl3;
103+ license = licenses.sspl;
104+ broken = stdenv.hostPlatform.isAarch64; #g++ has internal compiler errors
102105
103106 maintainers = with maintainers; [ bluescreen303 offline cstrahan ];
104− platforms = platforms.unix;
107+ platforms = subtractLists systems.doubles.i686 systems.doubles.unix;
105108 };
106109}