我无法构建guava v21.0
,因为测试concurrent.ListenerCallQueueTest
永远挂起:
$ git clone https://github.com/google/guava
$ cd guava
$ git tag
$ git checkout v21.0
$ mvn package
[...]
Tests run: 11, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.177 sec
Running com.google.common.util.concurrent.ListenerCallQueueTest
我似乎有三个睡眠过程:
$ ps aux | grep guava | grep -v grep
john 23619 16.6 12.5 4531216 1016192 pts/1 Sl+ 07:47 4:43 /usr/lib/jvm/java-8-openjdk-amd64/bin/java -classpath /usr/share/maven/boot/plexus-classworlds-2.x.jar -Dclassworlds.conf=/usr/share/maven/bin/m2.conf -Dmaven.home=/usr/share/maven -Dmaven.multiModuleProjectDirectory=/home/john/Libs/guava org.codehaus.plexus.classworlds.launcher.Launcher clean install
john 26401 0.0 0.0 4292 756 pts/1 S+ 07:55 0:00 /bin/sh -c cd /home/john/Libs/guava/guava-tests && /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java -Xmx1536M -Duser.language=hi -Duser.country=IN -jar /home/john/Libs/guava/guava-tests/target/surefire/surefirebooter6901955962891879666.jar /home/john/Libs/guava/guava-tests/target/surefire/surefire4499145904440222523tmp /home/john/Libs/guava/guava-tests/target/surefire/surefire2603198880854108081tmp
john 26403 68.8 14.4 4137984 1167932 pts/1 Sl+ 07:55 14:07 /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java -Xmx1536M -Duser.language=hi -Duser.country=IN -jar /home/john/Libs/guava/guava-tests/target/surefire/surefirebooter6901955962891879666.jar /home/john/Libs/guava/guava-tests/target/surefire/surefire4499145904440222523tmp /home/john/Libs/guava/guava-tests/target/surefire/surefire2603198880854108081tmp
我的debian stretch
计算机上出现这种情况:
$ uname -a
Linux front 4.8.0-1-amd64 #1 SMP Debian 4.8.5-1 (2016-10-28) x86_64 GNU/Linux
$ mvn -version
Apache Maven 3.3.9
Maven home: /usr/share/maven
Java version: 1.8.0_121, vendor: Oracle Corporation
Java home: /usr/lib/jvm/java-8-openjdk-amd64/jre
Default locale: en_GB, platform encoding: UTF-8
OS name: "linux", version: "4.8.0-1-amd64", arch: "amd64", family: "unix"
同样的程序可以在我的debian jessie
机器上成功构建:
Apache Maven 3.0.5
Maven home: /usr/share/maven
Java version: 1.8.0_111, vendor: Oracle Corporation
Java home: /usr/lib/jvm/java-8-openjdk-amd64/jre
Default locale: en_GB, platform encoding: UTF-8
OS name: "linux", version: "3.16.0-4-amd64", arch: "amd64", family: "unix"
在this post中找到以下建议后,我已成功完成了构建:
$ mvn clean install -Dmaven.test.skip
但是,运行mvn clean install
代替mvn clean package
会导致相同的结果。
非常感谢任何建议。