From 5dd6727af05c9c46726b5b22ba1fe3eed434e720 Mon Sep 17 00:00:00 2001 From: unknown Date: Tue, 7 Sep 2021 23:25:46 +0800 Subject: [PATCH 1/4] fix build problem Signed-off-by: unknown --- BUILD.gn | 120 +++++-------------------------------------------------- 1 file changed, 9 insertions(+), 111 deletions(-) diff --git a/BUILD.gn b/BUILD.gn index 0e82b411..4659f18d 100755 --- a/BUILD.gn +++ b/BUILD.gn @@ -11,117 +11,15 @@ # See the License for the specific language governing permissions and # limitations under the License. -import("//build/config/ohos/rules.gni") import("//build/ohos.gni") -import("//developtools/developtools.gni") - -java_library("hmos_app_packing_tool_java") { - java_files = [ - "adapter/ohos/BundleException.java", - "adapter/ohos/CommandParser.java", - "adapter/ohos/CompressEntrance.java", - "adapter/ohos/Compressor.java", - "adapter/ohos/CompressVerify.java", - "adapter/ohos/Log.java", - "adapter/ohos/ShowHelp.java", - "adapter/ohos/Utility.java", - ] - - main_class = "ohos.CompressEntrance" - - final_jar_path = "$root_build_dir/developtools/hmos_app_packing_tool.jar" -} - -java_library("hmos_app_unpacking_tool_java") { - java_files = [ - "adapter/ohos/BundleException.java", - "adapter/ohos/CommandParser.java", - "adapter/ohos/Log.java", - "adapter/ohos/ShowHelp.java", - "adapter/ohos/UncompressEntrance.java", - "adapter/ohos/Uncompress.java", - "adapter/ohos/UncompressVerify.java", - "adapter/ohos/Utility.java", - "adapter/ohos/HapInfo.java", - "adapter/ohos/ReqPermission.java", - "adapter/ohos/Distro.java", - "adapter/ohos/AbilityInfo.java", - "adapter/ohos/MetaData.java", - "adapter/ohos/MetaDataInfo.java", - "adapter/ohos/SkillInfo.java", - "adapter/ohos/UsedScene.java", - "adapter/ohos/PackInfo.java", - "adapter/ohos/FormInfo.java", - "adapter/ohos/ProfileInfo.java", - "adapter/ohos/AppInfo.java", - "adapter/ohos/DefPermission.java", - "adapter/ohos/DefPermissionGroup.java", - "adapter/ohos/CustomizeData.java", - "adapter/ohos/UncomperssResult.java", - "adapter/ohos/JsonUtil.java", - "adapter/ohos/JsInfo.java", - "adapter/ohos/DeviceConfig.java", - "adapter/ohos/CommonEvent.java", - "adapter/ohos/Shortcut.java", - "adapter/ohos/IntentInfo.java", - "adapter/ohos/ResourcesParser.java", - "adapter/ohos/DistroFilter.java", - "adapter/ohos/ApiVersion.java", - "adapter/ohos/ScreenShape.java", - "adapter/ohos/ScreenDensity.java", - "adapter/ohos/ScreenWindow.java", - "adapter/ohos/CountryCode.java", - "adapter/ohos/HapZipInfo.java", - ] - - deps = [ "//third_party/fastjson/repackaged:fastjson_utils_java" ] - - java_manifest_file = "META-INF/unpacking_tool/MANIFEST.MF" - - main_class = "ohos.UncompressEntrance" - - final_jar_path = "$root_build_dir/developtools/hmos_app_unpacking_tool.jar" -} - -java_library("hmos_haptobin_tool_java") { - java_files = [ - "adapter/ohos/Log.java", - "adapter/ohos/BinaryTool.java", - "adapter/ohos/FileUtils.java", - "adapter/ohos/ConvertHapToBin.java", - ] - - deps = [ "//third_party/fastjson/repackaged:fastjson_utils_java" ] - - java_manifest_file = "META-INF/packingbin_tool/MANIFEST.MF" - - main_class = "ohos.ConvertHapToBin" - - final_jar_path = "$root_build_dir/developtools/hmos_haptobin_tool.jar" +ohos_prebuilt_etc("etc_file_packing") { + source = "jar/hmos_app_packing_tool.jar" + deps = [] + part_name = "developtools_packing_tool" +}, +ohos_prebuilt_etc("etc_file_unpacking") { + source = "jar/hmos_app_unpacking_tool.jar" + deps = [] + part_name = "developtools_packing_tool" } - -java_library("hmos_bininfo_collecting_tool_java") { - java_files = [ - "adapter/ohos/Log.java", - "adapter/ohos/FileUtils.java", - "adapter/ohos/CollectBinInfo.java", - ] - - deps = [ "//third_party/fastjson/repackaged:fastjson_utils_java" ] - - java_manifest_file = "META-INF/collectingbininfo_tool/MANIFEST.MF" - - main_class = "ohos.CollectBinInfo" - - final_jar_path = - "$root_build_dir/developtools/hmos_bininfo_collecting_tool.jar" -} - -group("packing_tool_target") { - deps = [ - ":hmos_app_packing_tool_java", - ":hmos_app_unpacking_tool_java", - ":hmos_bininfo_collecting_tool_java", - ":hmos_haptobin_tool_java", - ] } -- Gitee From d5fb6434c3daf97949cf3b34cfb5de57ea3313b1 Mon Sep 17 00:00:00 2001 From: unknown Date: Tue, 7 Sep 2021 23:25:46 +0800 Subject: [PATCH 2/4] fix build problem Signed-off-by: unknown --- BUILD.gn | 116 ++++--------------------------------------------------- 1 file changed, 8 insertions(+), 108 deletions(-) diff --git a/BUILD.gn b/BUILD.gn index 0e82b411..d93256c8 100755 --- a/BUILD.gn +++ b/BUILD.gn @@ -11,117 +11,17 @@ # See the License for the specific language governing permissions and # limitations under the License. -import("//build/config/ohos/rules.gni") import("//build/ohos.gni") -import("//developtools/developtools.gni") -java_library("hmos_app_packing_tool_java") { - java_files = [ - "adapter/ohos/BundleException.java", - "adapter/ohos/CommandParser.java", - "adapter/ohos/CompressEntrance.java", - "adapter/ohos/Compressor.java", - "adapter/ohos/CompressVerify.java", - "adapter/ohos/Log.java", - "adapter/ohos/ShowHelp.java", - "adapter/ohos/Utility.java", - ] - - main_class = "ohos.CompressEntrance" - - final_jar_path = "$root_build_dir/developtools/hmos_app_packing_tool.jar" +ohos_prebuilt_etc("etc_file_packing") { + source = "jar/hmos_app_packing_tool.jar" + module_install_dir = "jar" + part_name = "developtools_packing_tool" } -java_library("hmos_app_unpacking_tool_java") { - java_files = [ - "adapter/ohos/BundleException.java", - "adapter/ohos/CommandParser.java", - "adapter/ohos/Log.java", - "adapter/ohos/ShowHelp.java", - "adapter/ohos/UncompressEntrance.java", - "adapter/ohos/Uncompress.java", - "adapter/ohos/UncompressVerify.java", - "adapter/ohos/Utility.java", - "adapter/ohos/HapInfo.java", - "adapter/ohos/ReqPermission.java", - "adapter/ohos/Distro.java", - "adapter/ohos/AbilityInfo.java", - "adapter/ohos/MetaData.java", - "adapter/ohos/MetaDataInfo.java", - "adapter/ohos/SkillInfo.java", - "adapter/ohos/UsedScene.java", - "adapter/ohos/PackInfo.java", - "adapter/ohos/FormInfo.java", - "adapter/ohos/ProfileInfo.java", - "adapter/ohos/AppInfo.java", - "adapter/ohos/DefPermission.java", - "adapter/ohos/DefPermissionGroup.java", - "adapter/ohos/CustomizeData.java", - "adapter/ohos/UncomperssResult.java", - "adapter/ohos/JsonUtil.java", - "adapter/ohos/JsInfo.java", - "adapter/ohos/DeviceConfig.java", - "adapter/ohos/CommonEvent.java", - "adapter/ohos/Shortcut.java", - "adapter/ohos/IntentInfo.java", - "adapter/ohos/ResourcesParser.java", - "adapter/ohos/DistroFilter.java", - "adapter/ohos/ApiVersion.java", - "adapter/ohos/ScreenShape.java", - "adapter/ohos/ScreenDensity.java", - "adapter/ohos/ScreenWindow.java", - "adapter/ohos/CountryCode.java", - "adapter/ohos/HapZipInfo.java", - ] - - deps = [ "//third_party/fastjson/repackaged:fastjson_utils_java" ] - - java_manifest_file = "META-INF/unpacking_tool/MANIFEST.MF" - - main_class = "ohos.UncompressEntrance" - - final_jar_path = "$root_build_dir/developtools/hmos_app_unpacking_tool.jar" +ohos_prebuilt_etc("etc_file_unpacking") { + source = "jar/hmos_app_unpacking_tool.jar" + module_install_dir = "jar" + part_name = "developtools_packing_tool" } - -java_library("hmos_haptobin_tool_java") { - java_files = [ - "adapter/ohos/Log.java", - "adapter/ohos/BinaryTool.java", - "adapter/ohos/FileUtils.java", - "adapter/ohos/ConvertHapToBin.java", - ] - - deps = [ "//third_party/fastjson/repackaged:fastjson_utils_java" ] - - java_manifest_file = "META-INF/packingbin_tool/MANIFEST.MF" - - main_class = "ohos.ConvertHapToBin" - - final_jar_path = "$root_build_dir/developtools/hmos_haptobin_tool.jar" -} - -java_library("hmos_bininfo_collecting_tool_java") { - java_files = [ - "adapter/ohos/Log.java", - "adapter/ohos/FileUtils.java", - "adapter/ohos/CollectBinInfo.java", - ] - - deps = [ "//third_party/fastjson/repackaged:fastjson_utils_java" ] - - java_manifest_file = "META-INF/collectingbininfo_tool/MANIFEST.MF" - - main_class = "ohos.CollectBinInfo" - - final_jar_path = - "$root_build_dir/developtools/hmos_bininfo_collecting_tool.jar" -} - -group("packing_tool_target") { - deps = [ - ":hmos_app_packing_tool_java", - ":hmos_app_unpacking_tool_java", - ":hmos_bininfo_collecting_tool_java", - ":hmos_haptobin_tool_java", - ] } -- Gitee From a5e4314cd20d47f0296e3e3f040ff755af2f0b75 Mon Sep 17 00:00:00 2001 From: unknown Date: Wed, 8 Sep 2021 14:24:18 +0800 Subject: [PATCH 3/4] fix BUILD.gn Signed-off-by: unknown --- BUILD.gn | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/BUILD.gn b/BUILD.gn index d93256c8..a8f14693 100755 --- a/BUILD.gn +++ b/BUILD.gn @@ -21,7 +21,6 @@ ohos_prebuilt_etc("etc_file_packing") { ohos_prebuilt_etc("etc_file_unpacking") { source = "jar/hmos_app_unpacking_tool.jar" - module_install_dir = "jar" + module_install_dir = "jar" part_name = "developtools_packing_tool" } -} -- Gitee From af3b80443c4546aa7dfa232e78d127cc8a21f7c9 Mon Sep 17 00:00:00 2001 From: unknown Date: Wed, 8 Sep 2021 14:44:02 +0800 Subject: [PATCH 4/4] fix Build.gn Signed-off-by: unknown --- BUILD.gn | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/BUILD.gn b/BUILD.gn index a8f14693..b4f4157e 100755 --- a/BUILD.gn +++ b/BUILD.gn @@ -13,14 +13,12 @@ import("//build/ohos.gni") -ohos_prebuilt_etc("etc_file_packing") { +ohos_prebuilt_etc("app_packing_tool") { source = "jar/hmos_app_packing_tool.jar" - module_install_dir = "jar" - part_name = "developtools_packing_tool" + install_enable = false } -ohos_prebuilt_etc("etc_file_unpacking") { +ohos_prebuilt_etc("app_unpacking_tool") { source = "jar/hmos_app_unpacking_tool.jar" - module_install_dir = "jar" - part_name = "developtools_packing_tool" + install_enable = false } -- Gitee