Execute on T2080RDB the application compiled in eclipse on host PC

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Execute on T2080RDB the application compiled in eclipse on host PC

Jump to solution
807 Views
francescocaiazz
Contributor II

Hello, I'm trying to run an HelloWorld application on T2080RDB target.

I used the following instructions to setup eclipse on host PC:

Yocto Application Development Using Eclipse IDE 

After compiled I transfer the binary to target by means of a usb pendrive.

When I try to run it I have the following lines:

-sh: .: ./HelloWorld: cannot execute binary file

Any suggestions about this? What's getting wrong?

0 Kudos
1 Solution
607 Views
Pavel
NXP Employee
NXP Employee

Test your board using static library for your software.

Use similar command for gcc:

$CC test.c --static -o test.elf


Have a great day,
Pavel Chubakov

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

View solution in original post

0 Kudos
3 Replies
608 Views
Pavel
NXP Employee
NXP Employee

Test your board using static library for your software.

Use similar command for gcc:

$CC test.c --static -o test.elf


Have a great day,
Pavel Chubakov

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos
607 Views
francescocaiazz
Contributor II

Problem solved. I copied the file under root and changed permissions to 777.

It works.

B.R.

0 Kudos
607 Views
francescocaiazz
Contributor II

Hello,

thanks for the reply.

On host PC I compiled with the command you suggested to use, but when trying to execute I obtain

root@t2080rdb:/run/media/sda1# ./Hello.elf
-sh: ./Hello.elf: Permission denied

sudo command doesn't work on T2080rdb. 

Which is the cause of such behavior?

0 Kudos