[Slackbuilds-users] openjdk was: Re: Updates - 20170225.1

Christoph Willing chris.willing at iinet.net.au
Sun Feb 26 04:20:27 UTC 2017


On 26/02/17 09:53, Christoph Willing wrote:
> On 26/02/17 09:25, Christoph Willing wrote:
>> On 25/02/17 18:12, B Watson wrote:
>>> On 2/24/17, Christoph Willing <chris.willing at iinet.net.au> wrote:
>>>> Over time, I've had many suggestions and reminders that LibreOffice will
>>>> build successfully without the jdk package. I prefer a build with as
>>>> full functionality as is made possible upstream, so I prefer that it
>>>> remain as a requirement. Java haters are welcome to add --without-java
>>>> or --with-java=no to their local versions - which reminds me I could add
>>>> a JAVA=no option to the SlackBuild at the next version update.
>>>
>>> Will it work with openjdk rather than Oracle's jdk?
>>>
>>> That's probably a question that should be asked about any of the builds
>>> mentioned in this thread.
>>>
>>> If the answer is "it requires a JDK, and will work with either jdk or
>>> openjdk", what's the best way to handle that? List jdk in REQUIRES,
>>> and say "you can use openjdk instead of jdk" in the README? Or, list
>>> neither in REQUIRES, and in the README say "you need one of either jdk
>>> or openjdk"?
>>>
>>> Or, maybe openjdk should be listed in REQUIRES, as it's easier to deal
>>> with (doesn't require jumping through hoops to download like jdk does)?
>>> In which case the README would say "you can use jdk instead of openjdk"?
>>
>> I haven't tried openjdk for a long time - there were often problems
>> running it with the java apps I was using at that time and the Oracle
>> version always just worked. However that was some time ago and your
>> comment about being 'easier to deal with' (in automated build systems,
>> at least) is a good point.
>>
>> Therefore I tried building openjdk in a fresh 14.2 64bit VM and very
>> soon had the following failure:
>>
>> compile:
>>     [javac] Compiling 2760 source files to
>> /tmp/SBo/openjdk/icedtea-build/openjdk.build-boot/jaxws/build/classes
>>     [javac] Annotation processing got disabled, since it requires a 1.6
>> compliant JVM
>>     [javac] java.lang.NullPointerException
>>     [javac]    at
>> org.eclipse.jdt.internal.compiler.batch.CompilationUnit.getContents(CompilationUnit.java:77)
>>     [javac]    at
>> org.eclipse.jdt.internal.compiler.batch.Main$2.acceptResult(Main.java:2962)
>>     [javac]    at
>> org.eclipse.jdt.internal.compiler.Compiler.handleInternalException(Compiler.java:609)
>>     [javac]    at
>> org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:527)
>>     [javac]    at
>> org.eclipse.jdt.internal.compiler.batch.Main.performCompilation(Main.java:4099)
>>     [javac]    at
>> org.eclipse.jdt.internal.compiler.batch.Main.compile(Main.java:1689)
>>     [javac]    at
>> org.eclipse.jdt.internal.compiler.batch.Main.main(Main.java:1400)
>>     [javac]
>>
>> BUILD FAILED
>> /tmp/SBo/openjdk/icedtea-build/openjdk-boot/jaxws/build.xml:155: Compile
>> failed; see the compiler error output for details.
>>
>> Total time: 1 second
>> Makefile:150: recipe for target 'all' failed
>>
>>
>>
>> This morning I've just started a build in a 32bit VM which is not
>> complete yet but seems to be progressing just fine. Is there a known
>> problem with openjdk on 64bit? Does anyone recognize the failure above
>> and/or know a possible solution?
>>
> Well the 32bit version finished building so I was encouraged to try the
> 64bit build again. This time it has passed the previous point of failure
> and seems also to be progressing just fine.
> 
> In the meantime, I see that the 32bit build produced
> openjdk-7u111b01-i486-1_SBo.txz which seems pretty old. Looking around I
> found there was also a SlackBuild for openjdk8 (and even older
> openjdk6). Wanting to try the openjdk8, I found it has a requirement for
> openjdk (not just apache-ant, as is the case for openjdk & openjdk6). Is
> that just a typo (should require apache-ant, not openjdk)?
> 
Answering my own question; no it's not a typo.

To test, I changed the openjdk8's REQUIRES field from openjdk to
apache-ant but the build failed because JAVA_HOME hadn't been set up
i.e. no jdk or openjdk installed. When I reverted the REQUIRES field to
openjdk, the build of openjdk8 succeeded.

Furthermore, openjdk's own README-builds.html states that before
attempting to build:
    "Install a Bootstrap JDK. All OpenJDK builds require access to a
previously released JDK called the bootstrap JDK or boot JDK. The
general rule is that the bootstrap JDK must be an instance of the
previous major release of the JDK."

The question for me now is whether changing LibreOffice's jdk
requirement to openjdk really makes building LibreOffice much more
straightforward. While it may build with openjdk, I'd personally be
uncomfortable with using an out of date version. However to use openjdk8
as the requirement means that a builder of LibreOffice needs to build
openjdk first, then openjdk8.

Apart from the complication of downloading the Oracle jdk, building it
(repackaging it) seems simpler, not to mention much faster.

Any other views on using openjdk* instead of jdk as requirement for
LibreOffice?

chris



More information about the SlackBuilds-users mailing list