From patchwork Tue Feb 21 06:43:55 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: jgart X-Patchwork-Id: 47186 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 5DA4A16B0B; Tue, 21 Feb 2023 06:45:46 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-3.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id AF94C16ACE for ; Tue, 21 Feb 2023 06:45:44 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pUMP2-0003h9-B1; Tue, 21 Feb 2023 01:45:28 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pUMOw-0003gq-Od for guix-patches@gnu.org; Tue, 21 Feb 2023 01:45:24 -0500 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pUMOc-0006S4-Hg for guix-patches@gnu.org; Tue, 21 Feb 2023 01:45:22 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pUMOc-0005Af-DF for guix-patches@gnu.org; Tue, 21 Feb 2023 01:45:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#61672] [PATCH v2] gnu: Add nlohmann-json. References: <20230221064023.11660-1-jgart@dismail.de> In-Reply-To: <20230221064023.11660-1-jgart@dismail.de> Resent-From: jgart Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 21 Feb 2023 06:45:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 61672 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 61672@debbugs.gnu.org Cc: jgart Received: via spool by 61672-submit@debbugs.gnu.org id=B61672.167696187219805 (code B ref 61672); Tue, 21 Feb 2023 06:45:02 +0000 Received: (at 61672) by debbugs.gnu.org; 21 Feb 2023 06:44:32 +0000 Received: from localhost ([127.0.0.1]:54402 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pUMO7-00059N-JB for submit@debbugs.gnu.org; Tue, 21 Feb 2023 01:44:31 -0500 Received: from mx1.dismail.de ([78.46.223.134]:6290) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pUMO5-000594-FA for 61672@debbugs.gnu.org; Tue, 21 Feb 2023 01:44:30 -0500 Received: from mx1.dismail.de (localhost [127.0.0.1]) by mx1.dismail.de (OpenSMTPD) with ESMTP id 549a6fb6 for <61672@debbugs.gnu.org>; Tue, 21 Feb 2023 07:44:21 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed; d=dismail.de; h=from:to:cc :subject:date:message-id:mime-version:content-type :content-transfer-encoding; s=20190914; bh=T3/qxjBwD8R+QS4p9XWui epRN7EwoaCILOtTuhG5iu0=; b=qwvOa2Ru15KtT6F67wpZTbOlyA+Pazh6gXqO4 Ggx6PQjHdISUGLwoO2whXHdnS72RZRkM3rnFHwicihgZhk4JmZQnci+jMgRoJviZ XHCejqk4du2xVu851V7ComIdQREhVoI3PFlmB85smDQpSZ7jsyCseA20pwScwMfD uXZuRYWuj0wYVpxlDb0jAZVRuGgwDAh8xmcANhqr++C8lNo/T8MuuoCFOFHkhJXS RPWRxdyDqva4hhC5+ihfZR70XX1uwfAvW4WdbsA7LnzdGC1c0NFUY9UM3mXd+UVV S01eHdKqIC+uYYFOrbkhF2/CWAEz1SXfoHFJzt1sheBfSC9rw== Received: from smtp1.dismail.de ( [10.240.26.11]) by mx1.dismail.de (OpenSMTPD) with ESMTP id 7579590b for <61672@debbugs.gnu.org>; Tue, 21 Feb 2023 07:44:21 +0100 (CET) Received: from smtp1.dismail.de (localhost [127.0.0.1]) by smtp1.dismail.de (OpenSMTPD) with ESMTP id cbea8385 for <61672@debbugs.gnu.org>; Tue, 21 Feb 2023 07:44:21 +0100 (CET) Received: by dismail.de (OpenSMTPD) with ESMTPSA id 9dfd6385 (TLSv1.3:TLS_AES_256_GCM_SHA384:256:NO); Tue, 21 Feb 2023 07:44:20 +0100 (CET) Date: Tue, 21 Feb 2023 07:43:55 +0100 Message-Id: <20230221064354.12168-1-jgart@dismail.de> X-Mailer: git-send-email 2.39.1 MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-to: jgart X-ACL-Warn: , jgart via Guix-patches X-Patchwork-Original-From: jgart via Guix-patches via From: jgart Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/packages/web.scm (nlohmann-json): New variable. v2 just rebases the history --- gnu/packages/web.scm | 48 +++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 47 insertions(+), 1 deletion(-) diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm index 98db004482..e2f9dddf06 100644 --- a/gnu/packages/web.scm +++ b/gnu/packages/web.scm @@ -58,7 +58,7 @@ ;;; Copyright © 2022 cage ;;; Copyright © 2022 Pradana Aumars ;;; Copyright © 2022 Petr Hodina -;;; Copyright © 2022 jgart +;;; Copyright © 2022, 2023 jgart ;;; Copyright © 2023 Paul A. Patience ;;; Copyright © 2022 Bruno Victal ;;; Copyright © 2023 David Thompson @@ -1109,6 +1109,52 @@ (define-public jansson data.") (license license:expat))) +(define-public nlohmann-json + (package + (name "nlohmann-json") + (version "3.11.2") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/nlohmann/json") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0g6rfsbkvrxmacchz4kbr741yybj7mls3r4hgyfdd3pdbqhn2is9")))) + (build-system cmake-build-system) + (arguments + (list #:out-of-source? #t + #:configure-flags + #~(list "-DJSON_FastTests=ON" + "-DJSON_MultipleHeaders=ON" + "-DJSON_BuildTests=ON" + (string-append "-DJSON_TestDataDirectory=" + #$(this-package-native-input "json-test-data"))) + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + ;; Skip tests that require git or modify “installed files”. + (when tests? + (invoke "make" "ARGS=-LE 'not_reproducible|git_required' --verbose"))))))) + (native-inputs + `(("json-test-data" + ,(origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/nlohmann/json_test_data") + (commit "v3.1.0"))) + (sha256 + (base32 "0nbirc428qx0lpi940p7y24fzdjbwl6xig3h5rdbihyymmdzhvbc")) + (file-name (git-file-name "vis-test" version)))))) + (home-page "https://json.nlohmann.me/") + (synopsis "JSON for Modern C++") + (description "This package provides a JSON implementation with an +intuitive syntax for C++, a single include header file, and with a +codebase that has 100% code coverage.") + (license license:expat))) + (define-public json-c (package (name "json-c")