Project Home
Project Home
Documents
Documents
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - Addr2line - Utility error: (9 Items)
   
Addr2line - Utility error  
Haiii, 

In my project am trying to use "addr2line" command, which is specified in below link,

https://www.qnx.com/developers/docs/7.0.0/#com.qnx.doc.neutrino.utilities/topic/a/addr2line.html


But it's showing error "addr2line_variant: cannot execute - No such file or directory".


Can you help mle why this error is coming and how to solve the same?


Thank you.... In advance
Re: Addr2line - Utility error  
Hi,

please read the documentation carefully:


 where addr2line_variant depends on the target platform, as follows:

Target platform addr2line_variant
ARMv7   ntoarmv7-addr2line
AArch64 ntoaarch64-addr2line
x86     ntox86-addr2line
x86 64-bit      ntox86_64-addr2line

you need to use one of the nto*-addr2line binaries.

HTH
On Tue, 2018-07-24 at 03:09 -0400, Sai Devasani wrote:

Haiii,

In my project am trying to use "addr2line" command, which is specified in below link,

https://www.qnx.com/developers/docs/7.0.0/#com.qnx.doc.neutrino.utilities/topic/a/addr2line.html


But it's showing error "addr2line_variant: cannot execute - No such file or directory".


Can you help mle why this error is coming and how to solve the same?


Thank you.... In advance



_______________________________________________

OSTech
http://community.qnx.com/sf/go/post118993
To cancel your subscription to this discussion, please e-mail ostech-core_os-unsubscribe@community.qnx.com<mailto:ostech
-core_os-unsubscribe@community.qnx.com>;

Attachment: HTML sf-attachment-mime36832 2.9 KB
Re: Addr2line - Utility error  
Hai Michael Schuster,

My target platform is "x86 64-bit" and am using "ntox86_64-addr2line", but its giving same error.

The command am using is given in below, 

ntox86_64-addr2line -e <binary> <address>
Re: Addr2line - Utility error  
I believe I've seen something like this before, it turned out to be some form of wrong binary for the platform it was 
running on ... or something similar.

I'd suggest you look closely at the SDP you have installed, the *addr2line* binaries, and what "file" has to say about 
them, and compare that to the platform you're actually trying to run this command, eg on my Linux machine:

$ which ntox86_64-addr2line
.....qnx700/host/linux/x86_64/usr/bin/ntox86_64-addr2line

$ file `which ntox86_64-addr2line`
....qnx700/host/linux/x86_64/usr/bin/ntox86_64-addr2line: symbolic link to x86_64-pc-nto-qnx7.0.0-addr2
line-2.25

$ file `which x86_64-pc-nto-qnx7.0.0-addr2line-2.25`
.....qnx700/host/linux/x86_64/usr/bin/x86_64-pc-nto-qnx7.0.0-addr2line-2.25: ELF 64-bit LSB executable,
x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 3.2.72, not st
ripped

if that doesn't prove conclusive, try 'strace ntox86_64-addr2line' (can't tell how to do that on Windows, I'm afraid)

HTH
On Tue, 2018-07-24 at 04:48 -0400, Sai Devasani wrote

Hai Michael Schuster,

My target platform is "x86 64-bit" and am using "ntox86_64-addr2line", but its giving same error.

The command am using is given in below,

ntox86_64-addr2line -e <binary> <address>



_______________________________________________

OSTech
http://community.qnx.com/sf/go/post118995
To cancel your subscription to this discussion, please e-mail ostech-core_os-unsubscribe@community.qnx.com<mailto:ostech
-core_os-unsubscribe@community.qnx.com>;

Attachment: HTML sf-attachment-mime36836 2.91 KB
Re: Addr2line - Utility error  
Actually am trying to build a utility on target, that can fetch the details from core dump.
 I am executing "ntox86_64-addr2line"  command on target itself.
Re: Addr2line - Utility error  
what I wrote still applies - qnx is POSIX-compliant after all :-)

$ which ntox86_64-addr2line
/usr/bin/ntox86_64-addr2line
$ file `which ntox86_64-addr2line`
/usr/bin/ntox86_64-addr2line: symbolic link to x86_64-pc-nto-qnx7.0.0-addr2line-2.25
$ file `which x86_64-pc-nto-qnx7.0.0-addr2line-2.25`
/usr/bin/x86_64-pc-nto-qnx7.0.0-addr2line-2.25: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically
linked, interpreter /usr/lib/ldqnx-64.so.2, 0 bytes lazy stack, 4096 bytes preallocated stack, BuildID[md5/uuid]=1
dbfa62b31ec82d74b928b4c820727d2, not stripped

$ ntox86_64-addr2line
ntox86_64-addr2line: 'a.out': No such file


On Tue, 2018-07-24 at 05:38 -0400, Sai Devasani wrote:

Actually am trying to build a utility on target, that can fetch the details from core dump.
 I am executing "ntox86_64-addr2line"  command on target itself.




_______________________________________________

OSTech
http://community.qnx.com/sf/go/post118997
To cancel your subscription to this discussion, please e-mail ostech-core_os-unsubscribe@community.qnx.com<mailto:ostech
-core_os-unsubscribe@community.qnx.com>;

Attachment: HTML sf-attachment-mime36840 1.83 KB
Re: Addr2line - Utility error  
We tried "which ntox86_64-addr2line" command on target to locate path of the executable, but we got below message,

"which: no ntox86_64-addr2line in /proc/boot:/bin:/sbin:/usr/bin:/usr/sbin"
Re: Addr2line - Utility error  
in that case, you need to talk to whoever created your image ...

On Wed, 2018-07-25 at 04:26 -0400, Sai Devasani wrote:

We tried "which ntox86_64-addr2line" command on target to locate path of the executable, but we got below message,

"which: no ntox86_64-addr2line in /proc/boot:/bin:/sbin:/usr/bin:/usr/sbin"




_______________________________________________

OSTech
http://community.qnx.com/sf/go/post119005
To cancel your subscription to this discussion, please e-mail ostech-core_os-unsubscribe@community.qnx.com<mailto:ostech
-core_os-unsubscribe@community.qnx.com>;

Attachment: HTML sf-attachment-mime36859 988 bytes
Re: Addr2line - Utility error  
You need to distinguish between host-side tools and target-side tools.
The nto* prefix is typically used for host-side tools, to let the host
system know what the target OS and architecture are. Target tools don't
need those, and will have the non-prefixed version, just like any UNIX-
like system. For example, the Linux compiler for an x86_64 QNX system
is ntox86_64-gcc, but a compiler running on a QNX system is simply gcc.
What you need is to copy 'addr2line' from $QNX_TARGET/<arch>/usr/bin to
/usr/bin on the target.

--Elad

On Tue, 2018-07-24 at 05:38 -0400, Sai Devasani wrote:
> Actually am trying to build a utility on target, that can fetch the
> details from core dump.
>  I am executing "ntox86_64-addr2line"  command on target itself.
> 
> 
> 
> 
> _______________________________________________
> 
> OSTech
> http://community.qnx.com/sf/go/post118997
> To cancel your subscription to this discussion, please e-mail ostech-
> core_os-unsubscribe@community.qnx.com