From 541bb02a46aa817953c29c8ffef222bbfb58ebd8 Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Thu, 10 Dec 2020 07:58:46 +0000 Subject: app-emulation/qemu: fix safe-stack feature detection Package-Manager: Portage-3.0.12, Repoman-3.0.2 Signed-off-by: Sergei Trofimovich --- app-emulation/qemu/files/qemu-5.2.0-safe-stack.patch | 12 ++++++++++++ app-emulation/qemu/qemu-5.2.0.ebuild | 1 + 2 files changed, 13 insertions(+) create mode 100644 app-emulation/qemu/files/qemu-5.2.0-safe-stack.patch (limited to 'app-emulation') diff --git a/app-emulation/qemu/files/qemu-5.2.0-safe-stack.patch b/app-emulation/qemu/files/qemu-5.2.0-safe-stack.patch new file mode 100644 index 000000000000..77ed254ab98e --- /dev/null +++ b/app-emulation/qemu/files/qemu-5.2.0-safe-stack.patch @@ -0,0 +1,12 @@ +If SafeStack fails to build it should be disabled, not enabled. +--- a/configure ++++ b/configure +@@ -4956,7 +4956,7 @@ if test "$safe_stack" = "no"; then + fi + else # "$safe_stack" = "" + # Set safe_stack to yes or no based on pre-existing flags +- if compile_prog "-Werror" ""; then ++ if ! compile_prog "-Werror" ""; then + safe_stack="no" + else + safe_stack="yes" diff --git a/app-emulation/qemu/qemu-5.2.0.ebuild b/app-emulation/qemu/qemu-5.2.0.ebuild index 3a200179aa25..a0c14681fac3 100644 --- a/app-emulation/qemu/qemu-5.2.0.ebuild +++ b/app-emulation/qemu/qemu-5.2.0.ebuild @@ -225,6 +225,7 @@ RDEPEND="${CDEPEND} PATCHES=( "${FILESDIR}"/${PN}-2.11.1-capstone_include_path.patch + "${FILESDIR}"/${PN}-5.2.0-safe-stack.patch ) QA_PREBUILT=" -- cgit v1.2.3-65-gdbad