If I unpacking the toolchain via gcc-arm-none-eabi-10.3-2021 and run
$ arm-none-eabi-g++ --help
...
-print-sysroot Display the target libraries directory.
...
$ arm-none-eabi-g++ -print-sysroot
$ /opt/gcc-arm-none-eabi-10.3-2021.07/bin/../arm-none-eabi
I get the sysroot path, but if I use the package manager
$ # ubuntu 20.04
$ sudo apt install gcc-arm-none-eabi libnewlib-arm-none-eabi \
libnewlib-dev libstdc++-arm-none-eabi-newlib
$ arm-none-eabi-g++ --help
...
-print-sysroot Display the target libraries directory.
...
$ arm-none-eabi-g++ -print-sysroot
$ # I would expect /usr/lib/gcc/arm-none-eabi, but it's empty
the sysroot path is empty.
Is this always the case for apt install
? Is there a way to avoid this?