hadoop 프로젝트 - 밟은 구덩이

2968 단어
IDEA가 장착되어 항상 환경이 맞지 않습니다.요즘 굳이 환경을 만들어야지--
Terminal에서 처음 실행
mvn package -Pdist,native,docs -DskipTests -Dtar

다음 오류가 발생했습니다.
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-antrun-plugin:1.7:run (pre-dist) on project hadoop-project-dist: An Ant BuildException has occured: Execute failed: java.io.IOException: Cannot run program "sh" (in directory "D:
\gitCode\JDHadoop-2.7.1\hadoop-project-dist\target"): CreateProcess error=2, ?????????
[ERROR] around Ant part ...... @ 41:103 in D:\gitCode\JDHadoop-2.7.1\hadoop-project-dist\target\antrun\build-main.xml
[ERROR] -> [Help 1]

그리고 cygwin64를 설치합니다. 설치 과정은 다음 단계를 누르면 됩니다. 마지막으로 IDEA의 Terminal 설정에서 Shell path는cygwin64 설치 디렉터리\Cygwin으로 변경됩니다.bat
두 번째는 Terminal에서 컴파일 명령을 실행하는데 프로토콜을 찾을 수 없는 오류가 발생했습니다. 프로토콜 --version으로 테스트해 보겠습니다.
그리고 프로토콜을 다운로드하여 설치하면 이 블로그 윈도우즈 환경에서의 프로토콜 설치를 참고할 수 있습니다
설치가 완료되면 Terminal에서 protoc --version을 실행하라는 메시지가 표시됩니다.
$ protoc --version
libprotoc 2.5.0

세 번째 Terminal에서 컴파일 명령을 실행하면 다음과 같은 오류가 발생합니다.
[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: Execute failed: java.io.IOException
: Cannot run program "cmake" (in directory "D:\gitCode\JDHadoop-2.7.1\hadoop-common-project\hadoop-common\target
ative"): CreateProcess error=2, ????????? [ERROR] around Ant part ...... @ 4:129 in D:\gitCode\JDHadoop -2.7.1\hadoop-common-project\hadoop-common\target\antrun\build-main.xml [ERROR] -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. [ERROR] Re-run Maven using the -X switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

다운로드 cmake-3.12.1-win64-x64.zip, 압축을 풀고 bin 디렉터리를 path에 추가하고camke --version을 실행합니다.
$ cmake --version
cmake version 3.12.1

CMake suite maintained and supported by Kitware (kitware.com/cmake).

네 번째 terminal에서 컴파일 명령을 실행하면 다음과 같은 오류가 발생합니다.
[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.3.1:exec (compile-ms-winutils) on project hadoop-common: Command execution failed. Cannot run program "msbuild" (in directory "D:\gitCode\JDHadoop-2.7.1\hadoop-common-proj
ect\hadoop-common"): CreateProcess error=2, ????????? -> [Help 1]

그래--------------- VSCode를 설치하러 가자.
vscode 설치가 끝나면 컴파일할 수 있습니다-----

좋은 웹페이지 즐겨찾기