Files
openhab.nix/jdk.nix

25 lines
552 B
Nix
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
{
buildPlatform,
hostPlatform,
jdk21,
which,
zip,
buildPackages,
}:
if buildPlatform == hostPlatform
then jdk21
else
jdk21.overrideAttrs (old: {
# lol, nixpkgs cant get pkgs right
# AUTOCONF = "${autoconf}/bin/autoconf";
nativeBuildInputs = old.nativeBuildInputs ++ [which zip];
depsBuildBuild = with buildPackages; [stdenv.cc autoconf];
configureFlags =
old.configureFlags
++ [
"--with-jtreg=no"
"--disable-hotspot-gtest"
"--with-build-jdk=${buildPackages.jdk21}"
];
})