Skip to content
Commits on Source (10)
jaxb (2.3.0.1-1) unstable; urgency=medium
* Team upload.
* New upstream release
- Refreshed the patches
- No longer build the jaxb1 module and dropped the dependency on libmsv-java
- Removed the patch replacing nb-javac-api with a system dependency
on tools.jar (Closes: #893214)
* Standards-Version updated to 4.1.4
* Switch to debhelper level 11
* Use salsa.debian.org Vcs-* URLs
-- Emmanuel Bourg <ebourg@apache.org> Tue, 29 May 2018 12:49:57 +0200
jaxb (2.3.0-3) unstable; urgency=medium
* Team upload.
......
......@@ -4,7 +4,7 @@ Priority: optional
Maintainer: Debian Java Maintainers <pkg-java-maintainers@lists.alioth.debian.org>
Uploaders: Timo Aaltonen <tjaalton@debian.org>
Build-Depends:
debhelper (>= 10),
debhelper (>= 11),
default-jdk,
javahelper (>= 0.43),
libargs4j-java,
......@@ -15,12 +15,11 @@ Build-Depends:
libjaxb-api-java,
libmaven-dependency-plugin-java,
libmaven-javadoc-plugin-java,
libmsv-java,
librelaxng-datatype-java,
maven-debian-helper (>= 2.2)
Standards-Version: 4.1.1
Vcs-Git: https://anonscm.debian.org/git/pkg-java/jaxb.git
Vcs-Browser: https://anonscm.debian.org/cgit/pkg-java/jaxb.git
Standards-Version: 4.1.4
Vcs-Git: https://salsa.debian.org/java-team/jaxb.git
Vcs-Browser: https://salsa.debian.org/java-team/jaxb
Homepage: https://javaee.github.io/jaxb-v2/
Package: libjaxb-java
......
......@@ -24,12 +24,6 @@ License: CDDL-1.1 or GPL-2 with classpath exception, and public-domain
Comment:
Modified version of AttributesImpl class by David Megginson.
Files: jaxb-ri/runtime/jaxb1/src/main/java/com/sun/xml/bind/marshaller/NamespaceSupport.java
Copyright: 1997-2011, Oracle and/or its affiliates
License: CDDL-1.1 or GPL-2 with classpath exception, and public-domain
Comment:
Modified version of NamespaceSupport class by David Megginson.
License: public-domain
XMLWriter
.
......
......@@ -2,4 +2,3 @@ usr/share/java/jaxb-core.jar /usr/share/java/jaxb-api.jar /u
usr/share/java/jaxb-jxc.jar /usr/share/java/jaxb-xjc.jar /usr/share/java/jaxb-runtime.jar
usr/share/java/jaxb-runtime.jar /usr/share/java/jaxb-core.jar /usr/share/java/stax-ex.jar /usr/share/java/stax-api.jar /usr/share/java/FastInfoset.jar
usr/share/java/jaxb-xjc.jar /usr/share/java/jaxb-core.jar /usr/share/java/xsom.jar /usr/share/java/codemodel.jar /usr/share/java/rngom.jar /usr/share/java/dtd-parser.jar /usr/share/java/istack-commons-tools.jar
usr/share/java/jaxb1-impl.jar /usr/share/java/jaxb-runtime.jar /usr/share/java/msv-core.jar
......@@ -7,7 +7,6 @@ jaxb-ri/external/rngom/pom.xml --package=librngom-java --relocate=org.kohsuke.rn
jaxb-ri/jxc/pom.xml
jaxb-ri/runtime/pom.xml
jaxb-ri/runtime/impl/pom.xml --relocate=com.sun.xml.bind:jaxb-impl
jaxb-ri/runtime/jaxb1/pom.xml
jaxb-ri/xjc/pom.xml
jaxb-ri/codemodel/pom.xml --no-parent --package=libcodemodel-java
......
......@@ -13,16 +13,6 @@ Forwarded: not-needed
</dependency>
<dependency>
<groupId>org.jvnet.staxex</groupId>
--- a/jaxb-ri/runtime/jaxb1/pom.xml
+++ b/jaxb-ri/runtime/jaxb1/pom.xml
@@ -63,6 +63,7 @@
<dependency>
<groupId>org.glassfish.jaxb</groupId>
<artifactId>jaxb-runtime</artifactId>
+ <version>${project.version}</version>
</dependency>
<dependency>
<groupId>net.java.dev.msv</groupId>
--- a/jaxb-ri/xjc/pom.xml
+++ b/jaxb-ri/xjc/pom.xml
@@ -73,6 +73,7 @@
......
Description: Replaces nb-javac-api with a system dependency pointing to tools.jar from the JRE
(it won't work with Java 9 but this is the only alternative for now).
Author: Emmanuel Bourg <ebourg@apache.org>
Forwarded: not-needed
--- a/jaxb-ri/pom.xml
+++ b/jaxb-ri/pom.xml
@@ -208,10 +208,11 @@
<!-- JDK dependencies -->
<dependency>
<!-- required by com.sun.tools.jxc.model.nav.ApNavigator (com.sun.source.*) -->
- <groupId>org.netbeans.external</groupId>
- <artifactId>nb-javac-api</artifactId>
- <version>RELEASE82</version>
- <scope>provided</scope>
+ <groupId>com.sun</groupId>
+ <artifactId>tools</artifactId>
+ <version>8</version>
+ <scope>system</scope>
+ <systemPath>${java.home}/../lib/tools.jar</systemPath>
</dependency>
<dependency>
<!-- required by com.sun.tools.xjc.Options on JDK < 9
......@@ -3,7 +3,7 @@ Author: Emmanuel Bourg <ebourg@apache.org>
Forwarded: not-needed
--- a/jaxb-ri/pom.xml
+++ b/jaxb-ri/pom.xml
@@ -713,7 +713,6 @@
@@ -705,7 +705,6 @@
</properties>-->
<modules>
<module>docs</module>
......
......@@ -2,5 +2,4 @@
02-args4j-compatibility.patch
03-dependencies-versions.patch
04-xml-resolver-compatibility.patch
05-replace-nb-javac-api.patch
06-ignore-osgi-test-modules.patch
......@@ -24,6 +24,3 @@ override_dh_gencontrol:
# To avoid introducing an epoch the jaxb version is appended to the former
# libcodemodel-java version until jaxb > 2.6 is released.
dh_gencontrol -plibcodemodel-java -- -v2.6+jaxb$(DEB_VERSION)
get-orig-source:
uscan --download-current-version --force-download --rename
......@@ -49,7 +49,7 @@
<groupId>org.glassfish.jaxb</groupId>
<artifactId>jaxb-bom</artifactId>
<relativePath>../bom/pom.xml</relativePath>
<version>2.3.0</version>
<version>2.3.0.1</version>
</parent>
<groupId>com.sun.xml.bind</groupId>
......@@ -64,11 +64,9 @@
<properties>
<dtd-parser.version>1.2</dtd-parser.version>
<ant.version>1.9.7</ant.version>
<msv.version>2013.6.1</msv.version>
<ant.version>1.10.2</ant.version>
<!-- don't forget to check if isorelax.version is valid -> used in osgi -->
<relaxngDatatype.version>20020414</relaxngDatatype.version>
<isorelax.version>20090621</isorelax.version>
</properties>
<dependencyManagement>
......@@ -94,26 +92,11 @@
<artifactId>ant</artifactId>
<version>${ant.version}</version>
</dependency>
<dependency>
<groupId>net.java.dev.msv</groupId>
<artifactId>msv-core</artifactId>
<version>${msv.version}</version>
</dependency>
<dependency> <!-- xjc dependency... needed to be specified for xjc maven-dependency-plugin -->
<groupId>relaxngDatatype</groupId>
<artifactId>relaxngDatatype</artifactId>
<version>${relaxngDatatype.version}</version>
</dependency>
<dependency> <!--for osgi sources-->
<groupId>net.java.dev.msv</groupId>
<artifactId>xsdlib</artifactId>
<version>${msv.version}</version>
</dependency>
<dependency> <!--for osgi sources-->
<groupId>com.sun.xml.bind.jaxb</groupId>
<artifactId>isorelax</artifactId>
<version>${isorelax.version}</version>
</dependency>
</dependencies>
</dependencyManagement>
......
......@@ -53,7 +53,7 @@
<groupId>org.glassfish.jaxb</groupId>
<artifactId>jaxb-bom</artifactId>
<version>2.3.0</version>
<version>2.3.0.1</version>
<packaging>pom</packaging>
<name>JAXB BOM</name>
......@@ -193,11 +193,6 @@
<artifactId>jaxb-osgi</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>com.sun.xml.bind</groupId>
<artifactId>jaxb-extra-osgi</artifactId>
<version>${project.version}</version>
</dependency>
<!-- Dependencies -->
......
......@@ -48,7 +48,7 @@
<parent>
<groupId>com.sun.xml.bind.mvn</groupId>
<artifactId>jaxb-bundles</artifactId>
<version>2.3.0</version>
<version>2.3.0.1</version>
<relativePath>../pom.xml</relativePath>
</parent>
......
......@@ -48,7 +48,7 @@
<parent>
<groupId>com.sun.xml.bind.mvn</groupId>
<artifactId>jaxb-bundles</artifactId>
<version>2.3.0</version>
<version>2.3.0.1</version>
<relativePath>../pom.xml</relativePath>
</parent>
......
<!--
DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
Copyright (c) 2013-2017 Oracle and/or its affiliates. All rights reserved.
The contents of this file are subject to the terms of either the GNU
General Public License Version 2 only ("GPL") or the Common Development
and Distribution License("CDDL") (collectively, the "License"). You
may not use this file except in compliance with the License. You can
obtain a copy of the License at
https://oss.oracle.com/licenses/CDDL+GPL-1.1
or LICENSE.txt. See the License for the specific
language governing permissions and limitations under the License.
When distributing the software, include this License Header Notice in each
file and include the License file at LICENSE.txt.
GPL Classpath Exception:
Oracle designates this particular file as subject to the "Classpath"
exception as provided by Oracle in the GPL Version 2 section of the License
file that accompanied this code.
Modifications:
If applicable, add the following below the License Header, with the fields
enclosed by brackets [] replaced by your own identifying information:
"Portions Copyright [year] [name of copyright owner]"
Contributor(s):
If you wish your version of this file to be governed by only the CDDL or
only the GPL Version 2, indicate your decision by adding "[Contributor]
elects to include this software in this distribution under the [CDDL or GPL
Version 2] license." If you don't indicate a single choice of license, a
recipient has the option to distribute your version of this file under
either the CDDL, the GPL Version 2 or to extend the choice of license to
its licensees as provided above. However, if you add GPL Version 2 code
and therefore, elected the GPL Version 2 license, then the option applies
only if the new code is made subject to such option by the copyright
holder.
-->
<FindBugsFilter>
<!--
Hardly can do anything about this - the classes are public.
-->
<Match>
<Bug pattern="NM_SAME_SIMPLE_NAME_AS_SUPERCLASS"/>
</Match>
<!--
As designed, performance reasons.
-->
<Match>
<Or>
<Class name="com.sun.msv.grammar.SimpleNameClass"/>
<Class name="com.sun.msv.scanner.dtd.MessageCatalog"/>
<Class name="com.sun.msv.scanner.dtd.SimpleHashtable"/>
<Class name="com.sun.msv.scanner.dtd.DTDParser"/>
</Or>
<Or>
<Bug pattern="ES_COMPARING_STRINGS_WITH_EQ"/>
<Bug pattern="ES_COMPARING_PARAMETER_STRING_WITH_EQ"/>
</Or>
</Match>
</FindBugsFilter>
<?xml version="1.0" encoding="UTF-8"?>
<!--
DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
Copyright (c) 2013-2017 Oracle and/or its affiliates. All rights reserved.
The contents of this file are subject to the terms of either the GNU
General Public License Version 2 only ("GPL") or the Common Development
and Distribution License("CDDL") (collectively, the "License"). You
may not use this file except in compliance with the License. You can
obtain a copy of the License at
https://oss.oracle.com/licenses/CDDL+GPL-1.1
or LICENSE.txt. See the License for the specific
language governing permissions and limitations under the License.
When distributing the software, include this License Header Notice in each
file and include the License file at LICENSE.txt.
GPL Classpath Exception:
Oracle designates this particular file as subject to the "Classpath"
exception as provided by Oracle in the GPL Version 2 section of the License
file that accompanied this code.
Modifications:
If applicable, add the following below the License Header, with the fields
enclosed by brackets [] replaced by your own identifying information:
"Portions Copyright [year] [name of copyright owner]"
Contributor(s):
If you wish your version of this file to be governed by only the CDDL or
only the GPL Version 2, indicate your decision by adding "[Contributor]
elects to include this software in this distribution under the [CDDL or GPL
Version 2] license." If you don't indicate a single choice of license, a
recipient has the option to distribute your version of this file under
either the CDDL, the GPL Version 2 or to extend the choice of license to
its licensees as provided above. However, if you add GPL Version 2 code
and therefore, elected the GPL Version 2 license, then the option applies
only if the new code is made subject to such option by the copyright
holder.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>com.sun.xml.bind.mvn</groupId>
<artifactId>jaxb-osgi</artifactId>
<version>2.3.0</version>
<relativePath>../pom.xml</relativePath>
</parent>
<groupId>com.sun.xml.bind</groupId>
<artifactId>jaxb-extra-osgi</artifactId>
<packaging>jar</packaging>
<name>JAXB extra OSGI</name>
<description>JAXB extra OSGI bundle</description>
<dependencies>
<dependency>
<groupId>net.java.dev.msv</groupId>
<artifactId>msv-core</artifactId>
<optional>true</optional>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
<properties>
<generated.sources.dir>${project.build.directory}/generated-sources</generated.sources.dir>
<findbugs.exclude>${project.basedir}/exclude.xml</findbugs.exclude>
</properties>
<build>
<plugins>
<plugin> <!-- we don't want to fix javadocs in external libs (e.g. msv) -->
<artifactId>maven-javadoc-plugin</artifactId>
<executions>
<execution>
<id>attach-javadocs</id>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<additionalparam>-Xdoclint:none</additionalparam>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<configuration>
<appendAssemblyId>false</appendAssemblyId>
<descriptors>
<descriptor>src/main/assembly/assembly.xml</descriptor>
</descriptors>
<finalName>classes</finalName>
</configuration>
<executions>
<execution>
<id>make-assembly</id>
<phase>prepare-package</phase>
<goals>
<goal>single</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<executions>
<execution>
<id>bundle-manifest</id>
<phase>prepare-package</phase>
<goals>
<goal>manifest</goal>
</goals>
<configuration>
<instructions>
<Export-Package>
com.sun.msv.*;version=${msv.version},
com.sun.xml.*;version=${msv.version},
jp.gr.xml.*;version=${isorelax.version},
org.iso_relax.*;version=${isorelax.version}
</Export-Package>
<Bundle-ActivationPolicy>lazy</Bundle-ActivationPolicy>
<Import-Package>
org.relaxng.datatype;version=${relaxngDatatype.version},
org.relaxng.datatype.*;version=${relaxngDatatype.version}
</Import-Package>
</instructions>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
<manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
</archive>
</configuration>
</plugin>
<!-- Can be used to build everything from sources
<plugin>
<groupId>org.glassfish.build</groupId>
<artifactId>glassfishbuild-maven-plugin</artifactId>
<executions>
<execution>
<id>unpack-sources</id>
<phase>process-resources</phase>
<goals>
<goal>unpack-sources</goal>
</goals>
<configuration>
<attachSources>true</attachSources>
<excludeTransitive>true</excludeTransitive>
</configuration>
</execution>
</executions>
</plugin>
-->
<plugin> <!-- want to unpack sources from individual modules -->
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>unpack-sources</id>
<phase>prepare-package</phase>
<goals>
<goal>unpack</goal>
</goals>
<configuration>
<skip>${skipSources}</skip>
<artifactItems>
<artifactItem>
<groupId>net.java.dev.msv</groupId>
<artifactId>msv-core</artifactId>
<classifier>sources</classifier>
<overWrite>false</overWrite>
<outputDirectory>${generated.sources.dir}</outputDirectory>
</artifactItem>
<artifactItem>
<groupId>net.java.dev.msv</groupId>
<artifactId>xsdlib</artifactId>
<classifier>sources</classifier>
<overWrite>false</overWrite>
<outputDirectory>${generated.sources.dir}</outputDirectory>
</artifactItem>
<artifactItem>
<groupId>com.sun.xml.bind.jaxb</groupId>
<artifactId>isorelax</artifactId>
<classifier>sources</classifier>
<overWrite>false</overWrite>
<outputDirectory>${generated.sources.dir}</outputDirectory>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<executions>
<execution>
<phase>prepare-package</phase>
<goals>
<goal>add-source</goal>
</goals>
<configuration>
<sources>
<source>${generated.sources.dir}</source>
</sources>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-shade-plugin</artifactId>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<artifactSet>
<includes>
<include>net.java.dev.msv:msv-core</include>
<include>net.java.dev.msv:xsdlib</include>
<include>com.sun.xml.bind.jaxb:isorelax</include>
</includes>
<excludes>
<exclude>relaxngDatatype:relaxngDatatype</exclude>
</excludes>
</artifactSet>
<transformers>
<transformer
implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
<manifestEntries>
<Major-Version>${jaxb.majorVersion}.${jaxb.minorVersion}.${jaxb.incrementalVersion}</Major-Version>
<Specification-Version>${jaxb-api.majorVersion}.${jaxb-api.minorVersion}</Specification-Version>
<Git-Revision>${buildNumber}</Git-Revision>
<Class-Path/>
</manifestEntries>
</transformer>
</transformers>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<skip>true</skip>
</configuration>
<executions>
<execution>
<id>integration-test</id>
<goals>
<goal>test</goal>
</goals>
<phase>integration-test</phase>
<configuration>
<skip>false</skip>
<systemProperties>
<jaxb.spec.version>${jaxb-api.version}</jaxb.spec.version>
<osgi.dist>${project.build.directory}/${project.build.finalName}</osgi.dist>
</systemProperties>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
<profiles>
<profile>
<id>jdk9-setup</id>
<activation>
<jdk>9</jdk>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<configuration>
<sourceFileExcludes>
<sourceFileExclude>META-INF/versions/**</sourceFileExclude>
</sourceFileExcludes>
<additionalJOptions>
<additionalJOption>--add-modules</additionalJOption>
<additionalJOption>java.activation</additionalJOption>
<additionalJOption>--add-exports</additionalJOption>
<additionalJOption>java.xml/com.sun.org.apache.xml.internal.resolver.tools=ALL-UNNAMED</additionalJOption>
<additionalJOption>--add-exports</additionalJOption>
<additionalJOption>java.xml/com.sun.org.apache.xml.internal.resolver=ALL-UNNAMED</additionalJOption>
</additionalJOptions>
</configuration>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>
<?xml version="1.0" encoding="UTF-8"?>
<!--
DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
Copyright (c) 2013-2017 Oracle and/or its affiliates. All rights reserved.
The contents of this file are subject to the terms of either the GNU
General Public License Version 2 only ("GPL") or the Common Development
and Distribution License("CDDL") (collectively, the "License"). You
may not use this file except in compliance with the License. You can
obtain a copy of the License at
https://oss.oracle.com/licenses/CDDL+GPL-1.1
or LICENSE.txt. See the License for the specific
language governing permissions and limitations under the License.
When distributing the software, include this License Header Notice in each
file and include the License file at LICENSE.txt.
GPL Classpath Exception:
Oracle designates this particular file as subject to the "Classpath"
exception as provided by Oracle in the GPL Version 2 section of the License
file that accompanied this code.
Modifications:
If applicable, add the following below the License Header, with the fields
enclosed by brackets [] replaced by your own identifying information:
"Portions Copyright [year] [name of copyright owner]"
Contributor(s):
If you wish your version of this file to be governed by only the CDDL or
only the GPL Version 2, indicate your decision by adding "[Contributor]
elects to include this software in this distribution under the [CDDL or GPL
Version 2] license." If you don't indicate a single choice of license, a
recipient has the option to distribute your version of this file under
either the CDDL, the GPL Version 2 or to extend the choice of license to
its licensees as provided above. However, if you add GPL Version 2 code
and therefore, elected the GPL Version 2 license, then the option applies
only if the new code is made subject to such option by the copyright
holder.
-->
<assembly xmlns="http://maven.apache.org/ASSEMBLY/2.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/ASSEMBLY/2.0.0 http://maven.apache.org/xsd/assembly-2.0.0.xsd">
<id>zip-bundle</id>
<includeBaseDirectory>false</includeBaseDirectory>
<formats>
<format>dir</format>
</formats>
<dependencySets>
<dependencySet>
<unpack>true</unpack>
<unpackOptions>
<excludes>
<exclude>META-INF/maven/**</exclude>
</excludes>
</unpackOptions>
<useProjectArtifact>true</useProjectArtifact>
<useTransitiveDependencies>true</useTransitiveDependencies>
<useTransitiveFiltering>true</useTransitiveFiltering>
<outputDirectory>/</outputDirectory>
<directoryMode>0755</directoryMode>
<fileMode>0644</fileMode>
<includes>
<include>net.java.dev.msv:msv-core</include>
<include>net.java.dev.msv:xsdlib</include>
<include>com.sun.xml.bind.jaxb:isorelax</include>
</includes>
<excludes>
<exclude>relaxngDatatype:relaxngDatatype</exclude>
</excludes>
</dependencySet>
</dependencySets>
</assembly>
/*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
*
* Copyright (c) 2014-2017 Oracle and/or its affiliates. All rights reserved.
*
* The contents of this file are subject to the terms of either the GNU
* General Public License Version 2 only ("GPL") or the Common Development
* and Distribution License("CDDL") (collectively, the "License"). You
* may not use this file except in compliance with the License. You can
* obtain a copy of the License at
* https://oss.oracle.com/licenses/CDDL+GPL-1.1
* or LICENSE.txt. See the License for the specific
* language governing permissions and limitations under the License.
*
* When distributing the software, include this License Header Notice in each
* file and include the License file at LICENSE.txt.
*
* GPL Classpath Exception:
* Oracle designates this particular file as subject to the "Classpath"
* exception as provided by Oracle in the GPL Version 2 section of the License
* file that accompanied this code.
*
* Modifications:
* If applicable, add the following below the License Header, with the fields
* enclosed by brackets [] replaced by your own identifying information:
* "Portions Copyright [year] [name of copyright owner]"
*
* Contributor(s):
* If you wish your version of this file to be governed by only the CDDL or
* only the GPL Version 2, indicate your decision by adding "[Contributor]
* elects to include this software in this distribution under the [CDDL or GPL
* Version 2] license." If you don't indicate a single choice of license, a
* recipient has the option to distribute your version of this file under
* either the CDDL, the GPL Version 2 or to extend the choice of license to
* its licensees as provided above. However, if you add GPL Version 2 code
* and therefore, elected the GPL Version 2 license, then the option applies
* only if the new code is made subject to such option by the copyright
* holder.
*/
package jaxb.extra_osgi.test;
import junit.framework.TestCase;
import java.io.File;
import java.io.IOException;
import java.util.jar.JarFile;
import java.util.jar.Manifest;
/**
* Tests if MANIFEST Bundle-Version has correct version format.
*
* @author Martin Vojtek
*/
public class OSGiBundleVersionTest extends TestCase {
public OSGiBundleVersionTest(String name) {
super(name);
}
public void testJaxbOsgiBundleVersion() throws IOException {
String osgiJar = System.getProperty("osgi.dist");
assertNotNull("osgi.dist not set", osgiJar);
checkVersion(new File(osgiJar + ".jar"));
}
private void checkVersion(File f) throws IOException {
System.out.println("Checking: " + f.getAbsolutePath());
Manifest mf = new JarFile(f).getManifest();
String version = mf.getMainAttributes().getValue("Bundle-Version");
assertNotNull(version);
String[] v = version.split("\\.");
assertTrue("only <X.Y.Z> or <X.Y.Z.SNAPSHOT> is allowed but was: <" + version + ">", v.length <= 4);
for (int i = 0; i < (4 == v.length ? v.length - 1 : v.length); i++) {
try {
Integer.parseInt(v[i]);
} catch (Throwable t) {
fail("'" + v[i] + "' is not a number");
}
}
}
}
......@@ -48,7 +48,7 @@
<parent>
<groupId>com.sun.xml.bind.mvn</groupId>
<artifactId>jaxb-osgi</artifactId>
<version>2.3.0</version>
<version>2.3.0.1</version>
<relativePath>../pom.xml</relativePath>
</parent>
......@@ -80,12 +80,6 @@
<artifactId>jaxb-jxc</artifactId>
<optional>true</optional>
</dependency>
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>jaxb1-impl</artifactId>
<version>${project.version}</version>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.jvnet.staxex</groupId>
<artifactId>stax-ex</artifactId>
......@@ -119,6 +113,19 @@
</goals>
<configuration>
<additionalparam>-Xdoclint:none</additionalparam>
<sourceFileExcludes>
<sourceFileExclude>META-INF/versions/**</sourceFileExclude>
<sourceFileExclude>module-info.java</sourceFileExclude>
</sourceFileExcludes>
<includeDependencySources>false</includeDependencySources>
<additionalJOptions>
<additionalJOption>--add-modules</additionalJOption>
<additionalJOption>java.activation,java.xml.bind</additionalJOption>
<additionalJOption>--add-exports</additionalJOption>
<additionalJOption>java.xml/com.sun.org.apache.xml.internal.resolver.tools=ALL-UNNAMED</additionalJOption>
<additionalJOption>--add-exports</additionalJOption>
<additionalJOption>java.xml/com.sun.org.apache.xml.internal.resolver=ALL-UNNAMED</additionalJOption>
</additionalJOptions>
</configuration>
</execution>
</executions>
......@@ -184,7 +191,7 @@
</goals>
<configuration>
<outputDirectory>${project.build.outputDirectory}</outputDirectory>
<includeArtifactIds>jaxb-core,jaxb-impl,jaxb1-impl,jaxb-jxc,jaxb-xjc,stax-ex,FastInfoset</includeArtifactIds>
<includeArtifactIds>jaxb-core,jaxb-impl,jaxb-jxc,jaxb-xjc,stax-ex,FastInfoset</includeArtifactIds>
</configuration>
</execution>
<execution>
......@@ -224,13 +231,6 @@
<overWrite>false</overWrite>
<outputDirectory>${generated.sources.dir}</outputDirectory>
</artifactItem>
<artifactItem>
<groupId>com.sun.xml.bind</groupId>
<artifactId>jaxb1-impl</artifactId>
<classifier>sources</classifier>
<overWrite>false</overWrite>
<outputDirectory>${generated.sources.dir}</outputDirectory>
</artifactItem>
<artifactItem>
<groupId>org.jvnet.staxex</groupId>
<artifactId>stax-ex</artifactId>
......@@ -331,13 +331,6 @@
org.apache.tools.ant.taskdefs;resolution:=optional,
org.apache.tools.ant.taskdefs.compilers;resolution:=optional,
org.apache.tools.ant.types;resolution:=optional,
com.sun.msv.grammar;version=${msv.version};resolution:=optional,
com.sun.msv.grammar.trex;version=${msv.version};resolution:=optional,
com.sun.msv.grammar.util;version=${msv.version};resolution:=optional,
com.sun.msv.util;version=${msv.version};resolution:=optional,
com.sun.msv.verifier;version=${msv.version};resolution:=optional,
com.sun.msv.verifier.regexp;version=${msv.version};resolution:=optional,
org.iso_relax.verifier.impl;version=${isorelax.version};resolution:=optional
</Import-Package>
</instructions>
</configuration>
......@@ -378,7 +371,6 @@
<include>com.sun.xml.bind:jaxb-xjc</include>
<include>com.sun.xml.bind:jaxb-impl</include>
<include>com.sun.xml.bind:jaxb-jxc</include>
<include>com.sun.xml.bind:jaxb1-impl</include>
<include>org.jvnet.staxex:stax-ex</include>
<include>com.sun.xml.fastinfoset:FastInfoset</include>
</includes>
......@@ -388,10 +380,7 @@
<exclude>javax.xml.bind:jaxb-api</exclude>
<exclude>org.glassfish.jaxb:txw2</exclude>
<exclude>com.sun.istack:istack-commons-runtime</exclude>
<exclude>net.java.dev.msv:msv-core</exclude>
<exclude>net.java.dev.msv:xsdlib</exclude>
<exclude>relaxngDatatype:relaxngDatatype</exclude>
<exclude>com.sun.xml.bind.jaxb:isorelax</exclude>
</excludes>
</artifactSet>
<transformers>
......@@ -401,7 +390,7 @@
<Major-Version>${jaxb.majorVersion}.${jaxb.minorVersion}.${jaxb.incrementalVersion}</Major-Version>
<Specification-Version>${jaxb-api.majorVersion}.${jaxb-api.minorVersion}</Specification-Version>
<Git-Revision>${buildNumber}</Git-Revision>
<Class-Path>jaxb-api.jar jaxb-extra-osgi.jar</Class-Path>
<Class-Path>jaxb-api.jar</Class-Path>
<Multi-Release>true</Multi-Release>
</manifestEntries>
</transformer>
......