Mercurial > hg > openjdk > jdk8 > jdk
changeset 6101:3717bcf9d7a7
8002040: Allow Full Debug Symbols when cross-compiling
Reviewed-by: dcubed, erikj, tbell
author | dholmes |
---|---|
date | Wed, 07 Nov 2012 23:12:45 -0500 |
parents | 26dbd73fb766 |
children | 1e79fec4a01f |
files | make/common/Defs-linux.gmk |
diffstat | 1 files changed, 12 insertions(+), 15 deletions(-) [+] |
line wrap: on
line diff
--- a/make/common/Defs-linux.gmk Wed Nov 07 15:39:07 2012 -0800 +++ b/make/common/Defs-linux.gmk Wed Nov 07 23:12:45 2012 -0500 @@ -111,21 +111,18 @@ # since objcopy is optional, we set ZIP_DEBUGINFO_FILES later ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1) - # Default OBJCOPY comes from GNU Binutils on Linux: - DEF_OBJCOPY=/usr/bin/objcopy - ifdef CROSS_COMPILE_ARCH - # don't try to generate .debuginfo files when cross compiling - _JUNK_ := $(shell \ - echo >&2 "INFO: cross compiling for ARCH $(CROSS_COMPILE_ARCH)," \ - "skipping .debuginfo generation.") - OBJCOPY= + ifndef CROSS_COMPILE_ARCH + # Default OBJCOPY comes from GNU Binutils on Linux: + DEF_OBJCOPY=/usr/bin/objcopy else - OBJCOPY=$(shell test -x $(DEF_OBJCOPY) && echo $(DEF_OBJCOPY)) - ifneq ($(ALT_OBJCOPY),) - _JUNK_ := $(shell echo >&2 "INFO: ALT_OBJCOPY=$(ALT_OBJCOPY)") - # disable .debuginfo support by setting ALT_OBJCOPY to a non-existent path - OBJCOPY=$(shell test -x $(ALT_OBJCOPY) && echo $(ALT_OBJCOPY)) - endif + # Assume objcopy is part of the cross-compilation toolkit + DEF_OBJCOPY=$(COMPILER_PATH)/objcopy + endif + OBJCOPY=$(shell test -x $(DEF_OBJCOPY) && echo $(DEF_OBJCOPY)) + ifneq ($(ALT_OBJCOPY),) + _JUNK_ := $(shell echo >&2 "INFO: ALT_OBJCOPY=$(ALT_OBJCOPY)") + # disable .debuginfo support by setting ALT_OBJCOPY to a non-existent path + OBJCOPY=$(shell test -x $(ALT_OBJCOPY) && echo $(ALT_OBJCOPY)) endif # Setting ENABLE_FULL_DEBUG_SYMBOLS=1 (and OBJCOPY) above enables the @@ -137,7 +134,7 @@ ifeq ($(OBJCOPY),) _JUNK_ := $(shell \ - echo >&2 "INFO: no objcopy cmd found so cannot create .debuginfo files.") + echo >&2 "INFO: no objcopy cmd found so cannot create .debuginfo files. You may need to set ALT_OBJCOPY.") ENABLE_FULL_DEBUG_SYMBOLS=0 else _JUNK_ := $(shell \