Name: json_simple
Version: 1.1.1
Release: 9%{?dist}
Summary: Simple Java toolkit for JSON
Group: Development/Libraries
License: ASL 2.0
URL: http://code.google.com/p/json-simple/
# svn export http://json-simple.googlecode.com/svn/tags/tag_release_1_1_1/ json-simple-1.1.1
# tar czf json-simple-1.1.1-src-svn.tar.gz json-simple-1.1.1
Source0: json-simple-1.1.1-src-svn.tar.gz
#https://code.google.com/p/json-simple/issues/detail?id=97
Patch0: json-simple-hash-java-1.8.patch
BuildArch: noarch
BuildRequires: jpackage-utils
BuildRequires: maven-local
BuildRequires: maven-compiler-plugin
BuildRequires: maven-install-plugin
BuildRequires: maven-javadoc-plugin
BuildRequires: maven-plugin-bundle
BuildRequires: maven-resources-plugin
BuildRequires: maven-surefire-plugin
%if 0%{?fc19} || 0%{?el7}
BuildRequires: maven-surefire-provider-junit4
BuildRequires: junit4
%else
BuildRequires: maven-surefire-provider-junit
BuildRequires: junit
%endif
Requires: jpackage-utils
%description
JSON.simple is a simple Java toolkit for JSON. You can use JSON.simple
to encode or decode JSON text.
* Full compliance with JSON specification (RFC4627) and reliable
* Provides multiple functionalities such as encode, decode/parse
and escape JSON text while keeping the library lightweight
* Flexible, simple and easy to use by reusing Map and List interfaces
* Supports streaming output of JSON text
* Stoppable SAX-like interface for streaming input of JSON text
* Heap based parser
* High performance (see performance testing)
* No dependency on external libraries
* Both of the source code and the binary are JDK1.2 compatible
%package javadoc
Group: Documentation
Summary: Javadoc for %{name}
Requires: jpackage-utils
%description javadoc
This package contains javadoc for %{name}.
%prep
%setup -q -n json-simple-%{version}
find . -name '*.jar' -exec rm -f '{}' \;
# All the files have dos line endings, remove them.
find . -type f -exec %{__sed} -i 's/\r//' {} \;
%patch0 -p1
%build
%{mvn_build}
%install
mkdir -p %{buildroot}%{_javadir}
install -pm 644 target/json-simple-%{version}.jar %{buildroot}%{_javadir}/%{name}.jar
mkdir -p %{buildroot}%{_mavenpomdir}
install -pm 644 pom.xml %{buildroot}%{_mavenpomdir}/JPP-%{name}.pom
%add_maven_depmap JPP-%{name}.pom %{name}.jar
mkdir -p %{buildroot}%{_javadocdir}/%{name}
cp -rp target/site/apidocs/* %{buildroot}%{_javadocdir}/%{name}
rm %{buildroot}%{_usr}/share/maven-metadata/json_simple.xml
%files
%{_javadir}/%{name}.jar
%{_mavenpomdir}/JPP-%{name}.pom
#%%{_mavendepmapfragdir}/%{name}
%doc AUTHORS.txt ChangeLog.txt LICENSE.txt README.txt
%files javadoc
%{_javadocdir}/%{name}
%doc LICENSE.txt
%changelog
* Tue Jul 22 2014 Steve Traylen <steve.traylen@cern.ch> - 1.1.1-9
- Skip hash tests for now bug #97
* Mon Jul 21 2014 Steve Traylen <steve.traylen@cern.ch> - 1.1.1-8
- BR junit4 -> junit.
* Sun Jun 08 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.1-7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
* Fri Mar 28 2014 Michael Simacek <msimacek@redhat.com> - 1.1.1-6
- Use Requires: java-headless rebuild (#1067528)
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.1-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.1-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
* Wed Feb 06 2013 Java SIG <java-devel@lists.fedoraproject.org> - 1.1.1-3
- Update for https://fedoraproject.org/wiki/Fedora_19_Maven_Rebuild
- Replace maven BuildRequires with maven-local
* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
* Fri Apr 20 2012 gil cattaneo <puntogil@libero.it> 1.1.1-1
- update to 1.1.1
- Removed gcj bits
- adapt to current guideline
- add sub package javadoc
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
* Thu Oct 15 2009 Steve Traylen <steve.traylen@cern.ch> - 1.1-2
- Add AUTHORS.txt and README.txt files.
* Tue Sep 8 2009 Steve Traylen <steve.traylen@cern.ch> - 1.1-1
- Initial build.