1 |
%global vertag 3f1ee79d50cf |
2 |
|
3 |
Name: snakeyaml |
4 |
Version: 1.13 |
5 |
Release: %mkrel 1 |
6 |
Group: Development/Java |
7 |
Summary: YAML parser and emitter for the Java programming language |
8 |
License: ASL 2.0 |
9 |
# http://code.google.com/p/snakeyaml |
10 |
URL: http://code.google.com/p/%{name} |
11 |
Source0: https://snakeyaml.googlecode.com/archive/v%{version}.zip#/%{name}-%{version}.zip |
12 |
|
13 |
# Upstream has forked gdata-java and base64 and refuses [1] to |
14 |
# consider replacing them by external dependencies. Bundled libraries |
15 |
# need to be removed and their use replaced by system libraries. |
16 |
# See rhbz#875777 and http://code.google.com/p/snakeyaml/issues/detail?id=175 |
17 |
# |
18 |
# Remove use of bundled Base64 implementation |
19 |
Patch0: 0001-Replace-bundled-base64-implementation.patch |
20 |
# We don't have gdata-java in Fedora any longer, use commons-codec instead |
21 |
Patch1: 0002-Replace-bundled-gdata-java-client-classes-with-commo.patch |
22 |
|
23 |
BuildArch: noarch |
24 |
|
25 |
BuildRequires: maven-local |
26 |
BuildRequires: mvn(biz.source_code:base64coder) |
27 |
BuildRequires: mvn(commons-codec:commons-codec) |
28 |
BuildRequires: mvn(com.mycila.maven-license-plugin:maven-license-plugin) |
29 |
BuildRequires: mvn(joda-time:joda-time) |
30 |
BuildRequires: mvn(junit:junit) |
31 |
BuildRequires: mvn(net.sourceforge.cobertura:cobertura) |
32 |
BuildRequires: mvn(org.apache.felix:maven-bundle-plugin) |
33 |
BuildRequires: mvn(org.apache.maven.plugins:maven-changes-plugin) |
34 |
BuildRequires: mvn(org.apache.maven.plugins:maven-eclipse-plugin) |
35 |
BuildRequires: mvn(org.apache.maven.plugins:maven-source-plugin) |
36 |
BuildRequires: mvn(org.apache.velocity:velocity) |
37 |
BuildRequires: mvn(org.springframework:spring-core) |
38 |
|
39 |
%description |
40 |
SnakeYAML features: |
41 |
* a complete YAML 1.1 parser. In particular, |
42 |
SnakeYAML can parse all examples from the specification. |
43 |
* Unicode support including UTF-8/UTF-16 input/output. |
44 |
* high-level API for serializing and deserializing |
45 |
native Java objects. |
46 |
* support for all types from the YAML types repository. |
47 |
* relatively sensible error messages. |
48 |
|
49 |
|
50 |
%package javadoc |
51 |
Summary: API documentation for %{name} |
52 |
Group: Documentation |
53 |
|
54 |
%description javadoc |
55 |
This package contains %{summary}. |
56 |
|
57 |
%prep |
58 |
%setup -q -n %{name}-%{vertag} |
59 |
%patch0 -p1 |
60 |
%patch1 -p1 |
61 |
|
62 |
%mvn_file : %{name} |
63 |
|
64 |
%pom_remove_plugin org.codehaus.mojo:cobertura-maven-plugin |
65 |
%pom_add_dep net.sourceforge.cobertura:cobertura:any:test |
66 |
sed -i "/<artifactId>spring</s/spring/&-core/" pom.xml |
67 |
rm -f src/test/java/examples/SpringTest.java |
68 |
|
69 |
# Replacement for bundled gdata-java-client |
70 |
%pom_add_dep commons-codec:commons-codec |
71 |
|
72 |
# remove bundled stuff |
73 |
rm -rf target |
74 |
rm -rf src/main/java/org/yaml/snakeyaml/external |
75 |
|
76 |
# convert CR+LF to LF |
77 |
sed -i 's/\r//g' LICENSE.txt |
78 |
|
79 |
%build |
80 |
%mvn_build |
81 |
|
82 |
%install |
83 |
%mvn_install |
84 |
|
85 |
%files -f .mfiles |
86 |
%doc LICENSE.txt |
87 |
|
88 |
%files javadoc -f .mfiles-javadoc |
89 |
%doc LICENSE.txt |
90 |
|
91 |
|