From 5b0ca6aad81436e426c685242106681bd9c911e9 Mon Sep 17 00:00:00 2001 From: Ganlin Zhao <36554565+glzhao89@users.noreply.github.com> Date: Thu, 1 Aug 2024 23:57:04 +0800 Subject: [PATCH] [fix](recycler) Fix recycler compilation issue with libhdfs3 (#38485) This PR fix compilation error for cloud recycler when the USE_LIBHDFS3 flag is enabled. --- cloud/src/recycler/hdfs_accessor.cpp | 6 +++++- cloud/src/recycler/hdfs_accessor.h | 4 ++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/cloud/src/recycler/hdfs_accessor.cpp b/cloud/src/recycler/hdfs_accessor.cpp index dea1e164eb7b80..d97c0a37aabdd9 100644 --- a/cloud/src/recycler/hdfs_accessor.cpp +++ b/cloud/src/recycler/hdfs_accessor.cpp @@ -18,7 +18,11 @@ #include "recycler/hdfs_accessor.h" #include -#include +#ifdef USE_HADOOP_HDFS +#include // IWYU pragma: export +#else +#include // IWYU pragma: export +#endif #include diff --git a/cloud/src/recycler/hdfs_accessor.h b/cloud/src/recycler/hdfs_accessor.h index 57f29cc1ae1fc6..bfbe02aadc9029 100644 --- a/cloud/src/recycler/hdfs_accessor.h +++ b/cloud/src/recycler/hdfs_accessor.h @@ -29,7 +29,11 @@ namespace doris::cloud { class HdfsVaultInfo; +#ifdef USE_HADOOP_HDFS using HdfsSPtr = std::shared_ptr; +#else +using HdfsSPtr = std::shared_ptr; +#endif class HdfsAccessor final : public StorageVaultAccessor { public: