Advertisement
Guest User

Untitled

a guest
May 4th, 2022
21
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Scheme 1.21 KB | None | 0 0
  1. (define z3-with-java
  2.   (package
  3.    (inherit z3)
  4.    ;; (native-inputs (modify-inputs (package-native-inputs z3)
  5.    ;;                               (append openjdk11)))
  6.    (native-inputs
  7.     `(("which" ,which)
  8.       ("python" ,python-wrapper)
  9.       ("jdk" ,openjdk11 "jdk")))
  10.    (arguments
  11.     `(#:tests? #f
  12.       #:phases
  13.       (modify-phases %standard-phases
  14.                      (add-after 'unpack 'set-JDK_HOME
  15.                                 (lambda* (#:key inputs #:allow-other-keys)
  16.                                   ;; (setenv "JDK_HOME" (search-input-directory ???))
  17.                                   (setenv "JDK_HOME" (assoc-ref inputs "jdk"))
  18.                                   #t))
  19.                      (replace 'configure
  20.                               (lambda* (#:key inputs outputs #:allow-other-keys)
  21.                                 (invoke "./configure"
  22.                                         "--java"
  23.                                         (string-append "--prefix=" (assoc-ref outputs "out")))))
  24.                      (add-after 'configure 'change-directory
  25.                                 (lambda _
  26.                                   (chdir "build")
  27.                                   #t)))))))
  28.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement