aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJory Pratt <anarchy@gentoo.org>2021-05-17 08:24:22 -0500
committerJory Pratt <anarchy@gentoo.org>2021-05-17 08:24:22 -0500
commit2ee29c244773dae16ed79fe702fc737c5b1c6458 (patch)
treeab0de36ade4501b1d62752b55b3c0a1bb8375596 /app-emulation/qemu/files
parentsys-process/psmisc: fix missing eapply (diff)
downloadmusl-2ee29c244773dae16ed79fe702fc737c5b1c6458.tar.gz
musl-2ee29c244773dae16ed79fe702fc737c5b1c6458.tar.bz2
musl-2ee29c244773dae16ed79fe702fc737c5b1c6458.zip
app-emulation/qemu: sync with ::gentoo
Package-Manager: Portage-3.0.18, Repoman-3.0.2 Signed-off-by: Jory Pratt <anarchy@gentoo.org>
Diffstat (limited to 'app-emulation/qemu/files')
-rw-r--r--app-emulation/qemu/files/qemu-5.2.0-dce-locks.patch18
1 files changed, 18 insertions, 0 deletions
diff --git a/app-emulation/qemu/files/qemu-5.2.0-dce-locks.patch b/app-emulation/qemu/files/qemu-5.2.0-dce-locks.patch
new file mode 100644
index 00000000..679a9f39
--- /dev/null
+++ b/app-emulation/qemu/files/qemu-5.2.0-dce-locks.patch
@@ -0,0 +1,18 @@
+Fix CFLAGS=-Og build break. -Og fails because gcc does not enable dead
+code elimination (but does set __OPTIMIZE__ define).
+
+The fix avoids DCE reliance downstream entirely.
+
+Reported-by: Luke-Jr
+Bug: https://bugs.gentoo.org/782364
+--- a/include/qemu/lockable.h
++++ b/include/qemu/lockable.h
+@@ -28,7 +28,7 @@ struct QemuLockable {
+ * to QEMU_MAKE_LOCKABLE. For optimized builds, we can rely on dead-code elimination
+ * from the compiler, and give the errors already at link time.
+ */
+-#if defined(__OPTIMIZE__) && !defined(__SANITIZE_ADDRESS__)
++#if defined(__OPTIMIZE__) && !defined(__SANITIZE_ADDRESS__) && defined(VALIDATE_LOCKS_VIA_DCE)
+ void unknown_lock_type(void *);
+ #else
+ static inline void unknown_lock_type(void *unused)