From: Liliana Marie Prikler <liliana.prikler@gmail.com>
To: soeren@soeren-tempel.net, 72106@debbugs.gnu.org
Subject: [bug#72106] [PATCH v2 2/5] gnu: klee: Enable the test suite.
Date: Sun, 14 Jul 2024 20:53:49 +0200 [thread overview]
Message-ID: <68c1ee2dec2780cc8d6d5bc0db0f36492236b85c.camel@gmail.com> (raw)
In-Reply-To: <b65bd1448a381db7821c51380d549643a0942601.1720981528.git.soeren@soeren-tempel.net>
Am Sonntag, dem 14.07.2024 um 20:25 +0200 schrieb
soeren@soeren-tempel.net:
> From: Sören Tempel <soeren@soeren-tempel.net>
>
> * gnu/packages/check.scm (klee): Enable all tests.
> [arguments]: Add phase to patch lit configuration, set #:test-target.
> <#:configure-flags?>: Enable system and unit tests, configure gtest.
> [inputs]: Add googletest and python-lit.
> ---
> gnu/packages/check.scm | 30 +++++++++++++++++++++++++++---
> 1 file changed, 27 insertions(+), 3 deletions(-)
>
> diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm
> index 6b0ea0aaa8..552cb39de5 100644
> --- a/gnu/packages/check.scm
> +++ b/gnu/packages/check.scm
> @@ -1063,13 +1063,23 @@ (define-public klee
> (base32
> "1nma6dqi8chjb97llsa8mzyskgsg4dx56lm8j514j5wmr8vkafz6"))))
> (arguments
> (list
> + #:test-target "check"
> #:phases
> #~(modify-phases %standard-phases
> - (add-after 'unpack 'patch
> + (add-after 'unpack 'patch-cmake
> (lambda _
> (substitute* "CMakeLists.txt"
>
> (("\\$\\{KLEE_UCLIBC_PATH\\}/lib/libc\\.a")
> "${KLEE_UCLIBC_PATH}"))))
> + (add-after 'unpack 'patch-lit-config
> + (lambda _
> + ;; Make sure that we retain the value of
> the GUIX_PYTHONPATH
> + ;; environment variable in the test
> environmented created by
> + ;; python-lit. Otherwise, the test scripts
> won't be able to
> + ;; find the python-tabulate dependency,
> causing test failures.
> + (substitute* "test/lit.cfg"
> + (("addEnv\\('PWD'\\)" env)
> + (string-append env "\n"
> "addEnv('GUIX_PYTHONPATH')")))))
If this is a test, then we should use native-inputs below.
> (add-after 'install 'wrap-klee-stats
> (lambda* (#:key outputs #:allow-other-keys)
> (let* ((out (assoc-ref outputs "out"))
> @@ -1088,7 +1098,13 @@ (define-public klee
> `("KLEE_RUNTIME_LIBRARY_PATH" =
> (,(string-append lib
> "/klee/runtime/"))))))))
> #:configure-flags
> - #~(list (string-append "-DLLVMCC="
> + #~(list "-DENABLE_UNIT_TESTS=ON"
> + "-DENABLE_SYSTEM_TESTS=ON"
> + (string-append "-DGTEST_SRC_DIR="
> + (assoc-ref %build-inputs "googletest"))
> + (string-append "-DGTEST_INCLUDE_DIR="
> + (assoc-ref %build-inputs "googletest")
> "/googletest/include")
> + (string-append "-DLLVMCC="
> (search-input-file %build-inputs
> "/bin/clang"))
> (string-append "-DLLVMCXX="
> (search-input-file %build-inputs
> "/bin/clang++"))
> @@ -1096,7 +1112,15 @@ (define-public klee
> (search-input-file %build-inputs
> "/lib/klee/libc.a"))
> "-DENABLE_POSIX_RUNTIME=ON")))
> (native-inputs (list clang-13 llvm-13 python-lit))
> - (inputs (list bash-minimal klee-uclibc gperftools sqlite z3
> python python-tabulate))
> + (inputs
> + `(("bash-minimal" ,bash-minimal)
> + ("klee-uclibc" ,klee-uclibc)
> + ("gperftools" ,gperftools)
> + ("sqlite" ,sqlite)
> + ("z3" ,z3)
> + ("python", python)
> + ("python-tabulate" ,python-tabulate)
> + ("googletest" ,(package-source googletest))))
Why the package source and not the compiled package? Can we make it so
that we can use a prebuilt compiled one?
Cheers
next prev parent reply other threads:[~2024-07-14 18:56 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-14 10:36 [bug#72106] [PATCH 0/3] gnu: klee: Enable test suite soeren
2024-07-14 10:42 ` [bug#72106] [PATCH 1/3] gnu: klee: Propagate Python dependencies needed by klee-stats soeren
2024-07-14 11:43 ` Liliana Marie Prikler
2024-07-14 10:42 ` [bug#72106] [PATCH 2/3] gnu: klee: Enable the test suite soeren
2024-07-14 10:42 ` [bug#72106] [PATCH 3/3] gnu: klee: Only strip bin directory soeren
2024-07-14 16:17 ` [bug#72106] [PATCH 0/3] gnu: klee: Enable test suite Liliana Marie Prikler
2024-07-14 18:29 ` Sören Tempel
2024-07-14 18:25 ` [bug#72106] [PATCH v2 1/5] gnu: klee: Wrap klee-stats for Python dependencies soeren
2024-07-14 18:25 ` [bug#72106] [PATCH v2 2/5] gnu: klee: Enable the test suite soeren
2024-07-14 18:53 ` Liliana Marie Prikler [this message]
2024-07-14 20:04 ` Sören Tempel
2024-07-20 9:56 ` Ludovic Courtès
2024-07-25 20:43 ` Sören Tempel
2024-07-14 18:25 ` [bug#72106] [PATCH v2 3/5] gnu: klee: Only strip bin directory soeren
2024-07-14 18:25 ` [bug#72106] [PATCH v2 4/5] gnu: klee: Only build on x86_64 Linux soeren
2024-07-14 18:54 ` Liliana Marie Prikler
2024-07-14 18:25 ` [bug#72106] [PATCH v2 5/5] gnu: klee-uclibc: " soeren
2024-07-14 18:54 ` Liliana Marie Prikler
2024-07-25 20:39 ` [bug#72106] [PATCH v3 1/5] gnu: klee: Wrap klee-stats for Python dependencies soeren
2024-07-25 20:40 ` [bug#72106] [PATCH v3 2/5] gnu: klee: Enable the test suite soeren
2024-07-25 20:40 ` [bug#72106] [PATCH v3 3/5] gnu: klee: Only strip bin directory soeren
2024-07-26 18:38 ` Liliana Marie Prikler
2024-07-25 20:40 ` [bug#72106] [PATCH v3 4/5] gnu: klee: Only build on x86_64 Linux soeren
2024-07-26 18:41 ` Liliana Marie Prikler
2024-07-27 9:13 ` Sören Tempel
2024-07-25 20:40 ` [bug#72106] [PATCH v3 5/5] gnu: klee-uclibc: " soeren
2024-07-26 18:37 ` [bug#72106] [PATCH v3 1/5] gnu: klee: Wrap klee-stats for Python dependencies Liliana Marie Prikler
2024-07-27 9:10 ` [bug#72106] [PATCH v4 " soeren
2024-07-27 9:10 ` [bug#72106] [PATCH v4 2/5] gnu: klee: Enable the test suite soeren
2024-07-27 9:10 ` [bug#72106] [PATCH v4 3/5] gnu: klee: Only strip bin directory soeren
2024-07-27 9:10 ` [bug#72106] [PATCH v4 4/5] gnu: klee: Only build on x86_64 Linux soeren
2024-07-27 9:10 ` [bug#72106] [PATCH v4 5/5] gnu: klee-uclibc: " soeren
2024-07-27 17:28 ` bug#72106: " Liliana Marie Prikler
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=68c1ee2dec2780cc8d6d5bc0db0f36492236b85c.camel@gmail.com \
--to=liliana.prikler@gmail.com \
--cc=72106@debbugs.gnu.org \
--cc=soeren@soeren-tempel.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).