OpenHarmony更新编译问题及解决办法
OpenHarmony更新编译问题及解决办法
Linux问题
没有/hgfs
Linux和Windows共享文件夹:/mnt目录下没有/hgfs的解决办法
sudo apt-get install open -vm -tools
sudo mkdir /mnt/hgfs
sudo vmhgfs-fuse .host:/ /mnt/hgfs
无法查看共享文件夹
无法查看共享文件夹解决办法
sudo vmhgfs-fuse .host:/ /mnt/hgfs/ -o allow_other -o uid=1000
修改缓存大小
修改缓存大小,ubuntu变快
在ubuntu里面,swappiness的值的大小对如何使用swap分区是有着很大的联系的。swappiness=0的时候表示最大限度使用物理内存,然后才是swap空间,swappiness=100的时候表示积极的使用swap分区,并且把内存上的数据及时的搬运到swap空间里面。两个极端,对于ubuntu的默认设置,这个值等于60,建议修改为10。具体这样做:1.查看你的系统里面的swappiness
cat /proc/sys/vm/swappiness
#不出意外的话,你应该看到是602.修改swappiness值为10
sudo sysctl vm.swappiness=103.但只是临时修改,重启系统后会恢复默认的60,所以,还要做一步:
sudo gedit /etc/sysctl.conf
在这个文档的最后加上这样一行:
vm.swappiness=104.然后保存,重启。设置就生效了。
键盘不能使用:
1、关闭虚拟机电源,点击 编辑虚拟机设置 选项 常规,在右下角的 增强型虚拟键盘 中,选择果可用请使用/需要,确定
2、备份并删除虚拟机系统目录下的 后缀名为 .vmdk.lck 的文件或文件夹,重启虚拟机
Linux拒绝访问
本地移动文件在Linux拒绝访问:
chown -R 用户名:用户名 masterchown -R 用户名:用户名 foundation/xxx/xxx
Ubuntu映射
Samba配置
samba 一个实现不同操作系统之间文件共享和打印机共享的一种SMB协议的免费软件
sudo apt install samba #安装samba
sudo vi /etc/samba/smb.conf
写入:
[share]comment = sharebrowseable = yespath = /home/si/writable = yesguest ok = noread only = nocreate mask = 0777
重启samba服务
sudo service smbd restart
sudo smbpasswd -a si #配置使用用户以及密码,si用户名
关闭防火墙路径:
控制面板\系统和安全\Windows Defender 防火墙\自定义设置
更新代码错误
error: hooks is different in /home/si/openharmony/.repo/projects/drivers/hdf_core.git vs /home/si/openharmony/.repo/project-objects/drivers_hdf_core.git
error: Cannot fetch drivers_hdf_core (GitError: --force-sync not enabled; cannot overwrite a local work tree. If you’re comfortable with the possibility of losing the work tree’s git metadata, use repo sync --force-sync drivers/hdf_core
to proceed.)
repo sync --force-sync drivers/hdf_core
client_loop: send disconnect: Broken pipe
fatal: the remote end hung up unexpectedly
fatal: the_remote end hung up unexpectedly
fatal; early EOF
fatal: index-pack failed
fatal: early EOF
fatal: index-pack failed
third_party_ffmpeg:
remote: Enurerating objects: 527204,done.
remote: Counting objects: 100%(27/27), done.
remote: Compressing objects: 100% (21/21), done.
fatal: the remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed
试下强制拉取: repo sync --force-sync
编译错误
全量编译
[OHOS ERROR] /usr/bin/env: ‘ruby’: No such file or directory
apt-get install ruby
[OHOS ERROR] …/…/prebuilts/mingw-w64/ohos/linux-x86_64/clang-mingw/bin/clang: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory
sudo apt-get install libncurses5
[OHOS ERROR] ‘…/…/third_party/flutter/skia/third_party/externals/icu/scripts/make_data_assembly.py’:No such file or directory
sudo apt-get install python
[OHOS ERROR] FileNotFoundError: [Errno 2] No such file or directory: ‘java’
apt install openjdk-11-jre-headless # version 11.0.15+10-0ubuntu0.20.04.1, or
apt install default-jre # version 2:1.11-72
apt install openjdk-13-jre-headless # version 13.0.7+5-0ubuntu1~20.04
apt install openjdk-16-jre-headless # version 16.0.1+9-1~20.04
apt install openjdk-17-jre-headless # version 17.0.3+7-0ubuntu0.20.04.1
apt install openjdk-8-jre-headless # version 8u312-b07-0ubuntu1~20.04
[OHOS ERROR] packages/phone/make-boot.sh: line 22: genext2fs: command not found
sudo apt install genext2fs
ValueError: invalid literal for int() with base 10: '\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x0
Set cache size limit to 100.0 GB
rm -rf out
[OHOS ERROR] ETS:ERROR File: /
rm -rf out
[OHOS ERROR] ninja: error: loading ‘build.ninja’: No such file or directory(非本人尝试)
apt-get install ninja-build
[OHOS INFO]ERROR at //foundation/multimedia/av_session/test/fuzztest/BUILD.gn:31:1: Invalid token.
[OHOS INFO] “avcontrollercallbackproxy_fuzzer:AVControllerCallbackProxyFuzzTest”,
[OHOS INFO] ^
[OHOS INFO] You got a tab character in here. Tabs are evil. Convert to spaces.
删除"avcontrollercallbackproxy_fuzzer:AVControllerCallbackProxyFuzzTest",前的tab,用空格替换
[OHOS ERROR] [34653/36849] CX obj/foundation/arkui/ace_engine/adapter/ohos/entrance/ace_ohos_standard_entrance/ ace_container.o
[OHOS ERROR] FAILED: obj/foundation/arkui/ace_engine/adapter/ohos/entrance/ace_ohos standard_entrance/ace container.o
内存给16G
[OHOS WARNING] Failed to find ccache, ccache disabled.
sudo apt-get install ccache
[OHOS ERROR] [4860/40593] ACTION //developtools/packing_tool:packing_tool(//build/toolchain/oho s:ohos_clang_arm64)
[OHOS ERROR] FAILED: obj/developtools/packing_tool/jar/haptobin_tool.jar obj/developtools/packi ng_tool/jar/app_unpacking_tool.jar obj/developtools/packing_tool/jar/app_packing_tool.jar obj/d eveloptools/packing_tool/jar
[OHOS ERROR] /usr/bin/env …/…/developtools/packing_tool/build.py --haptobin …/…/developtool s/packing_tool/adapter/ohos --haptobinOutput obj/developtools/packing_tool/jar/haptobin_tool.ja r --unpackOutput obj/developtools/packing_tool/jar/app_unpacking_tool.jar --packOutput obj/deve loptools/packing_tool/jar/app_packing_tool.jar --outpath obj/developtools/packing_tool/jar
[OHOS ERROR] obj/developtools/packing_tool/jar/haptobin_tool.jar
[OHOS ERROR] obj/developtools/packing_tool/jar/app_unpacking_tool.jar
[OHOS ERROR] obj/developtools/packing_tool/jar/app_packing_tool.jar
[OHOS ERROR] obj/developtools/packing_tool/jar
[OHOS ERROR] root_path is /home/si/openharmony64/master/developtools/packing_tool
[OHOS ERROR] obj/developtools/packing_tool/jar/haptobin_tool.jar
[OHOS ERROR] obj/developtools/packing_tool/jar
[OHOS ERROR] /home/si/openharmony64/master/out/rk3568
[OHOS ERROR] /home/si/openharmony64/master/out/rk3568/obj/developtools/packing_tool/jar exist
[OHOS ERROR] /home/si/openharmony64/master/developtools/packing_tool/META-INF/packingbin_tool/M ANIFEST.MF
[OHOS ERROR]
[OHOS ERROR] /home/si/openharmony64/master/developtools/packing_tool/haptobin.sh: line 66: java c: command not found
[OHOS ERROR]
[OHOS ERROR] Traceback (most recent call last):
[OHOS ERROR] File “/home/si/openharmony64/master/out/rk3568/…/…/developtools/packing_tool/b uild.py”, line 83, in
[OHOS ERROR] sys.exit(main())
[OHOS ERROR] File “/home/si/openharmony64/master/out/rk3568/…/…/developtools/packing_tool/b uild.py”, line 50, in main
[OHOS ERROR] raise Exception(“compile haptobin java class failed!”)
[OHOS ERROR] Exception: compile haptobin java class failed!
[OHOS INFO] ---------------------------------------------
sudo apt-get update
sudo apt install default-jdk
av_session单编
[OHOS ERROR] ninja: error: unknown target ‘multimedia_av_session’
1.修改板级配置,添加avsession部件:
进入vendor/hihope/rk3568目录下,修改config.json文件,添加如下内容,其中+号标记的行为要添加的内容,添加时不要包含+号
{"component": "multimedia_media_library_standard","features": []+ },
+ {
+ "component": "multimedia_av_session",
+ "features": []}]
},
2.打开developtools/syscap_codec/include/syscap_define.h文件,相应位置添加(非必要配置)
MULTIMEDIA_AVSESSION,
{"SystemCapability.Multimedia.AVSession", MULTIMEDIA_AVSESSION},
[OHOS ERROR] [23/89] CXX obj/foundation/multimedia/av_session/frameworks/innerkitsimpl/native/session/src/avsession_client/avsession_callback_client.o
[OHOS ERROR] FAILED: obj/foundation/multimedia/av_session/frameworks/innerkitsimpl/native/session/src/avsession_client/avsession_callback_client.o [OHOS ERROR] In file included from …/…/foundation/multimedia/av_session/frameworks/innerkitsimpl/native/session/src/avsession_callback_client.cpp:16:
[OHOS ERROR] In file included from …/…/foundation/multimedia/av_session/frameworks/innerkitsimpl/native/session/include/avsession_callback_client.h:19:
[OHOS ERROR] In file included from …/…/foundation/multimedia/av_session/services/session/ipc/include/avsession_callback_stub.h:19:
[OHOS ERROR] In file included from …/…/foundation/multimedia/av_session/services/session/ipc/include/iavsession_callback.h:19:
[OHOS ERROR] In file included from …/…/foundation/multimedia/av_session/interfaces/innerkits/native/session/include/avsession_info.h:20:
[OHOS ERROR] …/…/foundation/multimedia/av_session/interfaces/innerkits/native/session/include/avmeta_data.h:162:9: warning: array designators are a C99 extension [-Wc99-designator]
[OHOS ERROR] [META_KEY_ASSET_ID] = &AVMetaData::CloneAssetId,
[OHOS ERROR] ^~~~~~~~~~~~~~~~~~~
[OHOS ERROR] In file included from …/…/foundation/multimedia/av_session/frameworks/innerkitsimpl/native/session/src/avsession_callback_client.cpp:16:
[OHOS ERROR] In file included from …/…/foundation/multimedia/av_session/frameworks/innerkitsimpl/native/session/include/avsession_callback_client.h:19:
[OHOS ERROR] …/…/foundation/multimedia/av_session/services/session/ipc/include/avsession_callback_stub.h:43:9: warning: array designators are a C99 extension [-Wc99-designator]
[OHOS ERROR] [SESSION_CALLBACK_ON_PLAY] = &AVSessionCallbackStub::HandleOnPlay,
[OHOS ERROR] ^~~~~~~~~~~~~~~~~~~~~~~~~~
[OHOS ERROR] In file included from …/…/foundation/multimedia/av_session/frameworks/innerkitsimpl/native/session/src/avsession_callback_client.cpp:17:
[OHOS ERROR] …/…/foundation/multimedia/av_session/utils/avsession_trace.h:19:10: fatal error: ‘hitrace_meter/hitrace_meter.h’ file not found
[OHOS ERROR] #include “hitrace_meter/hitrace_meter.h”
[OHOS ERROR] ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
在av_session/utils/include目录下 vim avsession_trace.h
删除所有头文件和函数体内容在av_session/frameworks/kitsimpl/js/session目录下 vim BUILD.gn
删除sources里面的所有内容
[OHOS INFO] ERROR at //out/rk3568/build_configs/multimedia/multimedia_av_session/BUILD.gn:45:5: Unable to load “/home/si/openharmony/foundation/multimedia/av_session/frameworks/innerkitsimpl/native/session/test/fuzztest/BUILD.gn”.
[OHOS INFO] “//foundation/multimedia/av_session/frameworks/innerkitsimpl/native/session/test/fuzztest:fuzztest”,
[OHOS INFO] ^--------------------------------------------------------------------------------------------------
找不到BUILD.gn文件
[OHOS INFO] ERROR Unresolved dependencies.
[OHOS INFO] //out/rk3568/build_configs/multimedia/multimedia_av_session:multimedia_av_session_test(//build/toolchain/ohos:ohos_clang_arm)
[OHOS INFO] needs //foundation/multimedia/av_session/services/session/server/test:fuzztest(//build/toolchain/ohos:ohos_clang_arm)
路径错误,修改为//foundation/multimedia/av_session/services/session/server/test/fuzztest:fuzztest
[OHOS ERROR] Traceback (most recent call last):
[OHOS ERROR] File “/home/si/openharmony/build/lite/hb/main.py”, line 87, in main
[OHOS ERROR] status = args.command(args)
[OHOS ERROR] File “/home/si/openharmony/build/lite/hb_internal/build/build.py”, line 130, in exec_command
[OHOS ERROR] set_product(product_name=product, company=company)
[OHOS ERROR] File “/home/si/openharmony/build/lite/hb_internal/set/set.py”, line 66, in set_product
[OHOS ERROR] product_info = Product.get_product_info(product_name, company)
[OHOS ERROR] File “/home/si/openharmony/build/lite/hb_internal/common/product.py”, line 176, in get_product_info
[OHOS ERROR] for product_info in Product.get_products():
[OHOS ERROR] File “/home/si/openharmony/build/lite/hb_internal/common/product.py”, line 42, in get_products
[OHOS ERROR] info = read_json_file(config_path)
[OHOS ERROR] File “/home/si/openharmony/build/lite/hb_internal/common/utils.py”, line 55, in read_json_file
[OHOS ERROR] data = json.load(input_f)
[OHOS ERROR] File “/home/si/openharmony/prebuilts/python/linux-x86/3.9.2/lib/python3.9/json/init.py”, line 293, in load
[OHOS ERROR] return loads(fp.read(),
[OHOS ERROR] File “/home/si/openharmony/prebuilts/python/linux-x86/3.9.2/lib/python3.9/json/init.py”, line 346, in loads
[OHOS ERROR] return _default_decoder.decode(s)
[OHOS ERROR] File “/home/si/openharmony/prebuilts/python/linux-x86/3.9.2/lib/python3.9/json/decoder.py”, line 337, in decode
[OHOS ERROR] obj, end = self.raw_decode(s, idx=_w(s, 0).end())
[OHOS ERROR] File “/home/si/openharmony/prebuilts/python/linux-x86/3.9.2/lib/python3.9/json/decoder.py”, line 353, in raw_decode
[OHOS ERROR] obj, end = self.scan_once(s, idx)
[OHOS ERROR] json.decoder.JSONDecodeError: Expecting ‘,’ delimiter: line 71 column 5 (char 1541)
[OHOS ERROR] Unhandled error: Expecting ‘,’ delimiter: line 71 column 5 (char 1541)
config.json文件少了一个‘]’该括号;
[OHOS INFO] build configs generation is complete.
[OHOS INFO] ERROR at //build/templates/cxx/cxx.gni:517:7: Script returned non-zero exit code.
[OHOS INFO] exec_script(external_deps_script, arguments, “string”)
[OHOS INFO] ^----------
[OHOS INFO] Current dir: /home/si/openharmony/out/rk3568/
疑似config.json文件错误
PC预览动态库编译
[OHOS ERROR] [64/111] ACTION //foundation/arkui/ace_engine/frameworks/bridge/declarative_frontend:gen_obj_js_mock_system_plugin(//build/toolchain/mingw:mingw_x86_64)
[OHOS ERROR] FAILED: mingw_x86_64/obj/foundation/arkui/ace_engine/frameworks/bridge/declarative_frontend/js_mock_system_plugin.c
[OHOS ERROR] /usr/bin/env …/…/foundation/arkui/ace_engine/build/tools/build_resource_to_bytecode.py --objcopy /home/si/openharmony/prebuilts/gcc/linux-x86/host/x86_64-w64-mingw32-4.8/x86_64-w64-mingw32/bin/objcopy --input /home/si/openharmony/out/sdk/mingw_x86_64/obj/third_party/jsframework/dist/jsMockSystemPlugin.js --output /home/si/openharmony/out/sdk/mingw_x86_64/obj/foundation/arkui/ace_engine/frameworks/bridge/declarative_frontend/js_mock_system_plugin.c --arch x86_64
[OHOS ERROR] Traceback (most recent call last):
[OHOS ERROR] File “/home/si/openharmony/out/sdk/…/…/foundation/arkui/ace_engine/build/tools/build_resource_to_bytecode.py”, line 64, in
[OHOS ERROR] sys.exit(main())
[OHOS ERROR] File “/home/si/openharmony/out/sdk/…/…/foundation/arkui/ace_engine/build/tools/build_resource_to_bytecode.py”, line 60, in main
[OHOS ERROR] resource_file_to_bytecode(input_dir, input_file, output_path)
[OHOS ERROR] File “/home/si/openharmony/out/sdk/…/…/foundation/arkui/ace_engine/build/tools/build_resource_to_bytecode.py”, line 22, in resource_file_to_bytecode
[OHOS ERROR] with open(os.path.join(input_dir, input_file), ‘rb’)
[OHOS ERROR] FileNotFoundError: [Errno 2] No such file or directory: ‘/home/si/openharmony/out/sdk/mingw_x86_64/obj/third_party/jsframework/dist/jsMockSystemPlugin.js’
ohos_multimedia_av_session.js编写错误
[OHOS ERROR] warning: unknow warning option ‘-Wno-non-c-typedef-for-linkage’; did you mean ‘-Wno-return-type-c-linkage’? [-Wunknow-warning-option]
安装依赖包:
unix_time=`date '+%s'`;for one_tools in `curl -s -k https://gitee.com/landwind/openharmony_oneclick_env_init/raw/master/apt_install.list`;do echo "apt-get install -y ${one_tools}">>/tmp/openharmony_deps_${unix_time}.sh; done;
sudo apt-get update;
sudo bash -x /tmp/openharmony_deps_${unix_time}.sh
删除out:
rm -rf out
重置工作区,删除所有修改(记得备份你改的代码):
repo forall -c "pwd;git reset --hard; git clean -fd"
更新最新代码:
repo sync -c -j8;
repo forall -c "pwd;git lfs install;git lfs pull"
执行prebuilts下载脚本:
bash build/prebuilts_download.sh
benchmarktest编译
[OHOS ERROR] …/…/foundation/multimedia/av_session/frameworks/native/session/test/benchmarktest/avsession_test/avsession_test.cpp:42:45: error: expected function body after function declarator
[OHOS ERROR] void SetUp(const ::benchmark::State& state) override
[OHOS ERROR] ^
删掉override
[OHOS ERROR] …/…/foundation/multimedia/av_session/frameworks/native/session/test/benchmarktest/avsession_test/avsession_test.cpp:26:10: fatal error: ‘hilog_wrapper.h’ file not found
[OHOS ERROR] #include “hilog_wrapper.h”
删掉#include "hilog_wrapper.h"
[OHOS ERROR] …/…/foundation/multimedia/av_session/frameworks/native/session/test/benchmarktest/avsession_test/avsession_test.cpp:48:6: error: use of undeclared identifier ‘AvsessionTest’; did you mean ‘AVSessionTest’?
[OHOS ERROR] void AvsessionTest::SetUp(const ::benchmark::State& state)
[OHOS ERROR] ^~~~~~~~~~~~~
[OHOS ERROR] AVSessionTest
AvsessionTest改为AVSessionTest
[OHOS ERROR] …/…/foundation/multimedia/av_session/frameworks/native/session/test/benchmarktest/avsession_test/avsession_test.cpp:48:21: error: redefinition of ‘SetUp’
[OHOS ERROR] void AVSessionTest::SetUp(const ::benchmark::State& state)
[OHOS ERROR] ^
[OHOS ERROR] …/…/foundation/multimedia/av_session/frameworks/native/session/test/benchmarktest/avsession_test/avsession_test.cpp:80:9: error: unknown type name ‘ErrCode’; did you mean ‘OHOS::ErrCode’?
[OHOS ERROR] ErrCode errCode = (sessionId.length() == SESSION_LEN);
[OHOS ERROR] ^~~~~~~
[OHOS ERROR] OHOS::ErrCode
ErrCode前添加OHOS::
[OHOS ERROR] …/…/foundation/multimedia/av_session/frameworks/native/session/test/benchmarktest/avsession_test/avsession_test.cpp:46:21: error: reference to ‘AVSession’ is ambiguous
[OHOS ERROR] std::shared_ptr avsession_ = nullptr;
[OHOS ERROR] ^
命名空间冲突;删掉OHOS
[OHOS ERROR] …/…/foundation/multimedia/av_session/frameworks/native/session/test/benchmarktest/benchmark_avsession_test/benchmark_avsession_test.cpp:58:94: error: too few arguments to function call, expected 2, have 1
[OHOS ERROR] controller_ = AVSessionManager::GetInstance().CreateController(avsession_->GetSessionId());
[OHOS ERROR] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
缺少参数
[OHOS ERROR] json.decoder.JSONDecodeError: Expecting ‘,’ delimiter: line 64 column 5 (char 1407)
[OHOS ERROR] Unhandled error: Expecting ‘,’ delimiter: line 64 column 5 (char 1407)
/vendor/hihope/rk3568/config.json的第64行少了','
[OHOS INFO] See //foundation/multimedia/av_session/frameworks/native/session/test/benchmarktest/benchmark_avsession_test/BUILD.gn:19:1: whence it was called.
[OHOS INFO] ohos_benchmarktest(“BenchmarkTestAVSession”) {
[OHOS INFO] ^---------------------------------------------
[OHOS INFO] See //foundation/multimedia/av_session/frameworks/native/session/test/benchmarktest/BUILD.gn:21:5: which caused the file to be included.
[OHOS INFO] “benchmark_avsession_test:benchmarktest”,
[OHOS INFO] ^---------------------------------------
两个gn文件没用对应,应该把/benchmarktest/BUILD.gn里的benchmarktest改为BenchmarkTestAVSession
删掉/benchmarktest/benchmark_avsession_test/BUILD.gn里的group
[OHOS INFO] ERROR at //foundation/multimedia/av_session/frameworks/native/session/test/benchmarktest/BUILD.gn:17:3: Undefined identifier.
[OHOS INFO] deps += [
[OHOS INFO] ^—
[OHOS INFO] See //out/rk3568/build_configs/multimedia/multimedia_av_session/BUILD.gn:49:5: which caused the file to be included.
[OHOS INFO] “//foundation/multimedia/av_session/frameworks/native/session/test/benchmarktest:benchmarktest”,
[OHOS INFO] ^----------------------------------------------------------------------------------------------
/benchmarktest/BUILD.gn缺少deps = []
[OHOS INFO] ERROR at //build/templates/cxx/cxx.gni:221:7: Script returned non-zero exit code.
[OHOS INFO] exec_script(external_deps_script, arguments)
[OHOS INFO] ^----------
[OHOS INFO] Current dir: /home/si/openharmony/out/rk3568/
[OHOS INFO] Command: 。。。。。。。。。。。。。。。。。。。。。
[OHOS INFO] Returned 1 and printed out:
[OHOS INFO]
[OHOS INFO] The file ‘…/…/sdk/ohos-arm/samgr_standard/sdk_info.json’ format is incorrect.
[OHOS INFO] See //foundation/multimedia/av_session/frameworks/native/session/test/benchmarktest/avsession_controller_test/BUILD.gn:19:1: whence it was called.
[OHOS INFO] ohos_benchmarktest(“ControllerTest”) {
[OHOS INFO] ^-------------------------------------
[OHOS INFO] See //out/rk3568/build_configs/multimedia/multimedia_av_session/BUILD.gn:51:5: which caused the file to be included.
[OHOS INFO] “//foundation/multimedia/av_session/frameworks/native/session/test/benchmarktest/avsession_controller_test:benchmarktest”,
[OHOS INFO] ^------------------------------------------------------------------------------------------------------------------------
将gn文件里external_deps的"samgr_standard:samgr_proxy",
改为:"samgr:samgr_proxy",
signal 11
生成了部分用例,是内存泄漏导致:
换设备尝试成功;
原因可能是个别设备用例使用内存超出;
FUZZ编译错误
[OHOS ERROR] undefined symbol “OHOS::AVSession::Xxxx(xx,xx)”
1.所有函数名前加“OHOS::AVSession::”
2.把外层gn文件删掉,group加在里层gn文件
3.修改bundle.json文件
[OHOS ERROR] ld.lld: error: undefined symbol: CreatePendingPacket(unsigned int, unsigned long long)
cpp包含c语言的头文件需要加extern;extern "C"
{#include "xxx.h"
}
ut编译错误
[OHOS ERROR] ld.lld: error: undefined symbol: OHOS::AVSession::AVSessionControllerStub::OnRemoteRequest(unsigned int, OHOS::MessageParcel&, OHOS::MessageParcel&, OHOS::MessageOption&)
gn里deps加:
"//foundation/multimedia/av_session/services/session:avsession_service",注:搜索对象cpp文件,找有该cpp文件的gn文件,找到对应的依赖名字,搜索该依赖名字,查看其他地方如何写的该依赖路径
[OHOS ERROR] ld.lld: error: undefined symbol: VTT for AVSessionControllerStubTest
[OHOS ERROR] ld.lld: error: undefined symbol: vtable for AVSessionControllerStubTest
构造类的重写方法没有加作用域;
启动测试框架错误
无法连接:
1.板子没有连接好
2.cmd窗口执行hdc_std kill 再执行hdc_std shell
测试框架路径不能含有中文!!!
rk3568错误
卡在DAYU界面:
进入开机界面可以进入板子,试下这个命令,可能有用:
hdc shell
ps -ef |grep bootanimation
kill -11 //进程ID
或
在全量编译前执行:repo forall -c "git lfs pull"
或
用最新的代码尝试
git错误
git clone时fatal: unable to access ‘https://gitee.com/XXX.git/‘: The requested returned error: 403
控制面板->用户账户->管理Windows凭据->https://gitee.com(在普通凭据下)->编辑(修改为待使用的用户名与密码)
提PR代码质量检测失败
G.INC.09 按照合理的顺序包含头文件【c】
G.INC.04 禁止包含用不到的头文件【c】
#include "avsessionpixelmap_fuzzer.h"
#include "avsession_pixel_map.h"
#include "parcel.h"
修改为
#include "avsessionpixelmap_fuzzer.h"//该cpp文件的头文件与其他头文件空一行
#include "avsession_pixel_map.h"
#include "parcel.h"
测试错误分析问题Crash
hdc_std shell
cd /data/log/faultlog/temp拉取出cppcrash文件:
hdc_std file recv /data/local/tmp/cppcrash... D:\
利用分析工具分析问题:
在PraseCrashTool\cppcrash...工具下cmd;输入命令:
python main.py D:\...(待分析文件路径)
打开分析出的结果,在linux中:
找到错误模块的路径
out\exe.xxx\benchamrk\xxxxadd2line -C -e ControllerTest -f 000000000d8ec根据报错的行数找问题;
OpenHarmony更新编译问题及解决办法相关推荐
- ionic 安装 inappbrowser 插件后编译失败的解决办法
layout: post title: ionic 安装 inappbrowser 插件后编译失败的解决办法 tags: description: 学习使用 ionic 框架开发 ios app 时遇 ...
- IDEA jjsp 404_IDEA 卡住buid(编译)不动的解决办法_java
这篇文章主要介绍了IDEA 卡住buid(编译)不动的解决办法(适用于maven和gradle)及定位思路,本文给大家介绍的非常详细,对大家的学习或工作具有一定的参考借鉴价值,需要的朋友可以参考下 [ ...
- Impala编译错误及解决办法汇总
Impala编译错误及解决办法汇总 Impala repo里有C++.Java.Python.Bash的代码,编译过程中可能遇到各种问题.这个文章将作为一个汇总,以后每遇到一个编译问题,解决完后都会更 ...
- C#使用ListView更新数据出现闪烁解决办法
C#使用ListView更新数据出现闪烁解决办法 在使用vs自动控件ListView控件时候,更新里面的部分代码时候出现闪烁的情况 如图: 解决以后: 解决办法使用双缓冲:添加新类继承ListView ...
- 安卓手机更新过程手机乱码_王者荣耀安卓更新更新时出现乱码解决办法
王者荣耀1月14日进行版本大更新了,一般情况下大版本更新容易出问题的是苹果,但这次反过来是安卓,包括更新卡在45%.资源包升级失败.解析包出现问题等情况,这些都如何解决呢?小编马上就给大家分享一下解决 ...
- steam游戏一直连接服务器,steam无法连接到更新服务器快速有效解决办法
<steam>是玩家们使用较多的一个游戏平台,部分玩家启动过程中会出现无法连接的情况,于是就会发出steam无法连接到更新服务器怎么办的疑问.下面为大家带来的是steam无法连接到更新服务 ...
- EPIC客户端 “在我们启动更新时请稍后”解决办法
EPIC客户端 "在我们启动更新时请稍后"解决办法 已经尝试的方法:使用各种 加速器 标题解决问题的方法: 实例:
- Keil MDK 工程输入中文汉字编译报错解决办法
Keil MDK 工程输入中文汉字编译报错解决办法 官方说明:https://www.keil.com/support/man/docs/armcc/armcc_chr1359124934197.ht ...
- 说说百度快照不更新的原因及解决办法
百度快照是什么?有什么用呢?快照是指搜索引擎蜘蛛抓取后在其数据库内建立的备份,这样做的好处是为了当你的网站打不开时,用户可以通过快照来查看网站内容.下面合肥seo我们看网站快照时间的位置. 今天讲解关 ...
- Linux微信运行错误,Ubuntu 16.04 运行微信开发者工具编译出错的解决办法
最近有折腾小程序的意向,但微信的开发者工具只提供了 Windows 和 Mac 两个版本,对于我这样的 Linux 用户来说不是那么地友好. 经过观察发现,那个开发者工具实际上是基于nw.js开发的, ...
最新文章
- 软件工程实践第一次作业
- 推荐Scum敏捷开发的几款工具
- 如何读取jar包外的properties和log4j.properties等配置文件
- java进入下一个_在进入下一个循环迭代之前执行setTImeout操作
- 【IMPDP】当导入数据时遭遇表已存时的应对手段——TABLE_EXISTS_ACTION参数
- JDK 16 即将发布,迎来重大改变,新特性速览!
- SQL Server 2005 SP2发布了,开发人员怎么办?
- 【网易MCTalk】除了低价促销、丰富品类,电商就没有新玩法了?
- php电子商务模板,关于php:电商系统设计之运费模板下
- 性价比不高却出到8?华为存在感最低的一个系列再发新机
- 兴业银行实时跨行转入功能、免除手续费及网点排队
- 哈希(1) hash的基本知识回顾
- GFlags使用总结
- MicroExpSTCNN and MicroExpFuseNet-基于三维时空卷积神经网络的自发面部微表情识别
- php 错误503的原因,CentOS + Apache2.4 + PHP5.6 FPM报503错误
- gb2312的6763个汉字
- Hadoop分布式集群
- python --windos系统托盘
- c语言随机生成四则运算10道,c语言编10道四则运算题
- Nginx的配置及原理
热门文章
- 杂谈---一个项目经理的自我反省
- ssm毕设项目小型超市货物仓储管理系统w8wry(java+VUE+Mybatis+Maven+Mysql+sprnig)
- The simplest way to combine two csv file in python
- dns劫持教您dns被劫持如何修复、dns劫持如何修复
- ML之SHAP:机器学习可解释性之SHAP值的高级使用之聚合SHAP值以获得更详细的模型见解
- 2008年最后的感动
- 《计算机工程》投稿过程
- linux上删除rime方案_Linux中Rime输入法安装使用小结
- 1428D - Bouncing Boomerangs(思维+构造+贪心)
- 一个好用的剪切板复制粘贴工具