• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Chromium
2## Introduction
31. Chromium is an open-source web browser principally developed by Google and from which Google Chrome draws its source code. It is released under the BSD license and other permissive open-source licenses, aiming to build a safer, faster and more stable way to experience the Internet.
42. OpenHarmony nwebview is built on Chromium.
5## Software Architecture
6Below is the software architecture.
7```
8    -----------------------
9    |      Web component         |
10    -----------------------
11    |      nwebview        |
12    -----------------------
13    |       CEF            |
14    -----------------------
15    |      Chromium        |
16    -----------------------
17    |  OpenHarmony base library   |
18    -----------------------
19```
20* Web component: UI component in OpenHarmony.
21* nwebview: native engine of the OpenHarmony web component, which is built based on the Chromium Embedded Framework (CEF).
22* CEF: stands for Chromium Embedded Framework. It is an open-source project based on Google Chromium.
23* Chromium: an open-source web browser principally developed by Google and released under the BSD license and other permissive open-source licenses.
24## Directory Structure
25```
26.
27└── patch                      # patch directory customized for Chromium and used to build nwebview
28```
29## Usage
301. Run **./init_chromium.sh** to initialize the source code.
31* Download the Google tool set depot_tools.
32* Obtain the Chromium source code and download the third-party libraries on which Chromium depends.
33* Based on the source code, add nweb build modifications, including adding CEF code, adapting OpenHarmony compilation and build, nweb build source code, Chromium vulnerability patching, and nweb bug fixes.
34* *Note 1: For details about the CEF, visit [third_party_cef](https://gitee.com/openharmony/third_party_cef)*.
352. Compile the OpenHarmony image of the RK3568 platform in full mode. When the compilation is successful, perform step 3 to compile the nweb component in OpenHarmony.
36* *Note 2: For details about how to build the OpenHarmony image of the RK3568 platform, see [RK3568 Build Guidelines](https://gitee.com/openharmony/docs/blob/master/zh-cn/device-dev/quick-start/quickstart-standard-running-rk3568-build.md).*
373. Run **./build.sh rk3568** to build the source code.
384. Use DevEco Studio to package the build target into **NWeb.hap**, and run **hdc_std install NWeb.hap** to install **NWeb.hap** on RK3568. To download DevEco Studio, visit https://hmxt.org/deveco-studio.
39## Repositories Involved
40[ace_ace_engine](https://gitee.com/openharmony/ace_ace_engine)
41
42[third_party_cef](https://gitee.com/openharmony/third_party_cef)
43
44[web_webview](https://gitee.com/openharmony/web_webview)
45
46**[third_party_chromium](https://gitee.com/openharmony/third_party_chromium)**
47