diff mbox series

[bug#38635,WIP,v2] Add why3 and frama-c

Message ID 20200902150508.5c4a45e8@tachikoma.lepiller.eu
State Accepted
Headers show
Series [bug#38635,WIP,v2] Add why3 and frama-c | expand

Checks

Context Check Description
cbaines/applying patch fail View Laminar job

Commit Message

Julien Lepiller Sept. 2, 2020, 1:05 p.m. UTC
Hi Guix!

I've updated my patches to the newest versions of why3 and frama-c. The
issue is still present as before:

$ frama-c --help

[kernel] User Error: cannot load plug-in 'zip': cannot load module
  Details: error loading shared library: Dynlink.Error
(Dynlink.Cannot_open_dll
"Failure(\"/gnu/store/jrbkl0ls1vqnr1w7gcbg8jlxcd1jp71m-profile/lib/ocaml/site-lib/zip/zip.cmxa:
invalid ELF header\")") [kernel] User Error: cannot load plug-in
'why3': cannot load module Details: error loading shared library:
Dynlink.Error (Dynlink.Cannot_open_dll
"Failure(\"/gnu/store/jrbkl0ls1vqnr1w7gcbg8jlxcd1jp71m-profile/lib/ocaml/site-lib/why3/why3.cmxs:
undefined symbol: camlGzip\")") [kernel] User Error: cannot load
plug-in 'frama-c-wp': cannot load module Details: error loading shared
library: Dynlink.Error (Dynlink.Cannot_open_dll
"Failure(\"/gnu/store/bicyz7li6bvrxh4kh2h1dc5398bx5xsm-frama-c-21.1/lib/frama-c/plugins/top/Wp.cmxs:
undefined symbol: camlWhy3__Theory\")") [kernel] User Error: Deferred
error message was emitted during execution. See above messages for more
information. [kernel] Frama-C aborted: invalid user input.
diff mbox series

Patch

From 408f2a6feffc8d86d0e3ff31b891614b160ed142 Mon Sep 17 00:00:00 2001
From: Julien Lepiller <julien@lepiller.eu>
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 | 38 ++++++++++++++++++++++++++++++++++++++
 1 file changed, 38 insertions(+)

diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index aa3d0da77c..a18d35504c 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -6035,3 +6035,41 @@  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 "21.1")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "http://frama-c.com/download/frama-c-"
+                                  version "-Scandium.tar.gz"))
+              (sha256
+               (base32
+                "0qq0d08dzr0dmdjysiimdqmwlzgnn932vp5kf8lfn3nl45ai09dy"))))
+    (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)))
+    (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.28.0