diff --git a/.felix-osgi-compendium.metadata b/.felix-osgi-compendium.metadata new file mode 100644 index 0000000..0d56ebb --- /dev/null +++ b/.felix-osgi-compendium.metadata @@ -0,0 +1 @@ +be5620b1e693dc730802e942de6066d47655c6f2 SOURCES/org.osgi.compendium-1.4.0-project.tar.gz diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..91cf35c --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +SOURCES/org.osgi.compendium-1.4.0-project.tar.gz diff --git a/SOURCES/0001-Fix-servlet-api-dependency.patch b/SOURCES/0001-Fix-servlet-api-dependency.patch new file mode 100644 index 0000000..1a45582 --- /dev/null +++ b/SOURCES/0001-Fix-servlet-api-dependency.patch @@ -0,0 +1,27 @@ +From 3a7cfc3cf5cadca0e25854ccb85c65f46fd15737 Mon Sep 17 00:00:00 2001 +From: Stanislav Ochotnicky +Date: Wed, 2 Feb 2011 14:17:20 +0100 +Subject: [PATCH 1/2] Fix servlet api dependency + +--- + pom.xml | 4 ++-- + 1 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/pom.xml b/pom.xml +index d53eaa9..f45d162 100644 +--- a/pom.xml ++++ b/pom.xml +@@ -38,8 +38,8 @@ + 1.4.0 + + +- ${pom.groupId} +- javax.servlet ++ javax.servlet ++ servlet-api + 1.0.0 + + +-- +1.7.3.5 + diff --git a/SOURCES/0002-Fix-compile-target.patch b/SOURCES/0002-Fix-compile-target.patch new file mode 100644 index 0000000..363bf68 --- /dev/null +++ b/SOURCES/0002-Fix-compile-target.patch @@ -0,0 +1,32 @@ +From 5b80abcb5b2dbead332e1c77fa615d6f93fe2218 Mon Sep 17 00:00:00 2001 +From: Stanislav Ochotnicky +Date: Wed, 2 Feb 2011 14:50:17 +0100 +Subject: [PATCH 2/2] Fix compile target + +--- + pom.xml | 9 +++++++++ + 1 files changed, 9 insertions(+), 0 deletions(-) + +diff --git a/pom.xml b/pom.xml +index f45d162..2c1a7a9 100644 +--- a/pom.xml ++++ b/pom.xml +@@ -67,6 +67,15 @@ + + + ++ ++ org.apache.maven.plugins ++ maven-compiler-plugin ++ 2.3.2 ++ ++ 1.5 ++ 1.5 ++ ++ + + + +-- +1.7.3.5 + diff --git a/SOURCES/0003-Add-CM_LOCATION_CHANGED-property-to-ConfigurationEve.patch b/SOURCES/0003-Add-CM_LOCATION_CHANGED-property-to-ConfigurationEve.patch new file mode 100644 index 0000000..a3127c1 --- /dev/null +++ b/SOURCES/0003-Add-CM_LOCATION_CHANGED-property-to-ConfigurationEve.patch @@ -0,0 +1,37 @@ +From ec6885545fb6889ed9a5522647b9780a53c6fd93 Mon Sep 17 00:00:00 2001 +From: Marek Goldmann +Date: Fri, 15 Jun 2012 11:25:12 +0200 +Subject: [PATCH 3/3] Add CM_LOCATION_CHANGED property to ConfigurationEvent. + +--- + .../java/org/osgi/service/cm/ConfigurationEvent.java | 14 ++++++++++++++ + 1 file changed, 14 insertions(+) + +diff --git a/src/main/java/org/osgi/service/cm/ConfigurationEvent.java b/src/main/java/org/osgi/service/cm/ConfigurationEvent.java +index f17007f..e98f3ac 100644 +--- a/src/main/java/org/osgi/service/cm/ConfigurationEvent.java ++++ b/src/main/java/org/osgi/service/cm/ConfigurationEvent.java +@@ -79,6 +79,20 @@ public class ConfigurationEvent { + */ + public static final int CM_DELETED = 2; + /** ++ * The location of a {@code Configuration} has been changed. ++ * ++ *

++ * This {@code ConfigurationEvent} type that indicates that the location of ++ * a {@code Configuration} object has been changed. ++ * ++ * An event is fired when a call to ++ * {@link Configuration#setBundleLocation(String)} successfully changes the ++ * location. ++ * ++ * @since 1.4 ++ */ ++ public static final int CM_LOCATION_CHANGED = 3; ++ /** + * Type of this event. + * + * @see #getType +-- +1.7.10.2 + diff --git a/SOURCES/0004-Add-TARGET-property-to-ConfigurationPermission.patch b/SOURCES/0004-Add-TARGET-property-to-ConfigurationPermission.patch new file mode 100644 index 0000000..7d3c064 --- /dev/null +++ b/SOURCES/0004-Add-TARGET-property-to-ConfigurationPermission.patch @@ -0,0 +1,31 @@ +From 88616a67fcdcf3bbc201ed1736b31a61da7f609e Mon Sep 17 00:00:00 2001 +From: Marek Goldmann +Date: Fri, 15 Jun 2012 11:32:27 +0200 +Subject: [PATCH 4/4] Add TARGET property to ConfigurationPermission + +--- + src/main/java/org/osgi/service/cm/ConfigurationPermission.java | 8 ++++++++ + 1 file changed, 8 insertions(+) + +diff --git a/src/main/java/org/osgi/service/cm/ConfigurationPermission.java b/src/main/java/org/osgi/service/cm/ConfigurationPermission.java +index 3af9088..7b8f3e3 100644 +--- a/src/main/java/org/osgi/service/cm/ConfigurationPermission.java ++++ b/src/main/java/org/osgi/service/cm/ConfigurationPermission.java +@@ -40,6 +40,14 @@ public final class ConfigurationPermission extends BasicPermission { + public final static String CONFIGURE = "configure"; + + /** ++ * The permission to be updated, that is, act as a Managed Service or ++ * Managed Service Factory. The action string {@value #TARGET}. ++ * ++ * @since 1.4 ++ */ ++ public final static String TARGET = "target"; ++ ++ /** + * Create a new ConfigurationPermission. + * + * @param name Name must be "*". +-- +1.7.10.2 + diff --git a/SOURCES/0005-Add-getResourceURL-method-to-make-jbosgi-framework-h.patch b/SOURCES/0005-Add-getResourceURL-method-to-make-jbosgi-framework-h.patch new file mode 100644 index 0000000..aab7f71 --- /dev/null +++ b/SOURCES/0005-Add-getResourceURL-method-to-make-jbosgi-framework-h.patch @@ -0,0 +1,28 @@ +From d9df4679129efdc654b44213fb33abd7ac042e81 Mon Sep 17 00:00:00 2001 +From: Marek Goldmann +Date: Tue, 3 Jul 2012 18:43:17 +0200 +Subject: [PATCH 5/5] Add getResourceURL method to make jbosgi-framework + happy... + +--- + src/main/java/org/osgi/util/xml/XMLParserActivator.java | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/src/main/java/org/osgi/util/xml/XMLParserActivator.java b/src/main/java/org/osgi/util/xml/XMLParserActivator.java +index 963c092..85f9f56 100644 +--- a/src/main/java/org/osgi/util/xml/XMLParserActivator.java ++++ b/src/main/java/org/osgi/util/xml/XMLParserActivator.java +@@ -165,6 +165,10 @@ public class XMLParserActivator implements BundleActivator, ServiceFactory { + .getResource(DOMCLASSFILE))); + } + ++ protected URL getResourceURL(Bundle parserBundle, String resname) { ++ return parserBundle.getResource(resname); ++ } ++ + /** + * This method has nothing to do as all active service registrations will + * automatically get unregistered when the bundle stops. +-- +1.7.10.4 + diff --git a/SPECS/felix-osgi-compendium.spec b/SPECS/felix-osgi-compendium.spec new file mode 100644 index 0000000..abc3fcc --- /dev/null +++ b/SPECS/felix-osgi-compendium.spec @@ -0,0 +1,140 @@ +# Prevent brp-java-repack-jars from being run. +%define __jar_repack %{nil} + +%global bundle org.osgi.compendium +%global felixdir %{_javadir}/felix +%global POM %{_mavenpomdir}/JPP.felix-%{bundle}.pom + +Name: felix-osgi-compendium +Version: 1.4.0 +Release: 19%{?dist} +Summary: Felix OSGi R4 Compendium Bundle + +Group: Development/Libraries +License: ASL 2.0 +URL: http://felix.apache.org +Source0: http://www.apache.org/dist/felix/%{bundle}-%{version}-project.tar.gz + +Patch0: 0001-Fix-servlet-api-dependency.patch +Patch1: 0002-Fix-compile-target.patch +Patch2: 0003-Add-CM_LOCATION_CHANGED-property-to-ConfigurationEve.patch +Patch3: 0004-Add-TARGET-property-to-ConfigurationPermission.patch +# This is an ugly patch that adds getResourceURL method. This prevents jbosgi-framework +# package from bundling osgi files. Once the jbosgi-framework will be updated +# to a new version without the need for this patch, REMOVE it! +Patch4: 0005-Add-getResourceURL-method-to-make-jbosgi-framework-h.patch + +BuildArch: noarch + +BuildRequires: java-devel >= 1:1.6.0 +BuildRequires: jpackage-utils +BuildRequires: maven-local +BuildRequires: maven-surefire-provider-junit4 +BuildRequires: felix-parent +BuildRequires: felix-osgi-core +BuildRequires: felix-osgi-foundation +BuildRequires: tomcat-servlet-3.0-api + +%description +OSGi Service Platform Release 4 Compendium Interfaces and Classes. + +%package javadoc +Group: Documentation +Summary: Javadoc for %{name} + +%description javadoc +API documentation for %{name}. + +%prep +%setup -q -n %{bundle}-%{version} + +# fix servlet api properly +%patch0 -p1 +# fix compile source/target +%patch1 -p1 +# add CM_LOCATION_CHANGED property +%patch2 -p1 +# add TARGET property +%patch3 -p1 +# add getResourceURL method +%patch4 -p1 + +%mvn_file :%{bundle} "felix/%{bundle}" +%mvn_alias "org.apache.felix:%{bundle}" "org.osgi:%{bundle}" + +%build +%mvn_build + +%install +%mvn_install + +%files -f .mfiles +%doc LICENSE NOTICE + +%files javadoc -f .mfiles-javadoc +%doc LICENSE NOTICE + + +%changelog +* Fri Dec 27 2013 Daniel Mach - 1.4.0-19 +- Mass rebuild 2013-12-27 + +* Wed Sep 18 2013 Mikolaj Izdebski - 1.4.0-18 +- Add missing BR: felix-parent + +* Thu Aug 22 2013 Michal Srb - 1.4.0-17 +- Migrate away from mvn-rpmbuild (Resolves: rhbz#997463) + +* Fri Jul 12 2013 Mikolaj Izdebski - 1.4.0-16 +- Remove workaround for rpm bug #646523 + +* Fri Jun 28 2013 Mikolaj Izdebski - 1.4.0-15 +- Rebuild to regenerate API documentation +- Resolves: CVE-2013-1571 + +* Wed Feb 13 2013 Fedora Release Engineering - 1.4.0-14 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild + +* Wed Feb 06 2013 Java SIG - 1.4.0-13 +- Update for https://fedoraproject.org/wiki/Fedora_19_Maven_Rebuild +- Replace maven BuildRequires with maven-local + +* Thu Jul 19 2012 Fedora Release Engineering - 1.4.0-12 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild + +* Tue Jul 03 2012 Marek Goldmann 1.4.0-11 +- Add getResourceURL method to XMLParserActivator + +* Fri Jun 15 2012 Marek Goldmann 1.4.0-10 +- Add CM_LOCATION_CHANGED property to ConfigurationEvent +- Add TARGET property to ConfigurationPermission + +* Wed Mar 21 2012 Alexander Kurtakov 1.4.0-9 +- Move to tomcat 7.x servlet api. + +* Fri Jan 13 2012 Fedora Release Engineering - 1.4.0-8 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild + +* Thu Sep 22 2011 Stanislav Ochotnicky - 1.4.0-7 +- Add org.osgi groupId to depmap +- Packaging fixes + +* Tue Feb 08 2011 Fedora Release Engineering - 1.4.0-6 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild + +* Wed Feb 2 2011 Stanislav Ochotnicky - 1.4.0-5 +- Fix servlet api in pom + +* Mon Dec 27 2010 Mat Booth 1.4.0-4 +- Fix POM names RHBZ #655800. +- Versionless jars/docs, update maven plug-in BRs. +- Other misc guideline compliances. + +* Mon Jul 12 2010 Victor G. Vasilyev 1.4.0-3 +- Avoid owning the %%{_javadir}/%%{project} directory + +* Wed Jul 07 2010 Victor G. Vasilyev 1.4.0-2 +- Use maven instead of ant + +* Tue Jun 22 2010 Victor G. Vasilyev 1.4.0-1 +- Release 1.4.0