|
| 1 | +# Licensed to the Apache Software Foundation (ASF) under one |
| 2 | +# or more contributor license agreements. See the NOTICE file |
| 3 | +# distributed with this work for additional information |
| 4 | +# regarding copyright ownership. The ASF licenses this file |
| 5 | +# to you under the Apache License, Version 2.0 (the |
| 6 | +# "License"); you may not use this file except in compliance |
| 7 | +# with the License. You may obtain a copy of the License at |
| 8 | +# |
| 9 | +# http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | +# |
| 11 | +# Unless required by applicable law or agreed to in writing, |
| 12 | +# software distributed under the License is distributed on an |
| 13 | +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY |
| 14 | +# KIND, either express or implied. See the License for the |
| 15 | +# specific language governing permissions and limitations |
| 16 | +# under the License. |
| 17 | + |
| 18 | +io_tests = ['buffered_test', 'compressed_test', 'file_test', 'memory_test'] |
| 19 | + |
| 20 | +foreach io_test : io_tests |
| 21 | + test_name = 'arrow-io-@0@'.format(io_test.replace('_', '-')) |
| 22 | + exc = executable( |
| 23 | + test_name, |
| 24 | + sources: '@[email protected]'.format(io_test), |
| 25 | + dependencies: [arrow_test_dep], |
| 26 | + implicit_include_directories: false, |
| 27 | + ) |
| 28 | + test(test_name, exc) |
| 29 | +endforeach |
| 30 | + |
| 31 | +if needs_hdfs |
| 32 | + hdfs_incdir = '../../../thirdparty/hadoop/include' |
| 33 | + exc = executable( |
| 34 | + 'arrow-io-hdfs-test', |
| 35 | + sources: 'hdfs_test.cc', |
| 36 | + dependencies: [arrow_test_dep, filesystem_dep], |
| 37 | + implicit_include_directories: false, |
| 38 | + include_directories: [hdfs_incdir], |
| 39 | + ) |
| 40 | + test('arrow-io-hdfs-test', exc) |
| 41 | +endif |
| 42 | + |
| 43 | +io_benchmarks = ['file_benchmark', 'compressed_benchmark'] |
| 44 | + |
| 45 | +foreach io_benchmark : io_benchmarks |
| 46 | + benchmark_name = 'arrow-io-@0@'.format(io_benchmark.replace('_', '-')) |
| 47 | + exc = executable( |
| 48 | + benchmark_name, |
| 49 | + sources: '@[email protected]'.format(io_benchmark), |
| 50 | + dependencies: [arrow_test_dep, benchmark_dep], |
| 51 | + implicit_include_directories: false, |
| 52 | + ) |
| 53 | + benchmark(benchmark_name, exc) |
| 54 | +endforeach |
| 55 | + |
| 56 | +# TODO: Add memory benchmark with SIMD. See GH-45823 |
| 57 | + |
| 58 | +install_headers( |
| 59 | + [ |
| 60 | + 'api.h', |
| 61 | + 'buffered.h', |
| 62 | + 'caching.h', |
| 63 | + 'compressed.h', |
| 64 | + 'concurrency.h', |
| 65 | + 'file.h', |
| 66 | + 'hdfs.h', |
| 67 | + 'interfaces.h', |
| 68 | + 'memory.h', |
| 69 | + 'mman.h', |
| 70 | + 'slow.h', |
| 71 | + 'stdio.h', |
| 72 | + 'transform.h', |
| 73 | + 'type_fwd.h', |
| 74 | + ], |
| 75 | + subdir: 'arrow/io', |
| 76 | +) |
0 commit comments