Build OpenJDK 8 for armhf (Raspberry Pi)?

David Holmes david.holmes at
Wed Apr 30 09:21:26 UTC 2014


I don't think zero builds are generally addressed on this list but ...

On 30/04/2014 2:34 AM, Jim Connors wrote:
> Hello,
> Trying to build OpenJDK 8 for armhf, ultimately to be hosted on a
> Raspberry Pi.  I'm cross compiling from a Ubuntu 12.04 x86 Virtualbox
> image and am using gcc-4.7-linaro-rpi-gnueabihf for a toolchain.
> Configuration invocation looks as follows:
> $ bash configure
> --with-sys-root=/home/jimc/gcc-4.7-linaro-rpi-gnueabihf/
> --target=arm-unknown-linux-gnueabihf --with-jvm-variants=zero
> --with-num-cores=2
> The make fails like this:
> Compiling /home/jimc/openjdk8/hotspot/src/os/posix/vm/os_posix.cpp
> /home/jimc/openjdk8/hotspot/src/os/linux/vm/os_linux.cpp: In static
> member function 'static jint os::init_2()':
> /home/jimc/openjdk8/hotspot/src/os/linux/vm/os_linux.cpp:4853:42: error:
> 'workaround_expand_exec_shield_cs_limit' was not declared in this scope

You need to setup configure to do cross-compilation. I'm assuming you 
are building on an x86 box because that function is only defined on x86

#if defined(IA32)

I think


should be



> Might there a set of patches that are required to get this going
> further?  Anything else I'm missing?
> Any pointer greatly appreciated,
> -- Jim C

More information about the build-dev mailing list