[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Libunwind-devel] Fwd: question about compiling test-ptrace.c
From: |
Dave Watson |
Subject: |
Re: [Libunwind-devel] Fwd: question about compiling test-ptrace.c |
Date: |
Fri, 23 Jun 2017 09:44:39 -0700 |
User-agent: |
Mutt/1.6.0 (2016-04-01) |
On 06/23/17 11:00 AM, hai huang wrote:
> Just saw that I should post these types of questions to the mailing list
> and cc David. If anyone can help, I'd really appreciate it. Thanks!
>
> -
> Hai
>
> ---------- Forwarded message ----------
> From: hai huang <address@hidden>
> Date: Fri, Jun 23, 2017 at 10:36 AM
> Subject: question about compiling test-ptrace.c
> To: address@hidden
>
>
> Hi David,
>
> I'm trying out libunwind in the context of a ptrace'd process. After
> downloading, compiling, and installing the libunwind library from git, I
> tried to compile tests/test-ptrace.c using the following command:
>
> cd tests
> gcc -I../include -lunwind-ptrace -lunwind-generic -lunwind -o test-ptrace
> test-ptrace.c
IIRC the linker ordering is position-sensitive, this command works for me.
gcc -I../include test-ptrace.c -lunwind-ptrace -lunwind-x86_64 -lunwind -o
test-ptrace