Skip to content

Commit

Permalink
xorg-3.eclass: strip -fno-plt from *FLAGS
Browse files Browse the repository at this point in the history
As discussed in #778494, the GCC flag -fno-plt will break lazy
binding, which appears to still be necessary for Xorg. Stripping the
offending flag out is the next best solution for reliable user
experience on Gentoo.

Closes: https://bugs.gentoo.org/778494
Signed-off-by: Niklāvs Koļesņikovs <89q1r14hd@relay.firefox.com>
  • Loading branch information
pinkflames committed Mar 28, 2021
1 parent 53f894f commit bb0f1de
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions eclass/xorg-3.eclass
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 1999-2020 Gentoo Authors
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

# @ECLASS: xorg-3.eclass
Expand Down Expand Up @@ -327,7 +327,7 @@ xorg-3_flags_setup() {
[[ ${CHOST} == *-winnt* ]] && append-cppflags -DWIN32 -D__STDC__
# hardened ldflags
[[ ${PN} == xorg-server || ${PN} == xf86-video-* || ${PN} == xf86-input-* ]] \
&& append-ldflags -Wl,-z,lazy
&& filter-flags -fno-plt && append-ldflags -Wl,-z,lazy

# Quite few libraries fail on runtime without these:
if has static-libs ${IUSE//+}; then
Expand Down

0 comments on commit bb0f1de

Please sign in to comment.