--- old/make/common/NativeCompilation.gmk 2016-12-15 15:52:32.525783129 +0100 +++ new/make/common/NativeCompilation.gmk 2016-12-15 15:52:32.457780256 +0100 @@ -371,7 +371,8 @@ # when compiling C code # DISABLED_WARNINGS_CXX_ Disable the given warnings for the specified # toolchain when compiling C++ code -# STRIP_SYMBOLS Set to true to strip the final binary if the toolchain allows for it +# STRIP_SYMBOLS Set to false to override global strip policy and always leave +# symbols in the binary, if the toolchain allows for it # DEBUG_SYMBOLS Set to false to disable generation of debug symbols # COPY_DEBUG_SYMBOLS Set to false to override global setting of debug symbol copying # ZIP_EXTERNAL_DEBUG_SYMBOLS Set to false to override global setting of debug symbol @@ -886,6 +887,10 @@ endif # $1_DEBUG_SYMBOLS != false endif # COPY_DEBUG_SYMBOLS + # Unless specifically set, stripping should only happen if symbols are also + # being copied. + $$(call SetIfEmpty, $1_STRIP_SYMBOLS, $$($1_COPY_DEBUG_SYMBOLS)) + ifneq ($$($1_STRIP_SYMBOLS), false) ifneq ($$($1_STRIP), ) # Default to using the global STRIPFLAGS. Allow for overriding with an empty value --- old/hotspot/make/lib/CompileDtracePostJvm.gmk 2016-12-15 15:52:32.941800697 +0100 +++ new/hotspot/make/lib/CompileDtracePostJvm.gmk 2016-12-15 15:52:32.829795966 +0100 @@ -188,7 +188,6 @@ LIBS := $(LIBDL) -lc -lthread -ldoor, \ MAPFILE := $(HOTSPOT_TOPDIR)/make/mapfiles/libjvm_dtrace/mapfile-vers, \ OBJECT_DIR := $(LIBJVM_DTRACE_OUTPUTDIR)/objs, \ - STRIP_SYMBOLS := true, \ )) LIBJVM_DB_OUTPUTDIR := $(JVM_VARIANT_OUTPUTDIR)/libjvm_db @@ -206,7 +205,6 @@ LIBS := -lc, \ MAPFILE := $(HOTSPOT_TOPDIR)/make/mapfiles/libjvm_db/mapfile-vers, \ OBJECT_DIR := $(LIBJVM_DB_OUTPUTDIR)/objs, \ - STRIP_SYMBOLS := true, \ )) # We need the generated JvmOffsets.h before we can compile the libjvm_db source code. --- old/hotspot/make/lib/CompileGtest.gmk 2016-12-15 15:52:33.377819111 +0100 +++ new/hotspot/make/lib/CompileGtest.gmk 2016-12-15 15:52:33.269814549 +0100 @@ -86,6 +86,7 @@ USE_MAPFILE_FOR_SYMBOLS := true, \ COPY_DEBUG_SYMBOLS := $(GTEST_COPY_DEBUG_SYMBOLS), \ ZIP_EXTERNAL_DEBUG_SYMBOLS := false, \ + STRIP_SYMBOLS := false, \ PRECOMPILED_HEADER := $(JVM_PRECOMPILED_HEADER), \ PRECOMPILED_HEADER_EXCLUDE := gtest-all.cc gtestMain.cpp, \ )) --- old/hotspot/make/lib/Lib-jdk.hotspot.agent.gmk 2016-12-15 15:52:33.817837694 +0100 +++ new/hotspot/make/lib/Lib-jdk.hotspot.agent.gmk 2016-12-15 15:52:33.705832964 +0100 @@ -113,7 +113,6 @@ LIBS := $(SA_LIBS), \ MAPFILE := $(SA_MAPFILE), \ OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/libsa, \ - STRIP_SYMBOLS := true, \ )) TARGETS += $(BUILD_LIBSA)