Search code examples
maveneclipse-plugintycho

How to build plugins having different versions from a single parent pom.xml?


I am trying to build several Eclipse plug-ins with Maven Tycho. All the plug-ins does not have the same version number.

Let's say the following pom architecture:

  • plugin1 (version 1.0.6.qualifier) / pom.xml
  • plugin2 (version 1.4.0.qualifier) / pom.xml
  • pom.xml (parent pom version 1.0.0.SNAPSHOT)

Maven's build fails with the following error:

[ERROR] Failed to execute goal org.eclipse.tycho:tycho-packaging-plugin:0.12.0:validate-version (default-validate-version) on project plugin1: Unqualified OSGi version 1.0.6.qualifier must match unqualified Maven version 1.0.0-SNAPSHOT for SNAPSHOT builds

How to configure the parent pom to be able to build those plug-ins with different version numbers? Should I use a different pom architecture to solve this issue?

Note that I don't want to modify plug-in's versions.


Solution

  • I found a solution. I added a version tag corresponding to the Eclipse plug-in version in each modules' pom.xml.

    Is it possible to use maven pom.xml files without any version tag and let tycho using version specified in MANIFEST.MF files?