Support for gdb on m1? #1114
Replies: 5 comments 11 replies
-
Have you tried If that doesn't work, it's likely that |
Beta Was this translation helpful? Give feedback.
-
I too use a MBA M1 |
Beta Was this translation helpful? Give feedback.
-
Hey, is there an update on this? |
Beta Was this translation helpful? Give feedback.
-
GDB Configuration for Apple Silicon in CLion.app It's been discovered that CLion comes with a version of GDB configured for Apple Silicon. To access it, navigate to:
Then run
Compiling GDB for RISC-V on Apple Silicon For those interested in debugging RISC-V platforms, here are the steps to compile a special version of GDB:
Before compiling, configure your export LDFLAGS="-L/opt/homebrew/opt/gmp/lib $LDFLAGS"
export CPPFLAGS="-I/opt/homebrew/opt/gmp/include $CPPFLAGS"
export LDFLAGS="-L/opt/homebrew/opt/libiconv/lib $LDFLAGS"
export CPPFLAGS="-I/opt/homebrew/opt/libiconv/include $CPPFLAGS"
export LDFLAGS="-L/opt/homebrew/opt/gettext/lib $LDFLAGS"
export CPPFLAGS="-I/opt/homebrew/opt/gettext/include $CPPFLAGS" Then, in the gdb-13.2 source code root directory, execute: mkdir -p build/ && cd build/
../configure --prefix=/usr/local --with-python=/opt/homebrew/Cellar/[email protected]/3.10.14/Frameworks/Python.framework/Versions/3.10/bin/python3.10 --target=riscv64-unknown-elf --enable-tui=yes --enable-werror=no
make -j$(sysctl -n hw.ncpu)
sudo make install The result is a GDB configured for
This approach provides a viable solution for those needing GDB on Apple Silicon, particularly for specialized applications like RISC-V platform debugging. |
Beta Was this translation helpful? Give feedback.
-
will be fixed in Homebrew/homebrew-core#209753 |
Beta Was this translation helpful? Give feedback.
-
I am trying to install gdb on MBA m1 with
brew install gdb
. It gives an error asError: gdb: no bottle available! You can try to install from source with: brew install --build-from-source gdb Please note building from source is unsupported. You will encounter build failures with some formulae. If you experience any issues please create pull requests instead of asking for help on Homebrew's GitHub, Twitter or any other official channels.
Is there any other way to install gdb on an M1 machine?
EDIT: found onlinegdb, works good enough for now.
Beta Was this translation helpful? Give feedback.
All reactions