Project

General

Profile

Start Guide : Cannot build helloworld application with eclipse

Added by minh tung over 6 years ago

Hello,
I am using Virtual Box and MityDSP-L138_SDK_2012_06_13.eva image.
When I following Start Guide instruction step by step.
(1) Install Gcc toolchain 4.5.4
(2) Update Eclipse CDT

But when I build HelloWorld Application I get some errors

(1) Error launching external scanner info generator (arm-angstrom-linux-gnueabi-g++ -E -P -v -dD /home/tungdm/workspace/.metadata/.plugins/org.eclipse.cdt.make.core/specs.cpp) HelloWorld Unknown C/C++ Problem
(2) Error launching external scanner info generator (g++ -E -P -v -dD /home/tungdm/workspace/.metadata/.plugins/org.eclipse.cdt.make.core/specs.cpp) HelloWorld Unknown C/C++ Problem

Can you help me to resolve that issues.

Thanks


Replies (7)

RE: Start Guide : Cannot build helloworld application with eclipse - Added by Gregory Gluszek over 6 years ago

Hello,

Have you run the environment setup script:

user@desktop->. /usr/local/oecore-i686/environment-setup-armv5te-angstrom-linux-gnueabi

And when in a terminal in your VM, if you run the following command:

mitydspl138@vm$ arm-angstrom-linux-gnueabi-gcc -v

What response do you see?

Thanks,
\Greg

RE: Start Guide : Cannot build helloworld application with eclipse - Added by Doug Browning about 5 years ago

I'm working through the Starter Guide for the MityDSP-L138 configured with
- VirtualBox 4.3.0 (could not get MityDSP VM with VB 4.3.14 to load on Win7 laptop without errors)
- MityDSP-L138-SDK.ova installed from DVD
- Ubuntu 10.04.4 LTS
- GCC cross-compiler version 4.5.4 (from GCC Toolchain link)
- GCC compiler version 4.4.3 (Ubuntu 4.4.3-4ubuntu5.1)
- Updated Eclipse
- Installed BSP MDK using Release_2014-01-13.run
- Verified Environment and Settings variables in Eclipse per Starter Guide

So far have I've successfully compiled and run Hello World for the native compiler (GCC 4.4.3).

I can also compile a Hello World source file (verified the existence of the binary) for the ARM cross-compiler, but with the same warning as in the prior posting:
"Error launching external scanner info generator (arm-angstrom-linux-gnueabi-g++ -E -P -v -dD /home/mitydsp/workspace/.metadata/.plugins/org.eclipse.cdt.make.core/specs.cpp) Hello World CC Unknown C/C++ Problem"

Eclipse Discovery Options settings look like:
Compiler Invocation Command: arm-angstrom-linux-gnueabi-g++
Compiler Invocation Arguments: -E -P -v -dD ${plugin_state_location}/specs.cpp

After checking the specs.cpp file, I see that it's empty. Is this expected? An indication I haven't configured something properly along the way?

I've also run the environment setup script (I do not see any messages in the terminal window after running the script):
"mitydspl138@vm$ . /usr/local/oecore-i686/environment-setup-armv5te-angstrom-linux-gnueabi"
But when I run the version script
"mitydspl138@vm$ arm-angstrom-linux-gnueabi-gcc -v"
I do see the extensive listing in the terminal window ending with
gcc version 4.5.4 20120305 (prerelease) (GCC)

Has anyone seen this warning before and eliminated it for their cross-compiler configuration?
Also- any inconsistency/incompatibility on how the VM and toolchains are configured?
Would like to have confidence in config before going on to working on target ARM processor comm/download interface.

Thanks,
Doug

RE: Start Guide : Cannot build helloworld application with eclipse - Added by Doug Browning about 5 years ago

Jonathan,
Thanks for the reply.
Yes, I’ve followed the Starter Guide. Spent most of last week working through it. Issues w/ Virtual Box and the tool chain slowed me down a bit.

