./arm-none-eabi-gdb -ver ./arm-none-eabi-gdb: error while loading shared libraries: libncursesw.so.5: cannot open shared object file: No such file or directory libncursesw.so.5 does not exist in Centos 9 only the version 6 and also libtinfo.s0.5 is not available. So I cannot use the debugger.
This is a problem with your build of GDB, or CentOS, so nothing to do with GCC. You should report this to whoever provided you with arm-none-eabi-gdb