Openwall GNU/*/Linux - a small security-enhanced Linux distro for servers
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Sun, 2 Dec 2018 19:15:03 +0100
From: Szabolcs Nagy <nsz@...t70.net>
To: musl@...ts.openwall.com
Subject: Re: static linking problem

* argante <argante@...me> [2018-12-02 17:20:15 +0000]:
> ‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐
> On Sunday, 2 December 2018 01:18, Rich Felker <dalias@...c.org> wrote:
> > On Sat, Dec 01, 2018 at 10:07:53PM +0000, argante wrote:
> > > /lib/ld-musl-x86_64.so.1 (0x7ff0dca25000)
> > > libc.so => /lib/ld-musl-x86_64.so.1 (0x7ff0dca25000)
> >
> > This is dynamic-linked, yes. But there's nothing wrong with your
> > static-linked program. If you really don't want pie, use -no-pie or a
> > toolchain that wasn't built to produce pie by default (gcc's
> > --enable-default-pie option at configure time).
...
> I did everything step by step from scratch. Maybe it's a long mail, but shows stages and results.
...
> ./configure \
> 	CFLAGS="-Os -g0" \
> 	CXXFLAGS="${CFLAGS}" \
> 	--enable-languages=c,c++ \
> 	--disable-nls \
> 	--disable-multilib \
> 	--disable-werror \
> 	--disable-libmudflap \
> 	--disable-libsanitizer \
> 	--disable-gnu-indirect-function \
> 	--disable-libmpx \
> 	--disable-libssp \
> 	--disable-symver \
> 	--disable-libgomp \
> 	--disable-fixed-point \
> 	--enable-tls \
> 	--enable-deterministic-archives \
> 	--enable-__cxa_atexit \
> 	--enable-default-pie \
       ^^^^^^^^^^^^^^^^^^^^^
> 	--build=x86_64-linux-musl \
> 	--with-mpc=/usr/local
...
> I still can't understand why musl-cross ldd works correctly, and new toolchain shows such a strange result. Did I overlook something? I even tried -Wl,--no-dynamic-linker.

what do you mean strange?

it seems to work exactly as expected.

Powered by blists - more mailing lists

Your e-mail address:

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.