Using the S32K toolchain with cmake - Fatal error: lib_c99.prefix : No such file or directory

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Using the S32K toolchain with cmake - Fatal error: lib_c99.prefix : No such file or directory

ソリューションへジャンプ
2,509件の閲覧回数
gberthiaume
Contributor III

Hi,

I'm looking for guidance about how to use the S32K toolchain.

Context

I'm trying to use the S32K Linux (Ubuntu 16) arm-none-eabi build tools to compile my project.
I'm using CMake and Make to do so.

Currently, the build system fails at the "check for working C compiler" step. The exact error message is:

cc1: fatal error: lib_c99.prefix: No such file or directory

Of course, this file exists in my build_tools directory:

 

$  find /usr/local/build_tools/arm32_ewl2 | grep lib_c99
/usr/local/build_tools/arm32_ewl2/EWL_C/include/lib_c99.prefix

 

While the CMake toolchain file could be the cause of this problem, my compiler flags seem identical to the one used when compiling the project with the S32 DS IDE:

usr/local/build_tools/gcc-6.3-arm32-eabi/bin/arm-none-eabi-gcc -c -fmessage-length=0 -ffunction-sections -fdata-sections -mcpu=cortex-m4 -mthumb -specs=ewl_c9x_noio.specs --sysroot="/usr/local/build_tools/arm32_ewl2" -mfloat-abi=hard -mfpu=fpv4-sp-d16 -fdata-sections -ffunction-sections -o CMakeFiles/cmTC_ee422.dir/testCCompiler.c.obj -c /root/nBMSMv2_Tools/myproject/build/CMakeFiles/CMakeTmp/testCCompiler.c

I think the problem might reside in my environment setup.
Here's my build_tools tree:

 

/usr/local/build_tools/
|-- arm32_ewl2  # <-------- SYSROOT
|   |-- Build_Tag.txt
|   |-- Doxyfile
|   |-- EWL_C
|   |-- EWL_C++
|   |-- EWL_ReleaseNotes
|   |-- EWL_Runtime
|   |-- lib
|   `-- makefile
`-- gcc-6.3-arm32-eabi
    |-- arm-none-eabi
    |-- bin
    |-- include
    |-- lib
    |-- libexec
    |-- linux_support
    |-- patches_applied
    `-- share

 


Question

Why can't arm-none-eabi-gcc find the lib_c99.prefix file? 
If all the compilation flags are identical to the one used by the IDE, what did I miss? Is this a question of environment variables?

Thanks.

ATCH. The full CMake log

ラベル(1)
0 件の賞賛
返信
1 解決策
1 返信
2,498件の閲覧回数
gberthiaume
Contributor III
0 件の賞賛
返信