2009-06-04 04:31:56 +02:00
|
|
|
#
|
2023-08-24 07:16:24 +02:00
|
|
|
# spec file
|
2009-06-04 04:31:56 +02:00
|
|
|
#
|
2023-07-24 21:39:12 +02:00
|
|
|
# Copyright (c) 2023 SUSE LLC
|
2023-08-23 13:11:51 +02:00
|
|
|
# Copyright (c) 2000-2007, JPackage Project
|
2009-06-04 04:31:56 +02:00
|
|
|
#
|
|
|
|
# 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.
|
|
|
|
|
2019-01-25 13:20:07 +01:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2009-06-04 04:31:56 +02:00
|
|
|
#
|
|
|
|
|
|
|
|
|
2023-08-24 07:16:24 +02:00
|
|
|
%global base_name dom4j
|
|
|
|
%global flavor @BUILD_FLAVOR@%{nil}
|
|
|
|
%if "%{flavor}" == "bootstrap"
|
|
|
|
%bcond_without bootstrap
|
|
|
|
%else
|
|
|
|
%bcond_with bootstrap
|
|
|
|
%endif
|
2023-08-23 14:52:00 +02:00
|
|
|
Version: 2.1.4
|
2013-08-28 15:59:50 +02:00
|
|
|
Release: 0
|
2023-08-23 13:11:51 +02:00
|
|
|
Summary: Open Source XML framework for Java
|
|
|
|
License: BSD-3-Clause
|
|
|
|
URL: https://dom4j.github.io/
|
2023-08-24 07:16:24 +02:00
|
|
|
Source0: %{base_name}-%{version}.tar.xz
|
|
|
|
Source1: https://repo1.maven.org/maven2/org/%{base_name}/%{base_name}/%{version}/%{base_name}-%{version}.pom
|
|
|
|
Source2: %{base_name}-build.xml
|
|
|
|
Patch0: 0001-no-jaxen-dom4.patch
|
2023-08-23 13:11:51 +02:00
|
|
|
BuildRequires: ant
|
2018-07-10 14:44:23 +02:00
|
|
|
BuildRequires: fdupes
|
2022-03-30 11:56:28 +02:00
|
|
|
BuildRequires: glassfish-jaxb-api
|
2023-08-23 13:13:17 +02:00
|
|
|
BuildRequires: javapackages-local >= 6
|
2023-08-24 07:16:24 +02:00
|
|
|
Obsoletes: %{base_name}-manual < %{version}
|
2023-08-24 06:58:49 +02:00
|
|
|
BuildArch: noarch
|
2023-08-24 07:16:24 +02:00
|
|
|
%if %{with bootstrap}
|
|
|
|
Name: %{base_name}-bootstrap
|
|
|
|
%else
|
|
|
|
Name: %{base_name}
|
|
|
|
%endif
|
|
|
|
%if %{without bootstrap}
|
|
|
|
BuildRequires: fdupes
|
|
|
|
BuildRequires: jaxen
|
|
|
|
Conflicts: %{base_name}-bootstrap
|
|
|
|
Obsoletes: %{base_name}-bootstrap
|
|
|
|
%else
|
|
|
|
BuildRequires: jaxen-bootstrap
|
|
|
|
Conflicts: %{base_name}
|
|
|
|
%endif
|
2009-06-04 04:31:56 +02:00
|
|
|
|
|
|
|
%description
|
2023-08-23 13:11:51 +02:00
|
|
|
dom4j is an Open Source XML framework for Java. dom4j allows you to read,
|
2009-06-04 04:31:56 +02:00
|
|
|
write, navigate, create and modify XML documents. dom4j integrates with
|
2023-08-23 13:11:51 +02:00
|
|
|
DOM and SAX and is seamlessly integrated with full XPath support.
|
2009-06-04 04:31:56 +02:00
|
|
|
|
2023-08-24 07:16:24 +02:00
|
|
|
%if %{without bootstrap}
|
2009-06-04 04:31:56 +02:00
|
|
|
%package demo
|
2023-08-23 13:11:51 +02:00
|
|
|
Summary: Open Source XML framework for Java - demo
|
2009-06-04 04:31:56 +02:00
|
|
|
Group: Development/Libraries/Java
|
2023-08-24 07:16:24 +02:00
|
|
|
Requires: %{base_name} = %{version}
|
2009-06-04 04:31:56 +02:00
|
|
|
|
|
|
|
%description demo
|
2023-08-23 13:11:51 +02:00
|
|
|
dom4j is an Open Source XML framework for Java. dom4j allows you to read,
|
2013-08-28 15:59:50 +02:00
|
|
|
write, navigate, create and modify XML documents. dom4j integrates with
|
2023-08-23 13:11:51 +02:00
|
|
|
DOM and SAX and is seamlessly integrated with full XPath support.
|
2009-06-04 04:31:56 +02:00
|
|
|
|
|
|
|
%package javadoc
|
2023-08-24 07:16:24 +02:00
|
|
|
Summary: Javadoc for %{base_name}
|
2009-06-04 04:31:56 +02:00
|
|
|
|
|
|
|
%description javadoc
|
2023-08-24 07:16:24 +02:00
|
|
|
Javadoc for %{base_name}.
|
|
|
|
%endif
|
2009-06-04 04:31:56 +02:00
|
|
|
|
|
|
|
%prep
|
2023-08-24 07:16:24 +02:00
|
|
|
%setup -q -n %{base_name}-%{version}
|
|
|
|
%if %{with bootstrap}
|
|
|
|
%patch0 -p1
|
|
|
|
%endif
|
2023-08-23 13:11:51 +02:00
|
|
|
|
|
|
|
cp %{SOURCE1} pom.xml
|
|
|
|
cp %{SOURCE2} build.xml
|
|
|
|
|
|
|
|
# Remove xpp2 support
|
|
|
|
rm -r src/main/java/org/dom4j/xpp
|
|
|
|
rm src/main/java/org/dom4j/io/XPPReader.java
|
|
|
|
|
|
|
|
# Remove datatype code which depends on msv
|
|
|
|
rm -r src/main/java/org/dom4j/datatype
|
|
|
|
%pom_remove_dep net.java.dev.msv:xsdlib
|
|
|
|
|
|
|
|
# Remove xpp3 support
|
|
|
|
rm src/main/java/org/dom4j/io/XPP3Reader.java
|
|
|
|
%pom_remove_dep xpp3:xpp3
|
|
|
|
%pom_remove_dep pull-parser:pull-parser
|
|
|
|
%pom_remove_dep javax.xml.stream:stax-api
|
2009-06-04 04:31:56 +02:00
|
|
|
|
|
|
|
%build
|
2023-08-23 13:11:51 +02:00
|
|
|
mkdir -p lib
|
|
|
|
build-jar-repository -s lib jaxen glassfish-jaxb-api
|
|
|
|
%{ant} jar javadoc
|
2009-06-04 04:31:56 +02:00
|
|
|
|
|
|
|
%install
|
2013-08-28 15:59:50 +02:00
|
|
|
|
2023-08-23 13:11:51 +02:00
|
|
|
# jar
|
|
|
|
install -dm 0755 %{buildroot}%{_javadir}
|
2023-08-24 07:16:24 +02:00
|
|
|
install -pm 0644 target/%{base_name}-%{version}.jar %{buildroot}%{_javadir}/%{base_name}.jar
|
2023-08-23 13:11:51 +02:00
|
|
|
|
2023-08-24 07:16:24 +02:00
|
|
|
%if %{without bootstrap}
|
2023-08-23 13:11:51 +02:00
|
|
|
# pom
|
|
|
|
install -dm 0755 %{buildroot}%{_mavenpomdir}
|
2023-08-24 07:16:24 +02:00
|
|
|
%{mvn_install_pom} pom.xml %{buildroot}%{_mavenpomdir}/%{base_name}.pom
|
|
|
|
%add_maven_depmap %{base_name}.pom %{base_name}.jar -a %{base_name}:%{base_name}
|
2013-08-28 15:59:50 +02:00
|
|
|
|
2009-06-04 04:31:56 +02:00
|
|
|
# javadoc
|
2023-08-24 07:16:24 +02:00
|
|
|
install -dm 0755 %{buildroot}%{_javadocdir}/%{base_name}
|
|
|
|
cp -r target/site/apidocs %{buildroot}%{_javadocdir}/%{base_name}
|
2023-08-23 13:11:51 +02:00
|
|
|
%fdupes -s %{buildroot}%{_javadocdir}
|
|
|
|
|
2009-06-04 04:31:56 +02:00
|
|
|
# demo
|
2023-08-24 07:16:24 +02:00
|
|
|
install -dm 0755 %{buildroot}%{_datadir}/%{base_name}/src
|
|
|
|
cp -pr xml %{buildroot}%{_datadir}/%{base_name}
|
|
|
|
cp -pr src/example %{buildroot}%{_datadir}/%{base_name}/src
|
|
|
|
%fdupes -s %{buildroot}%{_datadir}/%{base_name}
|
2009-06-04 04:31:56 +02:00
|
|
|
|
2022-03-28 15:51:24 +02:00
|
|
|
%files -f .mfiles
|
2023-08-23 13:11:51 +02:00
|
|
|
%license LICENSE
|
|
|
|
%doc README.md
|
2009-06-04 04:31:56 +02:00
|
|
|
|
|
|
|
%files demo
|
2023-08-24 07:16:24 +02:00
|
|
|
%{_datadir}/%{base_name}
|
2009-06-04 04:31:56 +02:00
|
|
|
|
2023-08-23 13:11:51 +02:00
|
|
|
%files javadoc
|
|
|
|
%license LICENSE
|
2023-08-24 07:16:24 +02:00
|
|
|
%{_javadocdir}/%{base_name}
|
|
|
|
|
|
|
|
%else
|
|
|
|
|
|
|
|
%files
|
|
|
|
%{_javadir}/%{base_name}.jar
|
|
|
|
|
|
|
|
%endif
|
2023-08-23 13:11:51 +02:00
|
|
|
|
2009-06-04 04:31:56 +02:00
|
|
|
%changelog
|