From 96134e95a7468af63ff2ea74a85b0d6db2d2c25e Mon Sep 17 00:00:00 2001 From: Takuto Ikuta Date: Tue, 1 Jul 2025 18:04:24 +0900 Subject: [PATCH] BUILD.gn: Disable libc++ modules for NEON and SVE The -march arguments used for NEON and SVE builds in libyuv are incompatible with libc++ modules. This change disables libc++ modules for these build configurations to fix the build. Bug: 425535758 Change-Id: I578a0d9929c10177903c567bc268407470b45034 Reviewed-on: https://chromium-review.googlesource.com/c/libyuv/libyuv/+/6695664 Reviewed-by: Mirko Bonadei --- BUILD.gn | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/BUILD.gn b/BUILD.gn index c684e587d..30ebafb3d 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -236,6 +236,8 @@ if (libyuv_use_neon) { public_configs = [ ":libyuv_config" ] + # The -march arguments below are incompatible with libc++ modules. + use_libcxx_modules = false if (current_cpu == "arm64") { cflags = [ "-march=armv8-a+dotprod+i8mm" ] } else { @@ -253,6 +255,8 @@ if (libyuv_use_sve) { public_configs = [ ":libyuv_config" ] + # The -march arguments below are incompatible with libc++ modules. + use_libcxx_modules = false # SVE2 is an Armv9-A feature. cflags = [ "-march=armv9-a+i8mm+sve2" ] } @@ -270,6 +274,8 @@ if (libyuv_use_sme) { public_configs = [ ":libyuv_config" ] + # The -march arguments below are incompatible with libc++ modules. + use_libcxx_modules = false # SME is an Armv9-A feature. cflags = [ "-march=armv9-a+i8mm+sme" ] }