From c338bee718dea86e5b126f259c4dcbad91990cff Mon Sep 17 00:00:00 2001 From: alesapin Date: Thu, 16 Dec 2021 14:37:12 +0300 Subject: [PATCH] Revert "Fix build issue related to azure blob storage" --- contrib/azure-cmake/CMakeLists.txt | 7 ++----- src/CMakeLists.txt | 14 -------------- src/Disks/BlobStorage/BlobStorageAuth.h | 18 ------------------ src/Disks/BlobStorage/DiskBlobStorage.h | 16 ---------------- src/Disks/IO/ReadBufferFromRemoteFSGather.h | 19 ------------------- src/IO/ReadBufferFromBlobStorage.h | 18 ------------------ src/IO/WriteBufferFromBlobStorage.h | 17 ----------------- 7 files changed, 2 insertions(+), 107 deletions(-) diff --git a/contrib/azure-cmake/CMakeLists.txt b/contrib/azure-cmake/CMakeLists.txt index ed4283645989..7f9476e37b78 100644 --- a/contrib/azure-cmake/CMakeLists.txt +++ b/contrib/azure-cmake/CMakeLists.txt @@ -46,17 +46,14 @@ include("${AZURE_DIR}/cmake-modules/AzureTransportAdapters.cmake") add_library(azure_sdk ${AZURE_SDK_UNIFIED_SRC}) if (COMPILER_CLANG) - target_compile_options(azure_sdk PRIVATE + target_compile_options(azure_sdk PUBLIC -Wno-deprecated-copy-dtor -Wno-extra-semi -Wno-suggest-destructor-override -Wno-inconsistent-missing-destructor-override -Wno-error=unknown-warning-option + -Wno-reserved-identifier ) - - if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 13) - target_compile_options(azure_sdk PRIVATE -Wno-reserved-identifier) - endif() endif() # Originally, on Windows azure-core is built with bcrypt and crypt32 by default diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 428f817ac495..bca9bd9d2802 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -385,20 +385,6 @@ dbms_target_include_directories(SYSTEM BEFORE PUBLIC ${PDQSORT_INCLUDE_DIR}) target_include_directories(clickhouse_common_io BEFORE PUBLIC ${MINISELECT_INCLUDE_DIR}) dbms_target_include_directories(SYSTEM BEFORE PUBLIC ${MINISELECT_INCLUDE_DIR}) -macro (add_check_flag_definitions flag modules) - if (${flag}) - if (MAKE_STATIC_LIBRARIES OR NOT SPLIT_SHARED_LIBRARIES) - target_compile_definitions(clickhouse_common_io PRIVATE ${flag}) - target_compile_definitions(dbms PRIVATE ${flag}) - else () - foreach (module ${modules}) - target_compile_definitions(${module} PRIVATE ${flag}) - endforeach () - endif () - endif () -endmacro () -add_check_flag_definitions(HAS_SUGGEST_DESTRUCTOR_OVERRIDE "clickhouse_common_io;clickhouse_disks") - if (ZSTD_LIBRARY) dbms_target_link_libraries(PRIVATE ${ZSTD_LIBRARY}) target_link_libraries (clickhouse_common_io PUBLIC ${ZSTD_LIBRARY}) diff --git a/src/Disks/BlobStorage/BlobStorageAuth.h b/src/Disks/BlobStorage/BlobStorageAuth.h index 04abc2fd643f..16a088fc9601 100644 --- a/src/Disks/BlobStorage/BlobStorageAuth.h +++ b/src/Disks/BlobStorage/BlobStorageAuth.h @@ -7,26 +7,8 @@ #if USE_AZURE_BLOB_STORAGE #include - -#if defined(__clang__) -# pragma clang diagnostic push -# pragma clang diagnostic ignored "-Winconsistent-missing-destructor-override" -# pragma clang diagnostic ignored "-Wdeprecated-copy-dtor" -# pragma clang diagnostic ignored "-Wextra-semi" -# ifdef HAS_SUGGEST_DESTRUCTOR_OVERRIDE -# pragma clang diagnostic ignored "-Wsuggest-destructor-override" -# endif -# ifdef HAS_RESERVED_IDENTIFIER -# pragma clang diagnostic ignored "-Wreserved-identifier" -# endif -#endif - #include -#if defined(__clang__) -# pragma clang diagnostic pop -#endif - namespace DB { diff --git a/src/Disks/BlobStorage/DiskBlobStorage.h b/src/Disks/BlobStorage/DiskBlobStorage.h index d124a133eb21..16ba216df968 100644 --- a/src/Disks/BlobStorage/DiskBlobStorage.h +++ b/src/Disks/BlobStorage/DiskBlobStorage.h @@ -11,25 +11,9 @@ #include #include -#if defined(__clang__) -# pragma clang diagnostic push -# pragma clang diagnostic ignored "-Winconsistent-missing-destructor-override" -# pragma clang diagnostic ignored "-Wdeprecated-copy-dtor" -# pragma clang diagnostic ignored "-Wextra-semi" -# ifdef HAS_SUGGEST_DESTRUCTOR_OVERRIDE -# pragma clang diagnostic ignored "-Wsuggest-destructor-override" -# endif -# ifdef HAS_RESERVED_IDENTIFIER -# pragma clang diagnostic ignored "-Wreserved-identifier" -# endif -#endif - #include #include -#if defined(__clang__) -# pragma clang diagnostic pop -#endif namespace DB { diff --git a/src/Disks/IO/ReadBufferFromRemoteFSGather.h b/src/Disks/IO/ReadBufferFromRemoteFSGather.h index 6bef9488d055..045ab43850da 100644 --- a/src/Disks/IO/ReadBufferFromRemoteFSGather.h +++ b/src/Disks/IO/ReadBufferFromRemoteFSGather.h @@ -6,26 +6,7 @@ #include #if USE_AZURE_BLOB_STORAGE - -#if defined(__clang__) -# pragma clang diagnostic push -# pragma clang diagnostic ignored "-Winconsistent-missing-destructor-override" -# pragma clang diagnostic ignored "-Wdeprecated-copy-dtor" -# pragma clang diagnostic ignored "-Wextra-semi" -# ifdef HAS_SUGGEST_DESTRUCTOR_OVERRIDE -# pragma clang diagnostic ignored "-Wsuggest-destructor-override" -# endif -# ifdef HAS_RESERVED_IDENTIFIER -# pragma clang diagnostic ignored "-Wreserved-identifier" -# endif -#endif - #include - -#if defined(__clang__) -# pragma clang diagnostic pop -#endif - #endif namespace Aws diff --git a/src/IO/ReadBufferFromBlobStorage.h b/src/IO/ReadBufferFromBlobStorage.h index 029b53641eb4..cd66e897e25e 100644 --- a/src/IO/ReadBufferFromBlobStorage.h +++ b/src/IO/ReadBufferFromBlobStorage.h @@ -9,26 +9,8 @@ #include #include #include - -#if defined(__clang__) -# pragma clang diagnostic push -# pragma clang diagnostic ignored "-Winconsistent-missing-destructor-override" -# pragma clang diagnostic ignored "-Wdeprecated-copy-dtor" -# pragma clang diagnostic ignored "-Wextra-semi" -# ifdef HAS_SUGGEST_DESTRUCTOR_OVERRIDE -# pragma clang diagnostic ignored "-Wsuggest-destructor-override" -# endif -# ifdef HAS_RESERVED_IDENTIFIER -# pragma clang diagnostic ignored "-Wreserved-identifier" -# endif -#endif - #include -#if defined(__clang__) -# pragma clang diagnostic pop -#endif - namespace DB { diff --git a/src/IO/WriteBufferFromBlobStorage.h b/src/IO/WriteBufferFromBlobStorage.h index 4bb995f907da..5f8eaba3c0c7 100644 --- a/src/IO/WriteBufferFromBlobStorage.h +++ b/src/IO/WriteBufferFromBlobStorage.h @@ -10,26 +10,9 @@ #include #include - -#if defined(__clang__) -# pragma clang diagnostic push -# pragma clang diagnostic ignored "-Winconsistent-missing-destructor-override" -# pragma clang diagnostic ignored "-Wdeprecated-copy-dtor" -# pragma clang diagnostic ignored "-Wextra-semi" -# ifdef HAS_SUGGEST_DESTRUCTOR_OVERRIDE -# pragma clang diagnostic ignored "-Wsuggest-destructor-override" -# endif -# ifdef HAS_RESERVED_IDENTIFIER -# pragma clang diagnostic ignored "-Wreserved-identifier" -# endif -#endif - #include #include -#if defined(__clang__) -# pragma clang diagnostic pop -#endif namespace DB {