tinycc-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Tinycc-devel] Beginner issue when linking 7z LZMA SDK to dietlibc


From: Sandro
Subject: Re: [Tinycc-devel] Beginner issue when linking 7z LZMA SDK to dietlibc
Date: Mon, 24 Jan 2022 14:41:06 +0800

Hello Christian

Solved. Dietlibc's start.o is calling stackgap before entering main
for x86_64 by default. Everything goes well if I remove stackgap in
dietfeatures.h.

BR Sandro

Am Fr., 21. Jan. 2022 um 10:59 Uhr schrieb Sandro <sandro.yang@gmail.com>:
>
> Hello Christian
>
> Thanks for the reply! I checked the latest mob tinycc-4e0e9b8.tar.gz.
> The result is the same. :(
>
> What are the differences between gnu ld and tcc linker?
>
> BR Sandro
>
> ————————————————————————————————————
> Hi are you using mob?
> Tcc uses 0.9.27 for almost 4 years now, only mob is supported.
>
> C
>
> -----Original Message-----
> From: Tinycc-devel [mailto:tinycc-devel-bounces+eligis=orange.fr@nongnu.org]
> On Behalf Of Sandro
> Sent: Thursday, January 20, 2022 03:21
> To: tinycc-devel@nongnu.org
> Subject: [Tinycc-devel] Beginner issue when linking 7z LZMA SDK to dietlibc
>
> Hello Everyone
>
> I'm using tcc on sabotage. I use below to link LZMA to dietlibc (the
> start.o and libc.a from dietlibc are in current path):
>
> tcc -nostdlib start.o LzmaUtil.o Alloc.o LzFind.o LzmaEnc.o LzmaDec.o
> 7zFind.o 7zStream.o -L. -lc
>
> Linking succeeds without any error but always segfault when run the a.out.
>
> If I use ld from binutils, a.out can run without any problems.
>
> If adding linker flag -static, there will be the same situation.
>
> Anyone could advise on how to fix this? Thank you very much!
>
> Versions:
> tcc-0.9.27.tar.bz2
> dietlibc-0.34.tar.xz
> lzma1900.7z
> sabotage-1.1.24-x86_64-desktop-1f74666.img.xz
>
> Best regards
> Sandro Yang



reply via email to

[Prev in Thread] Current Thread [Next in Thread]