8259043: More Zero architectures need linkage with libatomic

Co-authored-by: Matthias Klose <doko@openjdk.org>
Reviewed-by: erikj
This commit is contained in:
Aleksey Shipilev 2021-01-11 13:45:35 +00:00
parent 020ec84852
commit e05f36f463

View File

@ -124,12 +124,18 @@ AC_DEFUN_ONCE([LIB_SETUP_LIBRARIES],
BASIC_JVM_LIBS="$BASIC_JVM_LIBS -lpthread"
fi
# Libatomic library
# 32-bit MIPS needs fallback library for 8-byte atomic ops
if test "x$OPENJDK_TARGET_OS" = xlinux &&
(test "x$OPENJDK_TARGET_CPU" = xmips ||
test "x$OPENJDK_TARGET_CPU" = xmipsel); then
BASIC_JVM_LIBS="$BASIC_JVM_LIBS -latomic"
# Atomic library
# 32-bit platforms needs fallback library for 8-byte atomic ops on Zero
if HOTSPOT_CHECK_JVM_VARIANT(zero); then
if test "x$OPENJDK_TARGET_OS" = xlinux &&
(test "x$OPENJDK_TARGET_CPU" = xarm ||
test "x$OPENJDK_TARGET_CPU" = xm68k ||
test "x$OPENJDK_TARGET_CPU" = xmips ||
test "x$OPENJDK_TARGET_CPU" = xmipsel ||
test "x$OPENJDK_TARGET_CPU" = xppc ||
test "x$OPENJDK_TARGET_CPU" = xsh); then
BASIC_JVM_LIBS="$BASIC_JVM_LIBS -latomic"
fi
fi
# perfstat lib