pico-sdk icon indicating copy to clipboard operation
pico-sdk copied to clipboard

`LLVM 20.1.0` change in `clang-runtimes` names

Open matsobdev opened this issue 5 months ago • 4 comments

Version 20.1.0 changes armv8m.main_soft_nofp to armv8m.main_soft_nofp_unaligned, thus: https://github.com/raspberrypi/pico-sdk/blob/ee68c78d0afae2b69c03ae1a72bf5cc267a2d94c/cmake/preload/toolchains/pico_arm_cortex_m33_clang.cmake#L4 need to reflect that change. There are armv6m_soft_nofp and armv6m_soft_nofp_unaligned as well, but diff says they're the same.

matsobdev avatar Jun 19 '25 13:06 matsobdev

sorry, can you give some more context. what is the effect of the Clang change. What does the fix do? What happens if you do nothing

kilograham avatar Jun 19 '25 13:06 kilograham

Upon no action, SDK in unable to locate default picolibc (release binary: https://github.com/arm/arm-toolchain/releases/download/release-20.1.0-ATfE/ATfE-20.1.0-Linux-x86_64.tar.xz) from the toolchain:

PICO_SDK_PATH is /home/mateush/Dysk_RAM/pico-sdk-2.1.1
Target board (PICO_BOARD) is 'pico2'.
Using board configuration from /home/mateush/Dysk_RAM/pico-sdk-2.1.1/src/boards/include/boards/pico2.h
Pico Platform (PICO_PLATFORM) is 'rp2350-arm-s'.
Configuring toolchain based on PICO_COMPILER 'pico_arm_cortex_m33_clang'
CMake Error at /home/mateush/Dysk_RAM/pico-sdk-2.1.1/cmake/preload/toolchains/util/pico_arm_clang_common.cmake:92 (message):
  Could not find an llvm runtime for ''
Call Stack (most recent call first):
  /home/mateush/Dysk_RAM/pico-sdk-2.1.1/cmake/preload/toolchains/pico_arm_cortex_m33_clang.cmake:8 (include)
  /home/mateush/cmake/share/cmake-3.19/Modules/CMakeDetermineSystem.cmake:123 (include)
  CMakeLists.txt:44 (project)


CMake Error: CMake was unable to find a build program corresponding to "Ninja".  CMAKE_MAKE_PROGRAM is not set.  You probably need to select a different build tool.
-- Configuring incomplete, errors occurred!
No such file or directory
CMake Error: Generator: execution of make failed. Make command was:  &&

Names has been changed as stated above:

Image adding _unaligned suffix. Changing the name in the toolchain or inside: https://github.com/raspberrypi/pico-sdk/blob/ee68c78d0afae2b69c03ae1a72bf5cc267a2d94c/cmake/preload/toolchains/pico_arm_cortex_m33_clang.cmake#L4 so they will correspond again is sufficient to make it compile again without any errors.

PS. It is a workaround, but I throw everything but armv6m and armv8m soft hard anyway, to get rid of 2 GB of a dead weight, so changing names there is good enough for me.

matsobdev avatar Jun 19 '25 17:06 matsobdev

"treats x as y" != "x has been renamed to y" :-) but ok, understand now, thanks

kilograham avatar Jun 19 '25 17:06 kilograham

Bad wording of mine, I'm still learning :D

matsobdev avatar Jun 19 '25 17:06 matsobdev

fix merged into develop

kilograham avatar Jun 30 '25 13:06 kilograham