From b0f13defd1fde775aabf916e637e9bef8c4c092b Mon Sep 17 00:00:00 2001
From: Esben Haabendal <esben.haabendal@huawei.com>
Date: Wed, 25 May 2022 16:02:31 +0200
Subject: [PATCH] openharmony-standard: Pull in java tool for building HAP
 packages

Signed-off-by: Esben Haabendal <esben.haabendal@huawei.com>
---
 recipes-openharmony/openharmony/java-tools.inc | 12 ++++++++++++
 1 file changed, 12 insertions(+)
 create mode 100644 recipes-openharmony/openharmony/java-tools.inc

diff --git a/recipes-openharmony/openharmony/java-tools.inc b/recipes-openharmony/openharmony/java-tools.inc
new file mode 100644
index 00000000..98e2859e
--- /dev/null
+++ b/recipes-openharmony/openharmony/java-tools.inc
@@ -0,0 +1,12 @@
+# SPDX-FileCopyrightText: Huawei Inc.
+#
+# SPDX-License-Identifier: Apache-2.0
+
+# Make sure we have java tools in $PATH
+
+DEPENDS:append:oniro-openharmony-linux = " openjdk-8-native"
+INHERIT:append:oniro-openharmony-linux = " java"
+JAVA_BUILD_VERSION:oniro-openharmony-linux = "openjdk-8-native"
+export JAVA_HOME:oniro-openharmony-linux = "${STAGING_LIBDIR_JVM_NATIVE}/${JAVA_BUILD_VERSION}"
+export CLASSPATH:oniro-openharmony-linux += "${STAGING_LIBDIR_JVM_NATIVE}/${JAVA_BUILD_VERSION}/lib/tools.jar"
+EXTRANATIVEPATH:append:oniro-openharmony-linux = " ../${baselib}/jvm/${JAVA_BUILD_VERSION}/bin"
-- 
GitLab