已开启
[sync] PR-124: C code adapt to gcc14 #125
AtomGit-Bot创建于 2025年12月11日
[sync] PR-124: C code adapt to gcc14 #125
已开启
共 2 个文件变更+72-1
| @@ -0,0 +1,67 @@ | |||
| 1 | +diff --git a/hadoop-common-project/hadoop-common/HadoopCommon.cmake b/hadoop-common-project/hadoop-common/HadoopCommon.cmake | ||
| 2 | +index 4de70ac3..eb45a41d 100644 | ||
| 3 | +--- a/hadoop-common-project/hadoop-common/HadoopCommon.cmake | ||
| 4 | ++++ b/hadoop-common-project/hadoop-common/HadoopCommon.cmake | ||
| 5 | + hadoop_add_linker_flags("${LINKER_SHARED_FLAGS}") | ||
| 6 | + if(CMAKE_SYSTEM_NAME STREQUAL "Linux") | ||
| 7 | + # Make GNU extensions available. | ||
| 8 | + hadoop_add_compiler_flags("-D_GNU_SOURCE") | ||
| 9 | ++ hadoop_add_compiler_flags("-Wno-error=implicit-function-declaration") | ||
| 10 | + | ||
| 11 | + # If JVM_ARCH_DATA_MODEL is 32, compile all binaries as 32-bit. | ||
| 12 | + if(JVM_ARCH_DATA_MODEL EQUAL 32) | ||
| 13 | + elseif(CMAKE_SYSTEM_NAME STREQUAL "SunOS") | ||
| 14 | + endif() | ||
| 15 | + | ||
| 16 | + # Set GNU99 as the C standard to use | ||
| 17 | +-set(CMAKE_C_FLAGS "-std=gnu99 ${CMAKE_C_FLAGS}") | ||
| 18 | + | ||
| 19 | ++set(CMAKE_C_FLAGS "-std=gnu99 ${CMAKE_C_FLAGS}") | ||
| 20 | +diff --git a/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/include/hdfspp/content_summary.h b/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/include/hdfspp/content_summary.h | ||
| 21 | +index 6762a65c..d9809bab 100644 | ||
| 22 | +--- a/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/include/hdfspp/content_summary.h | ||
| 23 | ++++ b/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/include/hdfspp/content_summary.h | ||
| 24 | + | ||
| 25 | + #define HDFSPP_CONTENT_SUMMARY_H_ | ||
| 26 | + | ||
| 27 | + #include <string> | ||
| 28 | ++#include <cstdint> | ||
| 29 | + | ||
| 30 | + namespace hdfs { | ||
| 31 | + | ||
| 32 | +diff --git a/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/include/hdfspp/fsinfo.h b/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/include/hdfspp/fsinfo.h | ||
| 33 | +index 103cf133..156ed445 100644 | ||
| 34 | +--- a/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/include/hdfspp/fsinfo.h | ||
| 35 | ++++ b/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/include/hdfspp/fsinfo.h | ||
| 36 | + | ||
| 37 | + #define HDFSPP_FSINFO_H_ | ||
| 38 | + | ||
| 39 | + #include <string> | ||
| 40 | ++#include <cstdint> | ||
| 41 | + | ||
| 42 | + namespace hdfs { | ||
| 43 | + | ||
| 44 | +diff --git a/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/include/hdfspp/statinfo.h b/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/include/hdfspp/statinfo.h | ||
| 45 | +index 1da1f18a..5924d1db 100644 | ||
| 46 | +--- a/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/include/hdfspp/statinfo.h | ||
| 47 | ++++ b/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/include/hdfspp/statinfo.h | ||
| 48 | + | ||
| 49 | + #define HDFSPP_STATINFO_H_ | ||
| 50 | + | ||
| 51 | + #include <string> | ||
| 52 | ++#include <cstdint> | ||
| 53 | + | ||
| 54 | + namespace hdfs { | ||
| 55 | + | ||
| 56 | +diff --git a/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/include/hdfspp/uri.h b/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/include/hdfspp/uri.h | ||
| 57 | +index bc3d8b96..a7f735af 100644 | ||
| 58 | +--- a/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/include/hdfspp/uri.h | ||
| 59 | ++++ b/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/include/hdfspp/uri.h | ||
| 60 | + | ||
| 61 | + #include <iostream> | ||
| 62 | + #include <string> | ||
| 63 | + #include <vector> | ||
| 64 | ++#include <cstdint> | ||
| 65 | + #include <stdexcept> | ||
| 66 | + | ||
| 67 | + namespace hdfs | ||
| @@ -13,7 +13,7 @@ | |||
| 13 | 13 | ||
| 14 | Name: hadoop | 14 | Name: hadoop |
| 15 | Version: 3.3.6 | 15 | Version: 3.3.6 |
| 16 | -Release: 6 | 16 | +Release: 7 |
| 17 | Summary: A software platform for processing vast amounts of data | 17 | Summary: A software platform for processing vast amounts of data |
| 18 | # The BSD license file is missing | 18 | # The BSD license file is missing |
| 19 | # https://issues.apache.org/jira/browse/HADOOP-9849 | 19 | # https://issues.apache.org/jira/browse/HADOOP-9849 |
| @@ -43,6 +43,7 @@ Patch0: 01-lock-triple-beam-version-to-1.3.0.patch | |||
| 43 | Patch1: 02-Upgrade-os-maven-plugin-to-1.7.1.patch | 43 | Patch1: 02-Upgrade-os-maven-plugin-to-1.7.1.patch |
| 44 | Patch2: 03-Fix-build-on-riscv.patch | 44 | Patch2: 03-Fix-build-on-riscv.patch |
| 45 | Patch3: 04-Enhance-access-control-for-RunJar.patch | 45 | Patch3: 04-Enhance-access-control-for-RunJar.patch |
| 46 | +Patch4: 05-c-code-adapt-to-gcc14.patch | ||
| 46 | 47 | ||
| 47 | BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root | 48 | BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root |
| 48 | BuildRequires: java-1.8.0-openjdk-devel maven hostname maven-local tomcat cmake snappy openssl-devel | 49 | BuildRequires: java-1.8.0-openjdk-devel maven hostname maven-local tomcat cmake snappy openssl-devel |
| @@ -1162,6 +1163,9 @@ fi | |||
| 1162 | %config(noreplace) %{_sysconfdir}/%{name}/container-executor.cfg | 1163 | %config(noreplace) %{_sysconfdir}/%{name}/container-executor.cfg |
| 1163 | 1164 | ||
| 1164 | %changelog | 1165 | %changelog |
| 1166 | +* Fri Nov 07 2025 laokz <zhangkai@iscas.ac.cn> - 3.3.6-7 | ||
| 1167 | +- C code adapt to gcc14 | ||
| 1168 | + | ||
| 1165 | * Fri Dec 13 2024 xuduo <fs-yao@126.com> - 3.3.6-6 | 1169 | * Fri Dec 13 2024 xuduo <fs-yao@126.com> - 3.3.6-6 |
| 1166 | - Add huawei repository | 1170 | - Add huawei repository |
| 1167 | 1171 | ||