提交 64208a97 编写于 作者: C conglin

update readme

Signed-off-by: Nconglin <conglin8023@126.com>
上级 a922f1c6
...@@ -52,7 +52,7 @@ OpenHarmony provides the following two types of Docker environments for you to q ...@@ -52,7 +52,7 @@ OpenHarmony provides the following two types of Docker environments for you to q
</td> </td>
<td class="cellrowborder" valign="top" headers="mcps1.2.6.1.3 "><p id="p552616549297"><a name="p552616549297"></a><a name="p552616549297"></a>swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard</p> <td class="cellrowborder" valign="top" headers="mcps1.2.6.1.3 "><p id="p552616549297"><a name="p552616549297"></a><a name="p552616549297"></a>swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard</p>
</td> </td>
<td class="cellrowborder" valign="top" headers="mcps1.2.6.1.4 "><p id="p1633303300"><a name="p1633303300"></a><a name="p1633303300"></a>0.0.3</p> <td class="cellrowborder" valign="top" headers="mcps1.2.6.1.4 "><p id="p1633303300"><a name="p1633303300"></a><a name="p1633303300"></a>0.0.4</p>
</td> </td>
</tr> </tr>
<tr id="row5986201731214"><td class="cellrowborder" align="center" valign="top" width="15.831583158315832%" headers="mcps1.2.6.1.1 "><p id="p136981216143"><a name="p136981216143"></a><a name="p136981216143"></a>HPM-based Docker environment</p> <tr id="row5986201731214"><td class="cellrowborder" align="center" valign="top" width="15.831583158315832%" headers="mcps1.2.6.1.1 "><p id="p136981216143"><a name="p136981216143"></a><a name="p136981216143"></a>HPM-based Docker environment</p>
...@@ -69,6 +69,7 @@ OpenHarmony provides the following two types of Docker environments for you to q ...@@ -69,6 +69,7 @@ OpenHarmony provides the following two types of Docker environments for you to q
</tbody> </tbody>
</table> </table>
## Preparations<a name="section7337134183512"></a> ## Preparations<a name="section7337134183512"></a>
Before using the Docker environment, perform the following operations: Before using the Docker environment, perform the following operations:
...@@ -178,7 +179,7 @@ hb set ...@@ -178,7 +179,7 @@ hb set
1. Obtain the Docker image. 1. Obtain the Docker image.
``` ```
docker pull swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard:0.0.3 docker pull swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard:0.0.4
``` ```
2. Go to the root directory of OpenHarmony code and run the following command to access the Docker build environment: 2. Go to the root directory of OpenHarmony code and run the following command to access the Docker build environment:
...@@ -212,21 +213,15 @@ hb set ...@@ -212,21 +213,15 @@ hb set
### Building for Standard-System Devices \(reference memory ≥ 128 MB\)<a name="section193711513406"></a> ### Building for Standard-System Devices \(reference memory ≥ 128 MB\)<a name="section193711513406"></a>
1. Run the preprocessing script in the root directory of the source code. Run the following script to start building for standard-system devices \(reference memory ≥ 128 MB\).
```
../scripts/prepare.sh
```
2. Run the following script to start building for standard-system devices \(reference memory ≥ 128 MB\).
``` ```
./build.sh --product-name {product_name} ./build.sh --product-name {product_name}
``` ```
**product\_name** indicates the platform supported by the current distribution, for example, Hi3516D V300. **product\_name** indicates the platform supported by the current distribution, for example, Hi3516D V300.
Files generated during building are stored in the **out/ohos-arm-release/** directory, and the generated image is stored in the **out/ohos-arm-release/packages/phone/images/** directory. Files generated during building are stored in the **out/ohos-arm-release/** directory, and the generated image is stored in the **out/ohos-arm-release/packages/phone/images/** directory.
>![](../public_sys-resources/icon-note.gif) **NOTE:** >![](../public_sys-resources/icon-note.gif) **NOTE:**
...@@ -307,4 +302,3 @@ Start building. Docker can be automatically installed only in Ubuntu. If you are ...@@ -307,4 +302,3 @@ Start building. Docker can be automatically installed only in Ubuntu. If you are
hpm run distWithDocker solution={product} hpm run distWithDocker solution={product}
``` ```
...@@ -44,6 +44,7 @@ Method 1 \(recommended\): Use the **repo** tool to download the source code ov ...@@ -44,6 +44,7 @@ Method 1 \(recommended\): Use the **repo** tool to download the source code ov
repo init -u git@gitee.com:openharmony/manifest.git -b master --no-repo-verify repo init -u git@gitee.com:openharmony/manifest.git -b master --no-repo-verify
repo sync -c repo sync -c
repo forall -c 'git lfs pull' repo forall -c 'git lfs pull'
bash build/prebuilts_download.sh
``` ```
Method 2: Use the **repo** tool to download the source code over HTTPS. Method 2: Use the **repo** tool to download the source code over HTTPS.
...@@ -52,6 +53,7 @@ Method 2: Use the **repo** tool to download the source code over HTTPS. ...@@ -52,6 +53,7 @@ Method 2: Use the **repo** tool to download the source code over HTTPS.
repo init -u https://gitee.com/openharmony/manifest.git -b master --no-repo-verify repo init -u https://gitee.com/openharmony/manifest.git -b master --no-repo-verify
repo sync -c repo sync -c
repo forall -c 'git lfs pull' repo forall -c 'git lfs pull'
bash build/prebuilts_download.sh
``` ```
## Obtaining the Docker Environment<a name="section181431248132513"></a> ## Obtaining the Docker Environment<a name="section181431248132513"></a>
...@@ -61,13 +63,13 @@ repo forall -c 'git lfs pull' ...@@ -61,13 +63,13 @@ repo forall -c 'git lfs pull'
1. Obtain the Docker image. 1. Obtain the Docker image.
``` ```
docker pull swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard:0.0.3 docker pull swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard:0.0.4
``` ```
2. Go to the root directory of OpenHarmony code and run the following command to access the Docker build environment: 2. Go to the root directory of OpenHarmony code and run the following command to access the Docker build environment:
``` ```
docker run -it -v $(pwd):/home/openharmony swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard:0.0.3 docker run -it -v $(pwd):/home/openharmony swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard:0.0.4
``` ```
...@@ -89,27 +91,21 @@ repo forall -c 'git lfs pull' ...@@ -89,27 +91,21 @@ repo forall -c 'git lfs pull'
3. Go to the root directory of OpenHarmony code and run the following command to access the Docker build environment: 3. Go to the root directory of OpenHarmony code and run the following command to access the Docker build environment:
``` ```
docker run -it -v $(pwd):/home/openharmony openharmony-docker-standard:0.0.3 docker run -it -v $(pwd):/home/openharmony openharmony-docker-standard:0.0.4
``` ```
## Building Source Code<a name="section92391739152318"></a> ## Building Source Code<a name="section92391739152318"></a>
1. Run the preprocessing script in the root directory of the source code. 1. Run the following script to start building for Standard-System Devices \(reference memory ≥ 128 MB\):
``` ```
../scripts/prepare.sh ./build.sh --product-name {product_name}
``` ```
2. Run the following script to start building for Standard-System Devices \(reference memory ≥ 128 MB\):
```
./build.sh --product-name {product_name}
```
**product\_name** indicates the product supported by the current distribution, for example, **Hi3516DV300**. **product\_name** indicates the product supported by the current distribution, for example, **Hi3516DV300**.
Files generated during the build are stored in the **out/ohos-arm-release/** directory, and the generated image is stored in the **out/ohos-arm-release/packages/phone/images/** directory. Files generated during the build are stored in the **out/ohos-arm-release/** directory, and the generated image is stored in the **out/ohos-arm-release/packages/phone/images/** directory.
3. Burn the image. For details, see [Burning Images](quickstart-standard-burn.md). 3. Burn the image. For details, see [Burning Images](quickstart-standard-burn.md).
......
...@@ -52,7 +52,7 @@ OpenHarmony为开发者提供了两种Docker环境,以帮助开发者快速完 ...@@ -52,7 +52,7 @@ OpenHarmony为开发者提供了两种Docker环境,以帮助开发者快速完
</td> </td>
<td class="cellrowborder" valign="top" headers="mcps1.2.6.1.3 "><p id="p552616549297"><a name="p552616549297"></a><a name="p552616549297"></a>swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard</p> <td class="cellrowborder" valign="top" headers="mcps1.2.6.1.3 "><p id="p552616549297"><a name="p552616549297"></a><a name="p552616549297"></a>swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard</p>
</td> </td>
<td class="cellrowborder" valign="top" headers="mcps1.2.6.1.4 "><p id="p1633303300"><a name="p1633303300"></a><a name="p1633303300"></a>0.0.3</p> <td class="cellrowborder" valign="top" headers="mcps1.2.6.1.4 "><p id="p1633303300"><a name="p1633303300"></a><a name="p1633303300"></a>0.0.4</p>
</td> </td>
</tr> </tr>
<tr id="row5986201731214"><td class="cellrowborder" align="center" valign="top" width="15.831583158315832%" headers="mcps1.2.6.1.1 "><p id="p136981216143"><a name="p136981216143"></a><a name="p136981216143"></a>HPM Docker环境</p> <tr id="row5986201731214"><td class="cellrowborder" align="center" valign="top" width="15.831583158315832%" headers="mcps1.2.6.1.1 "><p id="p136981216143"><a name="p136981216143"></a><a name="p136981216143"></a>HPM Docker环境</p>
...@@ -69,6 +69,7 @@ OpenHarmony为开发者提供了两种Docker环境,以帮助开发者快速完 ...@@ -69,6 +69,7 @@ OpenHarmony为开发者提供了两种Docker环境,以帮助开发者快速完
</tbody> </tbody>
</table> </table>
## 环境准备<a name="section7337134183512"></a> ## 环境准备<a name="section7337134183512"></a>
在使用docker环境前需要先完成以下操作: 在使用docker环境前需要先完成以下操作:
...@@ -178,13 +179,13 @@ hb set ...@@ -178,13 +179,13 @@ hb set
1. 获取Docker镜像。 1. 获取Docker镜像。
``` ```
docker pull swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard:0.0.3 docker pull swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard:0.0.4
``` ```
2. 进入OpenHarmony代码根目录执行如下命令,从而进入Docker构建环境。 2. 进入OpenHarmony代码根目录执行如下命令,从而进入Docker构建环境。
``` ```
docker run -it -v $(pwd):/home/openharmony swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard:0.0.3 docker run -it -v $(pwd):/home/openharmony swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard:0.0.4
``` ```
...@@ -212,21 +213,15 @@ hb set ...@@ -212,21 +213,15 @@ hb set
### 编译源码-标准系统类设备(参考内存≥128MB)<a name="section193711513406"></a> ### 编译源码-标准系统类设备(参考内存≥128MB)<a name="section193711513406"></a>
1. 在源码的根目录执行预处理脚本。 通过如下编译脚本启动标准系统类设备(参考内存≥128MB)的编译。
```
../scripts/prepare.sh
```
2. 通过如下编译脚本启动标准系统类设备(参考内存≥128MB)的编译。
``` ```
./build.sh --product-name {product_name} ./build.sh --product-name {product_name}
``` ```
\{product\_name\}为当前版本支持的平台。比如:Hi3516DV300等。 \{product\_name\}为当前版本支持的平台。比如:Hi3516DV300等。
编译所生成的文件都归档在out/ohos-arm-release/目录下,结果镜像输出在 out/ohos-arm-release/packages/phone/images/ 目录下。 编译所生成的文件都归档在out/ohos-arm-release/目录下,结果镜像输出在 out/ohos-arm-release/packages/phone/images/ 目录下。
>![](../public_sys-resources/icon-note.gif) **说明:** >![](../public_sys-resources/icon-note.gif) **说明:**
...@@ -307,4 +302,3 @@ docker\_dist是一个[HPM](https://hpm.harmonyos.com/)系统中的模板组件 ...@@ -307,4 +302,3 @@ docker\_dist是一个[HPM](https://hpm.harmonyos.com/)系统中的模板组件
hpm run distWithDocker solution={product} hpm run distWithDocker solution={product}
``` ```
...@@ -44,6 +44,7 @@ OpenHarmony标准系统为开发者提供的Docker环境已经将对应的编译 ...@@ -44,6 +44,7 @@ OpenHarmony标准系统为开发者提供的Docker环境已经将对应的编译
repo init -u git@gitee.com:openharmony/manifest.git -b master --no-repo-verify repo init -u git@gitee.com:openharmony/manifest.git -b master --no-repo-verify
repo sync -c repo sync -c
repo forall -c 'git lfs pull' repo forall -c 'git lfs pull'
bash build/prebuilts_download.sh
``` ```
方式二:通过repo + https 下载。 方式二:通过repo + https 下载。
...@@ -52,6 +53,7 @@ repo forall -c 'git lfs pull' ...@@ -52,6 +53,7 @@ repo forall -c 'git lfs pull'
repo init -u https://gitee.com/openharmony/manifest.git -b master --no-repo-verify repo init -u https://gitee.com/openharmony/manifest.git -b master --no-repo-verify
repo sync -c repo sync -c
repo forall -c 'git lfs pull' repo forall -c 'git lfs pull'
bash build/prebuilts_download.sh
``` ```
## 获取Docker环境<a name="section181431248132513"></a> ## 获取Docker环境<a name="section181431248132513"></a>
...@@ -61,13 +63,13 @@ repo forall -c 'git lfs pull' ...@@ -61,13 +63,13 @@ repo forall -c 'git lfs pull'
1. 获取Docker镜像。 1. 获取Docker镜像。
``` ```
docker pull swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard:0.0.3 docker pull swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard:0.0.4
``` ```
2. 进入OpenHarmony代码根目录执行如下命令,从而进入Docker构建环境。 2. 进入OpenHarmony代码根目录执行如下命令,从而进入Docker构建环境。
``` ```
docker run -it -v $(pwd):/home/openharmony swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard:0.0.3 docker run -it -v $(pwd):/home/openharmony swr.cn-south-1.myhuaweicloud.com/openharmony-docker/openharmony-docker-standard:0.0.4
``` ```
...@@ -89,27 +91,21 @@ repo forall -c 'git lfs pull' ...@@ -89,27 +91,21 @@ repo forall -c 'git lfs pull'
3. 进入OpenHarmony代码根目录执行如下命令,从而进入Docker构建环境。 3. 进入OpenHarmony代码根目录执行如下命令,从而进入Docker构建环境。
``` ```
docker run -it -v $(pwd):/home/openharmony openharmony-docker-standard:0.0.3 docker run -it -v $(pwd):/home/openharmony openharmony-docker-standard:0.0.4
``` ```
## 编译<a name="section92391739152318"></a> ## 编译<a name="section92391739152318"></a>
1. 在源码的根目录执行预处理脚本 1. 通过如下编译脚本启动标准系统类设备(参考内存≥128MB)的编译
``` ```
../scripts/prepare.sh ./build.sh --product-name {product_name}
``` ```
2. 通过如下编译脚本启动标准系统类设备(参考内存≥128MB)的编译。
```
./build.sh --product-name {product_name}
```
\{product\_name\}为当前版本支持的平台,比如:Hi3516DV300 \{product\_name\}为当前版本支持的平台,比如:Hi3516DV300
编译所生成的文件都归档在out/ohos-arm-release/目录下,结果镜像输出在 out/ohos-arm-release/packages/phone/images/ 目录下。 编译所生成的文件都归档在out/ohos-arm-release/目录下,结果镜像输出在 out/ohos-arm-release/packages/phone/images/ 目录下。
3. 编译源码完成,请进行镜像烧录,具体请参见[镜像烧录](quickstart-standard-burn.md) 3. 编译源码完成,请进行镜像烧录,具体请参见[镜像烧录](quickstart-standard-burn.md)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册