summary refs log tree commit diff
path: root/pkgs/development/libraries/jsoncpp/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/libraries/jsoncpp/default.nix')
-rw-r--r--pkgs/development/libraries/jsoncpp/default.nix37
1 files changed, 18 insertions, 19 deletions
diff --git a/pkgs/development/libraries/jsoncpp/default.nix b/pkgs/development/libraries/jsoncpp/default.nix
index b1aa03991bd..d8b85847975 100644
--- a/pkgs/development/libraries/jsoncpp/default.nix
+++ b/pkgs/development/libraries/jsoncpp/default.nix
@@ -1,32 +1,31 @@
-{ stdenv, fetchurl, scons}:
+{ stdenv, fetchurl, cmake, python }:
 
 let
   basename = "jsoncpp";
-  version = "0.6.0-rc2";
-  pkgname = "${basename}-src-${version}.tar.gz";
-in 
+  version = "1.6.0";
+in
 stdenv.mkDerivation rec {
   name = "${basename}-${version}";
   src = fetchurl {
-    url = "mirror://sourceforge/${basename}/${pkgname}";
-    sha256 = "10xj15nziqpwc6r3yznpb49wm4jqc5wakjsmj65v087mcg8r7lfl";
+    url = "https://github.com/open-source-parsers/${basename}/archive/${version}.tar.gz";
+    sha256 = "0ff1niks3y41gr6z13q9m391na70abqyi9rj4z3y2fz69cwm6sgz";
   };
 
-  buildInputs = [ scons ];
-
-  buildPhase = ''
-    mkdir -p $out
-    scons platform=linux-gcc check
-  '';
-
-  installPhase = ''
-    cp -r include $out
-    cp -r libs/* $out/lib
-  '';
+  nativeBuildInputs =
+    [
+      # cmake can be built with the system jsoncpp, or its own bundled version.
+      # Obviously we cannot build it against the system jsoncpp that doesn't yet exist, so
+      # we make a bootstrapping build with the bundled version.
+      (cmake.override { jsoncpp = null; })
+      python
+    ];
 
   meta = {
-    homepage = http://jsoncpp.sourceforge.net;
-    repositories.svn = svn://svn.code.sf.net/p/jsoncpp/code;
+    inherit version;
+    homepage = https://github.com/open-source-parsers/jsoncpp;
     description = "A simple API to manipulate JSON data in C++";
+    maintainers = with stdenv.lib.maintainers; [ ttuegel ];
+    license = with stdenv.lib.licenses; [ mit ];
+    branch = "1.6";
   };
 }