diff --git a/SOURCES/fixup-ant-script.patch b/SOURCES/fixup-ant-script.patch index 51a4384..8b44b00 100644 --- a/SOURCES/fixup-ant-script.patch +++ b/SOURCES/fixup-ant-script.patch @@ -4,20 +4,7 @@ diff --git a/build.xml b/build.xml --- a/build.xml +++ b/build.xml -@@ -42,6 +42,12 @@ - - - -+ -+ -+ -+ -+ -+ - - - -@@ -204,19 +210,14 @@ +@@ -204,19 +204,14 @@ diff --git a/SPECS/mockito.spec b/SPECS/mockito.spec index 1050bdb..b0c95c8 100644 --- a/SPECS/mockito.spec +++ b/SPECS/mockito.spec @@ -1,10 +1,10 @@ %{?scl:%scl_package mockito} %{!?scl:%global pkg_name %{name}} -%{!?maven_scl:%global maven_scl_prefix %{nil}} +%{?java_common_find_provides_and_requires} Name: %{?scl_prefix}mockito Version: 1.9.0 -Release: 15%{?dist} +Release: 16%{?dist} Summary: A Java mocking framework License: MIT @@ -20,20 +20,18 @@ Patch4: %{pkg_name}-matcher.patch Patch5: setting-naming-policy.patch BuildArch: noarch -BuildRequires: jpackage-utils BuildRequires: java-devel -BuildRequires: ant -BuildRequires: %{?scl_prefix}objenesis -BuildRequires: cglib -BuildRequires: junit -BuildRequires: hamcrest -BuildRequires: aqute-bnd - -Requires: jpackage-utils -Requires: %{?scl_prefix}objenesis -Requires: cglib -Requires: %{?scl_prefix}junit -Requires: hamcrest +BuildRequires: %{?scl_prefix_java_common}ant +BuildRequires: %{?scl_prefix_java_common}objenesis +BuildRequires: %{?scl_prefix_java_common}cglib +BuildRequires: %{?scl_prefix_java_common}junit +BuildRequires: %{?scl_prefix_java_common}hamcrest +BuildRequires: %{?scl_prefix_maven}aqute-bnd + +Requires: %{?scl_prefix_java_common}objenesis +Requires: %{?scl_prefix_java_common}cglib +Requires: %{?scl_prefix_java_common}junit +Requires: %{?scl_prefix_java_common}hamcrest %description Mockito is a mocking framework that tastes really good. It lets you write @@ -61,18 +59,18 @@ sed -i 's/Bundle-Version= ${version}/Bundle-Version= %{version}/' conf/mockito-c %patch5 -p1 %build -scl enable %{scl} - <<"EOF" -build-jar-repository lib/compile objenesis +%{?scl:scl enable %{scl_maven} %{scl} - << "EOF"} +build-jar-repository -p lib/compile objenesis cglib junit hamcrest/core unset ANT_HOME ant jar javadoc # Convert to OSGi bundle pushd target java -jar $(build-classpath aqute-bnd) wrap -output mockito-core-%{version}.bar -properties ../conf/mockito-core.bnd mockito-core-%{version}.jar popd -EOF +%{?scl:EOF} %install -scl enable %{scl} - <<"EOF" +%{?scl:scl enable %{scl_maven} %{scl} - << "EOF"} mkdir -p $RPM_BUILD_ROOT%{_javadir} sed -i -e "s|@version@|%{version}|g" maven/mockito-core.pom cp -p target/mockito-core-%{version}.bar $RPM_BUILD_ROOT%{_javadir}/%{pkg_name}.jar @@ -85,12 +83,11 @@ mkdir -p $RPM_BUILD_ROOT%{_javadocdir}/%{pkg_name} cp -rp target/javadoc/* $RPM_BUILD_ROOT%{_javadocdir}/%{pkg_name} %add_maven_depmap JPP-%{pkg_name}.pom %{pkg_name}.jar -a "org.mockito:mockito-all" -EOF +%{?scl:EOF} -%files +%files -f .mfiles %{_javadir}/%{pkg_name}.jar %{_mavenpomdir}/JPP-%{pkg_name}.pom -%{_mavendepmapfragdir}/%{pkg_name} %doc NOTICE %doc LICENSE @@ -100,6 +97,9 @@ EOF %doc NOTICE %changelog +* Mon May 11 2015 Mat Booth - 1.9.0-16 +- Resolves: rhbz#1219013 - Fails to build from source + * Fri Mar 28 2014 Michael Simacek - 1.9.0-15 - Use Requires: java-headless rebuild (#1067528)