diff --git a/README.md b/README.md index cb979bec3812735effeffcc915a6c07947b37f27..02a96842003947f41071681176fd128a36d941da 100644 --- a/README.md +++ b/README.md @@ -16,247 +16,7 @@ You can choose a code repository for development according to your own preferenc ## Status -Following is the project progress log (time in reverse order). - -- 2022-03-30 Status update - - - Sync aosp-riscv to RVI upstream: - - [improve vfork](https://github.com/riscv-android-src/platform-bionic/pull/19) - - Sync aosp-riscv from RVI upstream: - - N/A - - aosp-riscv development and bugfix: - - [New TARGET_PRODUCT sdk_phone_riscv64 with 64bit Support Only](https://gitee.com/aosp-riscv/platform_build/pulls/3) - - [changed device/generic/goldfish to aosp-riscv](https://gitee.com/aosp-riscv/platform_manifest/pulls/13) - - [pass build with m --skip-ninja for sdk_phone_riscv64-eng](https://gitee.com/aosp-riscv/device-generic-goldfish/pulls/1) - - [sudo is not required for make_rootfs.sh](https://gitee.com/aosp-riscv/test-riscv/pulls/15) - - [added prebuilt gdb](https://gitee.com/aosp-riscv/test-riscv/pulls/16) - - [use gdb built for 18.04](https://gitee.com/aosp-riscv/test-riscv/pulls/17) - - Technical articles related: - - [added doc to introduce howto build emu](https://gitee.com/aosp-riscv/working-group/pulls/22) - - [Add rust toolchain build instructions](https://gitee.com/aosp-riscv/working-group/pulls/23) - -- 2022-03-16 Status update - - - Sync aosp-riscv to RVI upstream: - - [squash and remove duplicated codes](https://github.com/riscv-android-src/platform-bionic/pull/17) - - [minor bugfixes in fenv](https://github.com/riscv-android-src/platform-bionic/pull/18) - - Sync aosp-riscv from RVI upstream: - - [riscv64: fix fenv handling](https://github.com/aosp-riscv/platform_bionic/pull/5) - - aosp-riscv development and bugfix: - - [libm/riscv64: minor bugfixes in fenv](https://github.com/aosp-riscv/platform_bionic/pull/7) - - [add argument check for fesetround()](https://gitee.com/aosp-riscv/platform_bionic/pulls/18) - - [fixed doc link issue](https://gitee.com/aosp-riscv/test-riscv/pulls/13) - - [fixed issue when run bionic host test](https://gitee.com/aosp-riscv/test-riscv/pulls/14) - - [PR for Feature "setup golang develop/debug env for soong"](https://gitee.com/aosp-riscv/working-group/pulls/17) - - [[RISCV] Pass -mno-relax to assembler when -fno-integrated-as specified](https://reviews.llvm.org/D120639) - - [[RISCV] Generate correct ELF EFlags when .ll file has target-abi attribute](https://reviews.llvm.org/D121183) - - Technical articles related: - - [20220226-case-prebuilt-elf-files.md](https://github.com/aosp-riscv/working-group/pull/38) - - [add doc to introduce how to add entry in lunch](https://gitee.com/aosp-riscv/working-group/pulls/20) - - [add code version for doc](https://gitee.com/aosp-riscv/working-group/pulls/19) - -- 2022-03-03 Status update - - - Sync aosp-riscv to RVI upstream: - - [upgrade kernel uapi to 5.12](https://github.com/riscv-android-src/platform-bionic/pull/14) - - [clean-up some minor faults](https://github.com/riscv-android-src/platform-bionic/pull/15) - - [fix android unsafe frame pointer chase](https://github.com/riscv-android-src/platform-bionic/pull/16) - - [some cleanup and restore](https://github.com/riscv-android-src/platform-build-soong/pull/3) - - Sync aosp-riscv from RVI upstream: - - [sync with RVI upsteam: pr#14](https://gitee.com/aosp-riscv/platform_bionic/pulls/15) - - [sync from RVI upstream: linker_wrapper](https://gitee.com/aosp-riscv/platform_bionic/pulls/16) - - [removed FIXME](https://gitee.com/aosp-riscv/platform_bionic/pulls/17) - - [sync from RVI upstream, removed duplicated cflags](https://gitee.com/aosp-riscv/platform_build_soong/pulls/4) - - [fixed format issue](https://gitee.com/aosp-riscv/platform_build_soong/pulls/5) - - [RVI upstream sync, removed FIXME](https://gitee.com/aosp-riscv/platform_build_soong/pulls/6) - - aosp-riscv development and bugfix: - - [updated bionic unit test on host](https://gitee.com/aosp-riscv/test-riscv/pulls/11) - - [optimize the test scripts](https://gitee.com/aosp-riscv/test-riscv/pulls/12) - - [Enable create_minidebuginfo](https://github.com/aosp-riscv/platform_build_soong/pull/2) - - [Updated dependencies needed by create_minidebuginfo (Relocated)](https://github.com/aosp-riscv/platform_art/pull/2) - - [linux-x86/bin/create_minidebuginfo supports riscv64](https://gitee.com/aosp-riscv/platform-prebuilts-build-tools/pulls/1) - - Technical articles related: - - [status updated on Feb/17/2022](https://gitee.com/aosp-riscv/working-group/pulls/14) - - [added template for articles](https://gitee.com/aosp-riscv/working-group/pulls/15) - -- 2022-02-17 Status update - - - Setup bionic dynamic-link unit test and bugfix: - - [support dynamic link tests](https://gitee.com/aosp-riscv/test-riscv/pulls/6) - - [updated doc about test](https://gitee.com/aosp-riscv/test-riscv/pulls/7) - - [added search path for libicu.so](https://gitee.com/aosp-riscv/test-riscv/pulls/8) - - [added 2.log for bionic dynamic link test](https://gitee.com/aosp-riscv/test-riscv/pulls/9) - - [added 4.log for bionic static test](https://gitee.com/aosp-riscv/test-riscv/pulls/10) - - Sync aosp-riscv from RVI upstream: - - [define REG_* for ucontext](https://gitee.com/aosp-riscv/platform_bionic/pulls/12) - - [asm header files](https://gitee.com/aosp-riscv/platform_bionic/pulls/13) - - [unify rv64 pre-processor definition](https://gitee.com/aosp-riscv/platform_bionic/pulls/14) - - Sync aosp-riscv to RVI upstream: - - [added stack overflow reserved bytes for rv64](https://github.com/riscv-android-src/platform-art/pull/2) - - [removed duplicated asm riscv header file](https://github.com/riscv-android-src/platform-bionic/pull/8) - - [unify rv64 preprocessor definition](https://github.com/riscv-android-src/platform-bionic/pull/13) - - [upgrade kernel uapi to 5.12](https://github.com/riscv-android-src/platform-bionic/pull/14) in reviewing - -- 2022-01-20 Status update - - Bionic static unit test and bugfix: - - [fix TLS issues](https://gitee.com/aosp-riscv/platform_bionic/pulls/5) - - [change TLS slot organization same as that for arm](https://gitee.com/aosp-riscv/platform_bionic/pulls/6) - - [fixed vfork](https://gitee.com/aosp-riscv/platform_bionic/pulls/7) - - [continue vfork](https://gitee.com/aosp-riscv/platform_bionic/pulls/8) - - [fixed memset infinite loop issue](https://gitee.com/aosp-riscv/platform_bionic/pulls/10) - - [some changes for test env](https://gitee.com/aosp-riscv/test-riscv/pulls/3) - - [run test with isolate mode](https://gitee.com/aosp-riscv/test-riscv/pulls/4) - - [enabled some blocking cases](https://gitee.com/aosp-riscv/test-riscv/pulls/5) - - [minor changes and ready for upstream](https://gitee.com/aosp-riscv/platform_bionic/pulls/9) - - [code format improvement](https://gitee.com/aosp-riscv/platform_bionic/pulls/11) - - [minor fix and ready for upstream](https://gitee.com/aosp-riscv/platform_build/pulls/2) - - [minor fix and ready for upstream](https://gitee.com/aosp-riscv/platform_build_soong/pulls/3) - - Article/Document update: - - [continue update android kernel related knowledge](https://gitee.com/aosp-riscv/working-group/pulls/10) - - [updated article: platform-version](https://gitee.com/aosp-riscv/working-group/pulls/11) - - [add how to build clang for aosp](https://gitee.com/aosp-riscv/working-group/pulls/12) - - RVI aosp 12 upstream work: - - [RISC-V Android 12 Source code repo in github, Jan/17/2022](https://lists.riscv.org/g/sig-android/message/32), - - [removed old seccomp txt files](https://github.com/riscv-android-src/platform-bionic/pull/3) - - [bugfix: enable rela ifunc resolver for riscv64](https://github.com/riscv-android-src/platform-bionic/pull/4) - - [format code style](https://github.com/riscv-android-src/platform-bionic/pull/6) - -- 2021-12-23 Status update - - Build a minimal system, run AOSP's bionic-unit-test-static on QEMU, and solve the bugs found in the test. - - malloc.malloc_info: SIGABRT: - - part of stdio cases FAILED due to can not create tmpfiles: - - Fixed wrong mdev path issue: - - ifunc.*:Segmentation fault: ; also raise PR to upstream: - - added bionic-unit-tests-static log: - - Added doc on how-to setup test env: - - Participate in OSDTConf2021 and present a report about AOSP for RISC-V community open source progress - - report slides: - - report vedio: - -- 2021-12-10: Bionic has been successfully compiled, and integration tests are being run using the gtest suite provided by Google. - - Clang toolchain: added libFuzzer - - - - - - - - Enable soong tests during building: - - - - - - Move some patches to git: - - - - - - - - - - - - - - - - Pass build with "mmm bionic": - - - - - - - - - - - - - - - - - - - - Added test repo: - - - -- 2021-11-30 For AOSP 12 ported to RV64, the implementation of `mmm bionic/libc/ --skip-soong-tests` was successfully built, we now have libc/libm/libdl. The relevant changes have been submitted to the repositories. The details are as follows (here, some PRs are created on gitee, all commits are pushed both on github & gitee): - - toolchain for AOSP: - - Rust for Android: - - compiler: add riscv64gc-linux-android target (Tier 3): - - library: add riscv64gc-linux-android support: - - Modified libc, added support for riscv64: - - Clang/llvm for Android: - - add riscv __get_tls method: - - Change some repos' fetch address and revision to support riscv64: - - manifest:PR: - - AOSP (PRs): - - - - - - - - - - - - - -- 2021-11-15 For AOSP 12 ported to RV64, the implementation of `m --skip-ninja --skip-soong-tests` was successfully built. The relevant changes have been submitted to the repositories. The details are as follows (here, gitee is taken as an example, github has been mirrored): - - manifest repository: - - Newly added AOSP repositories: - - art/ : - - bionic/: - - build/make/: - - build/soong/: - - external/crosvm/: - - frameworks/av/: - - packages/modules/NeuralNetworks/: - - prebuilts/vndk/v28/: - - prebuilts/vndk/v29/: - - prebuilts/vndk/v30/: - - system/apex/: - - system/core/: - - system/iorap/: - - system/nvram/: - - In addition, some repositories are currently unable to be created on gitee/github because the overall volume or some files are too large and exceed the limitaiton required by gitee/github. Therefore, we currently use patching method to save the changes, and below are these repositories involved: - - cts/ - - frameworks/base/ - - packages/modules/ArtPrebuilt/ - - packages/services/Car/ - - prebuilts/clang/host/linux-x86/ - - prebuilts/runtime/ - The newly built patch repository is: - - The list of PRs submitted is as follows: - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Updated tech article [“Howto build aosp-riscv” ](./articles/20211029-howto-setup-build-env.md) - - Newed tech article ["Code analysis for soong_ui"](./articles/20211102-codeanalysis-soong_ui.md) - -- 2021-10-29 Restart the AOSP migration work of PLCT lab. The new goal is to migrate AOSP 12 to RV64. - - Setup group @ (mirrored with ) with some initial repos. - - [PR Merged] added note on howto setup build env: - - Newed tech article ["Code analysis for envsetup"](./articles/20211026-lunch.md) - - Newed tech article ["Howto setup build environment"](./articles/20211029-howto-setup-build-env.md) - -- 2021-01-xx Due to [open-source work](https://github.com/T-head-Semi/aosp-riscv) from T-Head(alibaba), we (PLCT lab) stopped the AOSP porting work in early 2021. All code repositories (except working-group) under the original and are backed up to [Gitee's aosp-riscv-bionic-porting](https://gitee.com/aosp-riscv-bionic-porting). - -- 2021-01-15 Still in investigating how to add RVG64 support based on the Soong framework of AOSP. The main difficulty at present is: due to the AOSP compilation system is extremely large and complex, contains too much content required for engineering, and is intertwined and dependent on each other, so how to cleanly mask the modules that we don’t care about first and only compile those core content of the bionic library is the current focus and difficulty. There is not much clue yet, anyone is welcomed to provide help and suggestions. - -- 2020-12-29 Completed the porting of dynamic linking feature for bionic, we can now support implicit dynamic link and explicit dynamic link with bionic. The make framework system is also improved. For specific changes, please refer to the `develop` branch of the bionic transplantation main repository, . The next step is to port and modify AOSP's Soong construction system and use AOSP Soong construction system to compile the bionic library and related applications for RISC-V. - -- 2020-12-15 - - Started to port the dynamic link functionality for bionic. Currently, the compilation and linking of `libc.so` and `linker` have been completed, but still can not work well. We are still under debugging. Anybody familiar with the dynamic linker are welcomed to provide your suggestions. For specific changes, please refer to the `develop` branch of the bionic transplantation main repository, , and its corresponding submodule repository. - - The focus of further work is still to achieve dynamic link support, and the current implementation flaws are felt to be larger than static links. In addition, we will continue to improve the bionic function and try to transplant the Soong construction system of AOSP, and support the use of AOSP Soong construction system to compile the bionic library and related applications for RISC-V. - -- 2020-11-30 Completed the porting of shell and init. Currently, the bionic libc.a library can work, and a minimal Android root file system can be generated by statically linking against it. The rootfs can be launched and run on qemu-system-riscv64 and supports running some basic operation commands. In addition, the original make framework system has been improved to prepare for the next stage to further support dynamic linking. For specific changes, please refer to the `develop` branch of the bionic transplantation main repository, , and its corresponding submodule repository. For more detailed introduction, please refer to another introduction article: ["Create a minimal Android system for RISC-V"] (https://plctlab.github.io/aosp/create-a-minimal-android-system-for-riscv.html). The next step is to improve the dynamic linking support, continue to improve the bionic function and try to transplant the Soong construction system of AOSP, and support the use of the Soong construction system of AOSP to compile the bionic library and related applications for RISC-V. - -- 2020-11-13 Further improve the libc static library of bionic. Currently using v10.0.1 llvm/clang to compile, and using the GNU RISC-V version of ld based on bionic's libc_static, crtbegin_static and crtend.o to achieve static linking and executable program generation. On this basis, we transplanted and compiled the toybox that comes with AOSP and made a minimal rootfs (shell and init still use busybox compiled for glibc). At present, the rootfs can be started and run on qemu-system-riscv64. You can run some commands, but some commands will report errors when executed. For specific changes, please refer to the commit comment of the `develop` branch of the bionic porting main repository, , and the commit comments of the `develop` branch of its submodule repositories. The next step will be to continue to improve the libc of bionic and the self-made minimal root file system. - -- 2020-10-30 The make framework has been improved to support the compilation and generation of libc static libraries, as well as `crtbegin.o` and `crtend.o`. Currently, the statically compiled executable program can jump from the kernel to the main function and ensure that `argv` and `envp` are read correctly. The porting of other TLS and syscall parts is still ongoing. For specific changes, please refer to the `develop` branch of . - -- 2020-10-16 Simplify the build framework of the AOSP bionic library to make, and submit the preliminary porting work to the develop branch of . Currently, the project repository depends on two sub-repositories: and (Because the changes are still drafts, the current changes to AOSP are all placed on their respective `develop` branches. Another note: the current porting work is based off `android-10.0.0_r39` tag version based on AOSP). The next step is to continue to improve the make project and make changes to the bionic code. The first goal is to implement `libc.a`. - -- 2020-10-01 Using the latest AOSP kernel and configuration, with GNU and LLVM/Clang tool-chain for RISC-V, we successfully compiled and booted the kernel on QEMU. The only problem is: after mounting the minimum rootfs, we encounter a "Segmentation Fault" error. Still debugging this issue. In addition, we began to study how to port the bionic library of AOSP to RISC-V. The current work is to port the AOSP building framework for bionic. - -- 2020-09-15 We launched the task to port the AOSP kernel to RISC-V. After some research, we decided to base it off the branch `android-5.4-stable` of AOSP common kernels and we are working on it now. - -- 2020-09-01 We fixed the errors in build dir and prebuilts dir when using the 'mmm art/compiler' to generate the ninja files for the compiler module. We are debugging the errors in the system dir and cts dir. - -- 2020-08-15 We have added the lunch menu for RISC-V, and successfully loaded the menu. After that, we added the RISC-V config files for build/make and build/soong, We are debugging the RISC-V config files in build/soong. +Please read [project logging](./status.md). ## About Us @@ -268,6 +28,7 @@ We would like to contribute all of the efforts to the RISC-V community and the A ## Join Us If you want to contribute, please read the contribution guide on the AOSP website. +Or contact Chen Wang ([@unicornx](https://github.com/unicornx)) Feel free to open an issue for further questions/discussions! diff --git a/README_zh.md b/README_zh.md index d8fbac4aa682fc92d62b78dbf8d393f78c2bccf8..c07a71b3812a7357a8174b8f109ab946a7a71095 100644 --- a/README_zh.md +++ b/README_zh.md @@ -16,234 +16,7 @@ AOSP-RISCV 的代码开源,欢迎大家参与贡献。所有仓库在 Github ## 项目状态 -以下为项目进展日志(时间为倒序)。 - -- 2022-03-30 状态更新 - 不再维护中文版,请统一访问 [英文版](./README.md) - -- 2022-03-16 状态更新 - - - Sync aosp-riscv to RVI upstream: - - [squash and remove duplicated codes](https://github.com/riscv-android-src/platform-bionic/pull/17) - - [minor bugfixes in fenv](https://github.com/riscv-android-src/platform-bionic/pull/18) - - Sync aosp-riscv from RVI upstream: - - [riscv64: fix fenv handling](https://github.com/aosp-riscv/platform_bionic/pull/5) - - aosp-riscv development and bugfix: - - [libm/riscv64: minor bugfixes in fenv](https://github.com/aosp-riscv/platform_bionic/pull/7) - - [add argument check for fesetround()](https://gitee.com/aosp-riscv/platform_bionic/pulls/18) - - [fixed doc link issue](https://gitee.com/aosp-riscv/test-riscv/pulls/13) - - [fixed issue when run bionic host test](https://gitee.com/aosp-riscv/test-riscv/pulls/14) - - [PR for Feature "setup golang develop/debug env for soong"](https://gitee.com/aosp-riscv/working-group/pulls/17) - - [[RISCV] Pass -mno-relax to assembler when -fno-integrated-as specified](https://reviews.llvm.org/D120639) - - [[RISCV] Generate correct ELF EFlags when .ll file has target-abi attribute](https://reviews.llvm.org/D121183) - - Technical articles related: - - [20220226-case-prebuilt-elf-files.md](https://github.com/aosp-riscv/working-group/pull/38) - - [add doc to introduce how to add entry in lunch](https://gitee.com/aosp-riscv/working-group/pulls/20) - - [add code version for doc](https://gitee.com/aosp-riscv/working-group/pulls/19) - -- 2022-03-03 状态更新 - - - Sync aosp-riscv to RVI upstream: - - [upgrade kernel uapi to 5.12](https://github.com/riscv-android-src/platform-bionic/pull/14) - - [clean-up some minor faults](https://github.com/riscv-android-src/platform-bionic/pull/15) - - [fix android unsafe frame pointer chase](https://github.com/riscv-android-src/platform-bionic/pull/16) - - [some cleanup and restore](https://github.com/riscv-android-src/platform-build-soong/pull/3) - - Sync aosp-riscv from RVI upstream: - - [sync with RVI upsteam: pr#14](https://gitee.com/aosp-riscv/platform_bionic/pulls/15) - - [sync from RVI upstream: linker_wrapper](https://gitee.com/aosp-riscv/platform_bionic/pulls/16) - - [removed FIXME](https://gitee.com/aosp-riscv/platform_bionic/pulls/17) - - [sync from RVI upstream, removed duplicated cflags](https://gitee.com/aosp-riscv/platform_build_soong/pulls/4) - - [fixed format issue](https://gitee.com/aosp-riscv/platform_build_soong/pulls/5) - - [RVI upstream sync, removed FIXME](https://gitee.com/aosp-riscv/platform_build_soong/pulls/6) - - aosp-riscv development and bugfix: - - [updated bionic unit test on host](https://gitee.com/aosp-riscv/test-riscv/pulls/11) - - [optimize the test scripts](https://gitee.com/aosp-riscv/test-riscv/pulls/12) - - [Enable create_minidebuginfo](https://github.com/aosp-riscv/platform_build_soong/pull/2) - - [Updated dependencies needed by create_minidebuginfo (Relocated)](https://github.com/aosp-riscv/platform_art/pull/2) - - [linux-x86/bin/create_minidebuginfo supports riscv64](https://gitee.com/aosp-riscv/platform-prebuilts-build-tools/pulls/1) - - Technical articles related: - - [status updated on Feb/17/2022](https://gitee.com/aosp-riscv/working-group/pulls/14) - - [added template for articles](https://gitee.com/aosp-riscv/working-group/pulls/15) - -- 2022-02-17 状态更新 - - - Setup bionic dynamic-link unit test and bugfix: - - [support dynamic link tests](https://gitee.com/aosp-riscv/test-riscv/pulls/6) - - [updated doc about test](https://gitee.com/aosp-riscv/test-riscv/pulls/7) - - [added search path for libicu.so](https://gitee.com/aosp-riscv/test-riscv/pulls/8) - - [added 2.log for bionic dynamic link test](https://gitee.com/aosp-riscv/test-riscv/pulls/9) - - [added 4.log for bionic static test](https://gitee.com/aosp-riscv/test-riscv/pulls/10) - - Sync aosp-riscv from RVI upstream: - - [define REG_* for ucontext](https://gitee.com/aosp-riscv/platform_bionic/pulls/12) - - [asm header files](https://gitee.com/aosp-riscv/platform_bionic/pulls/13) - - [unify rv64 pre-processor definition](https://gitee.com/aosp-riscv/platform_bionic/pulls/14) - - Sync aosp-riscv to RVI upstream: - - [added stack overflow reserved bytes for rv64](https://github.com/riscv-android-src/platform-art/pull/2) - - [removed duplicated asm riscv header file](https://github.com/riscv-android-src/platform-bionic/pull/8) - - [unify rv64 preprocessor definition](https://github.com/riscv-android-src/platform-bionic/pull/13) - - [upgrade kernel uapi to 5.12](https://github.com/riscv-android-src/platform-bionic/pull/14) in reviewing - -- 2022-01-20 状态更新 - - 运行 bionic 单元测试并解决发现的问题,提交的 PR 列表如下: - - [fix TLS issues](https://gitee.com/aosp-riscv/platform_bionic/pulls/5) - - [change TLS slot organization same as that for arm](https://gitee.com/aosp-riscv/platform_bionic/pulls/6) - - [fixed vfork](https://gitee.com/aosp-riscv/platform_bionic/pulls/7) - - [continue vfork](https://gitee.com/aosp-riscv/platform_bionic/pulls/8) - - [fixed memset infinite loop issue](https://gitee.com/aosp-riscv/platform_bionic/pulls/10) - - [some changes for test env](https://gitee.com/aosp-riscv/test-riscv/pulls/3) - - [run test with isolate mode](https://gitee.com/aosp-riscv/test-riscv/pulls/4) - - [enabled some blocking cases](https://gitee.com/aosp-riscv/test-riscv/pulls/5) - - [minor changes and ready for upstream](https://gitee.com/aosp-riscv/platform_bionic/pulls/9) - - [code format improvement](https://gitee.com/aosp-riscv/platform_bionic/pulls/11) - - [minor fix and ready for upstream](https://gitee.com/aosp-riscv/platform_build/pulls/2) - - [minor fix and ready for upstream](https://gitee.com/aosp-riscv/platform_build_soong/pulls/3) - - 文章和技术手册更新: - - [continue update android kernel related knowledge](https://gitee.com/aosp-riscv/working-group/pulls/10) - - [updated article: platform-version](https://gitee.com/aosp-riscv/working-group/pulls/11) - - [add how to build clang for aosp](https://gitee.com/aosp-riscv/working-group/pulls/12) - - RVI aosp 12 上游提交工作 - - [RVI Android SIG 发布 AOSP 12 源码仓库, Jan/17/2022](https://lists.riscv.org/g/sig-android/message/32), - - [removed old seccomp txt files](https://github.com/riscv-android-src/platform-bionic/pull/3) - - [bugfix: enable rela ifunc resolver for riscv64](https://github.com/riscv-android-src/platform-bionic/pull/4) - - [format code style](https://github.com/riscv-android-src/platform-bionic/pull/6) - -- 2021-12-23 状态更新 - - 搭建了一个最小系统,在 QEMU 上运行 AOSP 的 bionic-unit-test-static,并解决测试中发现的 bugs。 - - malloc.malloc_info: SIGABRT: - - part of stdio cases FAILED due to can not create tmpfiles: - - Fixed wrong mdev path issue: - - ifunc.*:Segmentation fault: ; 该 bugfix 也提交上游 PR: - - added bionic-unit-tests-static log: - - Added doc on how-to setup test env: - - 参加 OSDTConf2021 并做 AOSP for RISC-V 社区开源进展报告 - - 报告 slides: - - 报告 vedio: - -- 2021-12-10 已可以完整地成功编译 bionic,正在利用 Google 提供的 gtest 套件运行集成测试。 - - Clang 工具链中增加 libFuzzer 支持 riscv - - - - - - - - 使能 soong tests,构建中无需输入 `--skip-soong-tests` - - - - - - 针对一些大仓库,不再使用 patch 方式,仍然使用 git 进行管理: - - - - - - - - - - - - - - - - 构建成功 bionic,使用 "mmm bionic": - - - - - - - - - - - - - - - - - - - - 增加一个仓库存放测试相关的脚本: - - - -- 2021-11-30 针对 AOSP 12 移植到 RV64 实现 `mmm bionic/libc/ --skip-soong-tests` 下构建成功 libc/libm/libdl。相关修改已经提交到仓库上。具体如下(部分 PR 在 gitee 上,所有代码同步推送至 github 和 gitee): - - 工具链 for AOSP 更新: - - Rust for Android: - - compiler: add riscv64gc-linux-android target (Tier 3): - - library: add riscv64gc-linux-android support: - - Modified libc, added support for riscv64: - - Clang/llvm for Android: - - add riscv __get_tls method: - - Change some repos' fetch address and revision to support riscv64: - - manifest 仓库:PR: - - AOSP 仓库更新(PR): - - - - - - - - - - - - - -- 2021-11-15 针对 AOSP 12 移植到 RV64 实现 `m --skip-ninja --skip-soong-tests` 下构建成功。相关修改已经提交到仓库上。具体如下(这里以 gitee 的为例,github 已经 mirror): - - manifest 仓库: - - 涉及新增的 AOSP 仓库: - - art/ : - - bionic/: - - build/make/: - - build/soong/: - - external/crosvm/: - - frameworks/av/: - - packages/modules/NeuralNetworks/: - - prebuilts/vndk/v28/: - - prebuilts/vndk/v29/: - - prebuilts/vndk/v30/: - - system/apex/: - - system/core/: - - system/iorap/: - - system/nvram/: - - 另有部分仓库由于整体体积过大或者部分文件体积过大,超过 gitee/github 限制的,目前无法在 gitee/github 上新建仓库,所以目前采用补丁方式保存修改、目前这些涉及的仓库为: - - cts/ - - frameworks/base/ - - packages/modules/ArtPrebuilt/ - - packages/services/Car/ - - prebuilts/clang/host/linux-x86/ - - prebuilts/runtime/ - 新建的补丁仓库为: - - 提交的 PR 列表如下: - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 更新文档 [“如何编译 aosp-riscv” ](./articles/20211029-howto-setup-build-env.md) - - 新增文档 ["代码走读:对 soong_ui 的深入理解"](./articles/20211102-codeanalysis-soong_ui.md) - -- 2021-10-29 重启 PLCT lab 的 AOSP 移植工作,最新的目标是将 AOSP 12 移植到 RV64 上。 - - 创建 group @ (mirrored with ) 以及部分仓库. - - [PR Merged] added note on howto setup build env: - - 新增文档 ["Code analysis for envsetup"](./articles/20211026-lunch.md) - - 新增文档 ["Howto setup build environment"](./articles/20211029-howto-setup-build-env.md) - -- 2021-01-xx 由于平头哥的 [开源工作 ](https://github.com/T-head-Semi/aosp-riscv),我们于 2021 年初停止了 PLCT lab 的相关 AOSP 移植工作。所有原 下的代码仓库(除了 working-group)都备份到 [Gitee 的 aosp-riscv-bionic-porting 组织](https://gitee.com/aosp-riscv-bionic-porting) 下。 - -- 2021-01-15 仍然在研究如何基于 AOSP 的 Soong 框架加入 RVG64。目前的主要难点是由于 AOSP 的编译系统异常庞大和复杂,包含了太多工程化所需的内容,而且互相交织和依赖在一起,所以如何干净地先屏蔽掉我们不关心的模块,只编译 bionic 库的核心内容是目前的重点也是难点。目前还没有太多的头绪,如果有好心的小伙伴欢迎来提供帮助和建议。 - -- 2020-12-29 完成 bionic 的动态链接功能,目前可以基于 bionic 支持实现隐式动态链接和显式动态链接。此外还改进了原先的 make 框架系统。具体改动请参考 bionic 移植主仓库 的 develop 分支以及其相应的 submodule 仓库(国内用户也可以访问 Gitee 镜像 )。下一步的工作重点是移植修改 AOSP 的 Soong 构造系统,支持采用 AOSP 提供的 Soong 构造系统编译 RISC-V 版本的 bionic 库和相关应用。 - -- 2020-12-15 - - 开始移植 bionic 的动态链接功能,目前完成了 `libc.so` 和 `linker` 的编译链接,但运行还有问题,还在调试中,欢迎熟悉动态链接器实现或者对此感兴趣的小伙伴一起来研究。此外还进一步改进优化了 make 框架。具体改动请参考 bionic 移植主仓库 的 develop 分支以及其相应的 submodule 仓库。 - - 目前移植工作涉及的 AOSP 子仓库已经达到 9 个,全部下载完有 537M。为了方便中国国内的小伙伴下载访问,我们在 Gitee 上为 建了一个 mirror 网站,具体地址是 。具体访问操作说明请参考另外一篇知乎介绍文章 [《AOSP-RISCV 的开源仓库在 Gitee 上新建了镜像》](https://zhuanlan.zhihu.com/p/337032693)。 - - 下一步的工作重点依然是实现动态链接支持,目前感觉实现难度比静态链接要大。除此之外会继续完善 bionic 功能并尝试移植 AOSP 的 Soong 构造系统,支持采用 AOSP 的 Soong 构造系统编译 RISC-V 版本的 bionic 库和相关应用。 - -- 2020-11-30 完成 shell 和 init 的移植,目前可以实现完全基于 bionic 的 libc 库,采用静态链接的方式生成一个最小的 android 根文件系统。该 rootfs 可以在 qemu-system-riscv64 上启动运行,并支持运行一些基本的操作命令。此外还改进了原先的 make 框架系统,为下一个阶段进一步支持动态链接做准备。具体改动请参考 bionic 移植主仓库 的 develop 分支以及其相应的 submodule 仓库。更多的详细介绍可以参考另一篇知乎介绍文章:[《第一个 RISC-V 上的“Android 最小系统”》](https://zhuanlan.zhihu.com/p/302870095)。下一步的工作重点是增加动态链接支持,继续完善 bionic 功能并尝试移植 AOSP 的 Soong 构造系统,支持采用 AOSP 的 Soong 构造系统编译 RISC-V 版本的 bionic 库和相关应用。 - -- 2020-11-13 进一步完善 bionic 的 libc 静态库。目前采用 v10.0.1 的 llvm/clang 进行编译,然后用 gnu riscv 版本的 ld 基于 bionic 的 libc_static 、crtbegin_static 和 crtend.o 可以实现静态链接,并生成可执行程序。在此基础上移植编译了 AOSP 自带的 toybox 并制作了一个最小的 rootfs(shell 和 init 还是采用基于 glibc 编译的 busybox)。目前该 rootfs 可以在 qemu-system-riscv64 上启动运行。可以运行部分命令,但还有部分命令执行会报错。具体改动请参考 bionic 移植主仓库 的 develop 分支以及其 submodule 仓库的 develop 分支的 commit comment。下一步将继续完善 bionic 的 libc,以及完善自制的最小根文件系统。 - -- 2020-10-30 完善了 make 框架,支持编译生成 libc 静态库以及 `crtbegin.o` 和 `crtend.o`。目前可以实现静态编译的可执行程序从内核跳转进入 main 函数并确保 argv 和 envp 读取正确,其他 TLS 和 syscall 部分的移植还在进行中。具体改动请参考 的 develop 分支。 - -- 2020-10-16 将 AOSP bionic 库的 build 框架简化为 make,初步的移植工作提交到 的 develop 分支,目前该项目仓库依赖于两个子仓库 (由于改动还很 draft,所以目前对 aosp 相关的改动全部放在各自的 develop 分支上。另备注:目前的移植工作基于 AOSP 的 `android-10.0.0_r39` tag 版本)。下一步的工作是继续完善 make 项目并对 bionic 的代码进行移植改动,第一个目标是实现 `libc.a`。 - -- 2020-10-01 采用最新的 AOSP 内核及配置,尝试使用 RISC-V 的 GNU 工具链和 LLVM/Clang 工具链均可以成功编译并启动,但在挂载最小根文件系统后遇到 “Segmentation Fault” 错误,继续调试中。另外开始研究如何将 AOSP 的 bionic 库移植到 RISC-V 上,目前主要工作是在修改移植编译框架。 - -- 2020-09-15 开始为 RISC-V 移植 AOSP 的内核,通过调研基本确定基于 AOSP common kernel 的 `android-5.4-stable` 分支开展移植工作,具体移植工作正在进行中。 - -- 2020-09-01 修复了运行 `mmm art/compiler` 命令在生成 ninja 文件过程中的编译错误,主要涉及 build 和 prebuilts 仓库下修改。我们目前调试的主要问题集中在 system 和 cts 仓库中。 - -- 2020-08-15 尝试修改 AOSP 的构造框架,在 lunch 菜单中加入 RISC-V 设备条目。我们还为 `build/make` 和 `build/soong` 增加了相关的配置项,目前还在调试 `build/soong` 中的问题。 +不再维护中文版,请统一访问 [英文版的项目状态进展](./status.md) ## 有关我们 @@ -254,7 +27,7 @@ AOSP-RISCV 的代码开源,欢迎大家参与贡献。所有仓库在 Github ## 加入我们 -如果您对本项目感兴趣,请阅读 AOSP 网站的相关指导文件。 +如果您对本项目感兴趣,请阅读 AOSP 网站的相关指导文件。或者联系 汪辰([@unicornx](https://github.com/unicornx))。 如果您有话题想进一步参与讨论,请在 github 上给我们提交 issue。 diff --git a/status.md b/status.md new file mode 100644 index 0000000000000000000000000000000000000000..a3304f24f16ebe88cf94d0fdb3b4bf6c4e54d538 --- /dev/null +++ b/status.md @@ -0,0 +1,260 @@ +Project(aosp-riscv) progress log (time in reverse order). + +- 2022-04-28 Status update + + - RVI upstream: + - [fixed issues and code cleanup for emulator](https://github.com/riscv-android-src/platform-external-qemu/pull/3) + - [implement generate cmake-main.xxx.inc by scripts](https://github.com/riscv-android-src/platform-external-qemu/pull/4) + - [reverted commented codes](https://github.com/riscv-android-src/platform-external-qemu/pull/7) + - [added defconfig for ranchu](https://github.com/riscv-android-src/kernel-common/pull/1) + - [updated with latest emulator](https://github.com/riscv-android-src/platform-prebuilts-android-emulator/pull/1) + - [updated kernel for emulator](https://github.com/riscv-android-src/kernel-prebuilts-5.10-riscv64/pull/1) + - [updated build guide for aosp 12](https://github.com/riscv-android-src/riscv-android/pull/2) + - aosp-riscv development and bugfix: + - [Updated emulator integration branch](https://gitee.com/aosp-riscv/working-group/pulls/28) + - [Remove bcc and ld.mc in Target Base System](https://gitee.com/aosp-riscv/platform_build/pulls/4) + - Technical articles related: + - [added article gdb android emulator](https://gitee.com/aosp-riscv/working-group/pulls/29) + - [added article run qemu 2.12.0](https://gitee.com/aosp-riscv/working-group/pulls/27) + - [added article to introduce how ndk is built](https://gitee.com/aosp-riscv/working-group/pulls/26) + - [article updated how-ndk-built](https://gitee.com/aosp-riscv/working-group/pulls/32) + +- 2022-03-30 Status update + + - Sync aosp-riscv to RVI upstream: + - [improve vfork](https://github.com/riscv-android-src/platform-bionic/pull/19) + - Sync aosp-riscv from RVI upstream: + - N/A + - aosp-riscv development and bugfix: + - [New TARGET_PRODUCT sdk_phone_riscv64 with 64bit Support Only](https://gitee.com/aosp-riscv/platform_build/pulls/3) + - [changed device/generic/goldfish to aosp-riscv](https://gitee.com/aosp-riscv/platform_manifest/pulls/13) + - [pass build with m --skip-ninja for sdk_phone_riscv64-eng](https://gitee.com/aosp-riscv/device-generic-goldfish/pulls/1) + - [sudo is not required for make_rootfs.sh](https://gitee.com/aosp-riscv/test-riscv/pulls/15) + - [added prebuilt gdb](https://gitee.com/aosp-riscv/test-riscv/pulls/16) + - [use gdb built for 18.04](https://gitee.com/aosp-riscv/test-riscv/pulls/17) + - Technical articles related: + - [added doc to introduce howto build emu](https://gitee.com/aosp-riscv/working-group/pulls/22) + - [Add rust toolchain build instructions](https://gitee.com/aosp-riscv/working-group/pulls/23) + +- 2022-03-16 Status update + + - Sync aosp-riscv to RVI upstream: + - [squash and remove duplicated codes](https://github.com/riscv-android-src/platform-bionic/pull/17) + - [minor bugfixes in fenv](https://github.com/riscv-android-src/platform-bionic/pull/18) + - Sync aosp-riscv from RVI upstream: + - [riscv64: fix fenv handling](https://github.com/aosp-riscv/platform_bionic/pull/5) + - aosp-riscv development and bugfix: + - [libm/riscv64: minor bugfixes in fenv](https://github.com/aosp-riscv/platform_bionic/pull/7) + - [add argument check for fesetround()](https://gitee.com/aosp-riscv/platform_bionic/pulls/18) + - [fixed doc link issue](https://gitee.com/aosp-riscv/test-riscv/pulls/13) + - [fixed issue when run bionic host test](https://gitee.com/aosp-riscv/test-riscv/pulls/14) + - [PR for Feature "setup golang develop/debug env for soong"](https://gitee.com/aosp-riscv/working-group/pulls/17) + - [[RISCV] Pass -mno-relax to assembler when -fno-integrated-as specified](https://reviews.llvm.org/D120639) + - [[RISCV] Generate correct ELF EFlags when .ll file has target-abi attribute](https://reviews.llvm.org/D121183) + - Technical articles related: + - [20220226-case-prebuilt-elf-files.md](https://github.com/aosp-riscv/working-group/pull/38) + - [add doc to introduce how to add entry in lunch](https://gitee.com/aosp-riscv/working-group/pulls/20) + - [add code version for doc](https://gitee.com/aosp-riscv/working-group/pulls/19) + +- 2022-03-03 Status update + + - Sync aosp-riscv to RVI upstream: + - [upgrade kernel uapi to 5.12](https://github.com/riscv-android-src/platform-bionic/pull/14) + - [clean-up some minor faults](https://github.com/riscv-android-src/platform-bionic/pull/15) + - [fix android unsafe frame pointer chase](https://github.com/riscv-android-src/platform-bionic/pull/16) + - [some cleanup and restore](https://github.com/riscv-android-src/platform-build-soong/pull/3) + - Sync aosp-riscv from RVI upstream: + - [sync with RVI upsteam: pr#14](https://gitee.com/aosp-riscv/platform_bionic/pulls/15) + - [sync from RVI upstream: linker_wrapper](https://gitee.com/aosp-riscv/platform_bionic/pulls/16) + - [removed FIXME](https://gitee.com/aosp-riscv/platform_bionic/pulls/17) + - [sync from RVI upstream, removed duplicated cflags](https://gitee.com/aosp-riscv/platform_build_soong/pulls/4) + - [fixed format issue](https://gitee.com/aosp-riscv/platform_build_soong/pulls/5) + - [RVI upstream sync, removed FIXME](https://gitee.com/aosp-riscv/platform_build_soong/pulls/6) + - aosp-riscv development and bugfix: + - [updated bionic unit test on host](https://gitee.com/aosp-riscv/test-riscv/pulls/11) + - [optimize the test scripts](https://gitee.com/aosp-riscv/test-riscv/pulls/12) + - [Enable create_minidebuginfo](https://github.com/aosp-riscv/platform_build_soong/pull/2) + - [Updated dependencies needed by create_minidebuginfo (Relocated)](https://github.com/aosp-riscv/platform_art/pull/2) + - [linux-x86/bin/create_minidebuginfo supports riscv64](https://gitee.com/aosp-riscv/platform-prebuilts-build-tools/pulls/1) + - Technical articles related: + - [status updated on Feb/17/2022](https://gitee.com/aosp-riscv/working-group/pulls/14) + - [added template for articles](https://gitee.com/aosp-riscv/working-group/pulls/15) + +- 2022-02-17 Status update + + - Setup bionic dynamic-link unit test and bugfix: + - [support dynamic link tests](https://gitee.com/aosp-riscv/test-riscv/pulls/6) + - [updated doc about test](https://gitee.com/aosp-riscv/test-riscv/pulls/7) + - [added search path for libicu.so](https://gitee.com/aosp-riscv/test-riscv/pulls/8) + - [added 2.log for bionic dynamic link test](https://gitee.com/aosp-riscv/test-riscv/pulls/9) + - [added 4.log for bionic static test](https://gitee.com/aosp-riscv/test-riscv/pulls/10) + - Sync aosp-riscv from RVI upstream: + - [define REG_* for ucontext](https://gitee.com/aosp-riscv/platform_bionic/pulls/12) + - [asm header files](https://gitee.com/aosp-riscv/platform_bionic/pulls/13) + - [unify rv64 pre-processor definition](https://gitee.com/aosp-riscv/platform_bionic/pulls/14) + - Sync aosp-riscv to RVI upstream: + - [added stack overflow reserved bytes for rv64](https://github.com/riscv-android-src/platform-art/pull/2) + - [removed duplicated asm riscv header file](https://github.com/riscv-android-src/platform-bionic/pull/8) + - [unify rv64 preprocessor definition](https://github.com/riscv-android-src/platform-bionic/pull/13) + - [upgrade kernel uapi to 5.12](https://github.com/riscv-android-src/platform-bionic/pull/14) in reviewing + +- 2022-01-20 Status update + - Bionic static unit test and bugfix: + - [fix TLS issues](https://gitee.com/aosp-riscv/platform_bionic/pulls/5) + - [change TLS slot organization same as that for arm](https://gitee.com/aosp-riscv/platform_bionic/pulls/6) + - [fixed vfork](https://gitee.com/aosp-riscv/platform_bionic/pulls/7) + - [continue vfork](https://gitee.com/aosp-riscv/platform_bionic/pulls/8) + - [fixed memset infinite loop issue](https://gitee.com/aosp-riscv/platform_bionic/pulls/10) + - [some changes for test env](https://gitee.com/aosp-riscv/test-riscv/pulls/3) + - [run test with isolate mode](https://gitee.com/aosp-riscv/test-riscv/pulls/4) + - [enabled some blocking cases](https://gitee.com/aosp-riscv/test-riscv/pulls/5) + - [minor changes and ready for upstream](https://gitee.com/aosp-riscv/platform_bionic/pulls/9) + - [code format improvement](https://gitee.com/aosp-riscv/platform_bionic/pulls/11) + - [minor fix and ready for upstream](https://gitee.com/aosp-riscv/platform_build/pulls/2) + - [minor fix and ready for upstream](https://gitee.com/aosp-riscv/platform_build_soong/pulls/3) + - Article/Document update: + - [continue update android kernel related knowledge](https://gitee.com/aosp-riscv/working-group/pulls/10) + - [updated article: platform-version](https://gitee.com/aosp-riscv/working-group/pulls/11) + - [add how to build clang for aosp](https://gitee.com/aosp-riscv/working-group/pulls/12) + - RVI aosp 12 upstream work: + - [RISC-V Android 12 Source code repo in github, Jan/17/2022](https://lists.riscv.org/g/sig-android/message/32), + - [removed old seccomp txt files](https://github.com/riscv-android-src/platform-bionic/pull/3) + - [bugfix: enable rela ifunc resolver for riscv64](https://github.com/riscv-android-src/platform-bionic/pull/4) + - [format code style](https://github.com/riscv-android-src/platform-bionic/pull/6) + +- 2021-12-23 Status update + - Build a minimal system, run AOSP's bionic-unit-test-static on QEMU, and solve the bugs found in the test. + - malloc.malloc_info: SIGABRT: + - part of stdio cases FAILED due to can not create tmpfiles: + - Fixed wrong mdev path issue: + - ifunc.*:Segmentation fault: ; also raise PR to upstream: + - added bionic-unit-tests-static log: + - Added doc on how-to setup test env: + - Participate in OSDTConf2021 and present a report about AOSP for RISC-V community open source progress + - report slides: + - report vedio: + +- 2021-12-10: Bionic has been successfully compiled, and integration tests are being run using the gtest suite provided by Google. + - Clang toolchain: added libFuzzer + - + - + - + - Enable soong tests during building: + - + - + - Move some patches to git: + - + - + - + - + - + - + - + - Pass build with "mmm bionic": + - + - + - + - + - + - + - + - + - + - Added test repo: + - + +- 2021-11-30 For AOSP 12 ported to RV64, the implementation of `mmm bionic/libc/ --skip-soong-tests` was successfully built, we now have libc/libm/libdl. The relevant changes have been submitted to the repositories. The details are as follows (here, some PRs are created on gitee, all commits are pushed both on github & gitee): + - toolchain for AOSP: + - Rust for Android: + - compiler: add riscv64gc-linux-android target (Tier 3): + - library: add riscv64gc-linux-android support: + - Modified libc, added support for riscv64: + - Clang/llvm for Android: + - add riscv __get_tls method: + - Change some repos' fetch address and revision to support riscv64: + - manifest:PR: + - AOSP (PRs): + - + - + - + - + - + - + +- 2021-11-15 For AOSP 12 ported to RV64, the implementation of `m --skip-ninja --skip-soong-tests` was successfully built. The relevant changes have been submitted to the repositories. The details are as follows (here, gitee is taken as an example, github has been mirrored): + - manifest repository: + - Newly added AOSP repositories: + - art/ : + - bionic/: + - build/make/: + - build/soong/: + - external/crosvm/: + - frameworks/av/: + - packages/modules/NeuralNetworks/: + - prebuilts/vndk/v28/: + - prebuilts/vndk/v29/: + - prebuilts/vndk/v30/: + - system/apex/: + - system/core/: + - system/iorap/: + - system/nvram/: + - In addition, some repositories are currently unable to be created on gitee/github because the overall volume or some files are too large and exceed the limitaiton required by gitee/github. Therefore, we currently use patching method to save the changes, and below are these repositories involved: + - cts/ + - frameworks/base/ + - packages/modules/ArtPrebuilt/ + - packages/services/Car/ + - prebuilts/clang/host/linux-x86/ + - prebuilts/runtime/ + The newly built patch repository is: + - The list of PRs submitted is as follows: + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - Updated tech article [“Howto build aosp-riscv” ](./articles/20211029-howto-setup-build-env.md) + - Newed tech article ["Code analysis for soong_ui"](./articles/20211102-codeanalysis-soong_ui.md) + +- 2021-10-29 Restart the AOSP migration work of PLCT lab. The new goal is to migrate AOSP 12 to RV64. + - Setup group @ (mirrored with ) with some initial repos. + - [PR Merged] added note on howto setup build env: + - Newed tech article ["Code analysis for envsetup"](./articles/20211026-lunch.md) + - Newed tech article ["Howto setup build environment"](./articles/20211029-howto-setup-build-env.md) + +- 2021-01-xx Due to [open-source work](https://github.com/T-head-Semi/aosp-riscv) from T-Head(alibaba), we (PLCT lab) stopped the AOSP porting work in early 2021. All code repositories (except working-group) under the original and are backed up to [Gitee's aosp-riscv-bionic-porting](https://gitee.com/aosp-riscv-bionic-porting). + +- 2021-01-15 Still in investigating how to add RVG64 support based on the Soong framework of AOSP. The main difficulty at present is: due to the AOSP compilation system is extremely large and complex, contains too much content required for engineering, and is intertwined and dependent on each other, so how to cleanly mask the modules that we don’t care about first and only compile those core content of the bionic library is the current focus and difficulty. There is not much clue yet, anyone is welcomed to provide help and suggestions. + +- 2020-12-29 Completed the porting of dynamic linking feature for bionic, we can now support implicit dynamic link and explicit dynamic link with bionic. The make framework system is also improved. For specific changes, please refer to the `develop` branch of the bionic transplantation main repository, . The next step is to port and modify AOSP's Soong construction system and use AOSP Soong construction system to compile the bionic library and related applications for RISC-V. + +- 2020-12-15 + - Started to port the dynamic link functionality for bionic. Currently, the compilation and linking of `libc.so` and `linker` have been completed, but still can not work well. We are still under debugging. Anybody familiar with the dynamic linker are welcomed to provide your suggestions. For specific changes, please refer to the `develop` branch of the bionic transplantation main repository, , and its corresponding submodule repository. + - The focus of further work is still to achieve dynamic link support, and the current implementation flaws are felt to be larger than static links. In addition, we will continue to improve the bionic function and try to transplant the Soong construction system of AOSP, and support the use of AOSP Soong construction system to compile the bionic library and related applications for RISC-V. + +- 2020-11-30 Completed the porting of shell and init. Currently, the bionic libc.a library can work, and a minimal Android root file system can be generated by statically linking against it. The rootfs can be launched and run on qemu-system-riscv64 and supports running some basic operation commands. In addition, the original make framework system has been improved to prepare for the next stage to further support dynamic linking. For specific changes, please refer to the `develop` branch of the bionic transplantation main repository, , and its corresponding submodule repository. For more detailed introduction, please refer to another introduction article: ["Create a minimal Android system for RISC-V"] (https://plctlab.github.io/aosp/create-a-minimal-android-system-for-riscv.html). The next step is to improve the dynamic linking support, continue to improve the bionic function and try to transplant the Soong construction system of AOSP, and support the use of the Soong construction system of AOSP to compile the bionic library and related applications for RISC-V. + +- 2020-11-13 Further improve the libc static library of bionic. Currently using v10.0.1 llvm/clang to compile, and using the GNU RISC-V version of ld based on bionic's libc_static, crtbegin_static and crtend.o to achieve static linking and executable program generation. On this basis, we transplanted and compiled the toybox that comes with AOSP and made a minimal rootfs (shell and init still use busybox compiled for glibc). At present, the rootfs can be started and run on qemu-system-riscv64. You can run some commands, but some commands will report errors when executed. For specific changes, please refer to the commit comment of the `develop` branch of the bionic porting main repository, , and the commit comments of the `develop` branch of its submodule repositories. The next step will be to continue to improve the libc of bionic and the self-made minimal root file system. + +- 2020-10-30 The make framework has been improved to support the compilation and generation of libc static libraries, as well as `crtbegin.o` and `crtend.o`. Currently, the statically compiled executable program can jump from the kernel to the main function and ensure that `argv` and `envp` are read correctly. The porting of other TLS and syscall parts is still ongoing. For specific changes, please refer to the `develop` branch of . + +- 2020-10-16 Simplify the build framework of the AOSP bionic library to make, and submit the preliminary porting work to the develop branch of . Currently, the project repository depends on two sub-repositories: and (Because the changes are still drafts, the current changes to AOSP are all placed on their respective `develop` branches. Another note: the current porting work is based off `android-10.0.0_r39` tag version based on AOSP). The next step is to continue to improve the make project and make changes to the bionic code. The first goal is to implement `libc.a`. + +- 2020-10-01 Using the latest AOSP kernel and configuration, with GNU and LLVM/Clang tool-chain for RISC-V, we successfully compiled and booted the kernel on QEMU. The only problem is: after mounting the minimum rootfs, we encounter a "Segmentation Fault" error. Still debugging this issue. In addition, we began to study how to port the bionic library of AOSP to RISC-V. The current work is to port the AOSP building framework for bionic. + +- 2020-09-15 We launched the task to port the AOSP kernel to RISC-V. After some research, we decided to base it off the branch `android-5.4-stable` of AOSP common kernels and we are working on it now. + +- 2020-09-01 We fixed the errors in build dir and prebuilts dir when using the 'mmm art/compiler' to generate the ninja files for the compiler module. We are debugging the errors in the system dir and cts dir. + +- 2020-08-15 We have added the lunch menu for RISC-V, and successfully loaded the menu. After that, we added the RISC-V config files for build/make and build/soong, We are debugging the RISC-V config files in build/soong.