[ 
https://issues.apache.org/jira/browse/HTTPCLIENT-865?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12739302#action_12739302
 ] 

Sebb commented on HTTPCLIENT-865:
---------------------------------

For an example of a small project that creates OSGI entries with versioning, 
see almost any of the Commons projects.
These use Felix too. Here is an extract from the Commons parent POM:

===
        <configuration>
          <excludeDependencies>true</excludeDependencies>
          <manifestLocation>target/osgi</manifestLocation>
          <instructions>
            <!-- stops the "uses" clauses being added to "Export-Package" 
manifest entry -->
            <_nouses>true</_nouses>
            
<Bundle-SymbolicName>${commons.osgi.symbolicName}</Bundle-SymbolicName>
            <Export-Package>${commons.osgi.export}</Export-Package>
            <Private-Package>${commons.osgi.private}</Private-Package>
            <Import-Package>${commons.osgi.import}</Import-Package>
            
<DynamicImport-Package>${commons.osgi.dynamicImport}</DynamicImport-Package>
            <Bundle-DocURL>${project.url}</Bundle-DocURL>
          </instructions>
        </configuration>

===

    <!-- Configuration properties for the OSGi maven-bundle-plugin -->
    
<commons.osgi.symbolicName>org.apache.commons.${commons.componentid}</commons.osgi.symbolicName>
    
<commons.osgi.export>org.apache.commons.*;version=${pom.version}</commons.osgi.export>
    <commons.osgi.import>*</commons.osgi.import>
    <commons.osgi.dynamicImport />
    <commons.osgi.private />

    <!-- location of any manifest file used by maven-jar-plugin -->
    <commons.manifestfile>target/osgi/MANIFEST.MF</commons.manifestfile>


===

I think the idea is that individual projects can override the commons.* 
properties if necesary; that is probably not necessary for HC

> HttpClient OSGi Export-Package doesn't specify version
> ------------------------------------------------------
>
>                 Key: HTTPCLIENT-865
>                 URL: https://issues.apache.org/jira/browse/HTTPCLIENT-865
>             Project: HttpComponents HttpClient
>          Issue Type: Bug
>          Components: HttpClient
>            Reporter: Richard Wallace
>
> The "Export-Package" manifest entry doesn't specify the version of the 
> package being exported.  This means that packages importing it can't specify 
> a version to import.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to