On 2015-05-26 16:35, Axel Beckert wrote: > Hi, > > Markus Koschany wrote: >> I think it is time to adjust the lintian warning about >> "incompatible-java-bytecode-format". The current version of Lintian >> still warns about Java 1.7 bytecode, however Java 1.7 is the default >> in Jessie and it is reasonable to update the check now. >> >> It seems to be sufficient to change the value of >> "max-bytecode-version" in data/java/constants from 50 to 51. > > There is a related bug report against lintian at > https://bugs.debian.org/783815 (Using oracle java 8 in a package > generate unknow-java-class-version). > > I'm actually unsure about the semantics of max-bytecode-version. > Citing from my (still unanswered) mail to the above bug-report: > > The code introduced in 2.5.23 may have an off-by-one error, but it > also may be on purpose (the changelog entry sys "Catch uses of Java8 > byte code"): > > if ( $mver <= $MAX_BYTECODE->value('min-bytecode-version') - 1 > or $mver > >= $MAX_BYTECODE->value('max-bytecode-existing-version')) { > # First public major version was 45 (Java1), latest > # version is 52 (Java8). > tag 'unknown-java-class-version', $jar_file, > "($class -> $mver)"; > > The ">=" in there likely should be just a ">" if Java 8 byte code > (i.e. for use with openjdk-8 from experimental) is fine. Or am I > misunderstanding the semantics of max-bytecode-existing-version? > > Regards, Axel >
Hi, The off-by-one seems to be a regression/mistake in be04767. It suggests it intends to make Java8 known. Unfortunately, the off-by-one causes to exactly not do this. Beyond fixing the off-by-one a.k.a. s/>=/>/, we should probably also fix: """ # If the lowest version used is: $bad = 1 if $jmajlow == $MAX_BYTECODE->value('max-bytecode-version') + 1; # Java7 - consider bad per request. """ Which I suspect should be a >= under the assumption that there could eventually be two (or more) versions between max-bytecode-version and max-bytecode-existing-version. Beyond that, everything else should be updating the data file accordingly. Thanks, ~Niels -- To UNSUBSCRIBE, email to debian-java-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: https://lists.debian.org/55648b84.1040...@thykier.net