Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3d18281f authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "libchrome: Fix build when using clang older than v12" am: e1bfd734...

Merge "libchrome: Fix build when using clang older than v12" am: e1bfd734 am: 202baa2c am: 8aa7d5a3

Original change: https://android-review.googlesource.com/c/platform/packages/modules/Bluetooth/+/2178328



Change-Id: I8eb05aa0297e7d291d77e86e4116e0840681234b
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents 8613f74e 8aa7d5a3
Loading
Loading
Loading
Loading
+25 −0
Original line number Diff line number Diff line
From 3841f20ab4c505dacc3bafb5348af79abe211849 Mon Sep 17 00:00:00 2001
From: Andre Braga <andrebraga@google.com>
Date: Mon, 8 Aug 2022 21:13:05 +0000
Subject: [PATCH] Fix build issues when using clang older than v12

---
 base/compiler_specific.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libchrome/base/compiler_specific.h b/libchrome/base/compiler_specific.h
index 8660018dc7..ad0e72eb84 100644
--- a/libchrome//base/compiler_specific.h
+++ b/libchrome//base/compiler_specific.h
@@ -370,7 +370,7 @@ inline constexpr bool AnalyzerAssumeTrue(bool arg) {
 #endif  // defined(__clang_analyzer__)
 
 // Use nomerge attribute to disable optimization of merging multiple same calls.
-#if defined(__clang__) && __has_attribute(nomerge)
+#if defined(__clang__) && __has_attribute(nomerge) && (__clang_major__ >= 12)
 #define NOMERGE [[clang::nomerge]]
 #else
 #define NOMERGE
-- 
2.37.1.559.g78731f0fdb-goog
+1 −0
Original line number Diff line number Diff line
@@ -2,3 +2,4 @@
0001-rebase_path-for-write_args.patch
0001-Remove-absl-from-pkgconfig.patch
0001-Fix-build-issues-on-930012.patch
0001-Fix-build-issues-when-using-clang-older-than-v12.patch
 No newline at end of file