提交 e9c218c3 编写于 作者: O openharmony_ci 提交者: Gitee

!148 更新 js framework子系统 readme

Merge pull request !148 from piggyguy_jdx/master
......@@ -44,7 +44,7 @@ The source code of the framework is stored in **/foundation/ace**. The followin
- RAM: memory pool shared with the native UI \(recommended\). The size must be greater than 80 KB.
- ROM: greater than 300 KB \(for the JS application framework and related subsystems, such as native UI and JavaScript engine\)
- Cortex-A RAM/ROM
- Cortex-A RAM and ROM
- JavaScript engine memory pool: greater than 128 KB \(recommended\)
- RAM: greater than 512 KB \(recommended\)
- ROM: greater than 2 MB \(for the JS application framework and related subsystems, such as native UI and JavaScript engine\)
......@@ -77,9 +77,11 @@ The framework uses feature macros to customize function code to be compiled on d
└── acelite_config.h*
```
Note: Currently only the target compilation for LiteOS Cortex-A is open-source, which is built using Ninja \(BUILD.g\). Other targets such as simulat \(CMake+MingW\), Linux\(Ninja\), and LiteOS Cortex-M \(IAR\) are not completely open and will be gradually released after the adaptation is complete. The following examples describe the role of the **targets** directory in building different targets.
When compiling for different platform targets, use the **acelite\_config.h** file in the corresponding platform directory. You can configure the header file searching path for compilation to locate the file to use. The following takes **ninja** and **cmake** build tools as examples:
- ninja:
- **ninja**:
```
if (ohos_kernel_type == "liteos_a" || ohos_kernel_type== "liteos_m" ||
......@@ -91,7 +93,7 @@ When compiling for different platform targets, use the **acelite\_config.h** f
```
- cmake:
- **cmake**:
```
......
......@@ -119,7 +121,7 @@ When compiling for different platform targets, use the **acelite\_config.h** f
The **acelite\_config.h** file is used to enable or disable the feature macros of different platforms. It can also be used to define constants for shielding platform differences. For example, platform file systems are different, and the names of some fixed directories might be different. These constants can be defined as follows:
- liteos-a/acelite\_config.h
- **liteos-a/acelite\_config.h**
```
#define JS_FRAMEWORK_PATH "//system/ace/bin/"
......@@ -175,9 +177,9 @@ The following NPM commands are supported:
```
build/
├── framework-dev.js // Framework code used by the development environment (uncompressed and obfuscated)
├── framework-dev.js // Framework code used in the development environment (uncompressed and obfuscated)
├── framework-dev.min.js // Framework code used in the development environment (compressed and obfuscated)
├── framework-dev.js // Framework code used by the production environment (uncompressed and obfuscated)
├── framework-dev.js // Framework code used in the production environment (uncompressed and obfuscated)
├── framework-dev.min.js // Framework code used in the production environment (compressed and obfuscated)
```
......
......@@ -77,6 +77,8 @@ JS应用框架通过一些特性宏来定制不同平台上参与编译的功能
└── acelite_config.h*
```
注:目前开源部分比较完整的是LiteOS A核的真机目标编译,使用ninja\(BUILD.gn\)构建,其他如 simulator \(CMake+MingW),Linux(ninja),LiteOS M核\(IAR\)目标,还未完全开源,在适配完成后会逐渐放出。以下仅通过示例说明targets目录在构建不同目标时的作用。
在编译不同的平台目标时,需要使用对应平台目录下的acelite\_config.h头文件,这可以通过配置编译时的搜索路径来进行,以下以ninja和cmake构建工具为例进行示例:
- ninja:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册