Ignore emply "_exportcontents" instructions
-------------------------------------------

                 Key: FELIX-989
                 URL: https://issues.apache.org/jira/browse/FELIX-989
             Project: Felix
          Issue Type: Improvement
          Components: Maven Bundle Plugin
    Affects Versions: maven-bundle-plugin-2.0.0, maven-bundle-plugin-1.4.3
            Reporter: Kaloyan Enimanev


There is a quite central parent POM in our build system, that incorporates all 
{{maven-bundle-plugin}} configuration . Basically, in this parent POM we 
specify all the possible configurations with some default values and leave the 
extender the possibility to override those via a set of POM properties. 

e.g. parent POM snippet :

{code:xml}
...
                        <plugin>
                                <groupId>org.apache.felix</groupId>
                                <artifactId>maven-bundle-plugin</artifactId>
...
                                                
<Import-Package>${osgi.import.package}</Import-Package>
..
{code}

can be used in the child POM as 

{code:xml}
...
<properties>
<osgi.import.package>com.foo.bar;version="1.0.0", *</osgi.import.package>
</properties>
..
{code}

That all worked fine, until yesterday when one of our developers wanted to use 
the "_exportcontents" instruction, so we have put the following snippet in our 
parent pom : 
{code:xml}
....
<_exportcontents>${osgi._exportcontents}</_exportcontents>
...
{code}

Since the property {{osgi._exportcontents}} is not set, the above line is equal 
to 

{code:xml}
....
<_exportcontents</_exportcontents>
...
{code}

Sadly, that broke the generation of "Export-Package" clauses in all the modules 
declaring "Embed-Dependency" of some form. The reason, seems to be hiding 
somewhere behind the empty-valued "_exportcontents" instruction.

So, would it be possible for the {{maven-bundle-plugin}} (or the BND tool) to 
ignore empty "_exportcontents" instructions ? 

Many thanks in advance,
  Kaloyan

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

Reply via email to