6829575: 100028: Debug information is incomplete or missing
authoraph
Fri, 17 Apr 2009 15:50:12 +0100
changeset 2784 f159507e4db1
parent 2524 9cdd6fb628a1
child 2785 cbf5323db2a4
6829575: 100028: Debug information is incomplete or missing Summary: Enable debugging in many places Reviewed-by: ohair Contributed-by: Andrew Haley <aph@redhat.com>
hotspot/make/linux/makefiles/gcc.make
hotspot/make/linux/makefiles/jsig.make
hotspot/make/linux/makefiles/saproc.make
--- a/hotspot/make/linux/makefiles/gcc.make	Thu Apr 16 11:22:40 2009 -0700
+++ b/hotspot/make/linux/makefiles/gcc.make	Fri Apr 17 15:50:12 2009 +0100
@@ -166,3 +166,9 @@
 ifeq ($(DEBUG_CFLAGS/$(BUILDARCH)),)
 DEBUG_CFLAGS += -gstabs
 endif
+
+# DEBUG_BINARIES overrides everything, use full -g debug information
+ifeq ($(DEBUG_BINARIES), true)
+  DEBUG_CFLAGS = -g
+  CFLAGS += $(DEBUG_CFLAGS)
+endif
--- a/hotspot/make/linux/makefiles/jsig.make	Thu Apr 16 11:22:40 2009 -0700
+++ b/hotspot/make/linux/makefiles/jsig.make	Fri Apr 17 15:50:12 2009 +0100
@@ -41,10 +41,15 @@
 
 LFLAGS_JSIG += -D_GNU_SOURCE -D_REENTRANT
 
+# DEBUG_BINARIES overrides everything, use full -g debug information
+ifeq ($(DEBUG_BINARIES), true)
+  JSIG_DEBUG_CFLAGS = -g
+endif
+
 $(LIBJSIG): $(JSIGSRCDIR)/jsig.c $(LIBJSIG_MAPFILE)
 	@echo Making signal interposition lib...
 	$(QUIETLY) $(CC) $(SYMFLAG) $(ARCHFLAG) $(SHARED_FLAG) $(PICFLAG) \
-                         $(LFLAGS_JSIG) -o $@ $< -ldl
+                         $(LFLAGS_JSIG) $(JSIG_DEBUG_CFLAGS) -o $@ $< -ldl
 
 install_jsig: $(LIBJSIG)
 	@echo "Copying $(LIBJSIG) to $(DEST_JSIG)"
--- a/hotspot/make/linux/makefiles/saproc.make	Thu Apr 16 11:22:40 2009 -0700
+++ b/hotspot/make/linux/makefiles/saproc.make	Fri Apr 17 15:50:12 2009 +0100
@@ -43,6 +43,11 @@
 
 DEST_SAPROC = $(JDK_LIBDIR)/$(LIBSAPROC)
 
+# DEBUG_BINARIES overrides everything, use full -g debug information
+ifeq ($(DEBUG_BINARIES), true)
+  SA_DEBUG_CFLAGS = -g
+endif
+
 # if $(AGENT_DIR) does not exist, we don't build SA
 # also, we don't build SA on Itanium.
 
@@ -67,6 +72,7 @@
 	           -I$(BOOT_JAVA_HOME)/include/$(Platform_os_family)    \
 	           $(SASRCFILES)                                        \
 	           $(SA_LFLAGS)                                         \
+	           $(SA_DEBUG_CFLAGS)                                   \
 	           -o $@                                                \
 	           -lthread_db