jena-shadowed-ext containing guava 18.0
Project: http://git-wip-us.apache.org/repos/asf/jena/repo Commit: http://git-wip-us.apache.org/repos/asf/jena/commit/6879a9e4 Tree: http://git-wip-us.apache.org/repos/asf/jena/tree/6879a9e4 Diff: http://git-wip-us.apache.org/repos/asf/jena/diff/6879a9e4 Branch: refs/heads/master Commit: 6879a9e41f9ac442a0617b365529330cd886f3ab Parents: cc55484 Author: Stian Soiland-Reyes <[email protected]> Authored: Fri Mar 20 23:13:49 2015 +0000 Committer: Stian Soiland-Reyes <[email protected]> Committed: Mon Mar 23 21:37:58 2015 +0000 ---------------------------------------------------------------------- jena-parent/pom.xml | 6 +++ jena-shadowed-ext/pom.xml | 109 +++++++++++++++++++++++++++++++++++++++++ pom.xml | 1 + 3 files changed, 116 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/jena/blob/6879a9e4/jena-parent/pom.xml ---------------------------------------------------------------------- diff --git a/jena-parent/pom.xml b/jena-parent/pom.xml index b573b62..8b0871a 100644 --- a/jena-parent/pom.xml +++ b/jena-parent/pom.xml @@ -665,6 +665,12 @@ <version>2.5.3</version> <extensions>true</extensions> </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-shade-plugin</artifactId> + <version>2.3</version> + </plugin> + </plugins> </pluginManagement> http://git-wip-us.apache.org/repos/asf/jena/blob/6879a9e4/jena-shadowed-ext/pom.xml ---------------------------------------------------------------------- diff --git a/jena-shadowed-ext/pom.xml b/jena-shadowed-ext/pom.xml new file mode 100644 index 0000000..5bb920b --- /dev/null +++ b/jena-shadowed-ext/pom.xml @@ -0,0 +1,109 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<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>org.apache.jena</groupId> + <artifactId>jena-parent</artifactId> + <version>13-SNAPSHOT</version> + <relativePath>../jena-parent</relativePath> + </parent> + <artifactId>jena-shadowed-ext</artifactId> + <version>2.13.1-SNAPSHOT</version> + <packaging>bundle</packaging> + <name>Apache Jena - Shadowed external libraries</name> + <description> + This module shadows some external libraries like Guava, + which we don't want to be depending on in their regular + package names, as they are likely to change/upgrade + externally and also be used in other libraries + in potentialyl conflicting versions. + + This module uses the Shade plugin to re-package them + under the package name + org.apache.jena.ext and is also a valid OSGi bundle + (but should only be used by used by other Jena modules). + + </description> + + + <dependencies> + <dependency> + <groupId>com.google.guava</groupId> + <artifactId>guava</artifactId> + <!-- Version number specified explicitly and not in jena-parent, + as it should only be used here, and further shadowing/bundle/NOTICE + consideration might be needed on upgrade. --> + <version>18.0</version> + <!-- + As Guava does not contain a NOTICE and is also + licensed under Apache License, no additional + NOTICE is required by us. In a way we should probably + NOT include our own NOTICE file in this JAR.. + --> + </dependency> + </dependencies> + + <build> + <plugins> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-shade-plugin</artifactId> + <executions> + <execution> + <phase>package</phase> + <goals> + <goal>shade</goal> + </goals> + </execution> + </executions> + <configuration> + <artifactSet> + <includes> + <artifact>com.google.guava:guava</artifact> + </includes> + </artifactSet> + <relocations> + <relocation> + <pattern>com.google</pattern> + <shadedPattern>org.apache.jena.ext.com.google</shadedPattern> + </relocation> + </relocations> + </configuration> + </plugin> + <plugin> + <groupId>org.apache.felix</groupId> + <artifactId>maven-bundle-plugin</artifactId> + <configuration> + <instructions> + <Export-Package>!org.apache.jena.ext.com.google.common.base.internal,org.apache.jena.ext.*</Export-Package> + <Import-Package> + javax.annotation;resolution:=optional, + sun.misc.*;resolution:=optional + </Import-Package> + </instructions> + </configuration> + </plugin> + </plugins> + </build> + +</project> http://git-wip-us.apache.org/repos/asf/jena/blob/6879a9e4/pom.xml ---------------------------------------------------------------------- diff --git a/pom.xml b/pom.xml index 044cfbf..54f3d05 100644 --- a/pom.xml +++ b/pom.xml @@ -98,6 +98,7 @@ </activation> <modules> <module>jena-parent</module> + <module>jena-shadowed-ext</module> <module>jena-iri</module> <module>jena-core</module>
