04-08-2014 10:56 AM
Hi there!
I am trying to set up the C Code Environment but I run into trouble when trying to compile one of the example projects. In general, I followed the instructions within C Support for NI myRIO 1.0 User Guide.
I have been trying this for a while and I am getting the feeling that it is something very simple (but critical), so I am kindly asking for someone's help who has experience with the C Coding Environment.
The error message I get is simply:
17:42:06 **** Rebuild of configuration Debug for project myRIO Example - PWM ****
Info: Internal Builder is used for build
arm-none-linux-gnueabi-gcc -DMyRio_1900 "-IC:\\Users\\boewie\\workspace\\myRIO\\C Support for NI myRIO\\source" -O0 -g3 -Wall -c -fmessage-length=0 -o main.o "..\\main.c"
arm-none-linux-gnueabi-gcc: CreateProcess: No such file or directory
17:42:06 Build Finished (took 98ms)
Further, in the code editor it says "Unresolved inclusion: [...]" to
#include <stdio.h>
#include <time.h>
Is it possible that the C/C++ standard headers are not properly setup? I have cygwin and MS Visual Studio installed.
The cross compiler can be invoked from the Windows command console, so I assume that the PATH variable is set up correctly.
Do I need to install any generic C/C++ build tools?
Are the spaces withing the C API path critical?
Thanks in advance!
-bowie
Solved! Go to Solution.
04-09-2014 09:17 AM
Hello boewie,
I dont think, that you need to install generic C/C++ build tools or the spaces withing the C API path are critical. What i can see in the first place is that there is no reference to the libary folder so the enviromnment can't find the librarys (even if they are standard).
Maybe this link will help you => http://stackoverflow.com/questions/13482927/cdt-visual-c-support-errors
04-09-2014 09:56 AM - last edited on 01-04-2024 01:03 PM by migration-bot
Hey boewie,
Are you using eclipse? If not you should use the C/C++ Development Tools for NI Linux Real-Time, Eclipse Edition 2013 here.
-Sam K
Join / Follow the LabVIEW Hacker Group on google+
04-10-2014 02:19 AM
Hi!
Thanks for the quick replies!
I do use the NI distribution of Eclipse which comes delovered with the arm cross compiler. To this point, I followed the instructions in
http://www.ni.com/tutorial/14625/de/
and
http://www.ni.com/tutorial/14619/de/
to configure the IDE. Apparently, the code-completion/pre-processor from ecplipse doesn't know the correct paths to the headers. I assume the above document is not complete regarding paths and symbols to be defined in Ecplipse. I will try now to set them up as described here:
http://help.eclipse.org/indigo/index.jsp?topic=/org.eclipse.cdt.doc.user/tasks/cdt_t_proj_paths.htm
I will provide a status update soon.
-bøwie
04-10-2014 06:23 AM
Ok, I reached the next stage. This is what I did:
1) I told Ecplipse the correct include paths (the tutorials omits this step). This solved the unresolved inclusions.
2) Also, I installed the GNU Core Utils for Windows (version 5.3.0). the command rm is required for a clean up of the project.
3) I copied the three files cc1.exe, cc1++.exe and collect2.exe from
C:\Program Files (x86)\National Instruments\Eclipse\toolchain\gcc-4.4-arm\i386\libexec\gcc\arm-none-linux-gnueabi\4.4.1
into
C:\Program Files (x86)\National Instruments\Eclipse\toolchain\gcc-4.4-arm\i386\arm-none-linux-gnueabi\bin
Now, the assembler seems to have issues:
13:25:09 **** Incremental Build of configuration Debug for project myRIO Example - PWM ****
Info: Internal Builder is used for build
arm-none-linux-gnueabi-gcc -DMyRio_1900 "-IC:\\Users\\heinbokel\\workspace\\myRIO\\C Support for NI myRIO\\source" "-IC:\\Program Files (x86)\\National Instruments\\Eclipse\\toolchain\\gcc-4.4-arm\\i386\\arm-none-linux-gnueabi\\libc\\usr\\include" "-IC:\\Program Files (x86)\\National Instruments\\Eclipse\\toolchain\\gcc-4.4-arm\\i386\\lib\\gcc\\arm-none-linux-gnueabi\\4.4.1\\include" -O0 -g3 -Wall -c -fmessage-length=0 -ansi -o PWM.o "..\\PWM.c"
Assembler messages:
Fatal error: invalid listing option `r'
13:25:10 Build Finished (took 354ms)
Any Ideas?
Thanks for your help!
-bøwie
04-10-2014 07:29 AM
here's the verbose compiler lof output:
14:31:34 **** Rebuild of configuration Debug for project myRIO Example - PWM ****
Info: Internal Builder is used for build
arm-none-linux-gnueabi-gcc -DMyRio_1900 "-IC:\\Users\\heinbokel\\workspace\\myRIO\\C Support for NI myRIO\\source" "-IC:\\Program Files (x86)\\National Instruments\\Eclipse\\toolchain\\gcc-4.4-arm\\i386\\arm-none-linux-gnueabi\\libc\\usr\\include" "-IC:\\Program Files (x86)\\National Instruments\\Eclipse\\toolchain\\gcc-4.4-arm\\i386\\lib\\gcc\\arm-none-linux-gnueabi\\4.4.1\\include" -O0 -g3 -Wall -c -fmessage-length=0 -v -ansi -o "C_Support\\NiFpga.o" "..\\..\\C Support for NI myRIO\\source\\NiFpga.c"
Using built-in specs.
Target: arm-none-linux-gnueabi
Configured with: /scratch/julian/2010q1-release-linux-lite/src/gcc-4.4-2010q1/configure --build=i686-pc-linux-gnu --host=i686-mingw32 --target=arm-none-linux-gnueabi --enable-threads --disable-libmudflap --disable-libssp --disable-libstdcxx-pch --enable-extra-sgxxlite-multilibs --with-arch=armv5te --with-gnu-as --with-gnu-ld --with-specs='%{funwind-tables|fno-unwind-tables|mabi=*|ffreestanding|nostdlib:;:-funwind-tables} %{O2:%{!fno-remove-local-statics: -fremove-local-statics}} %{O*:%{O|O0|O1|O2|Os:;:%{!fno-remove-local-statics: -fremove-local-statics}}}' --enable-languages=c,c++ --enable-shared --disable-lto --enable-symvers=gnu --enable-__cxa_atexit --with-pkgversion='Sourcery G++ Lite 2010q1-202' --with-bugurl=https://support.codesourcery.com/GNUToolchain/ --disable-nls --prefix=/opt/codesourcery --with-sysroot=/opt/codesourcery/arm-none-linux-gnueabi/libc --with-build-sysroot=/scratch/julian/2010q1-release-linux-lite/install/host-i686-mingw32/arm-none-linux-gnueabi/libc --with-libiconv-prefix=/scratch/julian/2010q1-release-linux-lite/obj/host-libs-2010q1-202-arm-none-linux-gnueabi-i686-mingw32/usr --with-gmp=/scratch/julian/2010q1-release-linux-lite/obj/host-libs-2010q1-202-arm-none-linux-gnueabi-i686-mingw32/usr --with-mpfr=/scratch/julian/2010q1-release-linux-lite/obj/host-libs-2010q1-202-arm-none-linux-gnueabi-i686-mingw32/usr --with-ppl=/scratch/julian/2010q1-release-linux-lite/obj/host-libs-2010q1-202-arm-none-linux-gnueabi-i686-mingw32/usr --with-host-libstdcxx='-static-libgcc -Wl,-Bstatic,-lstdc++,-Bdynamic -lm' --with-cloog=/scratch/julian/2010q1-release-linux-lite/obj/host-libs-2010q1-202-arm-none-linux-gnueabi-i686-mingw32/usr --disable-libgomp --enable-poison-system-directories --with-build-time-tools=/scratch/julian/2010q1-release-linux-lite/obj/tools-i686-pc-linux-gnu-2010q1-202-arm-none-linux-gnueabi-i686-mingw32/arm-none-linux-gnueabi/bin --with-build-time-tools=/scratch/julian/2010q1-release-linux-lite/obj/tools-i686-pc-linux-gnu-2010q1-202-arm-none-linux-gnueabi-i686-mingw32/arm-none-linux-gnueabi/bin
Thread model: posix
gcc version 4.4.1 (Sourcery G++ Lite 2010q1-202)
COLLECT_GCC_OPTIONS='-DMyRio_1900' '-IC:\Users\heinbokel\workspace\myRIO\C Support for NI myRIO\source' '-IC:\Program Files (x86)\National Instruments\Eclipse\toolchain\gcc-4.4-arm\i386\arm-none-linux-gnueabi\libc\usr\include' '-IC:\Program Files (x86)\National Instruments\Eclipse\toolchain\gcc-4.4-arm\i386\lib\gcc\arm-none-linux-gnueabi\4.4.1\include' '-O0' '-g3' '-Wall' '-c' '-fmessage-length=0' '-v' '-ansi' '-o' 'C_Support\NiFpga.o' '-march=armv5te' '-funwind-tables'
cc1 -quiet -v -IC:\Users\heinbokel\workspace\myRIO\C Support for NI myRIO\source -IC:\Program Files (x86)\National Instruments\Eclipse\toolchain\gcc-4.4-arm\i386\arm-none-linux-gnueabi\libc\usr\include -IC:\Program Files (x86)\National Instruments\Eclipse\toolchain\gcc-4.4-arm\i386\lib\gcc\arm-none-linux-gnueabi\4.4.1\include -iprefix c:\progra~2\egcs\lib\gcc-lib\arm-none-linux-gnueabi/4.4.1/ -isysroot c:\program files (x86)\national instruments\eclipse\toolchain\gcc-4.4-arm\i386\bin\../arm-none-linux-gnueabi/libc -dD -DMyRio_1900 ..\..\C Support for NI myRIO\source\NiFpga.c -quiet -dumpbase NiFpga.c -march=armv5te -ansi -auxbase-strip C_Support\NiFpga.o -g3 -O0 -Wall -ansi -version -fmessage-length=0 -funwind-tables -o C:\Users\HEINBO~1\AppData\Local\Temp\ccer4xKK.s
ignoring nonexistent directory "c:\progra~2\egcs\lib\gcc-lib\arm-none-linux-gnueabi/4.4.1/include"
ignoring nonexistent directory "c:\progra~2\egcs\lib\gcc-lib\arm-none-linux-gnueabi/4.4.1/include-fixed"
ignoring nonexistent directory "c:\progra~2\egcs\lib\gcc-lib\arm-none-linux-gnueabi/4.4.1/../../../../arm-none-linux-gnueabi/include"
ignoring nonexistent directory "c:\program files (x86)\national instruments\eclipse\toolchain\gcc-4.4-arm\i386\bin\../arm-none-linux-gnueabi/libc/opt/codesourcery/lib/gcc/arm-none-linux-gnueabi/4.4.1/../../../../include"
ignoring nonexistent directory "c:/progra~2/egcs/lib/gcc-lib/../../lib/gcc/arm-none-linux-gnueabi/4.4.1/include"
ignoring nonexistent directory "c:/progra~2/egcs/lib/gcc-lib/../../lib/gcc/arm-none-linux-gnueabi/4.4.1/include-fixed"
ignoring nonexistent directory "c:/progra~2/egcs/lib/gcc-lib/../../lib/gcc/arm-none-linux-gnueabi/4.4.1/../../../../arm-none-linux-gnueabi/include"
ignoring duplicate directory "C:\Program Files (x86)\National Instruments\Eclipse\toolchain\gcc-4.4-arm\i386\arm-none-linux-gnueabi\libc\usr\include"
as it is a non-system directory that duplicates a system directory
#include "..." search starts here:
#include <...> search starts here:
C:\Users\heinbokel\workspace\myRIO\C Support for NI myRIO\source
C:\Program Files (x86)\National Instruments\Eclipse\toolchain\gcc-4.4-arm\i386\lib\gcc\arm-none-linux-gnueabi\4.4.1\include
c:\program files (x86)\national instruments\eclipse\toolchain\gcc-4.4-arm\i386\bin\../arm-none-linux-gnueabi/libc/usr/include
End of search list.
GNU C (Sourcery G++ Lite 2010q1-202) version 4.4.1 (arm-none-linux-gnueabi)
compiled by GNU C version 4.3.2, GMP version 4.3.1, MPFR version 2.4.2.
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
Compiler executable checksum: 97312c89a49cb03409c16bf385cf880c
COLLECT_GCC_OPTIONS='-DMyRio_1900' '-IC:\Users\heinbokel\workspace\myRIO\C Support for NI myRIO\source' '-IC:\Program Files (x86)\National Instruments\Eclipse\toolchain\gcc-4.4-arm\i386\arm-none-linux-gnueabi\libc\usr\include' '-IC:\Program Files (x86)\National Instruments\Eclipse\toolchain\gcc-4.4-arm\i386\lib\gcc\arm-none-linux-gnueabi\4.4.1\include' '-O0' '-g3' '-Wall' '-c' '-fmessage-length=0' '-v' '-ansi' '-o' 'C_Support\NiFpga.o' '-march=armv5te' '-funwind-tables'
as -v -IC:\Users\heinbokel\workspace\myRIO\C Support for NI myRIO\source -IC:\Program Files (x86)\National Instruments\Eclipse\toolchain\gcc-4.4-arm\i386\arm-none-linux-gnueabi\libc\usr\include -IC:\Program Files (x86)\National Instruments\Eclipse\toolchain\gcc-4.4-arm\i386\lib\gcc\arm-none-linux-gnueabi\4.4.1\include -march=armv5te -meabi=5 -o C_Support\NiFpga.o C:\Users\HEINBO~1\AppData\Local\Temp\ccer4xKK.s
GNU assembler version 980830 (i386-mingw32) using BFD version 980830
Assembler messages:
Fatal error: invalid listing option `r'
14:31:35 Build Finished (took 1s.67ms)
04-11-2014 04:06 AM
My current problem is
arm-none-linux-gnueabi-gcc: selected multilib '.' not installed
For some reason my system won't compile...
can anybody help?
-boewie
04-15-2014 06:41 AM
May this will help => http://sourceforge.net/projects/mingw-w64/
04-15-2014 10:06 AM
that was it! I installed the MinGW-w64 - for 32 and 64 bit Windows files and it works!
Thank you all!
-bowie
04-16-2014 01:23 AM
Thats great to hear!