@yochananmarqos java-environment is not required here. There is no need to list it at all, not even at makedepends. As you already said, java-environment is required by gradle, which already pulls it. Most of the java packages depends only on the runtime, and only the ones that compiles java stuff (like gradle) needs the environment. This package does not compile java code and thus does not need the environment. It only runs a java software, so it needs only the runtime.
Specifying multiple java version restrictions can break the build on the chroot in certain future circumstances because it installs both ones when the current java version is exactly the maximum one. I'm not sure why this happens, but it looks like that multiple version restrictions does not work too smartly when dealing with virtual packages. For example, trying to build 0.8.8 on the chroot with multiple version restrictions right now fails while jre is at 16, because it will install both jre16 and jre11, being 16 the default one. To see what I'm talking about, just downgrade the PKGBUILD to 0.8.8 right now while jre is still at version 16 on the stable repositories, change java dependency to 'java-runtime>=11' 'java-runtime<16' (notice 'java-runtime<16' and not 'java-runtime<=16' for 0.8.8) and build the package in a clean chroot with devtools. This error will be gone when jre17 enters the stable repositories, but it's safer to stay like it's now to avoid future problems and reduce package maintenance burden, specially as jre11 is officially recommended by upstream.
Pinned Comments
dbermond commented on 2020-11-04 18:52 (UTC)
@txtsd AUR helpers are not supported. Manage the needed pgp key[1][2][3] and use makepkg[4]. The Arch Wiki is your friend.
[1] https://wiki.archlinux.org/index.php/GnuPG#Use_a_keyserver
[2] https://wiki.archlinux.org/index.php/GnuPG#Searching_and_receiving_keys
[3] https://wiki.archlinux.org/index.php/GnuPG#Key_servers
[4] https://wiki.archlinux.org/index.php/Makepkg