From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id rmLZCrwZi2A+aAEAgWs5BA (envelope-from ) for ; Thu, 29 Apr 2021 22:40:28 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id kPeaBbwZi2BlcQAAbx9fmQ (envelope-from ) for ; Thu, 29 Apr 2021 20:40:28 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 681E8B101 for ; Thu, 29 Apr 2021 22:40:27 +0200 (CEST) Received: from localhost ([::1]:32780 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lcDSU-0006QN-7j for larch@yhetil.org; Thu, 29 Apr 2021 16:40:26 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:50200) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lcDS6-0006QC-Pl for guix-patches@gnu.org; Thu, 29 Apr 2021 16:40:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:45336) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lcDS6-0007rq-IA for guix-patches@gnu.org; Thu, 29 Apr 2021 16:40:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lcDS6-000175-CD for guix-patches@gnu.org; Thu, 29 Apr 2021 16:40:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#38635] [PATCH v3] Add why3 and frama-c Resent-From: Julien Lepiller Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 29 Apr 2021 20:40:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 38635 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 38635@debbugs.gnu.org Received: via spool by 38635-submit@debbugs.gnu.org id=B38635.16197287804245 (code B ref 38635); Thu, 29 Apr 2021 20:40:02 +0000 Received: (at 38635) by debbugs.gnu.org; 29 Apr 2021 20:39:40 +0000 Received: from localhost ([127.0.0.1]:56882 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lcDRd-00016J-1V for submit@debbugs.gnu.org; Thu, 29 Apr 2021 16:39:39 -0400 Received: from lepiller.eu ([89.234.186.109]:35752) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lcDRY-000165-DA for 38635@debbugs.gnu.org; Thu, 29 Apr 2021 16:39:31 -0400 Received: from lepiller.eu (localhost [127.0.0.1]) by lepiller.eu (OpenSMTPD) with ESMTP id 34fb140d for <38635@debbugs.gnu.org>; Thu, 29 Apr 2021 20:39:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed; d=lepiller.eu; h=date:from :to:subject:message-id:in-reply-to:references:mime-version :content-type; s=dkim; bh=OvNYrtOaDDmQr2u8jmftkLpr8J9qEzzvJJZzGm pnU4g=; b=OcAu0brMsQj/3SMXCCQbQdCltCY3STEYjNAIH7EyrjNM6pwpEfQE/g 0s6a0fyqYiTzqfLOrm7R5wBgg/jk5VwSt3DbuujuQ7DinCA6tKfmek31TpmQ91fR r8nhih1M9BH5FPI1sFoiCzZ3V9K7g7cSYlvVxD73SL4JukKdh4dVvuFyvTU9fOmS nRa/skx26vZbOJsLtoZ6rzdSMQVnKuE96UPCTTao5emvSat1E0s7/BaRMwjXjY3H hgNp7eQiMG5W9rF8XD50DKXj8ZwZbMO7wg7vnLzzYn6/bYQSQzWOMU/W1lqsupgp KBsvTu64xWDBrRolQG/GzZRTg/SNUyNg== Received: by lepiller.eu (OpenSMTPD) with ESMTPSA id 947ea0ef (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256:NO) for <38635@debbugs.gnu.org>; Thu, 29 Apr 2021 20:39:24 +0000 (UTC) Date: Thu, 29 Apr 2021 22:39:18 +0200 From: Julien Lepiller Message-ID: <20210429223850.7659957a@tachikoma.lepiller.eu> In-Reply-To: <20200902150508.5c4a45e8@tachikoma.lepiller.eu> References: <20191216124626.048f0e43@sybil.lepiller.eu> <20200902150508.5c4a45e8@tachikoma.lepiller.eu> X-Mailer: Claws Mail 3.17.8 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="MP_/QzT+U_b0luleQBdJJK+jriZ" 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: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1619728827; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:in-reply-to:in-reply-to:references:references: list-id:list-help:list-unsubscribe:list-subscribe:list-post: dkim-signature; bh=5OcftZBIB8mo/PvQ+Ro+71ZD6I8FD+FkxzIknC450aw=; b=El04/nnh0o/PbeRmPi6NX6yMzRJHzUmYWPfVBIXoiiC+wsDRIH23swzWHB1ox9RDkUFuf3 Bjyt5eROywEEOloQUNzebtkfbJ9AmBgmAwUcxAn+0+MPjdqB2b4uIIXEh9lj88gi79SKXe oDcuQMEm0Q+kA1oNUXlRnXQQerhSCNq9gi+nuwu9HdBrSkyGOC0ZtEewlHd1n+KIqZgi0O luE+gt94IlDO1zmjEdIWeZNgJl2+HFl5LlV3Kp7YUgK+85xwU9cDQ6wu/iWXtbar7ag2QA artiPdVYsmQw7+2HZ2ZYakSLg2sWZd16XpOF6t9TYOowjF4rGOu6Aig4U0ym5A== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1619728827; a=rsa-sha256; cv=none; b=ripcLzJnrp/T3/bV1PQjXaQNZG1YO6Wwv/aFJNlnwbmjxKsvTQMG4iweEU+l287Tjdnv43 O6vCfqhqUWay0BMW8j/fTgZXo8Vh8CTNuEl90ndxpUaNd1c6WrWAcIhtboeKwaBykpHavq 9HRhORZ5ZZlHt/UISinqRklWiX5JbjzUYsR7DEfigiwAv0+vrpF2bkAqLKjZDj5qu93xRU rrn5GZW1qAZO6DyZKXwxTJ7jPBphOKjrgD2gGhno6vcnfS4E/Hqtftq90DmADv6F8PX0uj TC+lm0UOkvnSwJvOG2AVA8Rofs9vGm2zi/wA23Aoj2sgWGn5BNSbvEbTzkr/ZA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=lepiller.eu header.s=dkim header.b=OcAu0brM; dmarc=fail reason="SPF not aligned (relaxed)" header.from=lepiller.eu (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: -1.36 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=lepiller.eu header.s=dkim header.b=OcAu0brM; dmarc=fail reason="SPF not aligned (relaxed)" header.from=lepiller.eu (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: 681E8B101 X-Spam-Score: -1.36 X-Migadu-Scanner: scn0.migadu.com X-TUID: KV36lnry/T3M --MP_/QzT+U_b0luleQBdJJK+jriZ Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Content-Disposition: inline Hi Guix! I updated my patches to the latest version of frama-c, and the issue is gone now! Frama-c is working, as long as ocaml is in the environment (because it's calling ocaml-findlib that needs an environment variable defined by the ocaml package). --MP_/QzT+U_b0luleQBdJJK+jriZ Content-Type: text/x-patch Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename=0001-gnu-Add-why3.patch =46rom 103afc0730fda2b27a103bc66f1ff283b7883e8b Mon Sep 17 00:00:00 2001 From: Julien Lepiller Date: Mon, 16 Dec 2019 12:09:16 +0100 Subject: [PATCH 1/2] gnu: Add why3. * gnu/packages/maths.scm (why3): New variable. --- gnu/packages/maths.scm | 66 +++++++++++++++++++++++++++++++++++++++++- 1 file changed, 65 insertions(+), 1 deletion(-) diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index a79e128955..a214b5d780 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -28,7 +28,7 @@ ;;; Copyright =C2=A9 2018 Adam Massmann ;;; Copyright =C2=A9 2018, 2020 Marius Bakke ;;; Copyright =C2=A9 2018 Eric Brown -;;; Copyright =C2=A9 2018 Julien Lepiller +;;; Copyright =C2=A9 2018, 2021 Julien Lepiller ;;; Copyright =C2=A9 2018 Amin Bandali ;;; Copyright =C2=A9 2019, 2021 Nicolas Goaziou ;;; Copyright =C2=A9 2019 Steve Sprang @@ -74,6 +74,7 @@ #:use-module (guix build-system cmake) #:use-module (guix build-system glib-or-gtk) #:use-module (guix build-system gnu) + #:use-module (guix build-system ocaml) #:use-module (guix build-system python) #:use-module (guix build-system ruby) #:use-module (gnu packages algebra) @@ -85,11 +86,13 @@ #:use-module (gnu packages check) #:use-module (gnu packages cmake) #:use-module (gnu packages compression) + #:use-module (gnu packages coq) #:use-module (gnu packages curl) #:use-module (gnu packages cyrus-sasl) #:use-module (gnu packages dbm) #:use-module (gnu packages documentation) #:use-module (gnu packages elf) + #:use-module (gnu packages emacs) #:use-module (gnu packages file) #:use-module (gnu packages flex) #:use-module (gnu packages fltk) @@ -6190,3 +6193,64 @@ and conversions, physical constants, symbolic calcul= ations (including integrals and equations), arbitrary precision, uncertainty propagation, interval arithmetic, plotting.") (license license:gpl2+))) + +(define-public why3 + (package + (name "why3") + (version "1.3.1") + (source (origin + (method url-fetch) + (uri (string-append "https://gforge.inria.fr/frs/download.ph= p/file" + "/38291/why3-" version ".tar.gz")) + (sha256 + (base32 + "16zcrc60zz2j3gd3ww93z2z9x2jkxb3kr57y8i5rcgmacy7mw3bv")))) + (build-system ocaml-build-system) + (native-inputs + `(("coq" ,coq) + ("ocaml" ,ocaml) + ("which" ,which))) + (propagated-inputs + `(("camlzip" ,camlzip) + ("ocaml-graph" ,ocaml-graph) + ("ocaml-menhir" ,ocaml-menhir) + ("ocaml-num" ,ocaml-num) + ("ocaml-zarith" ,ocaml-zarith))) + (inputs + `(("coq-flocq" ,coq-flocq) + ("emacs-minimal" ,emacs-minimal) + ("zlib" ,zlib))) + (arguments + `(#:phases + (modify-phases %standard-phases + (add-before 'configure 'fix-configure + (lambda _ + (setenv "CONFIG_SHELL" (which "sh")) + (substitute* "configure" + ;; find ocaml-num in the correct directory + (("\\$DIR/nums.cma") "$DIR/../nums.cma") + (("\\$DIR/num.cmi") "$DIR/../num.cmi")) + #t)) + (add-after 'configure 'fix-makefile + (lambda _ + (substitute* "Makefile" + ;; find ocaml-num in the correct directory + (("site-lib/num") "site-lib")) + #t)) + (add-after 'install 'install-lib + (lambda _ + (invoke "make" "byte") + (invoke "make" "install-lib") + #t))))) + (home-page "http://why3.lri.fr") + (synopsis "Deductive program verification") + (description "Why3 provides a language for specification and programmi= ng, +called WhyML, and relies on external theorem provers, both automated and +interactive, to discharge verification conditions. Why3 comes with a stan= dard +library of logical theories (integer and real arithmetic, Boolean operatio= ns, +sets and maps, etc.) and basic programming data structures (arrays, queues, +hash tables, etc.). A user can write WhyML programs directly and get +correct-by-construction OCaml programs through an automated extraction +mechanism. WhyML is also used as an intermediate language for the verific= ation +of C, Java, or Ada programs.") + (license license:lgpl2.1))) --=20 2.26.3 --MP_/QzT+U_b0luleQBdJJK+jriZ Content-Type: text/x-patch Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=0002-gnu-Add-frama-c.patch >From 431dc3f0212c53b60f075e4e2719531f2ad4d84a Mon Sep 17 00:00:00 2001 From: Julien Lepiller Date: Mon, 16 Dec 2019 12:40:18 +0100 Subject: [PATCH 2/2] gnu: Add frama-c. * gnu/packages/maths.scm (frama-c): New variable. --- gnu/packages/maths.scm | 47 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index a214b5d780..49a3fd3904 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -6254,3 +6254,50 @@ correct-by-construction OCaml programs through an automated extraction mechanism. WhyML is also used as an intermediate language for the verification of C, Java, or Ada programs.") (license license:lgpl2.1))) + +(define-public frama-c + (package + (name "frama-c") + (version "22.0") + (source (origin + (method url-fetch) + (uri (string-append "http://frama-c.com/download/frama-c-" + version "-Titanium.tar.gz")) + (sha256 + (base32 + "1mq1fijka95ydrla486yr4w6wdl9l7vmp512s1q00b0p6lmfwmkh")))) + (build-system ocaml-build-system) + (arguments + `(#:tests? #f; no test target in Makefile + #:phases + (modify-phases %standard-phases + (add-before 'configure 'export-shell + (lambda* (#:key inputs #:allow-other-keys) + (setenv "CONFIG_SHELL" (string-append (assoc-ref inputs "bash") + "/bin/sh")) + #t))))) + (inputs + `(("gmp" ,gmp))) + (propagated-inputs + `(("ocaml-biniou" ,ocaml-biniou) + ("ocaml-easy-format" ,ocaml-easy-format) + ("ocaml-graph" ,ocaml-graph) + ("ocaml-yojson" ,ocaml-yojson) + ("ocaml-zarith" ,ocaml-zarith) + ("why3" ,why3))) + (native-search-paths + (list (search-path-specification + (variable "FRAMAC_SHARE") + (files '("share/frama-c")) + (separator #f)) + (search-path-specification + (variable "FRAMAC_LIB") + (files '("lib/frama-c")) + (separator #f)))) + (home-page "http://frama-c.com") + (synopsis "C source code analysis platform") + (description "Frama-C is an extensible and collaborative platform dedicated +to source-code analysis of C software. The Frama-C analyzers assist you in +various source-code-related activities, from the navigation through unfamiliar +projects up to the certification of critical software.") + (license license:lgpl2.1+))) -- 2.26.3 --MP_/QzT+U_b0luleQBdJJK+jriZ--