Maven Eclipse Plugin
  1. Maven Eclipse Plugin
  2. MECLIPSE-618

MANIFEST files generated by plugin are empty when they shouldnt

    Details

    • Type: Bug Bug
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Won't Fix
    • Affects Version/s: 2.7
    • Fix Version/s: None
    • Component/s: M2Eclipse support
    • Labels:
      None
    • Environment:
      Any
    • Number of attachments :
      0

      Description

      MANIFEST.MF files generated by the plugin are empty, therefore a correct deployment of an EAR project on an application server such as JBoss will fail with classloading issues.

      After a close look at the source code the problem comes from the fact that the dependencies resolving is disabled in the mojo, in order to not feed the .classpath, but having this side-effect.

      I suggest resolving dependencies in any case, and adding a property instead to filter dependencies in the .classpath generation.
      therefore :
      1: add boolean property to EclipsePlugin : ignoreDeps
      2: add boolean property to EclipseWriterConfig : ignoreDeps
      3: in M2EclipseMojo>>setupExtra() :

      • //setResolveDependencies( false );
      • setIgnoreDeps(true);
        4: in EclipsePlugin>>createEclipseWriterConfig(IdeDependency[]) :
      • call config.setIgnoreDeps(isIgnoreDeps());
        5: in EclipseClasspathWriter>>write() :
      • test against if (!config.isIgnoreDeps()) around lines 348 to 387 in order to skip writing of M2_REPO... dependencies

      Tested here, works like a charm

        Activity

        Hide
        Michael Osipov added a comment -

        Please refer to https://cwiki.apache.org/confluence/display/MAVEN/The+Great+JIRA+Cleanup+of+2014 if you're wondering why this issue was closed out.

        Show
        Michael Osipov added a comment - Please refer to https://cwiki.apache.org/confluence/display/MAVEN/The+Great+JIRA+Cleanup+of+2014 if you're wondering why this issue was closed out.
        Michael Osipov made changes -
        Field Original Value New Value
        Resolution Won't Fix [ 2 ]
        Status Open [ 1 ] Closed [ 6 ]

          People

          • Assignee:
            Unassigned
            Reporter:
            Andre Doherty
          • Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: