Hello community, here is the log from the commit of package hamcrest for openSUSE:Leap:15.2 checked in at 2020-02-05 07:23:27 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Leap:15.2/hamcrest (Old) and /work/SRC/openSUSE:Leap:15.2/.hamcrest.new.26092 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "hamcrest" Wed Feb 5 07:23:27 2020 rev:22 rq:762721 version:1.3 Changes: -------- --- /work/SRC/openSUSE:Leap:15.2/hamcrest/hamcrest.changes 2020-01-15 15:10:29.698075385 +0100 +++ /work/SRC/openSUSE:Leap:15.2/.hamcrest.new.26092/hamcrest.changes 2020-02-05 07:23:36.682599966 +0100 @@ -1,0 +2,34 @@ +Wed Oct 2 20:24:49 UTC 2019 - Fridrich Strba <fst...@suse.com> + +- Remove references to the hamcrest-parent pom and do not + distribute it + * useless since we don't build with maven + * creates problems with gradle connector + +------------------------------------------------------------------- +Tue Jan 15 08:52:39 UTC 2019 - Fridrich Strba <fst...@suse.com> + +- Make jmock and easymock integration opt-in (bsc#1121956) + +------------------------------------------------------------------- +Fri Jan 4 16:13:17 UTC 2019 - Fridrich Strba <fst...@suse.com> + +- Use sources from github, which are accessible +- Do not build the hamcrest-text empty jar +- Split a core package off the main package +- Added patch: + * hamcrest-1.3-qdox-2.0.patch + + Fix build against QDox 2.0 +- Removed patch: + * hamcrest-1.3-no-integration.patch + + Not needed any more since integration is buildable +- Modified patches: + * hamcrest-1.3-build.patch + * hamcrest-1.3-fork-javac.patch + * hamcrest-1.3-javadoc.patch + * hamcrest-1.3-javadoc10.patch + * hamcrest-1.3-javadoc9.patch + * hamcrest-1.3-no-jarjar.patch + * hamcrest-1.3-random-build-crash.patch + +------------------------------------------------------------------- Old: ---- hamcrest-1.3-no-integration.patch hamcrest-1.3.tgz hamcrest-all-1.3.pom hamcrest-core-1.3.pom hamcrest-generator-1.3.pom hamcrest-integration-1.3.pom hamcrest-library-1.3.pom hamcrest-parent-1.3.pom hamcrest-text-1.3.pom hamcrest-text-MANIFEST.MF New: ---- hamcrest-1.3-qdox-2.0.patch hamcrest-java-1.3.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ hamcrest.spec ++++++ --- /var/tmp/diff_new_pack.5JocQi/_old 2020-02-05 07:23:37.246600203 +0100 +++ /var/tmp/diff_new_pack.5JocQi/_new 2020-02-05 07:23:37.250600205 +0100 @@ -1,7 +1,7 @@ # # spec file for package hamcrest # -# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2019 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,55 +12,47 @@ # 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/ # +%bcond_with jmock +%bcond_with easymock Name: hamcrest Version: 1.3 Release: 0 Summary: Library of matchers for building test expressions License: BSD-3-Clause Group: Development/Libraries/Java -Url: https://github.com/hamcrest/JavaHamcrest -Source0: http://%{name}.googlecode.com/files/%{name}-%{version}.tgz -Source1: http://repo1.maven.org/maven2/org/%{name}/%{name}-parent/%{version}/%{name}-parent-%{version}.pom -Source2: http://repo1.maven.org/maven2/org/%{name}/%{name}-library/%{version}/%{name}-library-%{version}.pom -Source3: http://repo1.maven.org/maven2/org/%{name}/%{name}-integration/%{version}/%{name}-integration-%{version}.pom -Source4: http://repo1.maven.org/maven2/org/%{name}/%{name}-generator/%{version}/%{name}-generator-%{version}.pom -Source5: http://repo1.maven.org/maven2/org/%{name}/%{name}-core/%{version}/%{name}-core-%{version}.pom -Source6: http://repo1.maven.org/maven2/org/%{name}/%{name}-all/%{version}/%{name}-all-%{version}.pom -# This file was added by the maintainer for compatibility with maven dep -# solving system -Source7: %{name}-text-%{version}.pom +URL: https://github.com/hamcrest/JavaHamcrest +Source0: https://github.com/hamcrest/JavaHamcrest/archive/hamcrest-java-%{version}.tar.gz Source8: hamcrest-core-MANIFEST.MF Source9: hamcrest-library-MANIFEST.MF -Source10: hamcrest-text-MANIFEST.MF Source11: hamcrest-integration-MANIFEST.MF Source12: hamcrest-generator-MANIFEST.MF -#PATCH-FIX-OPENSUSE: don't use versioned deps, no overview in html Patch0: %{name}-%{version}-build.patch -#PATCH-FIX-OPENSUSE: don't bundle QDox classes into hamcrest-generator.jar Patch1: %{name}-%{version}-no-jarjar.patch -#PATCH-FIX-OPENSUSE: don't build hamcrest-integration.jar -Patch2: %{name}-%{version}-no-integration.patch -#PATCH-FIX-OPENSUSE: there is no hamcrest-generator-nodeps Patch3: %{name}-%{version}-javadoc.patch -#PATCH-FIX-UPSTREAM: random build crash fix -Patch4: hamcrest-1.3-random-build-crash.patch -Patch5: hamcrest-1.3-fork-javac.patch -Patch6: hamcrest-1.3-javadoc9.patch -Patch7: hamcrest-1.3-javadoc10.patch -BuildRequires: ant >= 1.6.5 -BuildRequires: java-devel >= 1.6.0 +Patch4: %{name}-%{version}-qdox-2.0.patch +Patch5: %{name}-%{version}-fork-javac.patch +Patch6: %{name}-%{version}-javadoc9.patch +Patch7: %{name}-%{version}-javadoc10.patch +Patch8: %{name}-%{version}-random-build-crash.patch +BuildRequires: ant +BuildRequires: fdupes BuildRequires: javapackages-local -BuildRequires: javapackages-tools -BuildRequires: qdox -BuildRequires: zip -Requires: java >= 1.6.0 -Requires: qdox -BuildRoot: %{_tmppath}/%{name}-%{version}-build +BuildRequires: qdox >= 2.0 +Requires: %{name}-core = %{version}-%{release} +Requires: qdox >= 2.0 BuildArch: noarch +%if %{with jmock} +BuildRequires: jmock +Requires: jmock +%endif +%if %{with easymock} +BuildRequires: easymock +Requires: easymock +%endif %description Provides a library of matcher objects (also known as constraints or @@ -68,6 +60,14 @@ used in other frameworks. Typical scenarios include testing frameworks, mocking libraries and UI validation rules. +%package core +Summary: Core API of hamcrest matcher framework. +Group: Development/Libraries/Java + +%description core +The core API of hamcrest matcher framework to be used by third-party framework providers. +This includes the a foundation set of matcher implementations for common operations. + %package javadoc Summary: Javadoc for %{name} Group: Documentation/HTML @@ -78,117 +78,103 @@ %package demo Summary: Demo files for %{name} Group: Development/Libraries/Java -Requires: %{name} = %{version} +Requires: %{name} = %{version}-%{release} Requires: junit %description demo Demo files for %{name}. %prep -%setup -q +%setup -q -n JavaHamcrest-%{name}-java-%{version} + find . -type f -name "*.jar" | xargs -t rm +ln -sf $(build-classpath qdox) lib/generator/ +%if %{with jmock} +ln -sf $(build-classpath jmock) lib/integration/ +%else rm -fr hamcrest-integration/src/main/java/org/hamcrest/integration/JMock1Adapter.java rm -fr hamcrest-integration/src/main/java/org/hamcrest/JMock1Matchers.java rm -fr hamcrest-unit-test/src/main/java/org/hamcrest/integration/JMock1AdapterTest.java -ln -sf $(build-classpath qdox) lib/generator/ +%endif +%if %{with easymock} +ln -sf $(build-classpath easymock3) lib/integration/ +%else +rm -fr hamcrest-integration/src/main/java/org/hamcrest/integration/EasyMock2Adapter.java +rm -fr hamcrest-integration/src/main/java/org/hamcrest/EasyMock2Matchers.java +%endif %patch0 -p1 %patch1 -p1 -%patch2 -p1 %patch3 -p1 %patch4 -p1 %patch5 -p1 %patch6 -p1 %patch7 -p1 +%patch8 -p1 -perl -pi -e 's/\r$//g' LICENSE.txt +sed -i 's/\r//' LICENSE.txt %build export CLASSPATH=$(build-classpath qdox) -ant -Dant.build.javac.source=1.6 -Dversion=%{version} -Dbuild.sysclasspath=last clean core generator library bigjar javadoc +ant -Dant.build.javac.source=1.6 -Dant.build.javac.target=1.6 -Dversion=%{version} -Dbuild.sysclasspath=last clean core generator library bigjar javadoc # inject OSGi manifests -mkdir -p META-INF -cp -p %{SOURCE8} META-INF/MANIFEST.MF -touch META-INF/MANIFEST.MF -zip -u build/%{name}-core-%{version}.jar META-INF/MANIFEST.MF - -rm -fr META-INF -mkdir -p META-INF -cp -p %{SOURCE9} META-INF/MANIFEST.MF -touch META-INF/MANIFEST.MF -zip -u build/%{name}-library-%{version}.jar META-INF/MANIFEST.MF - -rm -fr META-INF -mkdir -p META-INF -cp -p %{SOURCE10} META-INF/MANIFEST.MF -touch META-INF/MANIFEST.MF -zip -u build/%{name}-text-%{version}.jar META-INF/MANIFEST.MF - -rm -fr META-INF -mkdir -p META-INF -cp -p %{SOURCE11} META-INF/MANIFEST.MF -touch META-INF/MANIFEST.MF -zip -u build/%{name}-integration-%{version}.jar META-INF/MANIFEST.MF - -rm -fr META-INF -mkdir -p META-INF -cp -p %{SOURCE12} META-INF/MANIFEST.MF -touch META-INF/MANIFEST.MF -zip -u build/%{name}-generator-%{version}.jar META-INF/MANIFEST.MF +jar ufm build/%{name}-core-%{version}.jar %{SOURCE8} +jar ufm build/%{name}-library-%{version}.jar %{SOURCE9} +jar ufm build/%{name}-integration-%{version}.jar %{SOURCE11} +jar ufm build/%{name}-generator-%{version}.jar %{SOURCE12} %install +sed -i 's/@VERSION@/%{version}/g' pom/*.pom + # jars install -d -m 755 %{buildroot}%{_javadir}/%{name} -install -d -m 755 %{buildroot}%{_mavenpomdir} -install -m 644 %{SOURCE1} %{buildroot}%{_mavenpomdir}/JPP.%{name}-parent.pom -%add_maven_depmap JPP.%{name}-parent.pom +install -d -m 755 %{buildroot}%{_mavenpomdir}/%{name} -install -m 644 build/%{name}-all-%{version}.jar %{buildroot}%{_javadir}/%{name}/all.jar -install -m 644 %{SOURCE6} %{buildroot}%{_mavenpomdir}/JPP.%{name}-all.pom -%add_maven_depmap JPP.%{name}-all.pom %{name}/all.jar +rm -f pom/%{name}-parent.pom +for i in pom/%{name}*.pom; do + %pom_remove_parent ${i} + %pom_xpath_inject "pom:project" " + <groupId>org.hamcrest</groupId> + <version>%{version}</version>" ${i} +done install -m 644 build/%{name}-core-%{version}.jar %{buildroot}%{_javadir}/%{name}/core.jar -install -m 644 %{SOURCE5} %{buildroot}%{_mavenpomdir}/JPP.%{name}-core.pom -%add_maven_depmap JPP.%{name}-core.pom %{name}/core.jar +install -m 644 pom/%{name}-core.pom %{buildroot}%{_mavenpomdir}/%{name}/core.pom +%add_maven_depmap %{name}/core.pom %{name}/core.jar -f core + +install -m 644 build/%{name}-all-%{version}.jar %{buildroot}%{_javadir}/%{name}/all.jar +install -m 644 pom/%{name}-all.pom %{buildroot}%{_mavenpomdir}/%{name}/all.pom +%add_maven_depmap %{name}/all.pom %{name}/all.jar install -m 644 build/%{name}-generator-%{version}.jar %{buildroot}%{_javadir}/%{name}/generator.jar -install -m 644 %{SOURCE4} %{buildroot}%{_mavenpomdir}/JPP.%{name}-generator.pom -%add_maven_depmap JPP.%{name}-generator.pom %{name}/generator.jar +install -m 644 pom/%{name}-generator.pom %{buildroot}%{_mavenpomdir}/%{name}/generator.pom +%add_maven_depmap %{name}/generator.pom %{name}/generator.jar -install -m 644 build/%{name}-library-%{version}.jar %{buildroot}%{_javadir}/%{name}/library.jar -install -m 644 %{SOURCE2} %{buildroot}%{_mavenpomdir}/JPP.%{name}-library.pom -%add_maven_depmap JPP.%{name}-library.pom %{name}/library.jar +install -m 644 build/%{name}-integration-%{version}.jar %{buildroot}%{_javadir}/%{name}/integration.jar +install -m 644 pom/%{name}-integration.pom %{buildroot}%{_mavenpomdir}/%{name}/integration.pom +%add_maven_depmap %{name}/integration.pom %{name}/integration.jar -install -m 644 build/%{name}-text-%{version}.jar %{buildroot}%{_javadir}/%{name}/text.jar -install -m 644 %{SOURCE7} %{buildroot}%{_mavenpomdir}/JPP.%{name}-text.pom -%add_maven_depmap JPP.%{name}-text.pom %{name}/text.jar +install -m 644 build/%{name}-library-%{version}.jar %{buildroot}%{_javadir}/%{name}/library.jar +install -m 644 pom/%{name}-library.pom %{buildroot}%{_mavenpomdir}/%{name}/library.pom +%add_maven_depmap %{name}/library.pom %{name}/library.jar # javadoc install -d -m 755 %{buildroot}%{_javadocdir}/%{name} -cp -pr build/temp/hamcrest-all-1.3-javadoc.jar.contents/* %{buildroot}%{_javadocdir}/%{name} +cp -pr build/temp/hamcrest-all-%{version}-javadoc.jar.contents/* %{buildroot}%{_javadocdir}/%{name} +%fdupes -s %{buildroot}%{_javadocdir} # demo install -d -m 755 %{buildroot}%{_datadir}/%{name} cp -pr %{name}-examples %{buildroot}%{_datadir}/%{name}/ -%files +%files -f .mfiles %defattr(0644,root,root,0755) -%doc LICENSE.txt -%dir %{_javadir}/%{name} -%{_javadir}/%{name}/all.jar -%{_javadir}/%{name}/core.jar -%{_javadir}/%{name}/generator.jar -%if %with integration -%{_javadir}/%{name}/integration.jar -%endif -%{_javadir}/%{name}/library.jar -%{_javadir}/%{name}/text.jar -%if %with tests -%{_javadir}/%{name}/unit-test.jar -%endif -%{_mavenpomdir}/* -%{_datadir}/maven-metadata/%{name}.xml* +%license LICENSE.txt + +%files core -f .mfiles-core +%defattr(0644,root,root,0755) +%license LICENSE.txt %files javadoc %defattr(0644,root,root,0755) ++++++ hamcrest-1.3-build.patch ++++++ --- /var/tmp/diff_new_pack.5JocQi/_old 2020-02-05 07:23:37.262600210 +0100 +++ /var/tmp/diff_new_pack.5JocQi/_new 2020-02-05 07:23:37.262600210 +0100 @@ -1,30 +1,39 @@ diff --git a/build.xml b/build.xml -index 1cfd4fb..54d43fe 100644 +index 1cfd4fb..5a7c740 100644 --- a/build.xml +++ b/build.xml @@ -14,13 +14,13 @@ - <target name="generator" description="Build code generator tool"> - <java-to-jar srcdir="hamcrest-generator/src/main/java" - modulename="hamcrest-generator-nodeps" -- classpath="lib/generator/qdox-1.12.jar"/> -+ classpath="lib/generator/qdox.jar"/> - - <!-- Bundle QDox classes in hamcrest-generator.jar using JarJar to place classes under a different package --> -- <taskdef name="jarjar" classname="com.tonicsystems.jarjar.JarJarTask" classpath="lib/generator/jarjar-1.3.jar"/> -+ <taskdef name="jarjar" classname="com.tonicsystems.jarjar.JarJarTask" classpath="lib/generator/jarjar.jar"/> - <jarjar jarfile="build/hamcrest-generator-${version}.jar"> - <zipfileset src="build/hamcrest-generator-nodeps-${version}.jar"/> -- <zipfileset src="lib/generator/qdox-1.12.jar"/> -+ <zipfileset src="lib/generator/qdox.jar"/> - <rule pattern="com.thoughtworks.qdox.**" result="org.hamcrest.generator.qdox.@1"/> - </jarjar> - <copy file="build/hamcrest-generator-nodeps-${version}-sources.jar" tofile="build/hamcrest-generator-${version}-sources.jar"/> -@@ -152,7 +152,7 @@ - - <javadoc packagenames="org.hamcrest.*" defaultexcludes="yes" - destdir="build/temp/hamcrest-all-${version}-javadoc.jar.contents" author="true" version="true" use="true" -- windowtitle="Hamcrest" source="1.6" failonerror="yes" overview="overview.html"> -+ windowtitle="Hamcrest" source="1.6" failonerror="yes"> - <classpath> - <fileset dir="lib/integration"> - <include name="*.jar"/> + <target name="generator" description="Build code generator tool"> + <java-to-jar srcdir="hamcrest-generator/src/main/java" + modulename="hamcrest-generator-nodeps" +- classpath="lib/generator/qdox-1.12.jar"/> ++ classpath="lib/generator/qdox.jar"/> + + <!-- Bundle QDox classes in hamcrest-generator.jar using JarJar to place classes under a different package --> +- <taskdef name="jarjar" classname="com.tonicsystems.jarjar.JarJarTask" classpath="lib/generator/jarjar-1.3.jar"/> ++ <taskdef name="jarjar" classname="com.tonicsystems.jarjar.JarJarTask" classpath="lib/generator/jarjar.jar"/> + <jarjar jarfile="build/hamcrest-generator-${version}.jar"> + <zipfileset src="build/hamcrest-generator-nodeps-${version}.jar"/> +- <zipfileset src="lib/generator/qdox-1.12.jar"/> ++ <zipfileset src="lib/generator/qdox.jar"/> + <rule pattern="com.thoughtworks.qdox.**" result="org.hamcrest.generator.qdox.@1"/> + </jarjar> + <copy file="build/hamcrest-generator-nodeps-${version}-sources.jar" tofile="build/hamcrest-generator-${version}-sources.jar"/> +@@ -152,7 +152,8 @@ + + <javadoc packagenames="org.hamcrest.*" defaultexcludes="yes" + destdir="build/temp/hamcrest-all-${version}-javadoc.jar.contents" author="true" version="true" use="true" +- windowtitle="Hamcrest" source="1.6" failonerror="yes" overview="overview.html"> ++ windowtitle="Hamcrest" source="1.6" failonerror="yes"> ++ <arg value="-Xdoclint:none"/> + <classpath> + <fileset dir="lib/integration"> + <include name="*.jar"/> +@@ -313,6 +314,7 @@ + <javadoc packagenames="org.hamcrest.*" sourcepath="build/temp/@{modulename}-${version}-sources.jar.contents" defaultexcludes="yes" + destdir="build/temp/@{modulename}-${version}-javadoc.jar.contents" author="true" version="true" use="true" + windowtitle="Hamcrest" source="1.6" failonerror="yes"> ++ <arg value="-Xdoclint:none"/> + <classpath> + <fileset dir="lib/integration"> + <include name="*.jar"/> ++++++ hamcrest-1.3-fork-javac.patch ++++++ --- /var/tmp/diff_new_pack.5JocQi/_old 2020-02-05 07:23:37.266600212 +0100 +++ /var/tmp/diff_new_pack.5JocQi/_new 2020-02-05 07:23:37.270600213 +0100 @@ -7,16 +7,19 @@ build.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -Index: hamcrest-1.3/build.xml -=================================================================== ---- hamcrest-1.3.orig/build.xml -+++ hamcrest-1.3/build.xml -@@ -268,7 +268,7 @@ - <attribute name="Built-Date" value="${build.timestamp}"/> - </manifest> - <mkdir dir="build/temp/@{modulename}-${version}.jar.contents"/> -- <javac srcdir="@{srcdir}" destdir="build/temp/@{modulename}-${version}.jar.contents" debug="${debug}" target="1.5" includeantruntime="false"> -+ <javac srcdir="@{srcdir}" destdir="build/temp/@{modulename}-${version}.jar.contents" debug="${debug}" target="1.6" includeantruntime="false" fork="true"> - <classpath> - <fileset dir="lib/integration"> - <include name="*.jar"/> +diff --git a/build.xml b/build.xml +index 1cfd4fb..69acfe8 100644 +--- a/build.xml ++++ b/build.xml +@@ -284,7 +284,7 @@ + <attribute name="Built-Date" value="${build.timestamp}"/> + </manifest> + <mkdir dir="build/temp/@{modulename}-${version}.jar.contents"/> +- <javac srcdir="@{srcdir}" destdir="build/temp/@{modulename}-${version}.jar.contents" debug="${debug}" target="1.5" includeantruntime="false"> ++ <javac srcdir="@{srcdir}" destdir="build/temp/@{modulename}-${version}.jar.contents" debug="${debug}" includeantruntime="false" fork="true"> + <classpath> + <fileset dir="lib/integration"> + <include name="*.jar"/> +-- +2.9.3 + ++++++ hamcrest-1.3-javadoc.patch ++++++ --- /var/tmp/diff_new_pack.5JocQi/_old 2020-02-05 07:23:37.274600215 +0100 +++ /var/tmp/diff_new_pack.5JocQi/_new 2020-02-05 07:23:37.274600215 +0100 @@ -1,20 +1,17 @@ ---- - build.xml | 3 +-- - 1 file changed, 1 insertion(+), 2 deletions(-) - -Index: hamcrest-1.3/build.xml -=================================================================== ---- hamcrest-1.3.orig/build.xml -+++ hamcrest-1.3/build.xml -@@ -133,10 +133,9 @@ - </target> - - <target name="javadoc" description="build javadoc jars"> -- <java-to-javadoc-jar modulename="hamcrest-generator-nodeps"/> -+ <java-to-javadoc-jar modulename="hamcrest-generator"/> - <java-to-javadoc-jar modulename="hamcrest-core"/> - <java-to-javadoc-jar modulename="hamcrest-library"/> -- <copy file="build/hamcrest-generator-nodeps-${version}-javadoc.jar" tofile="build/hamcrest-generator-${version}-javadoc.jar"/> - - <javadoc packagenames="org.hamcrest.*" defaultexcludes="yes" - destdir="build/temp/hamcrest-all-${version}-javadoc.jar.contents" author="true" version="true" use="true" +diff --git a/build.xml b/build.xml +index ed57763..a4550cb 100644 +--- a/build.xml ++++ b/build.xml +@@ -135,11 +135,10 @@ + </target> + + <target name="javadoc" description="build javadoc jars"> +- <java-to-javadoc-jar modulename="hamcrest-generator-nodeps"/> ++ <java-to-javadoc-jar modulename="hamcrest-generator"/> + <java-to-javadoc-jar modulename="hamcrest-core"/> + <java-to-javadoc-jar modulename="hamcrest-library"/> + <java-to-javadoc-jar modulename="hamcrest-integration"/> +- <copy file="build/hamcrest-generator-nodeps-${version}-javadoc.jar" tofile="build/hamcrest-generator-${version}-javadoc.jar"/> + + <javadoc packagenames="org.hamcrest.*" defaultexcludes="yes" + destdir="build/temp/hamcrest-all-${version}-javadoc.jar.contents" author="true" version="true" use="true" ++++++ hamcrest-1.3-javadoc10.patch ++++++ --- /var/tmp/diff_new_pack.5JocQi/_old 2020-02-05 07:23:37.278600216 +0100 +++ /var/tmp/diff_new_pack.5JocQi/_new 2020-02-05 07:23:37.282600218 +0100 @@ -1,12 +1,12 @@ --- hamcrest-1.3/build.xml 2012-07-02 21:14:09.000000000 +0200 +++ hamcrest-1.3/build.xml 2017-12-18 07:46:06.290074242 +0100 @@ -165,9 +165,6 @@ - - <group title="Hamcrest API and Utility Classes" packages="org.hamcrest"/> - <group title="Matcher Library" packages="org.hamcrest.*"/> -- -- <link offline="false" href="http://www.junit.org/junit/javadoc/3.8.1/"/> -- <link offline="false" href="http://kentbeck.github.com/junit/javadoc/latest/"/> - </javadoc> - <jar jarfile="build/hamcrest-all-${version}-javadoc.jar"> - <fileset dir="build/temp/hamcrest-all-${version}-javadoc.jar.contents"/> + <group title="Hamcrest API and Utility Classes" packages="org.hamcrest"/> + <group title="Matcher Library" packages="org.hamcrest.*"/> + <group title="Integration" packages="org.hamcrest.integration, org.hamcrest.integration.*"/> +- +- <link offline="false" href="http://www.junit.org/junit/javadoc/3.8.1/"/> +- <link offline="false" href="http://kentbeck.github.com/junit/javadoc/latest/"/> + </javadoc> + <jar jarfile="build/hamcrest-all-${version}-javadoc.jar"> + <fileset dir="build/temp/hamcrest-all-${version}-javadoc.jar.contents"/> ++++++ hamcrest-1.3-javadoc9.patch ++++++ ++++ 2086 lines (skipped) ++++ between /work/SRC/openSUSE:Leap:15.2/hamcrest/hamcrest-1.3-javadoc9.patch ++++ and /work/SRC/openSUSE:Leap:15.2/.hamcrest.new.26092/hamcrest-1.3-javadoc9.patch ++++++ hamcrest-1.3-no-jarjar.patch ++++++ --- /var/tmp/diff_new_pack.5JocQi/_old 2020-02-05 07:23:37.290600222 +0100 +++ /var/tmp/diff_new_pack.5JocQi/_new 2020-02-05 07:23:37.294600223 +0100 @@ -3,21 +3,21 @@ --- a/build.xml +++ b/build.xml @@ -13,17 +13,8 @@ - - <target name="generator" description="Build code generator tool"> - <java-to-jar srcdir="hamcrest-generator/src/main/java" -- modulename="hamcrest-generator-nodeps" -+ modulename="hamcrest-generator" - classpath="lib/generator/qdox.jar"/> -- -- <!-- Bundle QDox classes in hamcrest-generator.jar using JarJar to place classes under a different package --> -- <taskdef name="jarjar" classname="com.tonicsystems.jarjar.JarJarTask" classpath="lib/generator/jarjar.jar"/> -- <jarjar jarfile="build/hamcrest-generator-${version}.jar"> -- <zipfileset src="build/hamcrest-generator-nodeps-${version}.jar"/> -- <zipfileset src="lib/generator/qdox.jar"/> -- <rule pattern="com.thoughtworks.qdox.**" result="org.hamcrest.generator.qdox.@1"/> -- </jarjar> -- <copy file="build/hamcrest-generator-nodeps-${version}-sources.jar" tofile="build/hamcrest-generator-${version}-sources.jar"/> - </target> - - <target name="core" depends="generator" description="Build core Hamcrest library"> + + <target name="generator" description="Build code generator tool"> + <java-to-jar srcdir="hamcrest-generator/src/main/java" +- modulename="hamcrest-generator-nodeps" ++ modulename="hamcrest-generator" + classpath="lib/generator/qdox.jar"/> +- +- <!-- Bundle QDox classes in hamcrest-generator.jar using JarJar to place classes under a different package --> +- <taskdef name="jarjar" classname="com.tonicsystems.jarjar.JarJarTask" classpath="lib/generator/jarjar.jar"/> +- <jarjar jarfile="build/hamcrest-generator-${version}.jar"> +- <zipfileset src="build/hamcrest-generator-nodeps-${version}.jar"/> +- <zipfileset src="lib/generator/qdox.jar"/> +- <rule pattern="com.thoughtworks.qdox.**" result="org.hamcrest.generator.qdox.@1"/> +- </jarjar> +- <copy file="build/hamcrest-generator-nodeps-${version}-sources.jar" tofile="build/hamcrest-generator-${version}-sources.jar"/> + </target> + + <target name="core" depends="generator" description="Build core Hamcrest library"> ++++++ hamcrest-1.3-qdox-2.0.patch ++++++ >From 6d7da5456a7458a249bed9c4c1e768cc7cc2fe40 Mon Sep 17 00:00:00 2001 From: Michael Simacek <msima...@redhat.com> Date: Wed, 1 Feb 2017 12:57:14 +0100 Subject: [PATCH] Port to qdox 2.0 --- .../src/main/java/org/hamcrest/generator/QDox.java | 4 ++-- .../org/hamcrest/generator/QDoxFactoryReader.java | 26 ++++++++++++---------- 2 files changed, 16 insertions(+), 14 deletions(-) diff --git a/hamcrest-generator/src/main/java/org/hamcrest/generator/QDox.java b/hamcrest-generator/src/main/java/org/hamcrest/generator/QDox.java index efaf615..338178d 100644 --- a/hamcrest-generator/src/main/java/org/hamcrest/generator/QDox.java +++ b/hamcrest-generator/src/main/java/org/hamcrest/generator/QDox.java @@ -1,6 +1,6 @@ package org.hamcrest.generator; -import com.thoughtworks.qdox.JavaDocBuilder; +import com.thoughtworks.qdox.JavaProjectBuilder; import com.thoughtworks.qdox.model.JavaClass; import java.io.File; @@ -16,7 +16,7 @@ import java.io.Reader; */ public class QDox { - private final JavaDocBuilder javaDocBuilder = new JavaDocBuilder(); + private final JavaProjectBuilder javaDocBuilder = new JavaProjectBuilder(); public void addSourceTree(File sourceDir) { javaDocBuilder.addSourceTree(sourceDir); diff --git a/hamcrest-generator/src/main/java/org/hamcrest/generator/QDoxFactoryReader.java b/hamcrest-generator/src/main/java/org/hamcrest/generator/QDoxFactoryReader.java index 5108140..97fce01 100644 --- a/hamcrest-generator/src/main/java/org/hamcrest/generator/QDoxFactoryReader.java +++ b/hamcrest-generator/src/main/java/org/hamcrest/generator/QDoxFactoryReader.java @@ -4,8 +4,10 @@ import com.thoughtworks.qdox.model.DocletTag; import com.thoughtworks.qdox.model.JavaClass; import com.thoughtworks.qdox.model.JavaMethod; import com.thoughtworks.qdox.model.JavaParameter; -import com.thoughtworks.qdox.model.Type; +import com.thoughtworks.qdox.model.JavaType; +import com.thoughtworks.qdox.model.impl.DefaultJavaClass; +import java.util.ArrayList; import java.util.Iterator; import java.util.List; import java.util.regex.Pattern; @@ -56,15 +58,15 @@ public class QDoxFactoryReader implements Iterable<FactoryMethod> { JavaMethod methodSource = findMethodInSource(factoryMethod); if (methodSource != null) { factoryMethod.setJavaDoc(createJavaDocComment(methodSource)); - JavaParameter[] parametersFromSource + List<JavaParameter> parametersFromSource = methodSource.getParameters(); List<FactoryMethod.Parameter> parametersFromReflection = factoryMethod.getParameters(); - if (parametersFromReflection.size() == parametersFromSource.length) { - for (int i = 0; i < parametersFromSource.length; i++) { + if (parametersFromReflection.size() == parametersFromSource.size()) { + for (int i = 0; i < parametersFromSource.size(); i++) { parametersFromReflection.get(i).setName( - parametersFromSource[i].getName()); + parametersFromSource.get(i).getName()); } } } @@ -79,18 +81,18 @@ public class QDoxFactoryReader implements Iterable<FactoryMethod> { // Note, this doesn't always work - it struggles with some kinds of generics. // This seems to cover most cases though. List<FactoryMethod.Parameter> params = factoryMethod.getParameters(); - Type[] types = new Type[params.size()]; + List<JavaType> types = new ArrayList<JavaType>(params.size()); boolean varArgs = false; - for (int i = 0; i < types.length; i++) { + for (int i = 0; i < params.size(); i++) { String type = params.get(i).getType(); varArgs = VARARGS_REGEX.matcher(type).find(); // QDox ignores varargs and generics, so we strip them out to help QDox. type = GENERIC_REGEX.matcher(type).replaceAll(""); type = VARARGS_REGEX.matcher(type).replaceAll(""); - types[i] = new Type(type); + types.add(new DefaultJavaClass(type)); } - JavaMethod[] methods = classSource.getMethodsBySignature(factoryMethod.getName(), types, false, varArgs); - return methods.length == 1 ? methods[0] : null; + List<JavaMethod> methods = classSource.getMethodsBySignature(factoryMethod.getName(), types, false, varArgs); + return methods.size() == 1 ? methods.get(0) : null; } /** @@ -98,8 +100,8 @@ public class QDoxFactoryReader implements Iterable<FactoryMethod> { */ private static String createJavaDocComment(JavaMethod methodSource) { String comment = methodSource.getComment(); - DocletTag[] tags = methodSource.getTags(); - if ((comment == null || comment.trim().length() == 0) && tags.length == 0) { + List<DocletTag> tags = methodSource.getTags(); + if ((comment == null || comment.trim().length() == 0) && tags.size() == 0) { return null; } StringBuilder result = new StringBuilder(); -- 2.9.3 ++++++ hamcrest-1.3-random-build-crash.patch ++++++ --- /var/tmp/diff_new_pack.5JocQi/_old 2020-02-05 07:23:37.302600226 +0100 +++ /var/tmp/diff_new_pack.5JocQi/_new 2020-02-05 07:23:37.306600228 +0100 @@ -2,41 +2,41 @@ --- hamcrest-1.3.old/build.xml 2014-06-16 13:00:29.321699344 +0200 +++ hamcrest-1.3/build.xml 2014-06-16 14:24:30.160165471 +0200 @@ -27,6 +27,7 @@ - </target> - - <target name="core" depends="generator" description="Build core Hamcrest library"> -+ <parallel threadcount="1"> - <java-to-jar srcdir="hamcrest-core/src/main/java" modulename="hamcrest-core"/> - - <!-- Generate one class with all static imports --> + </target> + + <target name="core" depends="generator" description="Build core Hamcrest library"> ++ <parallel threadcount="1"> + <java-to-jar srcdir="hamcrest-core/src/main/java" modulename="hamcrest-core"/> + + <!-- Generate one class with all static imports --> @@ -36,7 +37,7 @@ - fork="yes" - failonerror="yes" - classpath=" -- build/hamcrest-core-${version}.jar; -+ build/temp/hamcrest-core-${version}.jar.contents; - build/hamcrest-generator-${version}.jar; - "> - <arg value="core-matchers.xml"/> + fork="yes" + failonerror="yes" + classpath=" +- build/hamcrest-core-${version}.jar; ++ build/temp/hamcrest-core-${version}.jar.contents; + build/hamcrest-generator-${version}.jar; + "> + <arg value="core-matchers.xml"/> @@ -48,11 +49,13 @@ - <java-to-jar srcdir="build/temp/hamcrest-core/generated-code" - modulename="hamcrest-core" - classpath="build/hamcrest-core-${version}.jar"/> -+ </parallel> - </target> - - <target name="library" - depends="core,generator" - description="Build library of matchers"> -+ <parallel threadcount="1"> - <mkdir dir="build/temp/hamcrest-library/generated-code"/> - <java-to-jar srcdir="hamcrest-library/src/main/java" - modulename="hamcrest-library" + <java-to-jar srcdir="build/temp/hamcrest-core/generated-code" + modulename="hamcrest-core" + classpath="build/hamcrest-core-${version}.jar"/> ++ </parallel> + </target> + + <target name="library" + depends="core,generator" + description="Build library of matchers"> ++ <parallel threadcount="1"> + <mkdir dir="build/temp/hamcrest-library/generated-code"/> + <java-to-jar srcdir="hamcrest-library/src/main/java" + modulename="hamcrest-library" @@ -75,6 +78,7 @@ - <java-to-jar srcdir="build/temp/hamcrest-library/generated-code" - modulename="hamcrest-library" - classpath="build/hamcrest-core-${version}.jar"/> -+ </parallel> - </target> - - <target name="integration" depends="core, library" description="Build integration with external tools"> + <java-to-jar srcdir="build/temp/hamcrest-library/generated-code" + modulename="hamcrest-library" + classpath="build/hamcrest-core-${version}.jar"/> ++ </parallel> + </target> + + <target name="integration" depends="core, library" description="Build integration with external tools">