From 5ff26dd84b33b457fd5f977e70c423367576241a Mon Sep 17 00:00:00 2001 From: Marian Koncek Date: Wed, 30 Sep 2020 16:23:44 +0200 Subject: [PATCH] Update to ustream version 3.5.13 --- .gitignore | 1 + generate-tarball.sh | 22 ++++++++++++++++++++++ make-mockito-sourcetarball.sh | 20 -------------------- mockito.spec | 13 +++++++++---- sources | 2 +- 5 files changed, 33 insertions(+), 25 deletions(-) create mode 100755 generate-tarball.sh delete mode 100755 make-mockito-sourcetarball.sh diff --git a/.gitignore b/.gitignore index aa287b0..9e09129 100644 --- a/.gitignore +++ b/.gitignore @@ -2,3 +2,4 @@ /.build-*.log /noarch/ /*.src.rpm +/mockito-3.5.13.tar.gz diff --git a/generate-tarball.sh b/generate-tarball.sh new file mode 100755 index 0000000..6b3c542 --- /dev/null +++ b/generate-tarball.sh @@ -0,0 +1,22 @@ +#!/bin/bash +set -e + +name=mockito +version="$(sed -n 's/Version:\s*//p' *.spec)" + +# RETRIEVE +wget "https://github.com/mockito/mockito/archive/v${version}.tar.gz" -O "${name}-${version}.orig.tar.gz" + +rm -rf tarball-tmp +mkdir tarball-tmp +pushd tarball-tmp +tar -xf "../${name}-${version}.orig.tar.gz" + +# CLEAN TARBALL +find -name '*.jar' -delete +find -name '*.class' -delete +rm -rf gradlew gradlew.bat src/javadoc + +tar -czf "../${name}-${version}.tar.gz" * +popd +rm -r tarball-tmp "${name}-${version}.orig.tar.gz" diff --git a/make-mockito-sourcetarball.sh b/make-mockito-sourcetarball.sh deleted file mode 100755 index 8b47268..0000000 --- a/make-mockito-sourcetarball.sh +++ /dev/null @@ -1,20 +0,0 @@ -#!/bin/bash -ex - -VERSION="$(sed -n 's/Version:\s*//p' *.spec)" -SRCDIR=mockito-${VERSION} - -git clone https://github.com/mockito/mockito.git ${SRCDIR} -pushd $SRCDIR -git archive --format=tar --prefix=${SRCDIR}/ v${VERSION} > ../${SRCDIR}.tar -popd - -rm -rf ${SRCDIR} - -tar -xf ${SRCDIR}.tar -rm ${SRCDIR}.tar -pushd ${SRCDIR} -find -name '*.jar' -delete -rm -rf gradlew gradlew.bat src/javadoc -popd - -tar -cvJf mockito-${VERSION}.tar.xz ${SRCDIR} diff --git a/mockito.spec b/mockito.spec index db386f1..31892b7 100644 --- a/mockito.spec +++ b/mockito.spec @@ -1,14 +1,14 @@ Name: mockito -Version: 3.4.5 +Version: 3.5.13 Release: 1%{?dist} Summary: Tasty mocking framework for unit tests in Java License: MIT URL: https://site.mockito.org/ BuildArch: noarch -# Source tarball and the script to generate it -Source0: %{name}-%{version}.tar.xz -Source1: make-mockito-sourcetarball.sh +# ./generate-tarball.sh +Source0: %{name}-%{version}.tar.gz +Source1: generate-tarball.sh # A custom build script to allow building with maven instead of gradle Source2: mockito-core.pom @@ -60,6 +60,8 @@ EOF # Compatibility alias %mvn_alias org.%{name}:%{name}-core org.%{name}:%{name}-all +sed -i 's/net\.bytebuddy\.jar\.asm/org.objectweb.asm/' src/main/java/org/mockito/internal/creation/bytebuddy/MockMethodAdvice.java + %build # See the usage of exec-maven-plugin in the pom mkdir -p target/classes/ @@ -79,6 +81,9 @@ mv target/classes/org/mockito/internal/creation/bytebuddy/inject/MockMethodDispa %license LICENSE %changelog +* Wed Sep 30 2020 Marian Koncek - 3.5.13-1 +- Update to ustream version 3.5.13 + * Wed Jul 22 2020 Marian Koncek - 3.4.5-1 - Update to upstream version 3.4.5 diff --git a/sources b/sources index c22fd3b..f08c32b 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (mockito-3.4.5.tar.xz) = d85b7de6b2d286f5e6cd6b5e871f7354f66a106462bab78221df8cfc1c3a393a2f92c32ecdd297467b32f4fc9c21c362b9334d0834b3f04b255ea03b334cb2e6 +SHA512 (mockito-3.5.13.tar.gz) = be6741e4a68bbef26e0c920107929e3032f29acbdeb4468c3392fa5128bdba4b7ce3edce4c01902a5d3cd3136c755197729486714ff9e2f705d45c3ad56cf436