From 0edcc4084e34d47eb4e0f853955d4b394f60fa31 Mon Sep 17 00:00:00 2001 From: jhe Date: Sat, 5 Aug 2023 00:57:09 +0800 Subject: [PATCH] update README.md --- README.md | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) diff --git a/README.md b/README.md index 95ddf0d..b17fe52 100644 --- a/README.md +++ b/README.md @@ -2,3 +2,46 @@ #### 介绍 支持构建出ArkCompiler相关二进制以及SDK,用于ArkTS代码执行。 + + +https://gitee.com/openharmony/docs/blob/master/zh-cn/device-dev/subsystems/subsys-arkcompiler-guide.md + + +#install dependencies +sudo apt-get update && sudo apt-get install python ruby python3-pip git-lfs gcc-multilib g++-multilib zlib1g-dev libc++1 curl nodejs + + +#install repo by gitee +mkdir ~/bin/ +curl https://gitee.com/oschina/repo/raw/fork_flow/repo-py3 > ~/bin/repo +chmod a+x ~/bin/repo +export PATH=~/bin:$PATH +pip3 install -i https://pypi.tuna.tsinghua.edu.cn/simple requests + +#download source +repo init -u https://gitee.com/ark-standalone-build/manifest.git -b master +repo sync -c -j8 +repo forall -c 'git lfs pull' + +#download llvm and other needed bin utils +/prebuilts_download.sh + +#revert to enable ts2panda building +1, revert toolchain/build/core/gn/BUILD.gn +2, revert toolchain/prebuilts_download.py and prebuilts_download_config.json +3, add toolchain/third_party_jsoncpp/BUILD.gn + +#building +python ark.py x64.release + +#compile ts to abc +out/x64.release/arkcompiler/ets_frontend/es2abc helloworld.ts + +#interpreter +out/x64.release/arkcompiler/ets_runtime/ark_js_vm helloworld.abc + +#test262 +python ark.py x64.release test262 + +#ts2panda +node --expose-gc /your_code_path/out/rk3568/clang_x64/arkcompiler/ets_frontend/build/src/index.js -m --merge-abc test1/test.ts -- Gitee