我一直无法使用Maven 3.1.1构建Hadoop 2.2.0,这是我得到的输出的一部分(完整登录http://pastebin.com/FE6vu46M):
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] Apache Hadoop Main ................................ SUCCESS [27.471s]
[INFO] Apache Hadoop Project POM ......................... SUCCESS [0.936s]
[INFO] Apache Hadoop Annotations ......................... SUCCESS [3.819s]
[INFO] Apache Hadoop Assemblies .......................... SUCCESS [0.414s]
[INFO] Apache Hadoop Project Dist POM .................... SUCCESS [1.834s]
[INFO] Apache Hadoop Maven Plugins ....................... SUCCESS [4.693s]
[INFO] Apache Hadoop MiniKDC ............................. SUCCESS [4.346s]
[INFO] Apache Hadoop Auth ................................ SUCCESS [4.923s]
[INFO] Apache Hadoop Auth Examples ....................... SUCCESS [2.797s]
[INFO] Apache Hadoop Common .............................. FAILURE [22.898s]
[INFO] Apache Hadoop NFS ................................. SKIPPED
..........
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1:17.655s
[INFO] Finished at: Wed Dec 04 16:18:31 CET 2013
[INFO] Final Memory: 64M/420M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-antrun-plugin:1.7:
run (make) on project hadoop-common: An Ant BuildException has occured: exec returned: 1
[ERROR] around Ant part ...<exec dir="/home/scaino/hadoop-2.2.0-maven/hadoop-common-project/hadoop-common/target/native"
executable="cmake" failonerror="true">... @ 4:135 in
/home/scaino/hadoop-2.2.0-maven/hadoop-common-project/hadoop-common/target/antrun/build-main.xml
我检查了Protoc,它似乎正在工作,与库路径相同,它指向库(安装在$ HOME / install / lib中):
~/hadoop-2.2.0-maven$ protoc --version
libprotoc 2.5.0
~/hadoop-2.2.0-maven$ echo $LD_LIBRARY_PATH
/home/scaino/install/lib:/home/software/gcc-4.8/lib64:/home/software/mpich2-1.2.1/lib
这是Maven检索到的一些系统信息:
~/hadoop-2.2.0-maven$ mvn --version
Apache Maven 3.1.1 (0728685237757ffbf44136acec0402957f723d9a; 2013-09-17 17:22:22+0200)
Maven home: /home/scaino/apache-maven-3.1.1
Java version: 1.7.0_25, vendor: Oracle Corporation
Java home: /home/software/jdk1.7.0_25/jre
Default locale: es_ES, platform encoding: UTF-8
OS name: "linux", version: "2.6.35-32-server", arch: "amd64", family: "unix"
我很感激任何可以让我了解发生了什么的指导方针或提示,因为到目前为止,我已经尝试或看过的任何内容都有效。
提前多多感谢。
此致
里奥
答案 0 :(得分:2)
确保您已在机器中安装了cmake。如果您使用的是Ubuntu,可以使用以下命令安装cmake
sudo apt-get install cmake
安装后,尝试编译......
答案 1 :(得分:1)
在我尝试编译本机库的节点中,结果是库/编译器不一致。在更新的节点中构建足以实现成功构建。
答案 2 :(得分:0)
请确保您的文件夹名称不应包含空格, /home/hadoop2.2/hadoop2.2-src ---构建没有问题,
如果您的文件夹是这样的 / home / hadoop 2.2 / hadoop2.2-src ---会出现构建问题。