Skip to content

Commit b59bdef

Browse files
authored
GH-47431: [C++] Improve Meson configuration for WrapDB distribution (#47541)
### Rationale for this change These changes make it easier for downstream users to consume Arrow and its individual components, whether they are available on the system or need to be built from source. ### What changes are included in this PR? Various updates to the Meson configuration to provide dependencies for wrapdb, clean up various semantics ### Are these changes tested? Yes ### Are there any user-facing changes? No * GitHub Issue: #47431 Authored-by: Will Ayd <[email protected]> Signed-off-by: Sutou Kouhei <[email protected]>
1 parent 41659b8 commit b59bdef

File tree

6 files changed

+32
-1
lines changed

6 files changed

+32
-1
lines changed

cpp/src/arrow/acero/meson.build

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,11 @@ arrow_acero_lib = library(
8484
gnu_symbol_visibility: 'inlineshidden',
8585
)
8686

87-
arrow_acero_dep = declare_dependency(link_with: [arrow_acero_lib])
87+
arrow_acero_dep = declare_dependency(
88+
dependencies: [arrow_compute_dep],
89+
link_with: [arrow_acero_lib],
90+
)
91+
meson.override_dependency('arrow-acero', arrow_acero_dep)
8892

8993
arrow_acero_testing_sources = ['test_nodes.cc', 'test_util_internal.cc']
9094

@@ -145,6 +149,7 @@ foreach key, val : arrow_acero_benchmarks
145149
endforeach
146150

147151
pkg.generate(
152+
arrow_acero_lib,
148153
filebase: 'arrow-acero',
149154
name: 'Apache Arrow Acero Engine',
150155
description: 'Apache Arrow\'s Acero Engine',

cpp/src/arrow/adapters/tensorflow/meson.build

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,12 @@
1717

1818
install_headers(['convert.h'], subdir: 'arrow/adapters/tensorflow')
1919

20+
arrow_tensorflow_dep = declare_dependency(
21+
include_directories: include_directories('.'),
22+
dependencies: arrow_dep,
23+
)
24+
meson.override_dependency('arrow-tensorflow', arrow_tensorflow_dep)
25+
2026
pkg.generate(
2127
filebase: 'arrow-tensorflow',
2228
name: 'Apache Arrow Tensorflow',

cpp/src/arrow/csv/meson.build

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,11 @@ install_headers(
6262
subdir: 'arrow/csv',
6363
)
6464

65+
arrow_csv_dep = declare_dependency(
66+
include_directories: include_directories('.'),
67+
dependencies: arrow_dep,
68+
)
69+
meson.override_dependency('arrow-csv', arrow_csv_dep)
6570

6671
pkg.generate(
6772
filebase: 'arrow-csv',

cpp/src/arrow/filesystem/meson.build

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,12 @@ install_headers(
3434
subdir: 'arrow/filesystem',
3535
)
3636

37+
arrow_filesystem_dep = declare_dependency(
38+
include_directories: include_directories('.'),
39+
dependencies: arrow_dep,
40+
)
41+
meson.override_dependency('arrow-filesystem', arrow_filesystem_dep)
42+
3743
pkg.generate(
3844
filebase: 'arrow-filesystem',
3945
name: 'Apache Arrow Filesystem',

cpp/src/arrow/json/meson.build

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,12 @@ install_headers(
5555
subdir: 'arrow/json',
5656
)
5757

58+
arrow_json_dep = declare_dependency(
59+
include_directories: include_directories('.'),
60+
dependencies: arrow_dep,
61+
)
62+
meson.override_dependency('arrow-json', arrow_json_dep)
63+
5864
pkg.generate(
5965
filebase: 'arrow-json',
6066
name: 'Apache Arrow JSON',

cpp/src/arrow/meson.build

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -496,6 +496,7 @@ arrow_dep = declare_dependency(
496496
include_directories: [include_dir],
497497
link_with: arrow_lib,
498498
)
499+
meson.override_dependency('arrow', arrow_dep)
499500

500501
if needs_compute
501502
arrow_compute_lib_sources = [
@@ -559,6 +560,7 @@ if needs_compute
559560
include_directories: include_dir,
560561
dependencies: arrow_dep,
561562
)
563+
meson.override_dependency('arrow-compute', arrow_compute_dep)
562564
else
563565
arrow_compute_dep = disabler()
564566
endif
@@ -643,6 +645,7 @@ if needs_testing
643645
)
644646

645647
arrow_testing_dep = declare_dependency(link_with: [arrow_testing_lib])
648+
meson.override_dependency('arrow-testing', arrow_testing_dep)
646649
else
647650
arrow_testing_dep = disabler()
648651
endif

0 commit comments

Comments
 (0)