Conditionalize BR on jmh

This commit is contained in:
Mikolaj Izdebski 2017-07-10 13:25:22 +02:00
parent 3885a2d836
commit 6f3eea6529

View File

@ -1,6 +1,8 @@
%bcond_without jmh
Name: apache-commons-lang3
Version: 3.6
Release: 1%{?dist}
Release: 2%{?dist}
Summary: Provides a host of helper utilities for the java.lang API
License: ASL 2.0
URL: http://commons.apache.org/lang
@ -14,8 +16,10 @@ BuildRequires: mvn(org.apache.commons:commons-parent:pom:)
BuildRequires: mvn(org.apache.maven.plugins:maven-antrun-plugin)
BuildRequires: mvn(org.easymock:easymock)
BuildRequires: mvn(org.hamcrest:hamcrest-all)
%if %{with jmh}
BuildRequires: mvn(org.openjdk.jmh:jmh-core)
BuildRequires: mvn(org.openjdk.jmh:jmh-generator-annprocess)
%endif
%description
The standard Java libraries fail to provide enough methods for
@ -53,7 +57,11 @@ sed -i 's/\s*public void testParseSync().*/@org.junit.Ignore\n&/' \
rm src/test/java/org/apache/commons/lang3/RandomStringUtilsTest.java
%build
%if %{without jmh}
%mvn_build -f
%else
%mvn_build
%endif
%install
%mvn_install
@ -65,6 +73,9 @@ rm src/test/java/org/apache/commons/lang3/RandomStringUtilsTest.java
%doc LICENSE.txt NOTICE.txt
%changelog
* Mon Jul 10 2017 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.6-2
- Conditionalize BR on jmh
* Mon Jul 03 2017 Michael Simacek <msimacek@redhat.com> - 3.6-1
- Update to upstream version 3.6