# # spec file for package snakeyaml # # Copyright (c) 2021 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via https://bugs.opensuse.org/ # %global vertag b28f0b4d87c6 %bcond_with tests Name: snakeyaml Version: 1.28 Release: 0 Summary: YAML parser and emitter for the Java programming language License: Apache-2.0 Group: Development/Libraries/Java URL: https://bitbucket.org/asomov/snakeyaml/ Source0: https://bitbucket.org/asomov/snakeyaml/get/%{name}-%{version}.tar.bz2 Source1: %{name}-build.xml # Upstream has forked gdata-java and base64 and refuses [1] to # consider replacing them by external dependencies. Bundled libraries # need to be removed and their use replaced by system libraries. # See rhbz#875777 and http://code.google.com/p/snakeyaml/issues/detail?id=175 # # Replace use of bundled Base64 implementation with java.util.Base64 Patch0: 0001-replace-bundled-base64coder-with-java.util.Base64.patch # We don't have gdata-java, use commons-codec instead Patch1: 0002-Replace-bundled-gdata-java-client-classes-with-commo.patch BuildRequires: ant BuildRequires: apache-commons-codec BuildRequires: fdupes BuildRequires: java-devel >= 1.8 BuildRequires: javapackages-local Requires: mvn(commons-codec:commons-codec) BuildArch: noarch %if %{with tests} BuildRequires: ant-junit BuildRequires: apache-commons-collections BuildRequires: apache-commons-lang BuildRequires: hamcrest-core BuildRequires: joda-time BuildRequires: junit BuildRequires: oro BuildRequires: velocity # Differently sorted collections make fail some tests that rely on a particular order BuildConflicts: java >= 9 BuildConflicts: java-devel >= 9 BuildConflicts: java-headless >= 9 %endif %description SnakeYAML features: * a complete YAML 1.1 parser. In particular, SnakeYAML can parse all examples from the specification. * Unicode support including UTF-8/UTF-16 input/output. * high-level API for serializing and deserializing native Java objects. * support for all types from the YAML types repository. * relatively sensible error messages. %package javadoc Summary: API documentation for %{name} Group: Documentation/HTML %description javadoc This package contains %{summary}. %prep %setup -q -n asomov-%{name}-%{vertag} cp %{SOURCE1} build.xml %patch0 -p1 %patch1 -p1 %pom_remove_plugin :cobertura-maven-plugin %pom_remove_plugin :maven-changes-plugin %pom_remove_plugin :maven-license-plugin %pom_remove_plugin :maven-javadoc-plugin %pom_remove_plugin :maven-site-plugin sed -i "/spring