[yocto] Trouble with yocto sdk in collaboration with eclipse and cmake
Hartwig, Guido
g.hartwig at kostal.com
Fri Jul 29 01:27:09 PDT 2016
Hi,
I have some trouble with the yocto sdk in collaboration with eclipse and yocto CMake project. I have install all necessary eclipse plugins and linked my sdk with the yocto-plugin as described in the manual. When I try to build the "Hello World" yocto cmake project it fails with following message:
..
CMake Error at /usr/share/cmake-2.8/Modules/CMakeTestCCompiler.cmake:61 (message): The C compiler
"/opt/puck/1.0.0/sysroots/x86_64-pucksdk-linux/usr/bin/arm-kostal-linux-gnueabi/arm-kostal-linux-gnueabi-gcc"
is not able to compile a simple test program
...
This error occurs because the compiler is called with the wrong flags.
The SDK environment-setup script export the following environment variables
export CC="arm-kostal-linux-gnueabi-gcc -march=armv7-a -marm -mfpu=neon -mfloat-abi=hard -mcpu=cortex-a8 --sysroot=$SDKTARGETSYSROOT"
export CFLAGS=" -O2 -pipe -g -feliminate-unused-debug-types -fdebug-prefix-map=/home/hartwig02/Workspace/build-puck/build/tmp/work/x86_64-nativesdk-pucksdk-linux/meta-environment-scb/1.0-r8=/usr/src/debug/meta-environment-scb/1.0-r8 -fdebug-prefix-map=/home/hartwig02/Workspace/build-puck/build/tmp/sysroots/x86_64-linux= -fdebug-prefix-map=/home/hartwig02/Workspace/build-puck/build/tmp/sysroots/x86_64-nativesdk-pucksdk-linux= "
The eclipse environment (set by the yocto plugin) shows the following environment:
CC = arm-kostal-linux-gnueabi-gcc -march=armv7-a -marm -mfpu=neon -mfloat-abi=hard -mcpu=cortex-a8 --sysroot=/opt/puck/1.0.0/sysroots/cortexa8hf-neon-kostal-linux-gnueabi
CFLAGS = --sysroot=/opt/puck/1.0.0/sysroots/cortexa8hf-neon-kostal-linux-gnueabi
OECMAKE_C_COMPILER = arm-kostal-linux-gnueabi-gcc
OECMAKE_C_FLAGS = --sysroot=/opt/puck/1.0.0/sysroots/cortexa8hf-neon-kostal-linux-gnueabi
I assume that yocto cmake uses the OECMAKE* variables to build the program.
The error occurs because the following compiler options (Tunes) are missing "-march=armv7-a -marm -mfpu=neon -mfloat-abi=hard -mcpu=cortex-a8"
Now my questions
1. Is it right that the yocto plugin cuts off the tunes from the OECMAKE_C_COMPILER?
2. Is there a reason that this compiler options are not appended to the CFLAGS?
Thank you for your help
Mit freundlichen Grüßen / Kind regards
KOSTAL Industrie Elektrik GmbH
Dipl.-Ing.
Guido Hartwig
IE1 Entwicklung Elektronik
R & D Electronics
Lange Eck 11, 58099 Hagen
Deutschland / Germany
Telefon: +49 2331 8040 - 688
Telefax: +49 2331 8040 - 4660
E-Mail: g.hartwig at kostal.com
Internet: http://www.kostal.com/industrie
KOSTAL Industrie Elektrik GmbH - Sitz Lüdenscheid, Registergericht Iserlohn HRB 3924 - USt-Id-Nr./Vat No.: DE 813742170
Postanschrift: An der Bellmerei 10, D-58513 Lüdenscheid * Telefon: +49 2351 16-0 * Telefax: +49 2351 16-2400
Werksanschrift: Lange Eck 11, D-58099 Hagen * Tel. +49 2331 8040-601 * Fax +49 2331 8040-602
Geschäftsführung: Axel Zimmermann, Dipl.-Ing. Marwin Kinzl, Dipl.-Oec. Andreas Kostal
More information about the yocto
mailing list