Bug #22828
closedbuild Debian installation packages failure
0%
Description
When building Ceph Debian installation package, libcephfs build is fail. The error log is below:
[ 7%] Building Java objects for libcephfs-test.jar
cd /tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306/src/java && /usr/lib/jvm/java-8-openjdk-amd64/bin/javac -source 1.5 -target 1.5 -Xlint:-options -classpath :/usr/share/java/junit.jar:/tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306/obj-x86_64-linux-gnu/src/java/libcephfs.jar:/tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306/src/java:/tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306/obj-x86_64-linux-gnu/src/java -d /tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306/obj-x86_64-linux-gnu/src/java/CMakeFiles/libcephfs-test.dir @/tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306/obj-x86_64-linux-gnu/src/java/CMakeFiles/libcephfs-test.dir/java_sources
make -f src/java/CMakeFiles/jni-header.dir/build.make src/java/CMakeFiles/jni-header.dir/depend
make4: Entering directory '/tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306/obj-x86_64-linux-gnu'
cd /tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306/obj-x86_64-linux-gnu && /usr/bin/cmake -E cmake_depends "Unix Makefiles" /tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306 /tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306/src/java /tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306/obj-x86_64-linux-gnu /tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306/obj-x86_64-linux-gnu/src/java /tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306/obj-x86_64-linux-gnu/src/java/CMakeFiles/jni-header.dir/DependInfo.cmake --color=
Scanning dependencies of target jni-header
make4: Leaving directory '/tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306/obj-x86_64-linux-gnu'
make -f src/java/CMakeFiles/jni-header.dir/build.make src/java/CMakeFiles/jni-header.dir/build
make4: Entering directory '/tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306/obj-x86_64-linux-gnu'
[ 8%] Generating native/com_ceph_fs_CephMount.h
cd /tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306/obj-x86_64-linux-gnu/src/java && /usr/lib/jvm/java-8-openjdk-amd64/bin/javah -classpath /tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306/obj-x86_64-linux-gnu/src/java/libcephfs.jar -jni -o /tmp/release/Ubuntu/WORKDIR/ceph-13.0.0-3594-g99c0306/obj-x86_64-linux-g/src/java/native/com_ceph_fs_CephMount.h com.ceph.fs.CephMount
test/com/ceph/fs/CephAllTests.java:25: error: package org.junit does not exist
import org.junit.*;
^
test/com/ceph/fs/CephAllTests.java:26: error: package org.junit.runners does not exist
import org.junit.runners.Suite;
^
test/com/ceph/fs/CephAllTests.java:27: error: package org.junit.runner does not exist
import org.junit.runner.RunWith;
^
test/com/ceph/fs/CephAllTests.java:28: error: package org.junit does not exist
import static org.junit.Assert.*;
^
Updated by Anonymous about 6 years ago
The failure is because multi versions of junit.jar are install on the host, but in src/java/CMakeLists.txt, the "junit" search order is "junit" and then "junit4". In case multi junit versions are installed, the lower version (like 3.8) is found firstly, but junit4 is required only. The search result will cause the failure.
Updated by Anonymous about 6 years ago
The patch is https://github.com/ceph/ceph/pull/20175.
Updated by John Spray about 6 years ago
- Status changed from New to Fix Under Review
Updated by Kefu Chai about 6 years ago
- Status changed from Fix Under Review to Resolved
Updated by Kefu Chai about 6 years ago
- Status changed from Resolved to Pending Backport
Updated by Nathan Cutler about 6 years ago
- Copied to Backport #22856: luminous: build Debian installation packages failure added
Updated by Nathan Cutler about 6 years ago
- Status changed from Pending Backport to Resolved