To start with, we are using the PDE build and we have a directory based target platform. I am aware that this is considered 'outdated' technology but as this is an over 12 year old large RCP application using plugins in it's target platform not available from P2 repositories we are currently stuck with this and it was working fine. However, we are currently undertaking a refresh to Java 11 and the latest RCP version (2020-06) and I am struggling getting our headless build to work.
Everything works fine out of the workspace and I can even export the product.
However, in our headless build I get errors like
[p2.mirror] Problems resolving provisioning plan.
[p2.mirror] Unable to satisfy dependency from <product> to osgi.ee; JavaSE [11.0.0,11.0.0]
and for each plugin
[p2.mirror] Unable to satisfy dependency from <plugin> to osgi.ee; (&(osgi.ee=JavaSE)(version=11))
Each plugin has the line
in it's manifest. This is required as we have multi-version JARs in the target platform and compilation fails against the Java 11 JDK if we set the execution environment to JavaSE-1.8 or below.
So it appears the headless build P2 invocation can't find the Java 11 OSGi profile. Any idea, how I can make that profile available to the build?