From: André Draszik <andre.dras...@jci.com> The OpenJDK8-native recipe provides a Java SDK, and a Java Runtime. It is compatible with Java versions 5 through 8 (including), so add appropriate (R)PROVIDES, so that recipes depending on it can can specify that virtual dependency, rather than hard-coding to openjdk-8. This makes it possible to: a) add OpenJDK9 and OpenJDK10 recipes in the future without much disruption b) use a different provider than OpenJDK, e.g. Oracle Java, or Zulu Java
This is the approach taken by e.g. Debian. Signed-off-by: André Draszik <andre.dras...@jci.com> --- recipes-core/openjdk/openjdk-8-native.inc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/recipes-core/openjdk/openjdk-8-native.inc b/recipes-core/openjdk/openjdk-8-native.inc index 761ddc7..2dd31e7 100644 --- a/recipes-core/openjdk/openjdk-8-native.inc +++ b/recipes-core/openjdk/openjdk-8-native.inc @@ -87,3 +87,6 @@ do_install() { ln -sf "../lib/jvm/${JDK_DIR}/bin/$tool" ${D}${bindir}/$tool done } + +PROVIDES = "${@' '.join('virtual/java'+str(x)+'-sdk-native virtual/java'+str(x)+'-runtime-native' for x in range(5,9))}" +RPROVIDES_${PN} = "${@' '.join('virtual-java'+str(x)+'-sdk-native virtual-java'+str(x)+'-runtime-native' for x in range(5,9))}" -- 2.18.0 -- _______________________________________________ Openembedded-devel mailing list Openembedded-devel@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-devel