diff --git a/asm-3.3.1-jdk9.patch b/asm-3.3.1-jdk9.patch new file mode 100644 index 0000000..9d81ed7 --- /dev/null +++ b/asm-3.3.1-jdk9.patch @@ -0,0 +1,20 @@ +--- asm-3.3.1/src/org/objectweb/asm/util/CheckMethodAdapter.java 2010-12-19 09:35:58.000000000 +0100 ++++ asm-3.3.1/src/org/objectweb/asm/util/CheckMethodAdapter.java 2018-05-16 09:39:36.099879920 +0200 +@@ -1009,7 +1009,7 @@ + checkIdentifier(name, begin, slash, null); + begin = slash + 1; + } while (slash != max); +- } catch (IllegalArgumentException _) { ++ } catch (IllegalArgumentException ex) { + throw new IllegalArgumentException("Invalid " + + msg + + " (must be a fully qualified class name in internal form): " +@@ -1083,7 +1083,7 @@ + } + try { + checkInternalName(desc, start + 1, index, null); +- } catch (IllegalArgumentException _) { ++ } catch (IllegalArgumentException ex) { + throw new IllegalArgumentException("Invalid descriptor: " + + desc); + } diff --git a/objectweb-asm.changes b/objectweb-asm.changes index 28bcfde..6e13935 100644 --- a/objectweb-asm.changes +++ b/objectweb-asm.changes @@ -1,3 +1,12 @@ +------------------------------------------------------------------- +Wed May 16 07:57:32 UTC 2018 - fstrba@suse.com + +- Build with source and target 8 to prepare for a possible removal + of 1.6 compatibility in OpenJDK 11 +- Added patch: + * asm-3.3.1-jdk9.patch + + Since JDK9, "_" is reserved keyword + ------------------------------------------------------------------- Wed Oct 4 08:01:47 UTC 2017 - fstrba@suse.com diff --git a/objectweb-asm.spec b/objectweb-asm.spec index 8d134fb..375fc78 100644 --- a/objectweb-asm.spec +++ b/objectweb-asm.spec @@ -1,7 +1,7 @@ # # spec file for package objectweb-asm # -# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -35,8 +35,9 @@ Source8: http://repo1.maven.org/maven2/asm/asm-parent/3.3.1/asm-parent-3. Source9: asm-MANIFEST.MF Patch0: objectweb-asm-no-classpath-in-manifest.patch Patch1: asm-3.3.1-sourcetarget.patch +Patch2: asm-3.3.1-jdk9.patch BuildRequires: ant >= 1.6.5 -BuildRequires: java-devel >= 1.6 +BuildRequires: java-devel >= 1.8 BuildRequires: javapackages-local BuildRequires: javapackages-tools BuildRequires: objectweb-anttask @@ -62,6 +63,7 @@ smaller. %setup -q -n asm-%{version} %patch0 -p1 %patch1 -p1 +%patch2 -p1 perl -pi -e 's/\r$//g' LICENSE.txt README.txt mkdir META-INF cp -p %{SOURCE9} META-INF/MANIFEST.MF @@ -71,7 +73,7 @@ export CLASSPATH= export OPT_JAR_LIST=: ant \ -Dobjectweb.ant.tasks.path=$(build-classpath objectweb-anttask) \ - -Dant.build.javac.source=1.6 -Dant.build.javac.target=1.6 \ + -Dant.build.javac.source=8 -Dant.build.javac.target=8 \ jar %install