[Issue 19116] dmd compiles binary but segfaults immediately when run on Ubuntu / Debian 32Bit architectures

d-bugmail at puremagic.com d-bugmail at puremagic.com
Fri Nov 1 18:37:16 UTC 2019


https://issues.dlang.org/show_bug.cgi?id=19116

Silvercircle <silvercircle at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |silvercircle at gmail.com

--- Comment #13 from Silvercircle <silvercircle at gmail.com> ---
The issue is still valid on a fresh install of 32bit Debian 10.1 (Buster i686)
with most recent DMD (DMD 2.088.1 as of now) downloaded from dlang.org.

However, it only happens when linking with the default linker (which is still
the bfd variant on Debian i686). I've set ld.gold as default linker and this
seems to fix the problem with the crashes.

No issue so far with a couple of projects of different size.

Works:
[alex at nexus:/home/alex]$>ld --version
> GNU gold (GNU Binutils for Debian 2.31.1) 1.16

Does not work (all executables crash with SIGSEGV on start).
Affects both debug and release builds
> GNU ld (GNU Binutils for Debian) 2.31.1
> Copyright (C) 2018 Free Software Foundation, Inc.

ld.gold is installed on Debian but not set as default. It can be used by either
passing -fuse-ld=gold to the linker or by using update-alternatives to set
ld.gold as system-wide default.

sudo update-alternatives --install "/usr/bin/ld" "ld" "/usr/bin/ld.gold" 20
sudo update-alternatives --install "/usr/bin/ld" "ld" "/usr/bin/ld.bfd" 10

--


More information about the Digitalmars-d-bugs mailing list