瀏覽代碼

HADOOP-19551. Fix compilation error of native libraries on newer GCC. (#7644)

Reviewed-by: Chris Nauroth <cnauroth@apache.org>
(cherry picked from commit 7ea3f51287c54ac563ef19d42c5bc102699ea025)
Masatake Iwasaki 3 周之前
父節點
當前提交
0e81a54b1c
共有 1 個文件被更改,包括 3 次插入0 次删除
  1. 3 0
      hadoop-common-project/hadoop-common/HadoopCommon.cmake

+ 3 - 0
hadoop-common-project/hadoop-common/HadoopCommon.cmake

@@ -145,6 +145,9 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
     # Make GNU extensions available.
     hadoop_add_compiler_flags("-D_GNU_SOURCE")
 
+    # using old default behavior on GCC >= 14.0
+    hadoop_add_compiler_flags("-Wno-error=implicit-function-declaration")
+
     # If JVM_ARCH_DATA_MODEL is 32, compile all binaries as 32-bit.
     if(JVM_ARCH_DATA_MODEL EQUAL 32)
         # Force 32-bit code generation on amd64/x86_64, ppc64, sparc64