Allow jdk / install-jdk.sh to use the build cache

If you set jdk to use a version that uses install-jdk.sh to install itself (e.g. opendjk12) you end up downloading the build artifact from oracle for every build. This ends up running into issues of rate limiting and connection failures leading to flaky builds. Adding “$HOME/.cache/install-jdk” to the cache directories doesn’t solve the issue because the jdk is installed before the build cache is restored.

Is there a valid reason to not restore the build cache first? install-jdk.sh invokes wget with the correct timestamp options to prevent re-downloading.

Yeah, a cache would be awesome.