Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
3.4.0
-
Windows 10
Description
The tests in HDFS native client uses the -Wno-missing-field-initializers flag to ignore warnings about uninitialized members - https://github.com/apache/hadoop/blob/8f83d9f56d775c73af6e3fa1d6a9aa3e64eebc37/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/tests/CMakeLists.txt#L27-L28
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-missing-field-initializers") set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-missing-field-initializers")
This leads to the following error on Visual C++.
[exec] "E:\hadoop-hdfs-project\hadoop-hdfs-native-client\target\native\ALL_BUILD.vcxproj" (default target) (1) -> [exec] "E:\hadoop-hdfs-project\hadoop-hdfs-native-client\target\native\main\native\libhdfspp\tests\x-platform\x_platform_dirent_test_obj.vcxproj" (default target) (24) -> [exec] cl : command line error D8021: invalid numeric argument '/Wno-missing-field-initializers' [E:\hadoop-hdfs-project\hadoop-hdfs-native-client\target\native\main\native\libhdfspp\tests\x-platform\x_platform_dirent_test_obj.vcxproj]
Thus, we need to pass this flag only when the compiler isn't Visual C++.
Attachments
Issue Links
- is a child of
-
HADOOP-17193 Compile Hadoop on Windows natively
- Open
- links to