public inbox for openembedded-core@lists.openembedded.org
 help / color / mirror / Atom feed
* Error running GO-lang executable on target device
@ 2020-04-05 12:11 salman.isd
  0 siblings, 0 replies; only message in thread
From: salman.isd @ 2020-04-05 12:11 UTC (permalink / raw)
  To: openembedded-core

[-- Attachment #1: Type: text/plain, Size: 1211 bytes --]

I am trying to run the yocto go example on my arm target device. This is the receipe I am using https://git.yoctoproject.org/cgit.cgi/poky/plain/meta/recipes-extended/go-examples/go-helloworld_0.1.bb
I made one change to the recipe. I added GO_LINKSHARED="" which removes the runtime dependecy of the package on "go-runtime".
I have used both go 1.12 and go 1.14

The package is built correctly. I transfer and try to run on the device but this error.
./go-helloworld
-sh: ./go-helloworld: No such file or directory

Running file on the binary shows
file go-helloworld
go-helloworld: ELF 32-bit LSB pie executable, ARM, EABI5 version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux.so.3, BuildID[sha1]=b5d8fa526402b35c3233f7ce3e578eb9596d9de8, for GNU/Linux 3.2.0, stripped

There is no ld-linux.so.3 on my device, only ld-linux-armhf.so.3. So I creade a symlink like shown
ld-linux.so.3 -> ld-linux-armhf.so.3

Tried to run my binary again and this time it segfaults.

Does anyone have an idea what might be going on? All my C programs built with yocto refer to the correct ld-linux-armhf.so.3 and run fine.Do I need to install some other go-related stuff before running my program?

[-- Attachment #2: Type: text/html, Size: 1675 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2020-04-05 12:11 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-04-05 12:11 Error running GO-lang executable on target device salman.isd

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox