diff --git a/jmake.spec b/jmake.spec index 532eb8d..6fbf069 100644 --- a/jmake.spec +++ b/jmake.spec @@ -2,6 +2,9 @@ %global commit0 7761ee3e1537ccc61820c0d30061eb09edaf1c93 %global srcversion 1.3.8-8 +# build with actual java version +%global ant17 ant -Ddefault.javac.source=1.7 -Ddefault.javac.target=1.7 + Name: jmake Version: %(echo %{srcversion} |tr - . ) Summary: Make utility for large Java projects @@ -13,17 +16,16 @@ License: GPLv2+ URL: https://github.com/pantsbuild/%{name} %if 0%{?gitdate} -Release: 1.%{gitdate}git%(c=%{commit0}; echo ${c:0:7} )%{?dist} +Release: 2.%{gitdate}git%(c=%{commit0}; echo ${c:0:7} )%{?dist} Source0: %{url}/archive/%{commit0}.tar.gz#/%{name}-%{commit0}.tar.gz %else -Release: 1%{?dist} +Release: 2%{?dist} Source0: %{url}/archive/%{srcversion}.tar.gz#/%{name}-%{version}.tar.gz %endif BuildArch: noarch BuildRequires: ant maven-local BuildRequires: ant-junit -BuildRequires: findbugs %description JMake (formerly Javamake) is a tool for Java programmers to make @@ -48,14 +50,12 @@ This package contains the API documentation for %{name}. sed -i -r \ -e 's;(file.reference.junit.jar=).*;\1%(build-classpath junit);' \ -e 's;(javac.test.classpath=).*\\;\1%(build-classpath hamcrest):\\;' \ - -e 's;(findbugs.file.reference=).*;\1%{_bindir}/findbugs;' \ import.properties nbproject/project.properties # mark binary with version+commit sed -i -e 's;\%VERSION\%;%{srcversion};' -e 's;\%TAG\%;%{commit0};' %{name}.pom %build -# build with actual java version -ant -Ddefault.javac.source=1.7 -Ddefault.javac.target=1.7 +%ant17 jar javadoc %install %mvn_artifact %{name}.pom dist/%{name}.jar @@ -66,6 +66,10 @@ cat <>%{buildroot}%{_bindir}/%{name} java -jar %{_javadir}/%{name}/%{name}.jar \$@ EOT +%check +# don't call target test-report overriden in build.xml +%ant17 -f nbproject/build-impl.xml test + %files -f .mfiles %license LICENSE @@ -77,5 +81,8 @@ EOT %changelog +* Thu Jul 07 2016 Raphael Groner - 1.3.8.8-2.20150716git7761ee3 +- skip target test-reports, useless in mock/koji and findbugs is not available in EPEL7 + * Mon Jun 13 2016 Raphael Groner - 1.3.8.8-1.20150716git7761ee3 - initial