2017-09-14 6 views
0

Quand j'essaye de construire le xgboost4j utiliser la commande mvn clean install -DskipTests=true, l'erreur se produit! Quelqu'un peut-il avoir déjà vu cette exception d'erreur?
Mon OS est OS X
JDK version est JDK 1.8
version python 2.7
code xgboost est clone git --recursive https://github.com/dmlc/xgboost
Le message d'erreur comme suit:Construire Le Xgboost4j soulève ErrorException, Quelqu'un peut-il aider? L'exception comme coulant:

[INFO] argLine set to -javaagent:/Users/zhangkuantian/.m2/repository/org/jacoco/org.jacoco.agent/0.7.9/org.jacoco.agent-0.7.9-runtime.jar=destfile=/Users/zhangkuantian/code/xgboost/jvm-packages/xgboost4j/target/jacoco.exec 
[INFO] 
[INFO] --- exec-maven-plugin:1.6.0:exec (native) @ xgboost4j --- 
/bin/sh: cmake: command not found 
building Java wrapper 
cd .. 
mkdir -p build 
cd build 
cmake .. -DUSE_S3:BOOL=OFF -DUSE_OPENMP:BOOL=OFF -DPLUGIN_UPDATER_GPU:BOOL=OFF -DUSE_AZURE:BOOL=OFF -DUSE_HDFS:BOOL=OFF -DJVM_BINDINGS:BOOL=ON 
Traceback (most recent call last): 
    File "create_jni.py", line 88, in <module> 
    run("cmake .. " + " ".join(args) + maybe_generator) 
    File "create_jni.py", line 51, in run 
    subprocess.check_call(command, shell=True, **kwargs) 
    File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 540, in check_call 
    raise CalledProcessError(retcode, cmd) 
subprocess.CalledProcessError: Command 'cmake .. -DUSE_S3:BOOL=OFF -DUSE_OPENMP:BOOL=OFF -DPLUGIN_UPDATER_GPU:BOOL=OFF -DUSE_AZURE:BOOL=OFF -DUSE_HDFS:BOOL=OFF -DJVM_BINDINGS:BOOL=ON' returned non-zero exit status 127 
[ERROR] Command execution failed. 
org.apache.commons.exec.ExecuteException: Process exited with an error: 1 (Exit value: 1) 
    at org.apache.commons.exec.DefaultExecutor.executeInternal(DefaultExecutor.java:404) 
    at org.apache.commons.exec.DefaultExecutor.execute(DefaultExecutor.java:166) 
    at org.codehaus.mojo.exec.ExecMojo.executeCommandLine(ExecMojo.java:804) 
    at org.codehaus.mojo.exec.ExecMojo.executeCommandLine(ExecMojo.java:751) 
    at org.codehaus.mojo.exec.ExecMojo.execute(ExecMojo.java:313) 
    at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134) 
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207) 
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153) 
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145) 
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116) 
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80) 
    at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51) 
    at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128) 
    at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307) 
    at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193) 
    at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106) 
    at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863) 
    at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288) 
    at org.apache.maven.cli.MavenCli.main(MavenCli.java:199) 
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) 
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) 
    at java.lang.reflect.Method.invoke(Method.java:498) 
    at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289) 
    at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229) 
    at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415) 
    at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356) 
[INFO] ------------------------------------------------------------------------ 
[INFO] Reactor Summary: 
[INFO] 
[INFO] xgboost-jvm ........................................ SUCCESS [ 3.219 s] 
[INFO] xgboost4j .......................................... FAILURE [ 1.359 s] 
[INFO] xgboost4j-spark .................................... SKIPPED 
[INFO] xgboost4j-flink .................................... SKIPPED 
[INFO] xgboost4j-example .................................. SKIPPED 
[INFO] ------------------------------------------------------------------------ 
[INFO] BUILD FAILURE 
[INFO] ------------------------------------------------------------------------ 
[INFO] Total time: 4.683 s 
[INFO] Finished at: 2017-09-14T17:28:17+08:00 
[INFO] Final Memory: 27M/469M 
[INFO] ------------------------------------------------------------------------ 
[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.6.0:exec (native) on project xgboost4j: Command execution failed. Process exited with an error: 1 (Exit value: 1) -> [Help 1] 

Répondre

0

Je l'ai résolu, bien que je ne sais pas ce que le code du bloc dans le projet 'xgboost4j', 'xgboost4j-exemple', 'xgboost étincelle', 'xgboost-Flink' le fichier pom.xml »

 <plugin> 
      <artifactId>exec-maven-plugin</artifactId> 
      <groupId>org.codehaus.mojo</groupId> 
      <!-- executions> 
       <execution> 
        <id>native</id> 
        <phase>generate-sources</phase> 
        <goals> 
         <goal>exec</goal> 
        </goals> 
        <configuration> 
         <executable>python</executable> 
         <arguments> 
         <argument>create_jni.py</argument> 
         </arguments> 
         <workingDirectory>${user.dir}</workingDirectory> 
        </configuration> 
       </execution> 
      </executions--> 
     </plugin> 

utilisé pour, je l'ai annoté, puis le problème résolu!