gpt4 book ai didi

java - 在Windows 7 64位和Java 8上构建hadoop 2.6.0时出现问题

转载 作者:行者123 更新时间:2023-12-02 21:39:01 27 4
gpt4 key购买 nike

由于hadoop 2.6.0软件包不包含Windows二进制文件,因此,我尝试使用Windows 7 64位,Java 8,Windows SDK 7.1,Apache Maven 3.3.1和Visual Studio 2013自己构建它们。 :

Hadoop Windows Install Intructions

在Windows SDK 7.1命令提示符下执行此命令后:

mvn package -Pdist,native-win -DskipTests -Dtar

我不断收到以下错误:
LINK : fatal error LNK1123: failure during conversion to COFF: file invalid orcorrupt [E:\build\hadoop-common-project\hadoop-common\src\main\winutils\winutils.vcxproj]

....

[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2:exec (compile-ms-winutils) on project hadoop-common: Command execution failed. Process exited with an error: 1(Exit value: 1) -> [Help 1]

我尝试了其他线程中建议的不同解决方案,但未成功:

Remove .Net Framework 4.5 and install version 4

Replacing cvtres.exe

谁能帮我这个?

如果您可以考虑我的PC配置(Hadoop 2.6.0,Windows 7 64位和Java 8)来提供Windows二进制文件,这也将很有帮助。

谢谢!

最佳答案

这是已知的Visual Studio 2012问题here

This MSDN thread说明了解决方法。

总结一下:

  • 可以通过以下方法禁用增量链接
    Project Properties 
    -> Configuration Properties
    -> Linker (General)
    -> Enable Incremental Linking -> "No (/INCREMENTAL:NO)"
  • 或安装VS2010 SP1。


  • 打开位于解压缩后的 hadoop-2.6.0-src.tar.gz 或您的版本中的文件 BUILDING.txt
    它说明了如何为Windows构建-检查所有这些:

    我的BUILDING.txt说:
    Building on Windows
    Requirements:

    * Windows System
    * JDK 1.6+
    * Maven 3.0 or later
    * Findbugs 1.3.9 (if running findbugs)
    * ProtocolBuffer 2.5.0
    * CMake 2.6 or newer
    * Windows SDK or Visual Studio 2010 Professional
    * Unix command-line tools from GnuWin32 or Cygwin: sh, mkdir, rm, cp, tar, gzip
    * zlib headers (if building native code bindings for zlib)
    * Internet connection for first build (to fetch all Maven and Hadoop dependencies)

    If using Visual Studio, it must be Visual Studio 2010 Professional (not 2012).
    Do not use Visual Studio Express. It does not support compiling for 64-bit,
    which is problematic if running a 64-bit system. The Windows SDK is free to
    download here:

    http://www.microsoft.com/en-us/download/details.aspx?id=8279

    关于java - 在Windows 7 64位和Java 8上构建hadoop 2.6.0时出现问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/30074671/

    27 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com