You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@felix.apache.org by Rian Wouters <ri...@philips.com> on 2008/09/09 17:06:59 UTC
inconsistent documentation of UPnP on Felix binary distribution?
Dear all,
I am just starting to use Felix and tried to follow the available
documentation to play with its UPnP services.
I downloaded felix-1.2.0.zip, org.apache.felix.upnp.basedriver-0.8.0.jar,
org.osgi.compendium-1.2.0.jar and started the latter 2 bundles.
However, where can I find a binary distribution of the UPnP Extra, UPnP
Tester, UPnP Sample TV, UPnP Sample Clock, and UpnP Sample Binary-Light
bundles as they are shown in
http://felix.apache.org/site/upnp-getting-started.html?
I would really appreciate your help on this issue because I really don't
see how to use Felix now without downloading the source distribution, which
I hope I don't have to.
regards,
Rian Wouters
Ir. P.N. Wouters PDEng
Software Architect, Philips Applied Technologies, Digital Systems &
Technologies, Applied Software Engineering
Room 3-51C, High Tech Campus 5, 5636 AE, Eindhoven
Tel. +31 (0) 40 - 27 41757, Fax: +31 (0) 40 27 44108, Mobex +31 (0) 40 27
96048, Mobile: +31 (6) 22959643
E-mail: Rian.Wouters@philips.com
THURSDAY AFTERNOON ABSENT BECAUSE OF PART-TIME
Felix, Maven, Eclipse Tools questions
Posted by "Brad Cox, Ph.D." <bc...@virtualschool.edu>.
I'm using felix's maven plugin to build OSGI apps in eclipse. I
understand OSGI overall but the tools chain is driving me nuts.
What I don't understand is the interaction between pom.xml, the felix
maven plugin, MANIFEST.MF, and the "Organize Manifest Wizard" in
eclipse. And should META-INF be in the bundle root or
src/main/resources? Putting a copy in src/... does seem to be noticed
there but breaks everything, including command line builds. Apparently
due to a broken com.ibm.icu.something according to posted bugs.
My mental model is the pom is the input and MANIFEST.MF is produced by
felix maven plugin based on that pom. This model seems inaccurate
somehow. Felix maven plugin's output is voluminous with lots of broken
references which eclipse's "organize manifest wizard" seems there to
repair. Where do the bogus references come from? In practice, it seems
necessary for me to do further repairs to MANIFEST.MF by hand, but these
seem to somehow persist after I change the pom (thus the conflict with
my mental model).
There also seems to be vast differences between running mvn install in
the command line and running the same thing in eclipse. Using the
command line then importing into eclipse results in bundles that are
broken in eclipse and another round of whack a mole to sort things out
again. This often results in multiply-defined jar errors with the same
jar in "PDE Dependencies" and "Maven Dependencies". Removing PDE
dependencies in build settings seems to sort that out; sometimes.
The specific problem I'm struggling with is
org.osgi.framework.BundleException: The activator
com.gestalt.soakit.core.CoreActivator for bundle soakit.core is invalid
when that class is definitely defined. I think this means there's a
conflict between the BundleActivator class from OSGI vs Equinox, but
nothing I've tried seems to repair it (importing
org.eclipse.osgi.everything, not org.osgi.whatever).
The main problem here is that I'm confused about how the tools chain
works; broken mental model. Can someone set me straight?
Here's one of the key poms.
<?xml version="1.0" encoding="UTF-8"?>
<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>
<groupId>soakit</groupId>
<artifactId>soakit.core</artifactId>
<version>1.0-SNAPSHOT</version>
<name>soakit.core</name>
<description>SoaKit Core Abstraction Layer. Defines interfaces and
abstract classes for the components defined in sub-modules. Provides a
factory class for defining soakit composites with an XML configuration
file.</description>
<packaging>bundle</packaging>
<parent>
<groupId>soakit</groupId>
<artifactId>soakit</artifactId>
<version>1.0-SNAPSHOT</version>
</parent>
<dependencies>
<dependency>
<groupId>commons-collections</groupId>
<artifactId>commons-collections</artifactId>
<version>3.2</version>
</dependency>
<dependency>
<groupId>jdom</groupId>
<artifactId>jdom</artifactId>
<version>1.0</version>
</dependency>
<dependency>
<groupId>javax.xml.parsers</groupId>
<artifactId>jaxp-api</artifactId>
<version>1.4</version>
</dependency>
<dependency>
<groupId>javax.xml.ws</groupId>
<artifactId>jaxws-api</artifactId>
<version>2.1-1</version>
</dependency>
<dependency>
<groupId>xerces</groupId>
<artifactId>xercesImpl</artifactId>
<version>2.8.1</version>
</dependency>
<dependency>
<groupId>org.eclipse</groupId>
<artifactId>osgi</artifactId>
<version>3.4.0.v20080605-1900</version>
</dependency>
<dependency>
<groupId>jaxen</groupId>
<artifactId>jaxen</artifactId>
<version>1.1-beta-9</version>
</dependency>
</dependencies>
<build>
<resources>
<resource>
<directory>src/main/resources</directory>
</resource>
<resource>
<directory>.</directory>
<includes>
<include>plugin.xml</include>
</includes>
</resource>
</resources>
<plugins>
<plugin>
<artifactId>maven-eclipse-plugin</artifactId>
<configuration>
<pde>true</pde>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<version>1.4.3</version>
<extensions>true</extensions>
<configuration>
<unpackBundle>true</unpackBundle>
<manifestLocation>META-INF</manifestLocation>
<instructions>
<Bundle-Version>${pom.version}</Bundle-Version>
<Bundle-Name>${artifactId}</Bundle-Name>
<Bundle-SymbolicName>${artifactId}</Bundle-SymbolicName>
<Bundle-Description>Soakit Core Bundle</Bundle-Description>
<Bundle-Activator>com.gestalt.soakit.core.CoreActivator</Bundle-Activator>
<Embed-Dependency>*;scope=compile|runtime;inline=true</Embed-Dependency>
<Embed-Transitive>true</Embed-Transitive>
<Embed-Directory>target/dependency</Embed-Directory>
<_failok/>
<Bundle-RequiredExecutionEnvironment>J2SE-1.5</Bundle-RequiredExecutionEnvironment>
<Import-Package>
.,
*;-split-package:=merge-first,
org.apache.commons.collections.*;-split-package:=merge-first;version="3.2"
org.apache.commons.collections.iterators.*;-split-package:=merge-first;version="3.2",
org.jdom;-split-package:=merge-first;version="1.0",
org.jdom.*;-split-package:=merge-first;version="1.0",
org.jdom.input.*;-split-package:=merge-first;version="1.0",
org.jdom.output.*;-split-package:=merge-first;version="1.0",
org.apache.xerces.parsers;-split-package:=merge-first,
<!--
javax.*;-split-package:=merge-first,
javax.jws.*;-split-package:=merge-first,
javax.xml.bind.*;-split-package:=merge-first,
javax.annotation.*;-split-package:=merge-first,
javax.xml.soap.*;-split-package:=merge-first,
javax.xml.stream.*;-split-package:=merge-first,
javax.activation.*;-split-package:=merge-first,
-->
</Import-Package>
<Export-Package>
.,
*;-split-package:=merge-first,
org.apache.commons.collections.*;-split-package:=merge-first;version="3.2",
org.apache.commons.collections.iterators.*;-split-package:=merge-first;version="3.2",
org.jdom;-split-package:=merge-first;version="1.0",
org.jdom.*;-split-package:=merge-first;version="1.0",
org.jdom.input.*;-split-package:=merge-first;version="1.0",
org.jdom.output.*;-split-package:=merge-first;version="1.0",
org.apache.xerces.parsers.*;-split-package:=merge-first,
com.gestalt.soakit.core.*;-split-package;=merge-first,
<!--
javax.*;-split-package:=merge-first,
javax.jws.*;-split-package:=merge-first,
javax.xml.bind;-split-package:=merge-first,
javax.annotation;-split-package:=merge-first,
javax.xml.soap;-split-package:=merge-first,
javax.xml.stream;-split-package:=merge-first,
javax.activation;-split-package:=merge-first,
-->
</Export-Package>
</instructions>
</configuration>
</plugin>
<!--
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-eclipse-plugin</artifactId>
<configuration>
<projectNameTemplate>[artifactId]-[version]</projectNameTemplate>
<wtpmanifest>true</wtpmanifest>
<wtpapplicationxml>true</wtpapplicationxml>
<wtpversion>2.0</wtpversion>
<manifest>${basedir}/src/main/resources/META-INF/MANIFEST.MF</manifest>
</configuration>
</plugin>
-->
</plugins>
<extensions>
</extensions>
</build>
</project>