java/openjdk12: fix compilation for powerpc64 elfv2

Because of issue with macros in precompiled.hpp, --disable-precompiled-headers is necessary.

Since openjdk compiles for elfv1 by default on big-endian ppc64, use a patch to compile for elfv2.

PR:		243183
Approved by:	glewis (maintainer)
This commit is contained in:
Piotr Kubaj
2020-01-16 09:29:00 +00:00
parent a0342dde3c
commit 3ff99bec50
2 changed files with 14 additions and 0 deletions

View File

@@ -134,6 +134,9 @@ MAKE_ENV+= USE_CLANG=true
CONFIGURE_ARGS+= --disable-warnings-as-errors \
--disable-dtrace
.endif
.if defined(PPC_ABI) && ${PPC_ABI} == ELFv2
CONFIGURE_ARGS+= --disable-precompiled-headers
.endif
.if ${ARCH} != amd64
CONFIGURE_ARGS+= --enable-aot=no
.endif

View File

@@ -0,0 +1,11 @@
--- make/autoconf/flags-cflags.m4.orig 2020-01-08 09:12:31 UTC
+++ make/autoconf/flags-cflags.m4
@@ -770,6 +770,8 @@ AC_DEFUN([FLAGS_SETUP_CFLAGS_CPU_DEP],
# for all archs except arm and ppc, prevent gcc to omit frame pointer
$1_CFLAGS_CPU_JDK="${$1_CFLAGS_CPU_JDK} -fno-omit-frame-pointer"
fi
+ elif test "x$OPENJDK_TARGET_OS_ENV" = xbsd.freebsd; then
+ $1_CFLAGS_CPU_JVM="${$1_CFLAGS_CPU_JVM} -DABI_ELFv2 -mcpu=powerpc64 -mtune=power5"
fi
elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then