Skip to content

Commit 1b30753

Browse files
committed
feat: support x86-64 and arm64 architectures of macOS
1 parent f9cc572 commit 1b30753

7 files changed

Lines changed: 62 additions & 106 deletions

File tree

.github/workflows/clang_test.yaml

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -71,26 +71,3 @@ jobs:
7171
echo 'export PATH="/Applications/CMake.app/Contents/bin:$PATH"' >> ~/.zshrc
7272
source ~/.zshrc
7373
ci/scripts/build_paimon.sh $(pwd) false true
74-
clang-test-macos-arm64:
75-
name: macOS 26 arm64
76-
runs-on: macos-26-arm64
77-
timeout-minutes: 120
78-
strategy:
79-
fail-fast: false
80-
steps:
81-
- name: Checkout paimon-cpp
82-
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
83-
with:
84-
lfs: true
85-
fetch-depth: 0 # fetch all history for git diff in clang-tidy
86-
- name: Build Paimon
87-
shell: bash
88-
run: |
89-
brew uninstall cmake
90-
brew uninstall --ignore-dependencies brotli
91-
wget https://cmake.org/files/v3.31/cmake-3.31.0-macos-universal.tar.gz
92-
tar -xzf cmake-3.31.0-macos-universal.tar.gz
93-
mv cmake-3.31.0-macos-universal/CMake.app /Applications/
94-
echo 'export PATH="/Applications/CMake.app/Contents/bin:$PATH"' >> ~/.zshrc
95-
source ~/.zshrc
96-
ci/scripts/build_paimon.sh $(pwd) false true

src/paimon/CMakeLists.txt

Lines changed: 14 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -458,12 +458,13 @@ if(PAIMON_BUILD_TESTS)
458458
test_utils_static
459459
${GTEST_LINK_TOOLCHAIN})
460460

