mirror of
https://github.com/darlinghq/darling-openjdk.git
synced 2024-11-26 22:00:25 +00:00
[macos] Update build system to successfully build the zero variant for macOS/arm64
Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
This commit is contained in:
parent
a0990b15c3
commit
ca080a229f
0
make/autoconf/build-aux/autoconf-config.sub
Normal file → Executable file
0
make/autoconf/build-aux/autoconf-config.sub
Normal file → Executable file
0
make/autoconf/build-aux/config.sub
vendored
Normal file → Executable file
0
make/autoconf/build-aux/config.sub
vendored
Normal file → Executable file
@ -827,6 +827,12 @@ 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$FLAGS_OS" = xmacosx; then
|
||||
if test "x$FLAGS_CPU_ARCH" = xaarch64; then
|
||||
# override it to use arm64
|
||||
$1_CFLAGS_CPU_JDK="${$1_CFLAGS_CPU_JDK} -arch arm64"
|
||||
$1_CFLAGS_CPU_JVM="${$1_CFLAGS_CPU_JVM} -arch arm64"
|
||||
fi
|
||||
fi
|
||||
|
||||
elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
|
||||
|
@ -187,6 +187,14 @@ AC_DEFUN([FLAGS_SETUP_LDFLAGS_CPU_DEP],
|
||||
$1_CPU_LDFLAGS="$ARM_ARCH_TYPE_FLAGS $ARM_FLOAT_TYPE_FLAGS"
|
||||
fi
|
||||
|
||||
elif test "x$TOOLCHAIN_TYPE" = xclang; then
|
||||
if test "x$OPENJDK_TARGET_OS" = xmacosx; then
|
||||
if test "x${OPENJDK_$1_CPU}" = xaarch64; then
|
||||
# override it to use arm64
|
||||
$1_CPU_LDFLAGS="${$1_CPU_LDFLAGS} -arch arm64"
|
||||
fi
|
||||
fi
|
||||
|
||||
elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
|
||||
if test "x${OPENJDK_$1_CPU}" = "xsparcv9"; then
|
||||
$1_CPU_LDFLAGS_JVM_ONLY="-xarch=sparc"
|
||||
@ -214,7 +222,8 @@ AC_DEFUN([FLAGS_SETUP_LDFLAGS_CPU_DEP],
|
||||
|
||||
# Export variables according to old definitions, prefix with $2 if present.
|
||||
LDFLAGS_JDK_COMMON="$BASIC_LDFLAGS $BASIC_LDFLAGS_JDK_ONLY \
|
||||
$OS_LDFLAGS_JDK_ONLY $DEBUGLEVEL_LDFLAGS_JDK_ONLY ${$2EXTRA_LDFLAGS}"
|
||||
$OS_LDFLAGS_JDK_ONLY $DEBUGLEVEL_LDFLAGS_JDK_ONLY \
|
||||
${$1_CPU_LDFLAGS} ${$2EXTRA_LDFLAGS}"
|
||||
$2LDFLAGS_JDKLIB="$LDFLAGS_JDK_COMMON $BASIC_LDFLAGS_JDK_LIB_ONLY \
|
||||
${$1_LDFLAGS_JDK_LIBPATH} $SHARED_LIBRARY_FLAGS"
|
||||
$2LDFLAGS_JDKEXE="$LDFLAGS_JDK_COMMON $EXECUTABLE_LDFLAGS \
|
||||
|
@ -130,8 +130,13 @@ AC_DEFUN([FLAGS_SETUP_MACOSX_VERSION],
|
||||
# of the OS. It currently has a hard coded value. Setting this also limits
|
||||
# exposure to API changes in header files. Bumping this is likely to
|
||||
# require code changes to build.
|
||||
if test "x$OPENJDK_TARGET_CPU" = xaarch64 ; then
|
||||
MACOSX_VERSION_MIN=10.16.0
|
||||
MACOSX_VERSION_MIN_NODOTS=101600
|
||||
else
|
||||
MACOSX_VERSION_MIN=10.9.0
|
||||
MACOSX_VERSION_MIN_NODOTS=${MACOSX_VERSION_MIN//\./}
|
||||
MACOSX_VERSION_MIN_NODOTS=1090
|
||||
fi
|
||||
|
||||
AC_SUBST(MACOSX_VERSION_MIN)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user