mailing list of musl libc
 help / color / mirror / code / Atom feed
* Segmentation fault in static binaries built with recent binutils
@ 2018-07-18 16:39 Reiner Herrmann
  2018-07-18 17:37 ` Rich Felker
  2018-07-18 18:14 ` Reiner Herrmann
  0 siblings, 2 replies; 11+ messages in thread
From: Reiner Herrmann @ 2018-07-18 16:39 UTC (permalink / raw)
  To: musl

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

Hi,

Debian recently updated binutils from 2.30 to 2.31.
When compiling simple static binaries with musl (1.19 and git)
they segfault on startup (dynamic linking still works fine).
With the previous binutils version it is running successfully.

  $ cat test.c 
  int main() { return 0; }
  $ musl-gcc -ggdb3 -O0 -static test.c
  $ gdb ./a.out 
  GNU gdb (Debian 8.1-3) 8.1
  [...]
  Reading symbols from ./a.out...done.
  (gdb) run
  Starting program: /tmp/test/a.out 
  
  Program received signal SIGSEGV, Segmentation fault.
  0x000000000040159d in static_init_tls ()
  (gdb) bt
  #0  0x000000000040159d in static_init_tls ()
  #1  0x0000000000000000 in ?? ()

See also: https://ci.debian.net/packages/m/musl/unstable/amd64/

Is this a bug in musl or should I report it to binutils?

Kind regards,
   Reiner

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2018-07-18 21:49 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-07-18 16:39 Segmentation fault in static binaries built with recent binutils Reiner Herrmann
2018-07-18 17:37 ` Rich Felker
2018-07-18 18:14 ` Reiner Herrmann
2018-07-18 19:00   ` Szabolcs Nagy
2018-07-18 19:38     ` Szabolcs Nagy
2018-07-18 20:19       ` Szabolcs Nagy
2018-07-18 20:24         ` Szabolcs Nagy
2018-07-18 20:50         ` Rich Felker
2018-07-18 20:53         ` Reiner Herrmann
2018-07-18 21:37           ` Szabolcs Nagy
2018-07-18 21:49             ` Reiner Herrmann

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/musl/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).