diff --git a/RELEASE_3_1.tar.gz b/RELEASE_3_1.tar.gz
new file mode 100644
index 0000000..2bcc43c
--- /dev/null
+++ b/RELEASE_3_1.tar.gz
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a48c857232b902950cbd7c6b07bd70bfcc3773b9d4dd188f35f885c4477b8d3b
+size 1417623
diff --git a/cglib-2.2.pom b/cglib-3.1.pom
similarity index 58%
rename from cglib-2.2.pom
rename to cglib-3.1.pom
index a9aacec..e62d8e3 100644
--- a/cglib-2.2.pom
+++ b/cglib-3.1.pom
@@ -4,8 +4,9 @@
cglib
cglib
Code Generation Library
- 2.2
+ 3.1
http://cglib.sourceforge.net/
+ Code generation library
ASF 2.0
@@ -14,18 +15,19 @@
+ scm:cvs:pserver:anonymous@cglib.cvs.sourceforge.net:/cvsroot/cglib:cglib
http://cglib.cvs.sourceforge.net/cglib
- asm
+ org.ow2.asm
asm
- 3.1
+ 4.2
- asm
+ org.ow2.asm
asm-util
- 3.1
+ 4.2
true
@@ -35,4 +37,18 @@
true
+
+
+ baliuka
+ Juozas Baliuka
+
+
+ herbyderby
+ Chris Nokleberg
+
+
+ sameb
+ Sam Berlin
+
+
diff --git a/cglib-build_xml.patch b/cglib-build_xml.patch
index 7e2c699..34b6bbf 100644
--- a/cglib-build_xml.patch
+++ b/cglib-build_xml.patch
@@ -1,13 +1,14 @@
---- cglib/build.xml.orig 2008-08-14 13:37:22.000000000 +0200
-+++ cglib/build.xml 2008-08-14 13:35:51.000000000 +0200
-@@ -124,14 +124,6 @@
+--- cglib/build.xml 2013-12-07 17:08:18.000000000 +0100
++++ cglib/build.xml 2018-10-29 15:10:26.294707872 +0100
+@@ -123,15 +123,6 @@
+
-
+-
-
-
-
--
+-
-
-
-
diff --git a/cglib-src-2.2.jar b/cglib-src-2.2.jar
deleted file mode 100644
index 602ba5f..0000000
--- a/cglib-src-2.2.jar
+++ /dev/null
@@ -1,3 +0,0 @@
-version https://git-lfs.github.com/spec/v1
-oid sha256:762e0214f0d31f224e712a7a5b4768c16ad24741ba98fc2e94715ae390d07fcb
-size 1520971
diff --git a/cglib.changes b/cglib.changes
index 5dc47ed..455554d 100644
--- a/cglib.changes
+++ b/cglib.changes
@@ -1,3 +1,33 @@
+-------------------------------------------------------------------
+Mon Oct 29 14:24:03 UTC 2018 - Fridrich Strba
+
+- Upgrade to version 3.1, the last one buildable with ant
+- Depend on asm5
+- Modified patch:
+ * cglib-build_xml.patch
+ + rediff to changed context
+- Added patch:
+ * fix-javadoc.patch
+ + Do not import with wildcards a package that has no classes
+ + Fixes javadoc generation
+
+-------------------------------------------------------------------
+Mon Oct 29 13:45:46 UTC 2018 - Fridrich Strba
+
+- Add aliases to the maven artifact
+
+-------------------------------------------------------------------
+Wed Jun 13 15:39:52 UTC 2018 - fstrba@suse.com
+
+- Depend on asm3 and not objectweb-asm, since the binaries
+ are equivalent.
+
+-------------------------------------------------------------------
+Wed May 16 09:07:44 UTC 2018 - fstrba@suse.com
+
+- Build with source and target 8 to prepare for a possible removal
+ of 1.6 compatibility
+
-------------------------------------------------------------------
Mon Sep 18 06:30:45 UTC 2017 - fstrba@suse.com
diff --git a/cglib.spec b/cglib.spec
index c0922c1..640abde 100644
--- a/cglib.spec
+++ b/cglib.spec
@@ -1,7 +1,7 @@
#
# spec file for package cglib
#
-# 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
@@ -12,29 +12,30 @@
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
-# Please submit bugfixes or comments via http://bugs.opensuse.org/
+# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
+%global tarball_name RELEASE_3_1
Name: cglib
-Version: 2.2
+Version: 3.1
Release: 0
Summary: Code Generation Library
License: Apache-2.0
Group: Development/Libraries/Java
-Url: http://cglib.sourceforge.net/
-Source0: %{name}-src-%{version}.jar
-Source1: /%{name}-%{version}.pom
+URL: http://cglib.sourceforge.net/
+Source0: https://github.com/cglib/cglib/archive/%{tarball_name}.tar.gz
+Source1: http://central.maven.org/maven2/%{name}/%{name}/%{version}/%{name}-%{version}.pom
# Remove the repackaging step that includes other jars into the final thing
Patch0: %{name}-build_xml.patch
+Patch1: fix-javadoc.patch
BuildRequires: ant >= 1.6
-BuildRequires: fdupes
-BuildRequires: java-devel >= 1.6.0
# Needed for maven conversions
+BuildRequires: asm5
+BuildRequires: fdupes
+BuildRequires: java-devel >= 1.8
BuildRequires: javapackages-local
BuildRequires: javapackages-tools
-BuildRequires: objectweb-asm
-BuildRequires: unzip
Provides: %{name}-nohook = %{version}-%{release}
Obsoletes: %{name}-nohook < %{version}-%{release}
BuildArch: noarch
@@ -54,15 +55,15 @@ Library, It is used to extend JAVA classes and implements interfaces at
runtime.
%prep
-%setup -q -T -c -n %{name}
-unzip -q %{SOURCE0}
+%setup -q -n %{name}-%{tarball_name}
rm lib/*.jar
-build-jar-repository -s -p lib objectweb-asm ant
+build-jar-repository -s -p lib asm5 ant
%patch0 -p1
+%patch1 -p1
%build
ant \
- -Dcompile.target=1.6 -Dcompile.source=1.6 \
+ -Dcompile.target=8 -Dcompile.source=8 \
jar javadoc
%install
@@ -76,12 +77,13 @@ cp -r docs %{buildroot}%{_javadocdir}/%{name}
%fdupes -s %{buildroot}%{_javadocdir}/%{name}
#maven pom
-mkdir -p %{buildroot}%{_mavenpomdir}
-cp %{SOURCE1} %{buildroot}%{_mavenpomdir}/JPP-%{name}.pom
-%add_maven_depmap JPP-%{name}.pom %{name}.jar
+install -dm 755 %{buildroot}%{_mavenpomdir}
+install -pm 0644 %{SOURCE1} %{buildroot}%{_mavenpomdir}/%{name}.pom
+%add_maven_depmap %{name}.pom %{name}.jar -a "net.sf.cglib:cglib,cglib:cglib-full,cglib:cglib-nodep,org.sonatype.sisu.inject:cglib"
%files
-%doc LICENSE NOTICE
+%license LICENSE
+%doc NOTICE
%{_javadir}/*.jar
%{_mavenpomdir}/*
%config(noreplace) %{_datadir}/maven-metadata/%{name}.xml
diff --git a/fix-javadoc.patch b/fix-javadoc.patch
new file mode 100644
index 0000000..d0a65fb
--- /dev/null
+++ b/fix-javadoc.patch
@@ -0,0 +1,11 @@
+diff -urEbwB cglib/src/proxy/net/sf/cglib/reflect/MethodDelegate.java cglib/src/proxy/net/sf/cglib/reflect/MethodDelegate.java
+--- cglib/src/proxy/net/sf/cglib/reflect/MethodDelegate.java 2013-12-07 17:08:18.000000000 +0100
++++ cglib/src/proxy/net/sf/cglib/reflect/MethodDelegate.java 2018-10-29 15:15:55.528397043 +0100
+@@ -16,7 +16,6 @@
+ package net.sf.cglib.reflect;
+
+ import java.lang.reflect.*;
+-import net.sf.cglib.*;
+ import net.sf.cglib.core.*;
+ import org.objectweb.asm.ClassVisitor;
+ import org.objectweb.asm.Type;