This is an automated email from the ASF dual-hosted git repository.

kou pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/arrow.git


The following commit(s) were added to refs/heads/main by this push:
     new 41ce51b175 GH-47537: [C++] Use pkgconfig name for benchmark in Meson 
(#47538)
41ce51b175 is described below

commit 41ce51b1759125c48ac53230716b52d819e50a8e
Author: William Ayd <[email protected]>
AuthorDate: Mon Sep 8 21:26:44 2025 -0400

    GH-47537: [C++] Use pkgconfig name for benchmark in Meson (#47538)
    
    ### Rationale for this change
    
    Because of an inconsistency in the name of the pkgconfig file for google 
benchmark and the dependency exposed by Meson, Meson will always ignore a 
system install and fallback to building google benchmark locally. We can 
instead patch our Meson configuration to workaround the inconsistent naming
    
    ### What changes are included in this PR?
    
    We use the proper pkgconfig exposed name to find the dependency, and 
fallback to the Meson subproject / variable name combination as necessary
    
    ### Are these changes tested?
    
    Yes
    
    ### Are there any user-facing changes?
    
    No
    * GitHub Issue: #47537
    
    Authored-by: Will Ayd <[email protected]>
    Signed-off-by: Sutou Kouhei <[email protected]>
---
 cpp/src/arrow/meson.build | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/cpp/src/arrow/meson.build b/cpp/src/arrow/meson.build
index fbd9cc8551..33a9c6ed40 100644
--- a/cpp/src/arrow/meson.build
+++ b/cpp/src/arrow/meson.build
@@ -670,7 +670,8 @@ endforeach
 
 if needs_benchmarks
     benchmark_main_dep = dependency(
-        'benchmark-main',
+        'benchmark_main',
+        fallback: ['google-benchmark', 'google_benchmark_main_dep'],
         default_options: {'tests': 'disabled'},
     )
 

Reply via email to