# HG changeset patch # User mbaesken # Date 1524743716 -7200 # Node ID 98f57dff16f3b9a88ba6d6ac498e93eebb60465d # Parent 2d9dd2b876a0153eabb745900cdfad048f94d6f9 8202322: AIX: symbol visibility flags not support on xlc 12.1 Reviewed-by: erikj, clanger diff -r 2d9dd2b876a0 -r 98f57dff16f3 make/launcher/Launcher-jdk.pack.gmk --- a/make/launcher/Launcher-jdk.pack.gmk Tue May 15 15:36:46 2018 +0200 +++ b/make/launcher/Launcher-jdk.pack.gmk Thu Apr 26 13:55:16 2018 +0200 @@ -39,6 +39,7 @@ # On Mac, we have always exported all symbols, probably due to oversight # and/or misunderstanding. To emulate this, don't hide any symbols # by default. +# On AIX/xlc we need at least xlc 13.1 for the symbol hiding # Also provide an override for non-conformant libraries. ifeq ($(TOOLCHAIN_TYPE), gcc) CXXFLAGS_JDKEXE += -fvisibility=hidden @@ -50,7 +51,9 @@ else ifeq ($(TOOLCHAIN_TYPE), solstudio) CXXFLAGS_JDKEXE += -xldscope=hidden else ifeq ($(TOOLCHAIN_TYPE), xlc) - CXXFLAGS_JDKEXE += -qvisibility=hidden + ifneq ($(CC_VERSION_NUMBER), 12.1) + CXXFLAGS_JDKEXE += -qvisibility=hidden + endif endif UNPACKEXE_SRC := $(TOPDIR)/src/jdk.pack/share/native/common-unpack \ diff -r 2d9dd2b876a0 -r 98f57dff16f3 make/launcher/LauncherCommon.gmk --- a/make/launcher/LauncherCommon.gmk Tue May 15 15:36:46 2018 +0200 +++ b/make/launcher/LauncherCommon.gmk Thu Apr 26 13:55:16 2018 +0200 @@ -45,6 +45,7 @@ # On Mac, we have always exported all symbols, probably due to oversight # and/or misunderstanding. To emulate this, don't hide any symbols # by default. +# On AIX/xlc we need at least xlc 13.1 for the symbol hiding # Also provide an override for non-conformant libraries. ifeq ($(TOOLCHAIN_TYPE), gcc) LAUNCHER_CFLAGS += -fvisibility=hidden @@ -56,7 +57,9 @@ else ifeq ($(TOOLCHAIN_TYPE), solstudio) LAUNCHER_CFLAGS += -xldscope=hidden else ifeq ($(TOOLCHAIN_TYPE), xlc) - LAUNCHER_CFLAGS += -qvisibility=hidden + ifneq ($(CC_VERSION_NUMBER), 12.1) + CXXFLAGS_JDKEXE += -qvisibility=hidden + endif endif LAUNCHER_SRC := $(TOPDIR)/src/java.base/share/native/launcher diff -r 2d9dd2b876a0 -r 98f57dff16f3 make/lib/LibCommon.gmk --- a/make/lib/LibCommon.gmk Tue May 15 15:36:46 2018 +0200 +++ b/make/lib/LibCommon.gmk Thu Apr 26 13:55:16 2018 +0200 @@ -41,6 +41,7 @@ # On Mac, we have always exported all symbols, probably due to oversight # and/or misunderstanding. To emulate this, don't hide any symbols # by default. +# On AIX/xlc we need at least xlc 13.1 for the symbol hiding # Also provide an override for non-conformant libraries. ifeq ($(TOOLCHAIN_TYPE), gcc) CFLAGS_JDKLIB += -fvisibility=hidden @@ -58,9 +59,11 @@ CXXFLAGS_JDKLIB += -xldscope=hidden EXPORT_ALL_SYMBOLS := -xldscope=global else ifeq ($(TOOLCHAIN_TYPE), xlc) - CFLAGS_JDKLIB += -qvisibility=hidden - CXXFLAGS_JDKLIB += -qvisibility=hidden - EXPORT_ALL_SYMBOLS := -qvisibility=default + ifneq ($(CC_VERSION_NUMBER), 12.1) + CFLAGS_JDKLIB += -qvisibility=hidden + CXXFLAGS_JDKLIB += -qvisibility=hidden + EXPORT_ALL_SYMBOLS := -qvisibility=default + endif endif ################################################################################