From cf8d98db15451751d49de87ba70573bcdc9d5211 Mon Sep 17 00:00:00 2001 From: Yue Ni Date: Tue, 14 Nov 2023 09:33:01 +0800 Subject: [PATCH] Use arrow io util to replace std::filesystem::path in gandiva test_util so that AlmaLinux 8 won't complain. --- cpp/src/gandiva/tests/test_util.cc | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/cpp/src/gandiva/tests/test_util.cc b/cpp/src/gandiva/tests/test_util.cc index 42f67d3824a21..b4a90cf6c34e0 100644 --- a/cpp/src/gandiva/tests/test_util.cc +++ b/cpp/src/gandiva/tests/test_util.cc @@ -17,12 +17,11 @@ #include "gandiva/tests/test_util.h" -#include +#include "arrow/util/io_util.h" namespace gandiva { std::shared_ptr TestConfiguration() { - auto builder = ConfigurationBuilder(); - return builder.DefaultConfiguration(); + return ConfigurationBuilder::DefaultConfiguration(); } #ifndef GANDIVA_EXTENSION_TEST_DIR @@ -30,9 +29,8 @@ std::shared_ptr TestConfiguration() { #endif std::string GetTestFunctionLLVMIRPath() { - std::filesystem::path base(GANDIVA_EXTENSION_TEST_DIR); - std::filesystem::path ir_file = base / "multiply_by_two.bc"; - return ir_file.string(); + const arrow::internal::PlatformFilename base(GANDIVA_EXTENSION_TEST_DIR); + return base.Join("multiply_by_two.bc")->ToString(); } NativeFunction GetTestExternalFunction() {