leoleoasd / blog

Hosted by Github Pages.
0 stars 1 forks source link

Pintos 从编译到 Kernel Panic:在 CLion 里愉快的 Debug | Leo's blog #48

Open utterances-bot opened 1 year ago

utterances-bot commented 1 year ago

Pintos 从编译到 Kernel Panic:在 CLion 里愉快的 Debug | Leo's blog

注:流程支持M1的mac、Intel的Mac以及Ubuntu 20.04。 MacOS:brew install qemu x86_64-elf-gcc x86_64-elf-binutils Ubuntu: apt install qemu-system-i386 gcc 最新的代码在: git clone git://pintos-os.org/pintos-anon,但是建议使用我的

https://leoleoasd.me/2020/11/08/debug-pintos-in-clion/

happyhappy-jun commented 1 year ago

Where do you get the compiler?

my cmake build gives

x86_64-elf-gcc: error: unrecognized command-line option '-arch'
x86_64-elf-gcc: error: unrecognized command-line option '-mmacosx-version-min=13.2'
x86_64-elf-gcc: error: unrecognized command-line option '-fcolor-diagnostics'

I followed your install instruction.

FYI

x86_64-elf-gcc -v
Using built-in specs.
COLLECT_GCC=x86_64-elf-gcc
COLLECT_LTO_WRAPPER=/opt/homebrew/Cellar/x86_64-elf-gcc/13.1.0/libexec/gcc/x86_64-elf/13.1.0/lto-wrapper
Target: x86_64-elf
Configured with: ../configure --target=x86_64-elf --prefix=/opt/homebrew/Cellar/x86_64-elf-gcc/13.1.0 --infodir=/opt/homebrew/Cellar/x86_64-elf-gcc/13.1.0/share/info/x86_64-elf --disable-nls --without-isl --without-headers --with-as=/opt/homebrew/opt/x86_64-elf-binutils/bin/x86_64-elf-as --with-ld=/opt/homebrew/opt/x86_64-elf-binutils/bin/x86_64-elf-ld --enable-languages=c,c++
Thread model: single
Supported LTO compression algorithms: zlib
gcc version 13.1.0 (GCC)