-
Notifications
You must be signed in to change notification settings - Fork 2.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[need help] error compiling 32x hdfs native client #2
Comments
Hey @cdarlint I also got same error when building 3.2.1 on Windows 10 and I've fixed it temporarily in my local code. Refer to my post Compile and Build Hadoop 3.2.1 on Windows 10 Guide Section II Issue Fixes for more details. The error occurred because in my environment VS2010 C/C++ compiler doesn't support doesn't support declare variables in the middle of the function or in the loop for C code. [INFO] Apache Hadoop HDFS ................................. SUCCESS [01:32 min]
Two examples of test_libhdfs_threaded.c that causes errors:
|
There are errors when compiling hadoop 3.2.0 and 3.2.1 on windows
I believe there might be configuration problems or some glitches of windows-related problems
I'll post error messages here and please help
This is a dedicated virtual machine for compiling hadoop
I've successfully compiled multiple versions, up to 3.1.x
as my machine is Chinese language and locale, I translated and hand picked most related messages, as below
near the end of the output, there are mesasges like:
APACHE Hadoop HDFS Native Client ................... FAILURE [ 9.908 s]
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-antrun-plugin:1.7:run (make) on project hadoop-hdfs-native-client: An Ant BuildException has occured: exec returned 1
[ERROR] around Ant part ...(exec failonerror="true" dir="C:\h3\hadoop-hdfs-project\hadoop-hdfs-native-client\target/native" executable="msbuild">... @ 9:121 in c:\h3\hadoop-hdfs-project\hadoop-hdfs-native-client\target\antrun\build-main.xml
above this, there are error messages during compiling native client
there are basically two problems
1 cannot resolve reference
2 missing semicolon
problem 1:
test_libhdfs_ops.obj : error LNK2019: unresolved external symbol hdfsFileDisableDirectRead referenced in main
test_libhdfs_ops.obj : error LNK2019: unresolved external symbol hdfsFileUsesDirectRead referenced in main
problem 2. error messages got too long so I opened this solution in VS2010 on the same VM and collected error messages there:
ClCompile:
test_libhdfs_threaded.c
..........\src\main\native\libhdfs-tests\test_libhdfs_threaded.c(163): error C2143: grammar error : missing ";" (before 'type')
..........\src\main\native\libhdfs-tests\test_libhdfs_threaded.c(164): error C2065: "invalid_path": undeclared symbol
The text was updated successfully, but these errors were encountered: