me
/
guix
Archived
1
0
Fork 0

gnu: klee: Wrap klee-stats for Python dependencies.

* gnu/packages/check.scm (klee): Wrap klee-stats.

Signed-off-by: Liliana Marie Prikler <liliana.prikler@gmail.com>
master
Sören Tempel 2024-07-27 11:10:54 +02:00 committed by Liliana Marie Prikler
parent 0acc1c68d6
commit 661d5eeb8e
No known key found for this signature in database
GPG Key ID: 442A84B8C70E2F87
1 changed files with 8 additions and 3 deletions

View File

@ -1070,12 +1070,17 @@ with the @code{klee} package.")
(substitute* "CMakeLists.txt" (substitute* "CMakeLists.txt"
(("\\$\\{KLEE_UCLIBC_PATH\\}/lib/libc\\.a") (("\\$\\{KLEE_UCLIBC_PATH\\}/lib/libc\\.a")
"${KLEE_UCLIBC_PATH}")))) "${KLEE_UCLIBC_PATH}"))))
(add-after 'install 'wrap-hooks (add-after 'install 'wrap-programs
(lambda* (#:key inputs outputs #:allow-other-keys) (lambda* (#:key inputs outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out")) (let* ((out (assoc-ref outputs "out"))
(bin (string-append out "/bin")) (bin (string-append out "/bin"))
(lib (string-append out "/lib"))) (lib (string-append out "/lib")))
;; Ensure that KLEE finds runtime libraries (e.g. uclibc). ;; Ensure that klee-stats finds its Python dependencies.
(wrap-program (string-append bin "/klee-stats")
`("GUIX_PYTHONPATH" ":" prefix
,(search-path-as-string->list
(getenv "GUIX_PYTHONPATH"))))
;; Ensure that klee finds runtime libraries (e.g. uclibc).
(wrap-program (string-append bin "/klee") (wrap-program (string-append bin "/klee")
`("KLEE_RUNTIME_LIBRARY_PATH" = `("KLEE_RUNTIME_LIBRARY_PATH" =
(,(string-append lib "/klee/runtime/")))))))) (,(string-append lib "/klee/runtime/"))))))))
@ -1088,7 +1093,7 @@ with the @code{klee} package.")
(search-input-file %build-inputs "/lib/klee/libc.a")) (search-input-file %build-inputs "/lib/klee/libc.a"))
"-DENABLE_POSIX_RUNTIME=ON"))) "-DENABLE_POSIX_RUNTIME=ON")))
(native-inputs (list clang-13 llvm-13 python-lit)) (native-inputs (list clang-13 llvm-13 python-lit))
(inputs (list bash-minimal klee-uclibc gperftools sqlite z3)) (inputs (list bash-minimal klee-uclibc gperftools sqlite z3 python python-tabulate))
(build-system cmake-build-system) (build-system cmake-build-system)
(home-page "https://klee-se.org/") (home-page "https://klee-se.org/")
(synopsis "Symbolic execution engine") (synopsis "Symbolic execution engine")