[SRU] ceph: replace javah usage with a call to javac

Bug #1766995 reported by Tiago Stürmer Daitx
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
ceph (Ubuntu)
Fix Released
Undecided
Unassigned
Bionic
Fix Released
Undecided
Unassigned

Bug Description

[Impact]
Currently ceph 12.2.4-0ubuntu1 FTBFS on Bionic because it can't find the javah binary.

The javah binary has been removed from OpenJDK 10 and the java compiler should be used in its place to build native headers by calling "javac -h".

[Test Case]
Build ceph 12.2.4-0ubuntu1 in Bionic with a current default-jdk (ie. depends on openjdk-11-jdk), it should FTBFS with:

[ 41%] Generating native/com_ceph_fs_CephMount.h
cd /<<PKGBUILDDIR>>/obj-x86_64-linux-gnu/src/java && Java_JAVAH_EXECUTABLE-NOTFOUND -classpath /<<PKGBUILDDIR>>/obj-x86_64-linux-gnu/src/java/libcephfs.jar -jni -o /<<PKGBUILDDIR>>/obj-x86_64-linux-gnu/src/java/native/com_ceph_fs_CephMount.h com.ceph.fs.CephMount
/bin/sh: 1: Java_JAVAH_EXECUTABLE-NOTFOUND: not found

When fixed the build is build is expected to succeed.

[Regression Potential]
No regression is expected as the generated headers are the same.

[Other Info]
 * This SRU should not be backported to any Ubuntu release were the default-jdk depends on openjdk-8 (although it is supposed to be supported, I haven't tested that).
 * The javac -h option has been available since OpenJDK 8 - see JEP-313 and JDK-8182758 [1].
 * Please note that it is not usually possible to simply replace "javah" calls with "javac -h": the syntax and expected arguments are different; the "-h <output header directory>" argument should be added to the existing javac calls.

[References]
[1] https://bugs.java.com/view_bug.do?bug_id=JDK-8182758

tags: added: ftbfs
tags: added: patch
Revision history for this message
Tiago Stürmer Daitx (tdaitx) wrote :

Debdiff that fixes this bug as well as bug #1766998.

Revision history for this message
Tiago Stürmer Daitx (tdaitx) wrote :

Debdiff that fixes this bug only.

Revision history for this message
Brian Murray (brian-murray) wrote :

I've uploaded the debdiff in comment #5 to the bionic SRU queue.

Revision history for this message
Łukasz Zemczak (sil2100) wrote : Please test proposed package

Hello Tiago, or anyone else affected,

Accepted ceph into bionic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/ceph/12.2.4-0ubuntu1.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed.Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-bionic to verification-done-bionic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-bionic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

Changed in ceph (Ubuntu Bionic):
status: New → Fix Committed
tags: added: verification-needed verification-needed-bionic
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package ceph - 12.2.4-0ubuntu1.1

---------------
ceph (12.2.4-0ubuntu1.1) bionic; urgency=medium

  * d/p/update-java-source-target-flags.patch: Use --release instead
    of -source/-target and set release to 7 as that is the minimum
    required for OpenJDK 11 (LP: #1766998).
  * d/p/replace-javah-usage.patch: call -h during compilation time to
    generate native header files and remove the javah call as the binary
    is no longer part of openjdk-10 - javah has been deprecated since
    openjdk-9 (LP: #1766995).

 -- Tiago Stürmer Daitx <email address hidden> Wed, 25 Apr 2018 01:45:34 +0000

Changed in ceph (Ubuntu):
status: New → Fix Released
tags: added: verification-done-bionic
removed: verification-needed verification-needed-bionic
Revision history for this message
Tiago Stürmer Daitx (tdaitx) wrote :

Verified that the build works on bionic for ceph 12.2.4-0ubuntu1.1 (currently in bionic-proposed).

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package ceph - 12.2.4-0ubuntu1.1

---------------
ceph (12.2.4-0ubuntu1.1) bionic; urgency=medium

  * d/p/update-java-source-target-flags.patch: Use --release instead
    of -source/-target and set release to 7 as that is the minimum
    required for OpenJDK 11 (LP: #1766998).
  * d/p/replace-javah-usage.patch: call -h during compilation time to
    generate native header files and remove the javah call as the binary
    is no longer part of openjdk-10 - javah has been deprecated since
    openjdk-9 (LP: #1766995).

 -- Tiago Stürmer Daitx <email address hidden> Wed, 25 Apr 2018 01:45:34 +0000

Changed in ceph (Ubuntu Bionic):
status: Fix Committed → Fix Released
Revision history for this message
Brian Murray (brian-murray) wrote : Update Released

The verification of the Stable Release Update for ceph has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.