First time checking whether tool chain was installed (mitydspl138@vm$ arm-angstrom-linux-gnueabi-gcc –v) , received "command not found"

Then, following Starter Guide tool chain sourcing command (mitydspl138@vm$ . /usr/local/oecore-i686/environment-setup-armv5te-angstrom-linux-gnueabi), received "no such file or directory"

So I used the Wiki GCC Toolchain site and installed the 32-bit Aug-2012 SDK Tarball according to web site procedures. Tarball File: angstrom-eglibc-i686-armv5te-toolchain-qte-v2012.05.tar.bz2
After installing the cross-compiler (v 4.5.4), I verified the install using the above command (arm-angstrom-linux-gnueabi-bcc –v)

Along the way I did install the most recent MityDSP-L138 BSP package from the “Files” Wiki site (Release_2014-01-13.run).

At this point I can compile and run HelloWorld with the native compiler (4.4.3) and can cross-compile w/ the warning :
Error launching external scanner info generator (arm-angstrom-linux-gnueabi-g++ -E -P -v -dD /home/mitydsp/workspace/.metadata/.plugins/org.eclipse.cdt.make.core/specs.cpp)

I’ve also attempted to load and run the executable on the ARM core according the Starter Guide. During the opkg update and install segments, I was unable to execute the “sed –i … “ script but found the instructions on the SW Forum to edit the url paths in the feed.conf files in the target /etc/opkg directory.
After verifying that the executable HelloWorldCC was in the /tmp directory, I tried to run it (from the serial port interface) and received this error:

root@mityomapl138:/var/volatile/tmp# ./HelloWorldCC
./HelloWorldCC: /usr/lib/libstdc++.so.6: version `CXXABI_ARM_1.3.3' not found (required by ./HelloWorldCC)

Not sure if this is a shared object problem between host and target environments as I’m not an experienced embedded linux developer.
I’d appreciate any guidance or suggestions to fix these issues.

Thanks,
Doug

RE: Start Guide : Cannot build helloworld application with eclipse - Added by Jonathan Cormier about 5 years ago

root@mityomapl138:/var/volatile/tmp# ./HelloWorldCC
./HelloWorldCC: /usr/lib/libstdc++.so.6: version `CXXABI_ARM_1.3.3' not found (required by ./HelloWorldCC)

It looks like your using the old filesystem with the new compiler. Which will cause these shared object errors. The latest filesystem can be found in the MDK. Or you can use the older toolchain v4.3.3 with your current filesystem. Note that with the newer filesystem you shouldn't have to fix the opkg feed.

RE: Start Guide : Cannot build helloworld application with eclipse - Added by Doug Browning about 5 years ago

After using the older toolchain v4.3.3 and existing ARM filesystem, I was able to get the HelloWorld executable to run on the ARM.

I needed to set up the environment for the v4.3.3 toolchain:

Environment Setup for ToolChains 4.3.3 and below:
mitydsp@mitydsp$. /usr/local/angstrom/arm/environment-setup

(I found this information on the GCC Toolchain page, as well as helpful info on the SW Forum thread "DSP Hello World won't link")

Then, in Eclipse, modified the Environment and Settings Variables to point to the v4.3.3 toolchain:
Project --> Properties --> C/C++ Build -->Environment , Settings --> Path (for Debug and Release)
/usr/angstrom/arm/arm-angstrom-linux-gnueabi/bin
Note: (“Prefix” in Settings window remains same – “arm-angstrom-linux-gnueabi-“ )

After compiling and downloading executable to the ARM core, was able to confirm "HelloWorld" in the terminal window.

I'm still getting the "Error launching external scanner info generator..." warning and haven't found a way to eliminate that.

I would appreciate a reference for procedures on how to update the filesystem on the ARM processor to be able to use the newer v4.5.4 cross compiler.

Thanks for the help -
Doug

    (1-7/7)
    Add picture from clipboard (Maximum size: 500 MB)