From 615f4693daf5b27fa49045151b2776593877f47e Mon Sep 17 00:00:00 2001 From: chencheng31 Date: Mon, 7 Mar 2022 16:50:09 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E4=BF=AE=E6=94=B9readme=E6=8F=8F=E8=BF=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: chencheng31 --- README.md | 44 +++++++++++++++++++++++++++++++------------- README_zh.md | 44 +++++++++++++++++++++++++++++++------------- 2 files changed, 62 insertions(+), 26 deletions(-) diff --git a/README.md b/README.md index 9d6b4ea..5133a4c 100644 --- a/README.md +++ b/README.md @@ -1,18 +1,23 @@ -# global_resource_tool +# OpenHarmony resource compile tool -#### Description -OpenHarmony resource compile tool +## Description +restool(resource tool) is used in computer.In OpenHarmony SDK toolchain.When IDE pack OpenHarmony application, application resources will be compiled by restool, then the result compiling will be passed to pack tool.Support window,linux, macos platform. -#### Directory Structure ->developtools/ ->>----global_resource_tool ->>>----include ->>>----src ->>>----third_party dependence third patry lib make script ->>>----CMakeLists.txt ->>>----win32.cmake windows cross compile script +## Directory Structure -#### Instructions +``` +/developtools +|----global_resource_tool +| |----include +| |----src +| |----third_party dependence third patry lib make script +| |----CMakeLists.txt +| |----win32.cmake windows cross compile script +``` + +## Instructions + +### Compile 1. gcc/g++ version 9.3.0 required 2. cmake version mini 3.15 required @@ -22,7 +27,20 @@ OpenHarmony resource compile tool 6. make 7. compile result restool binary -#### Related to the storehouse +### Help + +restool usually integrate to IDE, OpenHarmony compile system. + +run ./restool, show command: + +-v version +-i input resource path +-o output resource path +-r resource ID header file path +-p package name + +using IDE(recommonded) +## Related to the storehouse third_party_libxml2 third_party_jsoncpp diff --git a/README_zh.md b/README_zh.md index 25a8b01..2352fef 100644 --- a/README_zh.md +++ b/README_zh.md @@ -1,19 +1,23 @@ -# global_resource_tool +# OpenHarmony 应用资源编译工具 -#### 介绍 -OpenHarmony 资源编译编译工具 +## 介绍 +资源编译工具(resource tool, 缩写restool) 属于PC端工具,在OpenHarmony SDK中toolchain 目录下。在IDE生成 OpenHarmony 应用包过程中,调用restool 编译应用资源,编译结果传递给打包工具生成 OpenHarmony 应用包。支持window, linux, macos平台。 -#### 目录 ->developtools/ ->>----global_resource_tool ->>>----include ->>>----src ->>>----third_party 依赖三方库编译脚本 ->>>----CMakeLists.txt ->>>----win32.cmake windows交叉编译脚本 +## 目录 +``` +/developtools +|----global_resource_tool +| |----include +| |----src +| |----third_party 依赖三方库编译脚本 +| |----CMakeLists.txt +| |----win32.cmake windows交叉编译脚本 +``` -#### 使用说明 +## 使用说明 + +### 代码编译命令 1. 编译环境gcc/g++ 9.3.0 2. cmake 版本最低3.15 @@ -23,7 +27,21 @@ OpenHarmony 资源编译编译工具 6. make 7. 编译结果输出restool -#### 相关仓 +### 命令帮助 + +本工具一般被IDE 和OpenHarmony 编译系统集成调用。 + +手动执行./restool 会提示支持的命令行参数。简单命令参数如下: + +-v 显示工具版本号 +-i 资源输入目录 +-o 资源输出目录 +-r 资源ID头文件 +-p 应用包名 + +复杂场景推荐使用IDE 工具。 + +## 相关仓 third_party_libxml2 third_party_jsoncpp From cfa89019a2e0e58661ca4275317b1120cda6838c Mon Sep 17 00:00:00 2001 From: chencheng31 Date: Tue, 8 Mar 2022 13:58:40 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E4=BF=AE=E6=94=B9readme=E5=86=85=E5=AE=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: chencheng31 --- README.md | 2 ++ README_zh.md | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 5133a4c..b1ec3df 100644 --- a/README.md +++ b/README.md @@ -39,6 +39,8 @@ run ./restool, show command: -r resource ID header file path -p package name +./restool -i main -o out -r out/ResourceTable.h -p ohos.demo + using IDE(recommonded) ## Related to the storehouse diff --git a/README_zh.md b/README_zh.md index 2352fef..b2997f8 100644 --- a/README_zh.md +++ b/README_zh.md @@ -39,7 +39,9 @@ -r 资源ID头文件 -p 应用包名 -复杂场景推荐使用IDE 工具。 +./restool -i main -o out -r out/ResourceTable.h -p ohos.demo + +推荐使用IDE工具。 ## 相关仓