# TODO: run tests, build and package javadocs %global commit0 30f001f9af77def24449950a77ebd0010980f33c %global shortcommit0 %(c=%{commit0}; echo ${c:0:7}) Name: java-vash Version: 1.1.0 Release: 0.4.%{shortcommit0}git%{?dist} Summary: Visual hashing algorithms that convert data into images License: AGPLv3 URL: https://github.com/thevash/vash Source0: https://github.com/thevash/vash/archive/%{commit0}.tar.gz#/vash-%{shortcommit0}.tar.gz BuildArch: noarch BuildRequires: java-devel BuildRequires: junit Requires: java-headless Requires: javapackages-tools %description Vash is a family of visual hashing algorithms that take data and convert it into images. As with a hash function, the same input will always produce the same output and similar inputs will reliably produce significantly different outputs. Generally you can use Vash anywhere you would normally want to show a hash function. Unlike a hash function however, you can show the output to the user. %prep %setup -qn vash-%{commit0} %build mkdir bin javac -source 1.6 -target 1.6 -cp /usr/share/java/junit.jar -d bin $(find . -name "*.java") make %{?_smp_mflags} jar %install mkdir -p $RPM_BUILD_ROOT%{_javadir} install -p -m 0644 Vash.jar $RPM_BUILD_ROOT%{_javadir} %files %license LICENSE %doc README.md %{_javadir}/Vash.jar %changelog * Tue Aug 4 2015 Jonathan Underwood - 1.1.0-0.4.30f001fgit - Use %%license for LICENSE file - Change BuildArch to noarch * Tue Aug 4 2015 Jonathan Underwood - 1.1.0-0.3.30f001fgit - Add BuildRequires for junit - Construct a proper compilation step that succeeds * Tue Aug 4 2015 Jonathan Underwood - 1.1.0-0.2.30f001fgit - Compile java files with javac * Tue Aug 4 2015 Jonathan Underwood - 1.1.0-0.1.30f001fgit - Initial package