未验证 提交 8634dc65 编写于 作者: O openharmony_ci 提交者: Gitee

!10606 [翻译完成】#I5S4AJ

Merge pull request !10606 from Annie_wang/PR9710
......@@ -4,32 +4,29 @@
## Mini and Small Systems
### "usr/sbin/ninja: invalid option -- w" Displayed During the Build Process
### "usr/sbin/ninja: invalid option -- w"
- **Symptom**
The compilation fails, and **usr/sbin/ninja: invalid option -- w** is displayed.
The build fails, and **usr/sbin/ninja: invalid option -- w** is displayed.
- **Possible Causes**
The Ninja version in the compilation environment is outdated and does not support the --w option.
The Ninja version in use does not support the **--w** option.
- **Solution**
Uninstall Ninja and GN in the environment and reinstall them by following instructions in [Obtaining Tools](../get-code/gettools-ide.md).
Uninstall Ninja and GN, and [install Ninja and GN of the required version](../get-code/gettools-ide.md).
### "/usr/bin/ld: cannot find -lncurses" Displayed During the Build Process
### "/usr/bin/ld: cannot find -lncurses"
- **Symptom**
The compilation fails, and **/usr/bin/ld: cannot find -lncurses** is displayed.
The build fails, and **/usr/bin/ld: cannot find -lncurses** is displayed.
- **Possible Causes**
The ncurses library is not installed.
- **Solution**
......@@ -39,17 +36,15 @@
```
### "line 77: mcopy: command not found" Displayed During the Build Process
### "line 77: mcopy: command not found"
- **Symptom**
The compilation fails, and **line 77: mcopy: command not found** is displayed.
The build fails, and **line 77: mcopy: command not found** is displayed.
- **Possible Causes**
Mcopy is not installed.
mcopy is not installed.
- **Solution**
......@@ -58,65 +53,62 @@
```
### "riscv32-unknown-elf-gcc: error trying to exec 'cc1': execvp: No such file or directory" Displayed During the Build Process
### "riscv32-unknown-elf-gcc: error trying to exec 'cc1': execvp: No such file or directory"
- **Symptom**
The compilation fails, and the following information is displayed: **riscv32-unknown-elf-gcc: error trying to exec 'cc1': execvp: No such file or directory**.
The build fails, and the following information is displayed: <br>**riscv32-unknown-elf-gcc: error trying to exec 'cc1': execvp: No such file or directory**
- **Possible Causes**
Permission is required to access files in the **riscv** compiler path.
You do not have the required permission to access files in the RISC-V compiler directory.
- **Solution**
1. Run the following command to query the directory where **gcc_riscv32** is located:
```
which riscv32-unknown-elf-gcc
```
1. Run the following command to locate **gcc_riscv32**:
```
which riscv32-unknown-elf-gcc
```
2. Run the **chmod** command to change the directory permission to **755**.
### "No module named 'Crypto'" Displayed During the Build Process
### "No module named 'Crypto'"
- **Symptom**
The compilation fails, and **No module named'Crypto loaded** is displayed.
The build fails, and **No module named 'Crypto'** is displayed.
- **Possible Causes**
Crypto is not installed in Python3.
- **Solution**
1. Run the following command to query the Python version:
```
python3 --version
```
2. Ensure that Python 3.7 or later is installed, and then run the following command to install pycryptodome:
```
sudo pip3 install pycryptodome
```
### "xx.sh : xx unexpected operator" Displayed During the Build Process
### "xx.sh: xx unexpected operator"
- **Symptom**
The compilation fails, and **xx.sh [: xx unexpected operator** is displayed.
The build fails, and **xx.sh [: xx unexpected operator** is displayed.
- **Possible Causes**
The compilation environment is shell instead of bash.
The build environment shell is not bash.
- **Solution**
......@@ -126,20 +118,18 @@
```
### "Could not find a version that satisfies the requirement six&gt;=1.9.0" Displayed During the Build Process
### "Could not find a version that satisfies the requirement six&gt;=1.9.0"
- **Symptom**
The following error occurs during compilation and building:
The following information is displayed during the build process:
```
Could not find a version that satisfies the requirement six>=1.9.0
```
- **Possible Causes**
**six** is not installed.
......@@ -149,88 +139,81 @@
Method 2: Install **six** offline.
Download the installation package from [PyPI](https://pypi.org/project/six/#files).
![en-us_image_0000001251276115](figures/en-us_image_0000001251276115.png)
1. Download the installation package from [PyPI](https://pypi.org/project/six/#files).
Save the source code to the Linux server and run the **pip3 install six-1.14.0-py2.py3-none-any.whl** command to install **six**.
After the preceding installation is complete, rebuild an environment.
![](figures/en-us_image_0000001251276115.png)
2. Save the source code to the Linux server and run the **pip3 install six-1.14.0-py2.py3-none-any.whl** command to install **six**.
3. Start the build again.
### "cannot find -lgcc" Displayed During the Build Process
### "cannot find -lgcc"
- **Symptom**
The following error occurs during the build process:
The following information is displayed during the build process:
```
riscv32-unknown-elf-ld: cannot find -lgcc
```
- **Possible Causes**
The gcc_riscv32 PATH is incorrect. There is an extra slash (/) after **bin**.
The gcc_riscv32 path is incorrectly set as follows. There is an extra slash (/) after **bin**.
```
~/gcc_riscv32/bin/:/data/toolchain/
```
- **Solution**
Modify the PATH as follows:
Modify the gcc_riscv32 path as follows:
```
~/gcc_riscv32/bin:/data/toolchain/
```
### The Message Indicating Python Cannot Be Found Is Displayed During the Build Process
### Failed to Find Python
- **Symptom**
The following error occurs during the build process:
The following information is displayed during the build process:
```
-bash: /usr/bin/python: No such file or directory
```
- **Possible Cause 1**
Python is not installed.
- **Solution**
Run the following command to install Python (Python 3.8 for example):
Run the following command to install Python. The following uses Python 3.8 as an example.
```
sudo apt-get install python3.8
```
- **Possible Cause 2**
The soft link that points to the Python does not exist in the **usr/bin** directory.
The soft link to Python does not exist in the **usr/bin** directory.
![en-us_image_0000001243200677](figures/en-us_image_0000001243200677.png)
![](figures/en-us_image_0000001243200677.png)
- **Solution**
Run the following commands to add a soft link:
Run the following commands to add the soft link to Python:
```
# cd /usr/bin/
# which python3
......@@ -238,28 +221,26 @@ After the preceding installation is complete, rebuild an environment.
# python --version
```
Example:
Example:
![en-us_image_0000001243320787](figures/en-us_image_0000001243320787.png)
![](figures/en-us_image_0000001243320787.png)
### The Message Indicating Python 3 Cannot Be Found Is Displayed During the Build Process
### Failed to Find Python3
- **Symptom**
![en-us_image_0000001251276255](figures/en-us_image_0000001251276255.png)
![](figures/en-us_image_0000001251276255.png)
- **Possible Causes**
Python 3 is not installed.
- **Solution**
Run the following command to install Python 3:
```
sudo apt-get install python3.8
```
......@@ -4,26 +4,30 @@
FAQs are used to help developers solve problems frequently encountered during development. They cover a wide range of topics.
## Environment setup
## Environment Setup
### Mini and Small Systems
- [What should I do if garbled characters and segmentation faults occur during hb installation?](../faqs/faqs-environment-setup.md)
- hb installation
- [What should I do if the message "cannot import 'sysconfig' from 'distutils'" is displayed during hb installation?](../faqs/faqs-environment-setup.md)
- [What should I do if garbled characters and segmentation faults occur during hb installation?](../faqs/faqs-environment-setup.md)
- [What should I do if the message "module 'platform' has no attribute 'linux_distribution'" is displayed during hb installation?](../faqs/faqs-environment-setup.md)
- [What should I do if the message "cannot import 'sysconfig' from 'distutils'" is displayed during hb installation?](../faqs/faqs-environment-setup.md)
- [What should I do if the message "Could not find a version that satisfies the requirement ohos-build" is displayed during hb installation?](../faqs/faqs-environment-setup.md)
- [What should I do if the message "module 'platform' has no attribute 'linux_distribution'" is displayed during hb installation?](../faqs/faqs-environment-setup.md)
- [What should I do if the message "configure: error: no acceptable C compiler found in $PATH" is displayed during Python 3 installation?](../faqs/faqs-environment-setup.md)
- [What should I do if the message "Could not find a version that satisfies the requirement ohos-build" is displayed during hb installation?](../faqs/faqs-environment-setup.md)
- [What should I do if the message "-bash: make: command not found" is displayed during Python 3 installation?](../faqs/faqs-environment-setup.md)
- Python3 Installation
- [What should I do if the message "zlib not available" is displayed during Python 3 installation?](../faqs/faqs-environment-setup.md)
- [What should I do if the message "configure: error: no acceptable C compiler found in $PATH" is displayed during Python 3 installation?](../faqs/faqs-environment-setup.md)
- [What should I do if the message "No module named 'Crypto'" is displayed during the build process?](../faqs/faqs-environment-setup.md)
- [What should I do if the message "-bash: make: command not found" is displayed during Python 3 installation?](../faqs/faqs-environment-setup.md)
- [What should I do if the message "zlib not available" is displayed during Python 3 installation?](../faqs/faqs-environment-setup.md)
- [What should I do if the message "No module named 'Crypto'" is displayed during the build process?](../faqs/faqs-environment-setup.md)
- [What should I do when an error with lsb_release occurs during kconfiglib installation?](../faqs/faqs-environment-setup.md)
......@@ -35,25 +39,25 @@ FAQs are used to help developers solve problems frequently encountered during de
### Mini and Small Systems
- ["usr/sbin/ninja: invalid option -- w" Displayed During the Build Process](../faqs/faqs-building.md)
- ["usr/sbin/ninja: invalid option -- w"](../faqs/faqs-building.md)
- ["/usr/bin/ld: cannot find -lncurses" Displayed During the Build Process](../faqs/faqs-building.md)
- ["/usr/bin/ld: cannot find -lncurses"](../faqs/faqs-building.md)
- ["line 77: mcopy: command not found" Displayed During the Build Process](../faqs/faqs-building.md)
- ["line 77: mcopy: command not found"](../faqs/faqs-building.md)
- ["riscv32-unknown-elf-gcc: error trying to exec 'cc1': execvp: No such file or directory" Displayed During the Build Process](../faqs/faqs-building.md)
- ["riscv32-unknown-elf-gcc: error trying to exec 'cc1': execvp: No such file or directory"](../faqs/faqs-building.md)
- ["No module named 'Crypto'" Displayed During the Build Process](../faqs/faqs-building.md)
- ["No module named 'Crypto'"](../faqs/faqs-building.md)
- ["xx.sh : xx unexpected operator" Displayed During the Build Process](../faqs/faqs-building.md)
- ["xx.sh : xx unexpected operator"](../faqs/faqs-building.md)
- ["Could not find a version that satisfies the requirement six>=1.9.0" Displayed During the Build Process](../faqs/faqs-building.md)
- ["Could not find a version that satisfies the requirement six>=1.9.0"](../faqs/faqs-building.md)
- ["cannot find -lgcc" Displayed During the Build Process](../faqs/faqs-building.md)
- ["cannot find -lgcc"](../faqs/faqs-building.md)
- [The Message Indicating Python Cannot Be Found Is Displayed During the Build Process](../faqs/faqs-building.md)
- [Failed to Find Python](../faqs/faqs-building.md)
- [The Message Indicating Python 3 Cannot Be Found Is Displayed During the Build Process](../faqs/faqs-building.md)
- [Failed to Find Python 3](../faqs/faqs-building.md)
## Burning
......@@ -173,6 +177,6 @@ FAQs are used to help developers solve problems frequently encountered during de
### hdc
- [Why does hdc_std fail to connect to a device?](../faqs/faqs-system-applications.md)
- [hdc_std Failed to Connect to a Device](../faqs/faqs-system-applications.md)
- [hdc_std fail to run](../faqs/faqs-system-applications.md)
- [hdc_std Failed to Run](../faqs/faqs-system-applications.md)
......@@ -3,10 +3,10 @@
## Utils FAQs
## Utils
### Failure in running the KV store on the LiteOS-A kernel (Hi3516 or Hi3518) due to incorrect path setting for the KV store
### Failed to Run a KV Store on LiteOS-A (Hi3516 or Hi3518)
**Symptom**
......@@ -119,9 +119,10 @@ The component added to the **.hml** file cannot be displayed.
**Solution**
(1) Check whether the width and height values are set explicitly.
1. Check whether the width and height values are set explicitly.
2. Check whether the style of the component is set correctly.
(2) Check whether the style of the component is set correctly.
### How do I implement scrolling on a page?
......@@ -174,27 +175,29 @@ If the total length of child components, except for the first and last ones, is
Do not include too many elements in an array. Avoid frequent operations on a large array.
## HDC FAQs
## hdc
### Why does hdc_std fail to connect to a device?
### hdc_std Failed to Connect to a Device
- **Symptom**
After the **hdc_std list targets** command is executed, **[Empty]** is displayed.
After the **hdc_std list targets** command is executed, **[Empty]** is displayed.
- **Solution**
1. The device cannot be identified.
Check whether **HDC Device** exists under the **Universal Serial Bus controllers** in the **Device Manager**. If **HDC Device** does not exist, the device cannot be connected. In this case, disconnect and then reconnect the USB connection between the test PC and the OpenHarmony device, or burn the latest image.
2. hdc_std works improperly.
Run the **hdc kill** command to terminate the hdc_std process or run the **hdc start -r** command to restart the hdc service. Then, run the **hdc list targets** command to check whether device information can be obtained.
3. hdc_std does not match the device.
If the latest image is burnt on the device, the latest hdc_std version must be used.
### hdc_std fail to run
### hdc_std Failed to Run
- **Symptom**
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册