From 5ef9d3d1c93081307926884ad142395ac3c9d907 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ciro=20Santilli=20=E5=85=AD=E5=9B=9B=E4=BA=8B=E4=BB=B6=20?= =?UTF-8?q?=E6=B3=95=E8=BD=AE=E5=8A=9F?= Date: Mon, 23 Mar 2020 07:17:11 +0000 Subject: [PATCH] c++ baremetal hello world move to issue tracker --- README.adoc | 43 +------------------------------------------ 1 file changed, 1 insertion(+), 42 deletions(-) diff --git a/README.adoc b/README.adoc index f51209c..e0c0a56 100644 --- a/README.adoc +++ b/README.adoc @@ -19589,48 +19589,7 @@ with the prebuilt toolchain, and I'm lazy to debug. [[baremetal-cpp]] === Baremetal C++ -TODO not working as of 8825222579767f2ee7e46ffd8204b9e509440759 + 1. Not yet properly researched / reported upstream yet. - -Should not be hard in theory since `libstdc++` is just part of GCC, as shown at: https://stackoverflow.com/questions/21872229/how-to-edit-and-re-build-the-gcc-libstdc-c-standard-library-source/51946224#51946224 - -To test it out, I first hack link:common.py[] to enable `C++`: - -.... -consts['baremetal_build_in_exts'] = consts['build_in_exts'] -.... - -and then I hack link:userland/arch/aarch64/inline_asm/multiline.cpp[] to consist only of an empty main: - -.... -int main() {} -.... - -then for example: - -.... -./build-baremetal --arch aarch64 -./run --arch aarch64 --baremetal userland/arch/aarch64/inline_asm/multiline.cpp -.... - -fails with: - -.... -rom: requested regions overlap (rom dtb. free=0x00000000000000a0, addr=0x0000000000000000) -qemu-system-aarch64: rom check and register reset failed -.... - -and the gem5 build fails completely: - -.... -./build-baremetal --arch aarch64 --emulator gem5 userland/arch/aarch64/inline_asm/multiline.cpp -.... - -fails with: - -.... -/tmp/ccFd2YIB.o:(.eh_frame+0x1c): relocation truncated to fit: R_AARCH64_PREL32 against `.text' -collect2: error: ld returned 1 exit status -.... +Didn't get it working, traking at: https://github.com/cirosantilli/linux-kernel-module-cheat/issues/119 === GDB builtin CPU simulator