[Wconversion] Suppress warnings
Bug: 58162
Change-Id: Ic7812d0a4eca483d7a8c48d00d398ac6a49933b5
Reviewed-on: https://fuchsia-review.googlesource.com/c/third_party/processor-trace/+/426736
Reviewed-by: Petr Hosek <phosek@google.com>
diff --git a/libipt/BUILD.gn b/libipt/BUILD.gn
index 18c36fa..80cd023 100644
--- a/libipt/BUILD.gn
+++ b/libipt/BUILD.gn
@@ -2,6 +2,12 @@
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
+config("libipt_config") {
+ # Suppress warnings in upstream code that are triggered by Fuchsia compilation flags.
+ cflags = [ "-Wno-conversion" ]
+ visibility = [ ":*" ]
+}
+
static_library("libipt") {
sources = [
"include/intel-pt.h",
@@ -97,6 +103,5 @@
"INCLUDE_EARLY_INIT",
]
- # Suppress warnings in upstream code that are triggered by Fuchsia compilation flags.
- cflags = [ "-Wno-conversion" ]
+ public_configs = [ ":libipt_config" ]
}