omajid pushed to java-1.8.0-openjdk (f20). "Build all java code with -g (..more)"

notifications at fedoraproject.org notifications at fedoraproject.org
Thu Apr 16 17:24:56 UTC 2015


>From b7f2073b91b49ba63c06e224ebd887aa2a4284db Mon Sep 17 00:00:00 2001
From: Omair Majid <omajid at redhat.com>
Date: Thu, 16 Apr 2015 13:24:21 -0400
Subject: Build all java code with -g

Also, test at build-time to ensure debugging information is included.

Resolves: rhbz#1150932

diff --git a/java-1.8.0-openjdk.spec b/java-1.8.0-openjdk.spec
index 9c82f10..5e916cd 100644
--- a/java-1.8.0-openjdk.spec
+++ b/java-1.8.0-openjdk.spec
@@ -128,7 +128,7 @@
 
 Name:    java-%{javaver}-%{origin}
 Version: %{javaver}.%{updatever}
-Release: 31.%{buildver}%{?dist}
+Release: 32.%{buildver}%{?dist}
 # java-1.5.0-ibm from jpackage.org set Epoch to 1 for unknown reasons,
 # and this change was brought into RHEL-4.  java-1.5.0-ibm packages
 # also included the epoch in their virtual provides.  This created a
@@ -559,6 +559,7 @@ bash ../../configure \
 
 make \
     DEBUG_BINARIES=true \
+    JAVAC_FLAGS=-g \
     STRIP_POLICY=no_strip \
     POST_STRIP_CMD="" \
     LOG=trace \
@@ -610,7 +611,17 @@ if [ -f "$ZERO_JVM" ] ; then
 fi
 
 # Check src.zip has all sources. See RHBZ#1130490
-jar -tf $JAVA_HOME/src.zip | grep Unsafe
+jar -tf $JAVA_HOME/src.zip | grep 'sun.misc.Unsafe'
+
+# Check class files include useful debugging information
+$JAVA_HOME/bin/javap -l java.lang.Object | grep "Compiled from"
+$JAVA_HOME/bin/javap -l java.lang.Object | grep LineNumberTable
+$JAVA_HOME/bin/javap -l java.lang.Object | grep LocalVariableTable
+
+# Check generated class files include useful debugging information
+$JAVA_HOME/bin/javap -l java.nio.ByteBuffer | grep "Compiled from"
+$JAVA_HOME/bin/javap -l java.nio.ByteBuffer | grep LineNumberTable
+$JAVA_HOME/bin/javap -l java.nio.ByteBuffer | grep LocalVariableTable
 
 %install
 rm -rf $RPM_BUILD_ROOT
@@ -1151,6 +1162,11 @@ exit 0
 %{_jvmdir}/%{jredir}/lib/accessibility.properties
 
 %changelog
+* Thu Apr 16 2015 Omair Majid <omajid at redhat.com> - 1:1.8.0.45-32.b13
+- Build all java code with -g
+- Test at build-time to ensure debugging information is included
+- Resolves: rhbz#1150932
+
 * Fri Apr 10 2015 Jiri Vanek <jvanek at redhat.com> - 1:1.8.0.45-31.b13
 - repacked sources
 - added Patch204: zero-interpreter-fix.patch
-- 
cgit v0.10.2


	http://pkgs.fedoraproject.org/cgit/java-1.8.0-openjdk.git/commit/?h=f20&id=b7f2073b91b49ba63c06e224ebd887aa2a4284db


More information about the scm-commits mailing list