461+
set(COMMON_SST_FILE_FORMAT_TEST
462+
common/compression/block_compression_factory_test.cpp
463+
common/sst/sst_file_io_test.cpp common/utils/crc32c_test.cpp)
461464
if(APPLE)
462465
add_paimon_test(common_sst_file_format_test
463466
SOURCES
464-
common/compression/block_compression_factory_test.cpp
465-
common/sst/sst_file_io_test.cpp
466-
common/utils/crc32c_test.cpp
467+
${COMMON_SST_FILE_FORMAT_TEST}
467468
STATIC_LINK_LIBS
468469
paimon_shared
469470
test_utils_static
@@ -473,9 +474,7 @@ if(PAIMON_BUILD_TESTS)
473474
else()
474475
add_paimon_test(common_sst_file_format_test
475476
SOURCES
476-
common/compression/block_compression_factory_test.cpp
477-
common/sst/sst_file_io_test.cpp
478-
common/utils/crc32c_test.cpp
477+
${COMMON_SST_FILE_FORMAT_TEST}
479478
STATIC_LINK_LIBS
480479
paimon_shared
481480
test_utils_static
@@ -619,14 +618,17 @@ if(PAIMON_BUILD_TESTS)
619618
${TEST_STATIC_LINK_LIBS}
620619
${GTEST_LINK_TOOLCHAIN})
621620

621+
set(FS_TEST
622+
common/fs/file_system_test.cpp
623+
common/fs/resolving_file_system_test.cpp
624+
fs/local/local_file_test.cpp
625+
# fs/jindo/jindo_file_system_factory_test.cpp
626+
# fs/jindo/jindo_file_system_test.cpp
627+
)
622628
if(APPLE)
623629
add_paimon_test(fs_test
624630
SOURCES
625-
common/fs/file_system_test.cpp
626-
common/fs/resolving_file_system_test.cpp
627-
fs/local/local_file_test.cpp
628-
# fs/jindo/jindo_file_system_factory_test.cpp
629-
# fs/jindo/jindo_file_system_test.cpp
631+
${FS_TEST}
630632
STATIC_LINK_LIBS
631633
paimon_shared
632634
"-Wl,-force_load,$<TARGET_FILE:paimon_local_file_system_static>"
@@ -636,11 +638,7 @@ if(PAIMON_BUILD_TESTS)
636638
else()
637639
add_paimon_test(fs_test
638640
SOURCES
639-
common/fs/file_system_test.cpp
640-
common/fs/resolving_file_system_test.cpp
641-
fs/local/local_file_test.cpp
642-
# fs/jindo/jindo_file_system_factory_test.cpp
643-
# fs/jindo/jindo_file_system_test.cpp
641+
${FS_TEST}
644642
STATIC_LINK_LIBS
645643
paimon_shared
646644
"-Wl,--whole-archive"

src/paimon/format/avro/CMakeLists.txt

Lines changed: 11 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -48,17 +48,19 @@ if(PAIMON_ENABLE_AVRO)
4848
${PAIMON_VERSION_SCRIPT_FLAGS})
4949

5050
if(PAIMON_BUILD_TESTS)
51+
set(AVRO_FORMAT_TEST
52+
avro_direct_encoder_decoder_test.cpp
53+
avro_file_batch_reader_test.cpp
54+
avro_file_format_test.cpp
55+
avro_format_writer_test.cpp
56+
avro_input_stream_impl_test.cpp
57+
avro_schema_converter_test.cpp
58+
avro_stats_extractor_test.cpp
59+
avro_writer_builder_test.cpp)
5160
if(APPLE)
5261
add_paimon_test(avro_format_test
5362
SOURCES
54-
avro_direct_encoder_decoder_test.cpp
55-
avro_file_batch_reader_test.cpp
56-
avro_file_format_test.cpp
57-
avro_format_writer_test.cpp
58-
avro_input_stream_impl_test.cpp
59-
avro_schema_converter_test.cpp
60-
avro_stats_extractor_test.cpp
61-
avro_writer_builder_test.cpp
63+
${AVRO_FORMAT_TEST}
6264
EXTRA_INCLUDES
6365
${AVRO_INCLUDE_DIR}
6466
STATIC_LINK_LIBS
@@ -71,14 +73,7 @@ if(PAIMON_ENABLE_AVRO)
7173
else()
7274
add_paimon_test(avro_format_test
7375
SOURCES
74-
avro_direct_encoder_decoder_test.cpp
75-
avro_file_batch_reader_test.cpp
76-
avro_file_format_test.cpp
77-
avro_format_writer_test.cpp
78-
avro_input_stream_impl_test.cpp
79-
avro_schema_converter_test.cpp
80-
avro_stats_extractor_test.cpp
81-
avro_writer_builder_test.cpp
76+
${AVRO_FORMAT_TEST}
8277
EXTRA_INCLUDES
8378
${AVRO_INCLUDE_DIR}
8479
STATIC_LINK_LIBS

src/paimon/format/blob/CMakeLists.txt

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -33,14 +33,16 @@ add_paimon_lib(paimon_blob_file_format
3333
${PAIMON_VERSION_SCRIPT_FLAGS})
3434

3535
if(PAIMON_BUILD_TESTS)
36+
set(BLOB_FORMAT_TEST
37+
blob_format_writer_test.cpp
38+
blob_file_batch_reader_test.cpp
39+
blob_stats_extractor_test.cpp
40+
blob_writer_builder_test.cpp
41+
blob_file_format_factory_test.cpp)
3642
if(APPLE)
3743
add_paimon_test(blob_format_test
3844
SOURCES
39-
blob_format_writer_test.cpp
40-
blob_file_batch_reader_test.cpp
41-
blob_stats_extractor_test.cpp
42-
blob_writer_builder_test.cpp
43-
blob_file_format_factory_test.cpp
45+
${BLOB_FORMAT_TEST}
4446
EXTRA_INCLUDES
4547
${BLOB_INCLUDE_DIR}
4648
STATIC_LINK_LIBS
@@ -53,10 +55,7 @@ if(PAIMON_BUILD_TESTS)
5355
else()
5456
add_paimon_test(blob_format_test
5557
SOURCES
56-
blob_format_writer_test.cpp
57-
blob_file_batch_reader_test.cpp
58-
blob_stats_extractor_test.cpp
59-
blob_writer_builder_test.cpp
58+
${BLOB_FORMAT_TEST}
6059
blob_file_format_factory_test.cpp
6160
EXTRA_INCLUDES
6261
${BLOB_INCLUDE_DIR}

src/paimon/format/orc/CMakeLists.txt

Lines changed: 13 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -48,19 +48,21 @@ if(PAIMON_ENABLE_ORC)
4848
${PAIMON_VERSION_SCRIPT_FLAGS})
4949

5050
if(PAIMON_BUILD_TESTS)
51+
set(ORC_FORMAT_TEST
52+
complex_predicate_test.cpp
53+
predicate_converter_test.cpp
54+
predicate_pushdown_test.cpp
55+
read_range_generator_test.cpp
56+
orc_reader_wrapper_test.cpp
57+
orc_input_output_stream_test.cpp
58+
orc_adapter_test.cpp
59+
orc_stats_extractor_test.cpp
60+
orc_format_writer_test.cpp
61+
orc_file_batch_reader_test.cpp)
5162
if(APPLE)
5263
add_paimon_test(orc_format_test
5364
SOURCES
54-
complex_predicate_test.cpp
55-
predicate_converter_test.cpp
56-
predicate_pushdown_test.cpp
57-
read_range_generator_test.cpp
58-
orc_reader_wrapper_test.cpp
59-
orc_input_output_stream_test.cpp
60-
orc_adapter_test.cpp
61-
orc_stats_extractor_test.cpp
62-
orc_format_writer_test.cpp
63-
orc_file_batch_reader_test.cpp
65+
${ORC_FORMAT_TEST}
6466
EXTRA_INCLUDES
6567
${ORC_INCLUDE_DIR}
6668
STATIC_LINK_LIBS
@@ -73,16 +75,7 @@ if(PAIMON_ENABLE_ORC)
7375
else()
7476
add_paimon_test(orc_format_test
7577
SOURCES
76-
complex_predicate_test.cpp
77-
predicate_converter_test.cpp
78-
predicate_pushdown_test.cpp
79-
read_range_generator_test.cpp
80-
orc_reader_wrapper_test.cpp
81-
orc_input_output_stream_test.cpp
82-
orc_adapter_test.cpp
83-
orc_stats_extractor_test.cpp
84-
orc_format_writer_test.cpp
85-
orc_file_batch_reader_test.cpp
78+
${ORC_FORMAT_TEST}
8679
EXTRA_INCLUDES
8780
${ORC_INCLUDE_DIR}
8881
STATIC_LINK_LIBS

src/paimon/format/parquet/CMakeLists.txt

Lines changed: 13 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -45,19 +45,21 @@ add_paimon_lib(paimon_parquet_file_format
4545
${PAIMON_VERSION_SCRIPT_FLAGS})
4646

4747
if(PAIMON_BUILD_TESTS)
48+
set(PARQUET_FORMAT_TEST
49+
file_reader_wrapper_test.cpp
50+
parquet_timestamp_converter_test.cpp
51+
parquet_field_id_converter_test.cpp
52+
parquet_file_batch_reader_test.cpp
53+
parquet_format_writer_test.cpp
54+
parquet_input_output_stream_test.cpp
55+
parquet_stats_extractor_test.cpp
56+
parquet_writer_builder_test.cpp
57+
predicate_converter_test.cpp
58+
predicate_pushdown_test.cpp)
4859
if(APPLE)
4960
add_paimon_test(parquet_format_test
5061
SOURCES
51-
file_reader_wrapper_test.cpp
52-
parquet_timestamp_converter_test.cpp
53-
parquet_field_id_converter_test.cpp
54-
parquet_file_batch_reader_test.cpp
55-
parquet_format_writer_test.cpp
56-
parquet_input_output_stream_test.cpp
57-
parquet_stats_extractor_test.cpp
58-
parquet_writer_builder_test.cpp
59-
predicate_converter_test.cpp
60-
predicate_pushdown_test.cpp
62+
${PARQUET_FORMAT_TEST}
6163
STATIC_LINK_LIBS
6264
paimon_shared
6365
test_utils_static
@@ -69,16 +71,7 @@ if(PAIMON_BUILD_TESTS)
6971
else()
7072
add_paimon_test(parquet_format_test
7173
SOURCES
72-
file_reader_wrapper_test.cpp
73-
parquet_timestamp_converter_test.cpp
74-
parquet_field_id_converter_test.cpp
75-
parquet_file_batch_reader_test.cpp
76-
parquet_format_writer_test.cpp
77-
parquet_input_output_stream_test.cpp
78-
parquet_stats_extractor_test.cpp
79-
parquet_writer_builder_test.cpp
80-
predicate_converter_test.cpp
81-
predicate_pushdown_test.cpp
74+
${PARQUET_FORMAT_TEST}
8275
STATIC_LINK_LIBS
8376
paimon_shared
8477
test_utils_static

src/paimon/testing/utils/CMakeLists.txt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,11 @@ if(PAIMON_BUILD_TESTS)
2626
paimon_static
2727
${GTEST_LINK_TOOLCHAIN})
2828

29+
set(TEST_UTILS_TEST data_generator_test.cpp)
2930
if(APPLE)
3031
add_paimon_test(test_utils_test
3132
SOURCES
32-
data_generator_test.cpp
33+
${TEST_UTILS_TEST}
3334
STATIC_LINK_LIBS
3435
paimon_shared
3536
"-Wl,-force_load"
@@ -39,7 +40,7 @@ if(PAIMON_BUILD_TESTS)
3940
else()
4041
add_paimon_test(test_utils_test
4142
SOURCES
42-
data_generator_test.cpp
43+
${TEST_UTILS_TEST}
4344
STATIC_LINK_LIBS
4445
paimon_shared
4546
"-Wl,--whole-archive"

0 commit comments

Comments
 (0)