89 lines
2.6 KiB
RPMSpec
89 lines
2.6 KiB
RPMSpec
#
|
|
# spec file for package json-smart
|
|
#
|
|
# Copyright (c) 2025 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/
|
|
#
|
|
|
|
|
|
Name: json-smart
|
|
Version: 2.2
|
|
Release: 0
|
|
Summary: A performance focused JSON processor
|
|
License: Apache-2.0
|
|
URL: https://github.com/netplex/json-smart-v2
|
|
Source: https://github.com/netplex/json-smart-v2/archive/%{version}.tar.gz
|
|
BuildRequires: fdupes
|
|
BuildRequires: maven-local
|
|
BuildRequires: mvn(org.apache.felix:maven-bundle-plugin)
|
|
BuildRequires: mvn(org.ow2.asm:asm)
|
|
BuildArch: noarch
|
|
|
|
%description
|
|
A small and fast JSON parser/generator for Java.
|
|
|
|
%package javadoc
|
|
Summary: Javadoc for %{name}
|
|
|
|
%description javadoc
|
|
This package contains javadoc for %{name}.
|
|
|
|
%prep
|
|
%setup -q -n %{name}-v2-%{version}
|
|
|
|
mkdir -p .mvn
|
|
|
|
%pom_remove_dep :json-smart-mini parent
|
|
%pom_remove_plugin :maven-javadoc-plugin parent
|
|
%pom_remove_plugin :maven-source-plugin parent
|
|
%pom_xpath_set "pom:dependency[pom:artifactId='accessors-smart']/pom:version" '${project.version}' parent
|
|
|
|
%pom_xpath_set "pom:Bundle-Version" "1.1" accessors-smart
|
|
%pom_xpath_remove "pom:Embed-Dependency" accessors-smart
|
|
%pom_xpath_remove "pom:Embed-Dependency" %{name}
|
|
|
|
%pom_xpath_inject "pom:dependency[pom:artifactId='accessors-smart']" "<version>%{version}</version>" %{name}
|
|
%pom_xpath_remove "pom:project/pom:version" accessors-smart
|
|
%pom_xpath_inject "pom:project" "<version>%{version}</version>" accessors-smart
|
|
|
|
cp -p %{name}/*.txt .
|
|
|
|
%{mvn_file} :%{name} %{name}
|
|
%{mvn_file} :accessors-smart accessors-smart
|
|
|
|
rm accessors-smart/src/test/java/net/minidev/asm/TestDateConvert.java
|
|
|
|
%build
|
|
pushd parent
|
|
%{mvn_build} -f -- \
|
|
%if %{?pkg_vcmp:%pkg_vcmp java-devel >= 9}%{!?pkg_vcmp:0}
|
|
-Dmaven.compiler.release=8 \
|
|
%endif
|
|
-Dsource=8
|
|
popd
|
|
|
|
%install
|
|
pushd parent
|
|
%mvn_install
|
|
%fdupes %{buildroot}%{_javadocdir}/%{name}
|
|
popd
|
|
|
|
%files -f parent/.mfiles
|
|
%doc ChangeLog.txt readme.txt
|
|
%license LICENSE.txt
|
|
|
|
%files javadoc -f parent/.mfiles-javadoc
|
|
%license LICENSE.txt
|
|
|
|
%changelog
|