Fix various circular requirements, method redefinitions, etc.
Split the core requirement class into generic, Linux-specific, and macOS-specific parts. Additionally, the Linux version is now able to detect Java versions (the previous Linuxbrew implementation was only able to detect if Java was present at all.)