Uploaded image for project: 'Commons IO'
  1. Commons IO
  2. IO-350

Maven-Bundle-Plugin imports version 2.4 as 1.4

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 2.4, 2.5
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      In 2.4 you added

       <commons.osgi.export>
              <!-- Explicit list of packages from IO 1.4 -->
              org.apache.commons.io;
              org.apache.commons.io.comparator;
              org.apache.commons.io.filefilter;
              org.apache.commons.io.input;
              org.apache.commons.io.output;version=1.4.9999;-noimport:=true,
              <!-- Same list plus * for new packages -->
              org.apache.commons.io;
              org.apache.commons.io.comparator;
              org.apache.commons.io.filefilter;
              org.apache.commons.io.input;
              org.apache.commons.io.output;
              org.apache.commons.io.*;version=${project.version};-noimport:=true
          </commons.osgi.export>
      

      This creates an entry in the MANIFEST.MF like

      Import-Package: org.apache.commons.io;version="[1.4,2)"
      

      Which leads to our bundles not working with 2.4, as we are exporting 2.4 and not 1.4 in our application.

      I think the solution is, that if somebody want's to use it as 1.4 he should export the packages as 1.4 by themselves.

      I added an example project.

        Attachments

        1. commons-io-osgi-bug.zip
          2 kB
          Adrian Moerchen

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                adrian2k7 Adrian Moerchen
              • Votes:
                1 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated: