Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[tycho-user] Export product via tycho

Dear Tycho Community



I have a Eclipse RCP application, that consist of a few plugins. 
I have set  of eclipse projects. Each project describe one plugin. I have separate project that contains two products file for 32-bits platforms and 64 bits platform
I am able to export product via Eclipse IDE. 
I am able to build each plugin using tycho and maven

I need to find out how to export product using tycho.

Problem is : when I run maven against parent pom all plugins is built with success, but export of product fails  I see that tycho cannot find my plugins from other projects and include them in export process. I did not understand how to describe dependency that helps maven to find other  projects. The required files have been attached



[ERROR] Failed to execute goal org.eclipse.tycho:tycho-p2-publisher-plugin:0.24.0:publish-products (default-publish-products) on project com.psl.atom.product: Execution default-publish-products of goal org.eclipse.tycho:tycho-p2-publisher-plugin:0.24.0:publish-products failed: Cannot resolve dependencies of product AtomProduct32.product. See log for details. -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.eclipse.tycho:tycho-p2-publisher-plugin:0.24.0:publish-products (default-publish-products) on project com.psl.atom.product: Execution default-publish-products of goal org.eclipse.tycho:tycho-p2-publisher-plugin:0.24.0:publish-products failed: Cannot resolve dependencies of product AtomProduct32.product. See log for details.
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:224)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)
at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:120)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:347)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:154)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:582)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:214)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:158)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
Caused by: org.apache.maven.plugin.PluginExecutionException: Execution default-publish-products of goal org.eclipse.tycho:tycho-p2-publisher-plugin:0.24.0:publish-products failed: Cannot resolve dependencies of product AtomProduct32.product. See log for details.
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:143)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
... 19 more
Caused by: org.eclipse.tycho.artifacts.DependencyResolutionException: Cannot resolve dependencies of product AtomProduct32.product. See log for details.
at org.eclipse.tycho.p2.tools.publisher.ProductVersionExpansionRun.reportErrors(ProductVersionExpansionRun.java:83)
at org.eclipse.tycho.p2.tools.publisher.ExpandedProduct.expandVersions(ExpandedProduct.java:117)
at org.eclipse.tycho.p2.tools.publisher.ExpandedProduct.<init>(ExpandedProduct.java:56)
at org.eclipse.tycho.p2.tools.publisher.PublishProductToolImpl.publishProduct(PublishProductToolImpl.java:73)
at org.eclipse.tycho.plugins.p2.publisher.PublishProductMojo.publishContent(PublishProductMojo.java:97)
at org.eclipse.tycho.plugins.p2.publisher.AbstractPublishMojo.execute(AbstractPublishMojo.java:35)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:132)
... 20 more


-- 

--
Александр

Attachment: build.log
Description: Binary data

<project xmlns="http://maven.apache.org/POM/4.0.0"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd";>
    <modelVersion>4.0.0</modelVersion>
    <groupId>com.psl.atom</groupId>
    <artifactId>parent</artifactId>
    <version>3.4.0-SNAPSHOT</version>
    <packaging>pom</packaging>
    <properties>
        <tycho.version>0.24.0</tycho.version>
        <xtext.version>2.9.2</xtext.version>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <mars.repo.url>http://download.eclipse.org/releases/mars</mars.repo.url>
        <xtext.repo.url>http://download.eclipse.org/modeling/tmf/xtext/updates/releases/${xtext.version}</xtext.repo.url>
        <project.groupId>com.psl.atom</project.groupId>
    </properties>
    <repositories>
        <repository>
            <id>eclipse</id>
            <layout>p2</layout>
            <url>${mars.repo.url}</url>
        </repository>
        <repository>
            <id>Xtext Update Site</id>
            <layout>p2</layout>
            <url>${xtext.repo.url}/</url>
        </repository>
        <repository>
            <id>Oracle 12.2.1.2</id>
            <layout>p2</layout>
            <url>http://download.oracle.com/otn_software/oepe/12.2.1.2/mars/repository/</url>
        </repository>
        <repository>
            <id>Oracle 12.2.1.2 dependencies</id>
            <layout>p2</layout>
            <url>http://download.oracle.com/otn_software/oepe/12.2.1.2/mars/repository/dependencies</url>
        </repository>
    </repositories>
    <modules>
        <module>com.psl.atom</module>
        <module>com.psl.atom.help</module>
        <module>com.psl.atom.ide</module>
        <module>com.psl.atom.services</module>
        <module>com.psl.atom.product</module>
        <module>com.psl.atom.ui</module>
    </modules>
    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>3.5.1</version>
                    <configuration>
                        <source>1.8</source>
                        <target>1.8</target>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.eclipse.xtend</groupId>
                    <artifactId>xtend-maven-plugin</artifactId>
                    <version>${xtext.version}</version>
                    <executions>
                        <execution>
                            <goals>
                                <goal>compile</goal>
                                <goal>xtend-install-debug-info</goal>
                            </goals>
                        </execution>
                    </executions>
                    <configuration>
                        <outputDirectory>xtend-gen</outputDirectory>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-clean-plugin</artifactId>
                    <version>2.5</version>
                    <executions>
                        <execution>
                            <id>gen-clean</id>
                            <goals>
                                <goal>clean</goal>
                            </goals>
                            <configuration>
                                <filesets>
                                    <fileset>
                                        <directory>${basedir}/xtend-gen</directory>
                                    </fileset>
                                </filesets>
                            </configuration>
                        </execution>
                    </executions>
                </plugin>
            </plugins>
        </pluginManagement>
        <plugins>
            <plugin>
                <groupId>org.eclipse.tycho</groupId>
                <artifactId>tycho-maven-plugin</artifactId>
                <version>${tycho.version}</version>
                <extensions>true</extensions>
                <configuration>
                    <target>
                        <artifact>
                            <groupId>com.psl.atom</groupId>
                            <artifactId>com.psl.atom.target</artifactId>
                            <version>1.0.0-SNAPSHOT</version>
                        </artifact>
                    </target>
                    <environments>
                        <environment>
                            <os>win32</os>
                            <ws>win32</ws>
                            <arch>x86</arch>
                        </environment>
                        <environment>
                            <os>win32</os>
                            <ws>win32</ws>
                            <arch>x86_64</arch>
                        </environment>
                    </environments>
                </configuration>
            </plugin>
        </plugins>
    </build>
</project>
<project>
  <modelVersion>4.0.0</modelVersion>
  <parent>
    <groupId>com.psl.atom</groupId>
    <artifactId>parent</artifactId>
    <version>3.4.0-SNAPSHOT</version>
    <relativePath>../pom.xml</relativePath>
  </parent>

  <artifactId>com.psl.atom.product</artifactId>
  <packaging>eclipse-repository</packaging>
  <version>3.4.0-SNAPSHOT</version>

  <build>
    <plugins>
      <plugin>
        <groupId>org.eclipse.tycho</groupId>
        <artifactId>tycho-p2-repository-plugin</artifactId>
        <version>${tycho.version}</version>
        <configuration>
          <includeAllDependencies>true</includeAllDependencies>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.eclipse.tycho</groupId>
        <artifactId>tycho-p2-director-plugin</artifactId>
        <version>${tycho.version}</version>
        <executions>
          <execution>
            <id>materialize-products</id>
            <goals>
              <goal>materialize-products</goal>
            </goals>
          </execution>
          <execution>
            <id>archive-products</id>
            <goals>
              <goal>archive-products</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>
</project> 

Back to the top