Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell11
提交
fbbdb34e
D
dragonwell11
项目概览
openanolis
/
dragonwell11
通知
7
Star
2
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
D
dragonwell11
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
fbbdb34e
编写于
10月 05, 2015
作者:
E
erikj
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
8138694: Devkit build on Macosx still requires Xcode to be installed
Reviewed-by: ihse, tbell
上级
d7394f2d
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
246 addition
and
170 deletion
+246
-170
common/autoconf/configure.ac
common/autoconf/configure.ac
+5
-0
common/autoconf/flags.m4
common/autoconf/flags.m4
+97
-71
common/autoconf/generated-configure.sh
common/autoconf/generated-configure.sh
+134
-97
common/autoconf/hotspot-spec.gmk.in
common/autoconf/hotspot-spec.gmk.in
+2
-2
common/autoconf/spec.gmk.in
common/autoconf/spec.gmk.in
+2
-0
common/autoconf/toolchain.m4
common/autoconf/toolchain.m4
+6
-0
未找到文件。
common/autoconf/configure.ac
浏览文件 @
fbbdb34e
...
...
@@ -165,6 +165,11 @@ SRCDIRS_SETUP_OUTPUT_DIRS
# First determine the toolchain type (compiler family)
TOOLCHAIN_DETERMINE_TOOLCHAIN_TYPE
# User supplied flags should be used when configure detects compilers
FLAGS_SETUP_USER_SUPPLIED_FLAGS
# The sysroot cflags are needed for configure to be able to run the compilers
FLAGS_SETUP_SYSROOT_FLAGS
# Then detect the actual binaries needed
TOOLCHAIN_PRE_DETECTION
TOOLCHAIN_DETECT_TOOLCHAIN_CORE
...
...
common/autoconf/flags.m4
浏览文件 @
fbbdb34e
...
...
@@ -23,6 +23,100 @@
# questions.
#
# Reset the global CFLAGS/LDFLAGS variables and initialize them with the
# corresponding configure arguments instead
AC_DEFUN_ONCE([FLAGS_SETUP_USER_SUPPLIED_FLAGS],
[
if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then
AC_MSG_WARN([Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags])
fi
if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then
AC_MSG_WARN([Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags])
fi
if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then
AC_MSG_WARN([Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags])
fi
AC_ARG_WITH(extra-cflags, [AS_HELP_STRING([--with-extra-cflags],
[extra flags to be used when compiling jdk c-files])])
AC_ARG_WITH(extra-cxxflags, [AS_HELP_STRING([--with-extra-cxxflags],
[extra flags to be used when compiling jdk c++-files])])
AC_ARG_WITH(extra-ldflags, [AS_HELP_STRING([--with-extra-ldflags],
[extra flags to be used when linking jdk])])
EXTRA_CFLAGS="$with_extra_cflags"
EXTRA_CXXFLAGS="$with_extra_cxxflags"
EXTRA_LDFLAGS="$with_extra_ldflags"
# Hotspot needs these set in their legacy form
LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $EXTRA_CFLAGS"
LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $EXTRA_CXXFLAGS"
LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $EXTRA_LDFLAGS"
AC_SUBST(LEGACY_EXTRA_CFLAGS)
AC_SUBST(LEGACY_EXTRA_CXXFLAGS)
AC_SUBST(LEGACY_EXTRA_LDFLAGS)
# The global CFLAGS and LDLAGS variables are used by configure tests and
# should include the extra parameters
CFLAGS="$EXTRA_CFLAGS"
CXXFLAGS="$EXTRA_CXXFLAGS"
LDFLAGS="$EXTRA_LDFLAGS"
CPPFLAGS=""
])
# Setup the sysroot flags and add them to global CFLAGS and LDFLAGS so
# that configure can use them while detecting compilers.
# TOOLCHAIN_TYPE is available here.
AC_DEFUN_ONCE([FLAGS_SETUP_SYSROOT_FLAGS],
[
if test "x$SYSROOT" != "x"; then
if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
if test "x$OPENJDK_TARGET_OS" = xsolaris; then
# Solaris Studio does not have a concept of sysroot. Instead we must
# make sure the default include and lib dirs are appended to each
# compile and link command line.
SYSROOT_CFLAGS="-I$SYSROOT/usr/include"
SYSROOT_LDFLAGS="-L$SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \
-L$SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR \
-L$SYSROOT/usr/ccs/lib$OPENJDK_TARGET_CPU_ISADIR"
fi
elif test "x$TOOLCHAIN_TYPE" = xgcc; then
SYSROOT_CFLAGS="--sysroot=$SYSROOT"
SYSROOT_LDFLAGS="--sysroot=$SYSROOT"
elif test "x$TOOLCHAIN_TYPE" = xclang; then
SYSROOT_CFLAGS="-isysroot $SYSROOT"
SYSROOT_LDFLAGS="-isysroot $SYSROOT"
fi
# Propagate the sysroot args to hotspot
LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $SYSROOT_CFLAGS"
LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $SYSROOT_CFLAGS"
LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $SYSROOT_LDFLAGS"
# The global CFLAGS and LDFLAGS variables need these for configure to function
CFLAGS="$CFLAGS $SYSROOT_CFLAGS"
CPPFLAGS="$CPPFLAGS $SYSROOT_CFLAGS"
CXXFLAGS="$CXXFLAGS $SYSROOT_CFLAGS"
LDFLAGS="$LDFLAGS $SYSROOT_LDFLAGS"
fi
if test "x$OPENJDK_TARGET_OS" = xmacosx; then
# We also need -iframework<path>/System/Library/Frameworks
SYSROOT_CFLAGS="$SYSROOT_CFLAGS -iframework $SYSROOT/System/Library/Frameworks"
SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -iframework $SYSROOT/System/Library/Frameworks"
# These always need to be set, or we can't find the frameworks embedded in JavaVM.framework
# set this here so it doesn't have to be peppered throughout the forest
SYSROOT_CFLAGS="$SYSROOT_CFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks"
SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks"
fi
AC_SUBST(SYSROOT_CFLAGS)
AC_SUBST(SYSROOT_LDFLAGS)
])
AC_DEFUN_ONCE([FLAGS_SETUP_INIT_FLAGS],
[
# Option used to tell the compiler whether to create 32- or 64-bit executables
...
...
@@ -113,44 +207,6 @@ AC_DEFUN_ONCE([FLAGS_SETUP_INIT_FLAGS],
# silence copyright notice and other headers.
COMMON_CCXXFLAGS="$COMMON_CCXXFLAGS -nologo"
fi
if test "x$SYSROOT" != "x"; then
if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
if test "x$OPENJDK_TARGET_OS" = xsolaris; then
# Solaris Studio does not have a concept of sysroot. Instead we must
# make sure the default include and lib dirs are appended to each
# compile and link command line.
SYSROOT_CFLAGS="-I$SYSROOT/usr/include"
SYSROOT_LDFLAGS="-L$SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \
-L$SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR \
-L$SYSROOT/usr/ccs/lib$OPENJDK_TARGET_CPU_ISADIR"
fi
elif test "x$OPENJDK_TARGET_OS" = xmacosx; then
# Apple only wants -isysroot <path>, but we also need -iframework<path>/System/Library/Frameworks
SYSROOT_CFLAGS="-isysroot \"$SYSROOT\" -iframework\"$SYSROOT/System/Library/Frameworks\""
SYSROOT_LDFLAGS=$SYSROOT_CFLAGS
elif test "x$TOOLCHAIN_TYPE" = xgcc; then
SYSROOT_CFLAGS="--sysroot=$SYSROOT"
SYSROOT_LDFLAGS="--sysroot=$SYSROOT"
elif test "x$TOOLCHAIN_TYPE" = xclang; then
SYSROOT_CFLAGS="-isysroot \"$SYSROOT\""
SYSROOT_LDFLAGS="-isysroot \"$SYSROOT\""
fi
# Propagate the sysroot args to hotspot
LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $SYSROOT_CFLAGS"
LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $SYSROOT_CFLAGS"
LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $SYSROOT_LDFLAGS"
fi
# These always need to be set, or we can't find the frameworks embedded in JavaVM.framework
# set this here so it doesn't have to be peppered throughout the forest
if test "x$OPENJDK_TARGET_OS" = xmacosx; then
SYSROOT_CFLAGS="$SYSROOT_CFLAGS -F\"$SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks\""
SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -F\"$SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks\""
fi
AC_SUBST(SYSROOT_CFLAGS)
AC_SUBST(SYSROOT_LDFLAGS)
])
AC_DEFUN_ONCE([FLAGS_SETUP_COMPILER_FLAGS_FOR_LIBS],
...
...
@@ -480,39 +536,9 @@ AC_DEFUN_ONCE([FLAGS_SETUP_COMPILER_FLAGS_FOR_JDK],
CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt"
fi
if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then
AC_MSG_WARN([Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags])
fi
if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then
AC_MSG_WARN([Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags])
fi
if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then
AC_MSG_WARN([Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags])
fi
AC_ARG_WITH(extra-cflags, [AS_HELP_STRING([--with-extra-cflags],
[extra flags to be used when compiling jdk c-files])])
AC_ARG_WITH(extra-cxxflags, [AS_HELP_STRING([--with-extra-cxxflags],
[extra flags to be used when compiling jdk c++-files])])
AC_ARG_WITH(extra-ldflags, [AS_HELP_STRING([--with-extra-ldflags],
[extra flags to be used when linking jdk])])
CFLAGS_JDK="${CFLAGS_JDK} $with_extra_cflags"
CXXFLAGS_JDK="${CXXFLAGS_JDK} $with_extra_cxxflags"
LDFLAGS_JDK="${LDFLAGS_JDK} $with_extra_ldflags"
# Hotspot needs these set in their legacy form
LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $with_extra_cflags"
LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $with_extra_cxxflags"
LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $with_extra_ldflags"
AC_SUBST(LEGACY_EXTRA_CFLAGS)
AC_SUBST(LEGACY_EXTRA_CXXFLAGS)
AC_SUBST(LEGACY_EXTRA_LDFLAGS)
CFLAGS_JDK="${CFLAGS_JDK} $EXTRA_CFLAGS"
CXXFLAGS_JDK="${CXXFLAGS_JDK} $EXTRA_CXXFLAGS"
LDFLAGS_JDK="${LDFLAGS_JDK} $EXTRA_LDFLAGS"
###############################################################################
#
...
...
common/autoconf/generated-configure.sh
浏览文件 @
fbbdb34e
...
...
@@ -705,9 +705,6 @@ CXXFLAGS_JDKLIB
CFLAGS_JDKEXE
CFLAGS_JDKLIB
MACOSX_VERSION_MIN
LEGACY_EXTRA_LDFLAGS
LEGACY_EXTRA_CXXFLAGS
LEGACY_EXTRA_CFLAGS
CXX_O_FLAG_NONE
CXX_O_FLAG_DEBUG
CXX_O_FLAG_NORM
...
...
@@ -728,8 +725,6 @@ SET_SHARED_LIBRARY_ORIGIN
SET_EXECUTABLE_ORIGIN
CXX_FLAG_REORDER
C_FLAG_REORDER
SYSROOT_LDFLAGS
SYSROOT_CFLAGS
RC_FLAGS
AR_OUT_OPTION
LD_OUT_OPTION
...
...
@@ -747,6 +742,8 @@ HOTSPOT_LD
HOTSPOT_CXX
HOTSPOT_RC
HOTSPOT_MT
BUILD_SYSROOT_LDFLAGS
BUILD_SYSROOT_CFLAGS
BUILD_LD
BUILD_CXX
BUILD_CC
...
...
@@ -793,6 +790,11 @@ VS_LIB
VS_INCLUDE
VS_PATH
CYGWIN_LINK
SYSROOT_LDFLAGS
SYSROOT_CFLAGS
LEGACY_EXTRA_LDFLAGS
LEGACY_EXTRA_CXXFLAGS
LEGACY_EXTRA_CFLAGS
EXE_SUFFIX
OBJ_SUFFIX
STATIC_LIBRARY
...
...
@@ -1078,11 +1080,11 @@ with_override_nashorn
with_override_jdk
with_import_hotspot
with_toolchain_type
with_toolchain_version
with_jtreg
with_extra_cflags
with_extra_cxxflags
with_extra_ldflags
with_toolchain_version
with_jtreg
enable_warnings_as_errors
enable_debug_symbols
enable_zip_debug_info
...
...
@@ -1937,14 +1939,14 @@ Optional Packages:
source
--with-toolchain-type the toolchain type (or family) to use, use '--help'
to show possible values [platform dependent]
--with-extra-cflags extra flags to be used when compiling jdk c-files
--with-extra-cxxflags extra flags to be used when compiling jdk c++-files
--with-extra-ldflags extra flags to be used when linking jdk
--with-toolchain-version
the version of the toolchain to look for, use
'--help' to show possible values [platform
dependent]
--with-jtreg Regression Test Harness [probed]
--with-extra-cflags extra flags to be used when compiling jdk c-files
--with-extra-cxxflags extra flags to be used when compiling jdk c++-files
--with-extra-ldflags extra flags to be used when linking jdk
--with-x use the X Window System
--with-cups specify prefix directory for the cups package
(expecting the headers under PATH/include)
...
...
@@ -3767,6 +3769,15 @@ ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
# questions.
#
# Reset the global CFLAGS/LDFLAGS variables and initialize them with the
# corresponding configure arguments instead
# Setup the sysroot flags and add them to global CFLAGS and LDFLAGS so
# that configure can use them while detecting compilers.
# TOOLCHAIN_TYPE is available here.
...
...
@@ -4364,7 +4375,7 @@ VS_SDK_PLATFORM_NAME_2013=
#CUSTOM_AUTOCONF_INCLUDE
# Do not change or remove the following line, it is needed for consistency checks:
DATE_WHEN_GENERATED=144
3605847
DATE_WHEN_GENERATED=144
4045451
###############################################################################
#
...
...
@@ -26827,6 +26838,109 @@ $as_echo "$as_me: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESC
fi
# User supplied flags should be used when configure detects compilers
if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5
$as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;}
fi
if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5
$as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;}
fi
if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5
$as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;}
fi
# Check whether --with-extra-cflags was given.
if test "${with_extra_cflags+set}" = set; then :
withval=$with_extra_cflags;
fi
# Check whether --with-extra-cxxflags was given.
if test "${with_extra_cxxflags+set}" = set; then :
withval=$with_extra_cxxflags;
fi
# Check whether --with-extra-ldflags was given.
if test "${with_extra_ldflags+set}" = set; then :
withval=$with_extra_ldflags;
fi
EXTRA_CFLAGS="$with_extra_cflags"
EXTRA_CXXFLAGS="$with_extra_cxxflags"
EXTRA_LDFLAGS="$with_extra_ldflags"
# Hotspot needs these set in their legacy form
LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $EXTRA_CFLAGS"
LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $EXTRA_CXXFLAGS"
LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $EXTRA_LDFLAGS"
# The global CFLAGS and LDLAGS variables are used by configure tests and
# should include the extra parameters
CFLAGS="$EXTRA_CFLAGS"
CXXFLAGS="$EXTRA_CXXFLAGS"
LDFLAGS="$EXTRA_LDFLAGS"
CPPFLAGS=""
# The sysroot cflags are needed for configure to be able to run the compilers
if test "x$SYSROOT" != "x"; then
if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
if test "x$OPENJDK_TARGET_OS" = xsolaris; then
# Solaris Studio does not have a concept of sysroot. Instead we must
# make sure the default include and lib dirs are appended to each
# compile and link command line.
SYSROOT_CFLAGS="-I$SYSROOT/usr/include"
SYSROOT_LDFLAGS="-L$SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \
-L$SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR \
-L$SYSROOT/usr/ccs/lib$OPENJDK_TARGET_CPU_ISADIR"
fi
elif test "x$TOOLCHAIN_TYPE" = xgcc; then
SYSROOT_CFLAGS="--sysroot=$SYSROOT"
SYSROOT_LDFLAGS="--sysroot=$SYSROOT"
elif test "x$TOOLCHAIN_TYPE" = xclang; then
SYSROOT_CFLAGS="-isysroot $SYSROOT"
SYSROOT_LDFLAGS="-isysroot $SYSROOT"
fi
# Propagate the sysroot args to hotspot
LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $SYSROOT_CFLAGS"
LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $SYSROOT_CFLAGS"
LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $SYSROOT_LDFLAGS"
# The global CFLAGS and LDFLAGS variables need these for configure to function
CFLAGS="$CFLAGS $SYSROOT_CFLAGS"
CPPFLAGS="$CPPFLAGS $SYSROOT_CFLAGS"
CXXFLAGS="$CXXFLAGS $SYSROOT_CFLAGS"
LDFLAGS="$LDFLAGS $SYSROOT_LDFLAGS"
fi
if test "x$OPENJDK_TARGET_OS" = xmacosx; then
# We also need -iframework<path>/System/Library/Frameworks
SYSROOT_CFLAGS="$SYSROOT_CFLAGS -iframework $SYSROOT/System/Library/Frameworks"
SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -iframework $SYSROOT/System/Library/Frameworks"
# These always need to be set, or we can't find the frameworks embedded in JavaVM.framework
# set this here so it doesn't have to be peppered throughout the forest
SYSROOT_CFLAGS="$SYSROOT_CFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks"
SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks"
fi
# Then detect the actual binaries needed
# FIXME: Is this needed?
...
...
@@ -40557,12 +40671,16 @@ $as_echo "$as_me: Rewriting BUILD_LD to \"$new_complete\"" >&6;}
fi
fi
BUILD_SYSROOT_CFLAGS=""
BUILD_SYSROOT_LDFLAGS=""
else
# If we are not cross compiling, use the normal target compilers for
# building the build platform executables.
BUILD_CC="$CC"
BUILD_CXX="$CXX"
BUILD_LD="$LD"
BUILD_SYSROOT_CFLAGS="$SYSROOT_CFLAGS"
BUILD_SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS"
fi
...
...
@@ -40570,6 +40688,8 @@ $as_echo "$as_me: Rewriting BUILD_LD to \"$new_complete\"" >&6;}
if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
# For hotspot, we need these in Windows mixed path,
# so rewrite them all. Need added .exe suffix.
...
...
@@ -41308,44 +41428,6 @@ $as_echo "$tool_specified" >&6; }
COMMON_CCXXFLAGS="$COMMON_CCXXFLAGS -nologo"
fi
if test "x$SYSROOT" != "x"; then
if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
if test "x$OPENJDK_TARGET_OS" = xsolaris; then
# Solaris Studio does not have a concept of sysroot. Instead we must
# make sure the default include and lib dirs are appended to each
# compile and link command line.
SYSROOT_CFLAGS="-I$SYSROOT/usr/include"
SYSROOT_LDFLAGS="-L$SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \
-L$SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR \
-L$SYSROOT/usr/ccs/lib$OPENJDK_TARGET_CPU_ISADIR"
fi
elif test "x$OPENJDK_TARGET_OS" = xmacosx; then
# Apple only wants -isysroot <path>, but we also need -iframework<path>/System/Library/Frameworks
SYSROOT_CFLAGS="-isysroot \"$SYSROOT\" -iframework\"$SYSROOT/System/Library/Frameworks\""
SYSROOT_LDFLAGS=$SYSROOT_CFLAGS
elif test "x$TOOLCHAIN_TYPE" = xgcc; then
SYSROOT_CFLAGS="--sysroot=$SYSROOT"
SYSROOT_LDFLAGS="--sysroot=$SYSROOT"
elif test "x$TOOLCHAIN_TYPE" = xclang; then
SYSROOT_CFLAGS="-isysroot \"$SYSROOT\""
SYSROOT_LDFLAGS="-isysroot \"$SYSROOT\""
fi
# Propagate the sysroot args to hotspot
LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $SYSROOT_CFLAGS"
LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $SYSROOT_CFLAGS"
LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $SYSROOT_LDFLAGS"
fi
# These always need to be set, or we can't find the frameworks embedded in JavaVM.framework
# set this here so it doesn't have to be peppered throughout the forest
if test "x$OPENJDK_TARGET_OS" = xmacosx; then
SYSROOT_CFLAGS="$SYSROOT_CFLAGS -F\"$SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks\""
SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -F\"$SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks\""
fi
# FIXME: Currently we must test this after toolchain but before flags. Fix!
...
...
@@ -42338,54 +42420,9 @@ $as_echo "$supports" >&6; }
CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt"
fi
if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5
$as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;}
fi
if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5
$as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;}
fi
if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5
$as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;}
fi
# Check whether --with-extra-cflags was given.
if test "${with_extra_cflags+set}" = set; then :
withval=$with_extra_cflags;
fi
# Check whether --with-extra-cxxflags was given.
if test "${with_extra_cxxflags+set}" = set; then :
withval=$with_extra_cxxflags;
fi
# Check whether --with-extra-ldflags was given.
if test "${with_extra_ldflags+set}" = set; then :
withval=$with_extra_ldflags;
fi
CFLAGS_JDK="${CFLAGS_JDK} $with_extra_cflags"
CXXFLAGS_JDK="${CXXFLAGS_JDK} $with_extra_cxxflags"
LDFLAGS_JDK="${LDFLAGS_JDK} $with_extra_ldflags"
# Hotspot needs these set in their legacy form
LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $with_extra_cflags"
LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $with_extra_cxxflags"
LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $with_extra_ldflags"
CFLAGS_JDK="${CFLAGS_JDK} $EXTRA_CFLAGS"
CXXFLAGS_JDK="${CXXFLAGS_JDK} $EXTRA_CXXFLAGS"
LDFLAGS_JDK="${LDFLAGS_JDK} $EXTRA_LDFLAGS"
###############################################################################
#
common/autoconf/hotspot-spec.gmk.in
浏览文件 @
fbbdb34e
...
...
@@ -48,8 +48,8 @@ ALT_CUPS_HEADERS_PATH:=$(patsubst -I%,%,$(filter -I%,@CUPS_CFLAGS@))
# The HOSTCC/HOSTCXX is Hotspot terminology for the BUILD_CC/BUILD_CXX, i.e. the
# compiler that produces code that can be run on the build platform.
HOSTCC:=@FIXPATH@ @BUILD_CC@
HOSTCXX:=@FIXPATH@ @BUILD_CXX@
HOSTCC:=@FIXPATH@ @BUILD_CC@
$(BUILD_SYSROOT_CFLAGS)
HOSTCXX:=@FIXPATH@ @BUILD_CXX@
$(BUILD_SYSROOT_CFLAGS)
####################################################
#
...
...
common/autoconf/spec.gmk.in
浏览文件 @
fbbdb34e
...
...
@@ -367,6 +367,8 @@ LDFLAGS_TESTEXE_SUFFIX:=@LDFLAGS_TESTEXE_SUFFIX@
# build platform.
BUILD_CC:=@FIXPATH@ @BUILD_CC@
BUILD_LD:=@FIXPATH@ @BUILD_LD@
BUILD_SYSROOT_CFLAGS:=@BUILD_SYSROOT_CFLAGS@
BUILD_SYSROOT_LDFLAGS:=@BUILD_SYSROOT_LDFLAGS@
AS:=@FIXPATH@ @AS@
...
...
common/autoconf/toolchain.m4
浏览文件 @
fbbdb34e
...
...
@@ -656,17 +656,23 @@ AC_DEFUN_ONCE([TOOLCHAIN_SETUP_BUILD_COMPILERS],
BASIC_FIXUP_EXECUTABLE(BUILD_CXX)
BASIC_PATH_PROGS(BUILD_LD, ld)
BASIC_FIXUP_EXECUTABLE(BUILD_LD)
BUILD_SYSROOT_CFLAGS=""
BUILD_SYSROOT_LDFLAGS=""
else
# If we are not cross compiling, use the normal target compilers for
# building the build platform executables.
BUILD_CC="$CC"
BUILD_CXX="$CXX"
BUILD_LD="$LD"
BUILD_SYSROOT_CFLAGS="$SYSROOT_CFLAGS"
BUILD_SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS"
fi
AC_SUBST(BUILD_CC)
AC_SUBST(BUILD_CXX)
AC_SUBST(BUILD_LD)
AC_SUBST(BUILD_SYSROOT_CFLAGS)
AC_SUBST(BUILD_SYSROOT_LDFLAGS)
])
# Setup legacy variables that are still needed as alternative ways to refer to
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录