If you want to use Debian packages (corresponding to the ARM toolchain), you should install gcc-arm-none-eabi which provides C and C++ cross-compilers for 32-bit ARM, including Cortex-R processors:
apt-get install -y --no-install-recommends gcc-arm-none-eabi
The compiler command for C++ will then be arm-none-eabi-g++.
If you need the STL, you should also install libstdc++-arm-none-eabi-newlib:
apt-get install -y --no-install-recommends libstdc++-arm-none-eabi-newlib
armr5-none-eabi-g++ is (was) available in the Xilinx SDK; the relevant SDK nowadays would appear to be Vitis. For a container image you’d probably be best off installing it using the full unified installer archive. (I haven’t tried this so I can’t confirm that the armr5-none-eabi is included in current versions.)
c++ - linking succeeds with arm-none-eabi-g++ but not arm-none-eabi-gcc - Stack Overflow
Whats "gcc-arm-none-eabi" toolchain ??
Adaptive Support
arm-none-eabi-gcc toolchain is not working - Stack Overflow
gcc-arm-none-eabi toolchain, my major question is, why is it made and for what problem to solve ? before toolchains existed, what were the methods used to program a chip ??
also, who makes toolchains and how are they doing it ??