Add conditional build for reduced dependency set
This commit is contained in:
parent
8517c71115
commit
b3e941feb4
1611
0001-Avoid-unnecessary-dep-on-istack-commons.patch
Normal file
1611
0001-Avoid-unnecessary-dep-on-istack-commons.patch
Normal file
File diff suppressed because it is too large
Load Diff
@ -1,3 +1,12 @@
|
||||
From 23b7ecb1e748f79c28af927ae8dc4c7e66fe20cf Mon Sep 17 00:00:00 2001
|
||||
From: Mat Booth <mat.booth@redhat.com>
|
||||
Date: Fri, 10 May 2019 10:41:07 +0100
|
||||
Subject: [PATCH 2/2] Port to latest version of args4j
|
||||
|
||||
---
|
||||
.../main/java/com/sun/tools/txw2/Main.java | 69 +++++++++++--------
|
||||
1 file changed, 42 insertions(+), 27 deletions(-)
|
||||
|
||||
diff --git a/txw/compiler/src/main/java/com/sun/tools/txw2/Main.java b/txw/compiler/src/main/java/com/sun/tools/txw2/Main.java
|
||||
index 3c8cc84..3f1a092 100644
|
||||
--- a/txw/compiler/src/main/java/com/sun/tools/txw2/Main.java
|
||||
@ -145,3 +154,6 @@ index 3c8cc84..3f1a092 100644
|
||||
return new SAXParseable(in,eh);
|
||||
|
||||
// otherwise sniff from the file extension
|
||||
--
|
||||
2.20.1
|
||||
|
@ -1,15 +1,26 @@
|
||||
# Conditionally build with a minimal dependency set
|
||||
%bcond_with jp_minimal
|
||||
|
||||
Name: glassfish-jaxb
|
||||
Version: 2.2.11
|
||||
Release: 12%{?dist}
|
||||
Release: 13%{?dist}
|
||||
Summary: JAXB Reference Implementation
|
||||
|
||||
License: CDDL-1.1 and GPLv2 with exceptions
|
||||
URL: http://jaxb.java.net
|
||||
|
||||
Source0: https://jaxb.java.net/%{version}/jaxb-ri-%{version}.src.zip
|
||||
Patch0: txw2-args4j.patch
|
||||
Patch0: 0001-Avoid-unnecessary-dep-on-istack-commons.patch
|
||||
Patch1: 0002-Port-to-latest-version-of-args4j.patch
|
||||
|
||||
BuildRequires: maven-local
|
||||
BuildRequires: mvn(javax.xml.bind:jaxb-api)
|
||||
BuildRequires: mvn(net.java:jvnet-parent:pom:)
|
||||
BuildRequires: mvn(org.apache.felix:maven-bundle-plugin)
|
||||
BuildRequires: mvn(org.apache.maven.plugins:maven-dependency-plugin)
|
||||
BuildRequires: mvn(org.apache.maven.plugins:maven-shade-plugin)
|
||||
BuildRequires: mvn(org.codehaus.mojo:build-helper-maven-plugin)
|
||||
%if %{without jp_minimal}
|
||||
BuildRequires: mvn(args4j:args4j)
|
||||
BuildRequires: mvn(com.sun.istack:istack-commons-runtime)
|
||||
BuildRequires: mvn(com.sun.istack:istack-commons-tools)
|
||||
@ -17,32 +28,29 @@ BuildRequires: mvn(com.sun:tools)
|
||||
BuildRequires: mvn(com.sun.xml.dtd-parser:dtd-parser)
|
||||
BuildRequires: mvn(com.sun.xml.fastinfoset:FastInfoset)
|
||||
BuildRequires: mvn(com.sun.xsom:xsom)
|
||||
BuildRequires: mvn(javax.xml.bind:jaxb-api)
|
||||
BuildRequires: mvn(net.java:jvnet-parent:pom:)
|
||||
BuildRequires: mvn(org.apache.ant:ant)
|
||||
BuildRequires: mvn(org.apache.felix:maven-bundle-plugin)
|
||||
BuildRequires: mvn(org.apache.maven.plugins:maven-dependency-plugin)
|
||||
BuildRequires: mvn(org.apache.maven.plugins:maven-shade-plugin)
|
||||
BuildRequires: mvn(org.codehaus.mojo:build-helper-maven-plugin)
|
||||
BuildRequires: mvn(org.jvnet.staxex:stax-ex)
|
||||
BuildRequires: mvn(relaxngDatatype:relaxngDatatype)
|
||||
%endif
|
||||
|
||||
Requires: %{name}-core = %{version}-%{release}
|
||||
Requires: %{name}-runtime = %{version}-%{release}
|
||||
Requires: %{name}-txw2 = %{version}-%{release}
|
||||
%if %{without jp_minimal}
|
||||
Requires: %{name}-bom = %{version}-%{release}
|
||||
Requires: %{name}-bom-ext = %{version}-%{release}
|
||||
Requires: %{name}-codemodel = %{version}-%{release}
|
||||
Requires: %{name}-codemodel-annotation-compiler = %{version}-%{release}
|
||||
Requires: %{name}-codemodel-parent = %{version}-%{release}
|
||||
Requires: %{name}-core = %{version}-%{release}
|
||||
Requires: %{name}-external-parent = %{version}-%{release}
|
||||
Requires: %{name}-jxc = %{version}-%{release}
|
||||
Requires: %{name}-parent = %{version}-%{release}
|
||||
Requires: %{name}-rngom = %{version}-%{release}
|
||||
Requires: %{name}-runtime = %{version}-%{release}
|
||||
Requires: %{name}-runtime-parent = %{version}-%{release}
|
||||
Requires: %{name}-txw2 = %{version}-%{release}
|
||||
Requires: %{name}-txwc2 = %{version}-%{release}
|
||||
Requires: %{name}-txw-parent = %{version}-%{release}
|
||||
Requires: %{name}-xjc = %{version}-%{release}
|
||||
%endif
|
||||
|
||||
Obsoletes: glassfish-jaxb1-impl < 2.2.11-12
|
||||
|
||||
@ -51,6 +59,26 @@ BuildArch: noarch
|
||||
%description
|
||||
GlassFish JAXB Reference Implementation.
|
||||
|
||||
%package core
|
||||
Summary: JAXB Core
|
||||
|
||||
%description core
|
||||
JAXB Core module. Contains sources required by XJC, JXC and Runtime
|
||||
modules.
|
||||
|
||||
%package runtime
|
||||
Summary: JAXB Runtime
|
||||
|
||||
%description runtime
|
||||
JAXB (JSR 222) Reference Implementation
|
||||
|
||||
%package txw2
|
||||
Summary: TXW2 Runtime
|
||||
|
||||
%description txw2
|
||||
TXW is a library that allows you to write XML documents.
|
||||
|
||||
%if %{without jp_minimal}
|
||||
%package codemodel
|
||||
Summary: Codemodel Core
|
||||
|
||||
@ -83,13 +111,6 @@ Summary: Codemodel parent POM
|
||||
%description codemodel-parent
|
||||
This package contains codemodel parent POM.
|
||||
|
||||
%package core
|
||||
Summary: JAXB Core
|
||||
|
||||
%description core
|
||||
JAXB Core module. Contains sources required by XJC, JXC and Runtime
|
||||
modules.
|
||||
|
||||
%package external-parent
|
||||
Summary: JAXB External parent POM
|
||||
|
||||
@ -108,12 +129,6 @@ Summary: JAXB parent POM
|
||||
%description parent
|
||||
This package contains parent POM.
|
||||
|
||||
%package runtime
|
||||
Summary: JAXB Runtime
|
||||
|
||||
%description runtime
|
||||
JAXB (JSR 222) Reference Implementation
|
||||
|
||||
%package runtime-parent
|
||||
Summary: JAXB Runtime parent POM
|
||||
|
||||
@ -140,18 +155,13 @@ Summary: RELAX NG Object Model/Parser
|
||||
%description rngom
|
||||
This package contains RELAX NG Object Model/Parser.
|
||||
|
||||
%package txw2
|
||||
Summary: TXW2 Runtime
|
||||
|
||||
%description txw2
|
||||
TXW is a library that allows you to write XML documents.
|
||||
|
||||
%package txwc2
|
||||
Summary: TXW2 Compiler
|
||||
|
||||
%description txwc2
|
||||
JAXB schema generator. The tool to generate XML schema based on java
|
||||
classes.
|
||||
%endif
|
||||
|
||||
%package javadoc
|
||||
Summary: Javadocs for %{name}
|
||||
@ -162,7 +172,10 @@ This package contains the API documentation for %{name}.
|
||||
%prep
|
||||
%setup -q -c
|
||||
|
||||
%if %{with jp_minimal}
|
||||
%patch0 -p1
|
||||
%endif
|
||||
%patch1 -p1
|
||||
|
||||
# Disable unneeded OSGi bundles
|
||||
%pom_disable_module xjc bundles
|
||||
@ -180,6 +193,7 @@ This package contains the API documentation for %{name}.
|
||||
# Disable ancient jaxb1 runtime
|
||||
%pom_disable_module jaxb1 runtime
|
||||
|
||||
# Fix hard-coded tools location
|
||||
%pom_remove_dep com.sun:tools
|
||||
%pom_add_dep_mgmt com.sun:tools
|
||||
%pom_remove_dep com.sun:tools jxc
|
||||
@ -193,13 +207,33 @@ This package contains the API documentation for %{name}.
|
||||
%pom_remove_plugin :maven-source-plugin jxc
|
||||
%pom_remove_plugin :maven-source-plugin xjc
|
||||
|
||||
%if %{with jp_minimal}
|
||||
# For minimal build disable all modules with extra deps
|
||||
%pom_disable_module codemodel
|
||||
%pom_disable_module external
|
||||
%pom_disable_module jxc
|
||||
%pom_disable_module compiler txw
|
||||
%pom_disable_module xjc
|
||||
# For minimal build of impl module, don't compile in support for extra deps
|
||||
%pom_remove_dep org.jvnet.staxex:stax-ex runtime/impl
|
||||
%pom_remove_dep com.sun.xml.fastinfoset:FastInfoset runtime/impl
|
||||
rm runtime/impl/src/main/java/com/sun/xml/bind/v2/runtime/unmarshaller/{FastInfoset,StAXEx}Connector.java
|
||||
rm runtime/impl/src/main/java/com/sun/xml/bind/v2/runtime/output/{FastInfoset,StAXEx}StreamWriterOutput.java
|
||||
%endif
|
||||
|
||||
%mvn_alias org.glassfish.jaxb:jaxb-xjc "com.sun.xml.bind:jaxb-xjc"
|
||||
|
||||
# Package OSGi version of runtime with the non-OSGi version
|
||||
%mvn_package com.sun.xml.bind:jaxb-impl jaxb-runtime
|
||||
|
||||
# Don't install bundles parent pom
|
||||
%mvn_package com.sun.xml.bind.mvn:jaxb-bundles __noinstall
|
||||
|
||||
# Package OSGi version of runtime with the non-OSGi version
|
||||
%mvn_package com.sun.xml.bind:jaxb-impl jaxb-runtime
|
||||
%if %{with jp_minimal}
|
||||
# Don't install aggregator poms or boms for minimal build
|
||||
%mvn_package com.sun.xml.bind.mvn: __noinstall
|
||||
%mvn_package :jaxb-bom* __noinstall
|
||||
%endif
|
||||
|
||||
%build
|
||||
%mvn_build -f -s -- -Ddev -DbuildNumber=unknown
|
||||
@ -210,6 +244,16 @@ This package contains the API documentation for %{name}.
|
||||
%files
|
||||
%license License.txt licenceheader.txt License.html
|
||||
|
||||
%files core -f .mfiles-jaxb-core
|
||||
%license License.txt licenceheader.txt License.html
|
||||
|
||||
%files runtime -f .mfiles-jaxb-runtime
|
||||
%license License.txt licenceheader.txt License.html
|
||||
|
||||
%files txw2 -f .mfiles-txw2
|
||||
%license License.txt licenceheader.txt License.html
|
||||
|
||||
%if %{without jp_minimal}
|
||||
%files codemodel -f .mfiles-codemodel
|
||||
%license License.txt licenceheader.txt License.html
|
||||
|
||||
@ -222,9 +266,6 @@ This package contains the API documentation for %{name}.
|
||||
|
||||
%files codemodel-parent -f .mfiles-jaxb-codemodel-parent
|
||||
|
||||
%files core -f .mfiles-jaxb-core
|
||||
%license License.txt licenceheader.txt License.html
|
||||
|
||||
%files external-parent -f .mfiles-jaxb-external-parent
|
||||
|
||||
%files jxc -f .mfiles-jaxb-jxc
|
||||
@ -232,9 +273,6 @@ This package contains the API documentation for %{name}.
|
||||
|
||||
%files parent -f .mfiles-jaxb-parent
|
||||
|
||||
%files runtime -f .mfiles-jaxb-runtime
|
||||
%license License.txt licenceheader.txt License.html
|
||||
|
||||
%files runtime-parent -f .mfiles-jaxb-runtime-parent
|
||||
|
||||
%files txw-parent -f .mfiles-jaxb-txw-parent
|
||||
@ -244,17 +282,18 @@ This package contains the API documentation for %{name}.
|
||||
%files rngom -f .mfiles-rngom
|
||||
%license License.txt licenceheader.txt License.html
|
||||
|
||||
%files txw2 -f .mfiles-txw2
|
||||
%license License.txt licenceheader.txt License.html
|
||||
|
||||
%files txwc2 -f .mfiles-txwc2
|
||||
%license License.txt licenceheader.txt License.html
|
||||
%endif
|
||||
|
||||
%files javadoc -f .mfiles-javadoc
|
||||
%license License.txt licenceheader.txt License.html
|
||||
|
||||
|
||||
%changelog
|
||||
* Fri May 10 2019 Mat Booth <mat.booth@redhat.com> - 2.2.11-13
|
||||
- Add conditional build for reduced dependency set
|
||||
|
||||
* Thu May 09 2019 Mat Booth <mat.booth@redhat.com> - 2.2.11-12
|
||||
- Disable ancient jaxb1 runtime
|
||||
- Enable OSGi bundle version of the runtime
|
||||
|
Loading…
Reference in New Issue
Block a user