https://kotlinlang.org logo
#compiler
Title
# compiler
n

napperley

03/09/2023, 10:32 PM
When generating a static library file with
kotlinc-native -no-endorsed-libs -p static -target rp2040 src
an obscure error appears (about missing tool chain )
Copy code
Produced library API in static_api.h
error: compilation failed: The /home/napperley/.konan/dependencies/llvm-11.1.0-linux-x64-essentials/bin/clang++ command returned non-zero exit code: 1.
output:
clang-11: warning: argument unused during compilation: '--gcc-toolchain=/home/napperley/.konan/dependencies/arm-gnu-toolchain-12.2.rel1-x86_64-arm-none-eabi' [-Wunused-command-line-argument]
/tmp/konan_temp5064211914009885466/api.cpp:118:10: fatal error: 'exception' file not found
#include <exception>
         ^~~~~~~~~~~
1 error generated.
From my limited understanding clang should recognise the
--gcc-toolchain
argument, however there have been some cases reported on the Internet where clang ignores the argument for some bizarre reason.
Attached is the log file.
How do I get clang to find the exception.h file? With the official ARM Embedded GCC tool chain there is a exception.h file located in arm-none-eabi/include/c++/12.2.1/bits.
10 Views