Opatch requires Java 1.7 but Oracle 12.1.0.2 has 1.6
I recently stumbled upon an interesting problem, I had to apply the latest PSU on a 12.1.0.2 release (Solaris x86). However Opatch complained about backlevel Java and refused to apply the patch.
I tried setting JAVA home and Classpath/JLIB environment variables to a newer installation stored with an Oracle 19c release.
However it seems opatch is somehow hardcoded to use the jdk installed in Oracle HOME?
What would be the supported methodology for opatch to use a specific java installation? I briefly looked into the opatch itself, but I failed to understand how it overrides my JAVA home environment variable.