Generate different Bundle-SymbolicName for different JARs
- Resolves: rhbz#1123055
This commit is contained in:
parent
8994abf010
commit
0ccbd402b9
@ -0,0 +1,99 @@
|
|||||||
|
From 00823b8008bffc5dd65c9e8de604994040a3190d Mon Sep 17 00:00:00 2001
|
||||||
|
From: Mikolaj Izdebski <mizdebsk@redhat.com>
|
||||||
|
Date: Tue, 29 Jul 2014 09:00:03 +0200
|
||||||
|
Subject: [PATCH] Generate different Bundle-SymbolicName for different JARs
|
||||||
|
|
||||||
|
---
|
||||||
|
pom.xml | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||||
|
1 file changed, 55 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/pom.xml b/pom.xml
|
||||||
|
index cdad31c..5707595 100644
|
||||||
|
--- a/pom.xml
|
||||||
|
+++ b/pom.xml
|
||||||
|
@@ -179,6 +179,52 @@ under the License.
|
||||||
|
<build>
|
||||||
|
<plugins>
|
||||||
|
|
||||||
|
+ <plugin>
|
||||||
|
+ <groupId>org.apache.felix</groupId>
|
||||||
|
+ <artifactId>maven-bundle-plugin</artifactId>
|
||||||
|
+ <executions>
|
||||||
|
+ <execution>
|
||||||
|
+ <id>tests-bundle-manifest</id>
|
||||||
|
+ <phase>process-classes</phase>
|
||||||
|
+ <goals>
|
||||||
|
+ <goal>manifest</goal>
|
||||||
|
+ </goals>
|
||||||
|
+ <configuration>
|
||||||
|
+ <manifestLocation>${project.build.directory}/osgi-tests</manifestLocation>
|
||||||
|
+ <instructions>
|
||||||
|
+ <Bundle-SymbolicName>${commons.osgi.symbolicName}.tests</Bundle-SymbolicName>
|
||||||
|
+ </instructions>
|
||||||
|
+ </configuration>
|
||||||
|
+ </execution>
|
||||||
|
+ <execution>
|
||||||
|
+ <id>api-bundle-manifest</id>
|
||||||
|
+ <phase>process-classes</phase>
|
||||||
|
+ <goals>
|
||||||
|
+ <goal>manifest</goal>
|
||||||
|
+ </goals>
|
||||||
|
+ <configuration>
|
||||||
|
+ <manifestLocation>${project.build.directory}/osgi-api</manifestLocation>
|
||||||
|
+ <instructions>
|
||||||
|
+ <Bundle-SymbolicName>${commons.osgi.symbolicName}.api</Bundle-SymbolicName>
|
||||||
|
+ </instructions>
|
||||||
|
+ </configuration>
|
||||||
|
+ </execution>
|
||||||
|
+ <execution>
|
||||||
|
+ <id>adapters-bundle-manifest</id>
|
||||||
|
+ <phase>process-classes</phase>
|
||||||
|
+ <goals>
|
||||||
|
+ <goal>manifest</goal>
|
||||||
|
+ </goals>
|
||||||
|
+ <configuration>
|
||||||
|
+ <manifestLocation>${project.build.directory}/osgi-adapters</manifestLocation>
|
||||||
|
+ <instructions>
|
||||||
|
+ <Bundle-SymbolicName>${commons.osgi.symbolicName}.adapters</Bundle-SymbolicName>
|
||||||
|
+ </instructions>
|
||||||
|
+ </configuration>
|
||||||
|
+ </execution>
|
||||||
|
+ </executions>
|
||||||
|
+ </plugin>
|
||||||
|
+
|
||||||
|
<!--
|
||||||
|
- We want to create four jarfiles from this project: normal, tests, api
|
||||||
|
- and adapters. The first two are handled by the normal jar:jar and
|
||||||
|
@@ -202,6 +248,9 @@ under the License.
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<jarName>commons-logging</jarName>
|
||||||
|
+ <archive>
|
||||||
|
+ <manifestFile>${project.build.directory}/osgi-tests/MANIFEST.MF</manifestFile>
|
||||||
|
+ </archive>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
|
|
||||||
|
@@ -213,6 +262,9 @@ under the License.
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<jarName>${project.artifactId}-api-${project.version}</jarName>
|
||||||
|
+ <archive>
|
||||||
|
+ <manifestFile>${project.build.directory}/osgi-api/MANIFEST.MF</manifestFile>
|
||||||
|
+ </archive>
|
||||||
|
<includes>
|
||||||
|
<include>org/apache/commons/logging/*.class</include>
|
||||||
|
<include>org/apache/commons/logging/impl/LogFactoryImpl*.class</include>
|
||||||
|
@@ -237,6 +289,9 @@ under the License.
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<jarName>${project.artifactId}-adapters-${project.version}</jarName>
|
||||||
|
+ <archive>
|
||||||
|
+ <manifestFile>${project.build.directory}/osgi-adapters/MANIFEST.MF</manifestFile>
|
||||||
|
+ </archive>
|
||||||
|
<includes>
|
||||||
|
<include>org/apache/commons/logging/impl/**.class</include>
|
||||||
|
<include>META-INF/LICENSE.txt</include>
|
||||||
|
--
|
||||||
|
1.9.3
|
||||||
|
|
@ -4,13 +4,15 @@
|
|||||||
|
|
||||||
Name: apache-%{short_name}
|
Name: apache-%{short_name}
|
||||||
Version: 1.2
|
Version: 1.2
|
||||||
Release: 1%{?dist}
|
Release: 2%{?dist}
|
||||||
Summary: Apache Commons Logging
|
Summary: Apache Commons Logging
|
||||||
License: ASL 2.0
|
License: ASL 2.0
|
||||||
URL: http://commons.apache.org/%{base_name}
|
URL: http://commons.apache.org/%{base_name}
|
||||||
Source0: http://www.apache.org/dist/commons/%{base_name}/source/%{short_name}-%{version}-src.tar.gz
|
Source0: http://www.apache.org/dist/commons/%{base_name}/source/%{short_name}-%{version}-src.tar.gz
|
||||||
Source2: http://mirrors.ibiblio.org/pub/mirrors/maven2/%{short_name}/%{short_name}-api/1.1/%{short_name}-api-1.1.pom
|
Source2: http://mirrors.ibiblio.org/pub/mirrors/maven2/%{short_name}/%{short_name}-api/1.1/%{short_name}-api-1.1.pom
|
||||||
|
|
||||||
|
Patch0: 0001-Generate-different-Bundle-SymbolicName-for-different.patch
|
||||||
|
|
||||||
BuildRequires: maven-local
|
BuildRequires: maven-local
|
||||||
BuildRequires: mvn(avalon-framework:avalon-framework-api)
|
BuildRequires: mvn(avalon-framework:avalon-framework-api)
|
||||||
BuildRequires: mvn(avalon-framework:avalon-framework-impl)
|
BuildRequires: mvn(avalon-framework:avalon-framework-impl)
|
||||||
@ -47,6 +49,7 @@ Summary: API documentation for %{name}
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n %{short_name}-%{version}-src
|
%setup -q -n %{short_name}-%{version}-src
|
||||||
|
%patch0 -p1
|
||||||
|
|
||||||
# Sent upstream https://issues.apache.org/jira/browse/LOGGING-143
|
# Sent upstream https://issues.apache.org/jira/browse/LOGGING-143
|
||||||
%pom_remove_dep :avalon-framework
|
%pom_remove_dep :avalon-framework
|
||||||
@ -102,6 +105,10 @@ install -pm 644 %{SOURCE2} %{buildroot}/%{_mavenpomdir}/JPP-%{short_name}-api.po
|
|||||||
# -----------------------------------------------------------------------------
|
# -----------------------------------------------------------------------------
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Jul 29 2014 Mikolaj Izdebski <mizdebsk@redhat.com> - 1.2-2
|
||||||
|
- Generate different Bundle-SymbolicName for different JARs
|
||||||
|
- Resolves: rhbz#1123055
|
||||||
|
|
||||||
* Sun Jul 20 2014 Mikolaj Izdebski <mizdebsk@redhat.com> - 1.2-1
|
* Sun Jul 20 2014 Mikolaj Izdebski <mizdebsk@redhat.com> - 1.2-1
|
||||||
- Update to upstream version 1.2
|
- Update to upstream version 1.2
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user