Subject: bug#25787: [PATCH 1/6] gnu: Add qjson.

From: Pierre Langlois <[email-masked]>
Date: Sat, 18 Feb 2017 18:00:16 +0000

* gnu/packages/qt.scm (qjson): New variable.
---
 gnu/packages/qt.scm | 28 ++++++++++++++++++++++++++++
 1 file changed, 28 insertions(+)

diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm
index 47a7caae4..0895e034c 100644
--- a/gnu/packages/qt.scm
+++ b/gnu/packages/qt.scm
@@ -5,6 +5,7 @@
 ;;; Copyright © 2015, 2016, 2017 Efraim Flashner <[email-masked]>
 ;;; Copyright © 2016, 2017 ng0 <[email-masked]>
 ;;; Copyright © 2016 Thomas Danckaert <[email-masked]>
+;;; Copyright © 2017 Pierre Langlois <[email-masked]>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1135,6 +1136,33 @@ developers using C++ or QML, a CSS & JavaScript like language.")
      `(("qtbase" ,qtbase)
        ("qtdeclarative" ,qtdeclarative)))))
 
+(define-public qjson
+  (package
+    (name "qjson")
+    (version "0.9.0")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append
+                     "https://github.com/flavio/qjson/archive/"
+                     version ".tar.gz"))
+              (file-name (string-append name "-" version ".tar.gz"))
+              (sha256
+               (base32
+                 "1m0h4rajj99hv9w4i381a8x81lxiv167lxk10ncvphpkfxs624p8"))))
+    (build-system cmake-build-system)
+    (arguments
+      ;; The tests require a X server
+      ;; #:configure-flags '("-DQJSON_BUILD_TESTS=ON")
+      `(#:tests? #f))
+    (inputs
+      `(("qt" ,qt-4)))
+    (home-page "http://qjson.sourceforge.net")
+    (synopsis "Library that maps JSON data to QVariant objects")
+    (description "QJson is a qt-based library that maps JSON data to QVariant
+objects.  JSON arrays will be mapped to QVariantList instances, while JSON's
+objects will be mapped to QVariantMap.")
+    (license license:lgpl2.1)))
+
 (define-public python-sip
   (package
     (name "python-sip")
-- 
2.11.1