gnu: java-flatlaf: Link library with libjawt.so.

* gnu/packages/java-graphics.scm (java-flatlaf)[arguments]: Add link options.

Change-Id: I2306e7ea4c2ca9f0f20eeca107b09fa41304a8df
This commit is contained in:
Ricardo Wurmus 2024-04-06 00:40:59 +02:00
parent 6ec2888ff7
commit 886ed061d7
No known key found for this signature in database
GPG key ID: 197A5888235FACAC

View file

@ -187,6 +187,24 @@ (define-public java-flatlaf
("aarch64-linux" "aarch64")
("x86_64-linux" "x86_64")
(_ "generic")))
(lib #$(match (%current-system)
("i686-linux"
"/lib/i386")
("x86_64-linux"
"/lib/amd64")
("armhf-linux"
"/lib/arm")
("aarch64-linux"
"/lib/aarch64")
("powerpc-linux"
"/lib/ppc")
;; We need a catch-all, dropping
;; '-linux' works in most cases.
(_
(string-append
"/lib/"
(string-drop-right
(%current-system) 6)))))
(filename
(string-append "libflatlaf-linux-" suffix ".so"))
(target-dir
@ -197,6 +215,8 @@ (define-public java-flatlaf
"src/main/cpp/ApiVersion.cpp"
"src/main/cpp/X11WmUtils.cpp"
"-Isrc/main/headers"
"-ljawt"
(string-append "-L" jdk lib)
(string-append "-I" jdk "/include")
(string-append "-I" jdk "/include/linux")
"-o" filename)