[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [tycho-user] Will pomDependencies=consider work inside the eclipse IDE?
|
Hi Steinar
I'm using this in my eclipse-target-definition pom:
<build>
<plugins>
<plugin>
<groupId>lt.velykis.maven</groupId>
<artifactId>pde-target-maven-plugin</artifactId>
<version>1.0.0</version>
<executions>
<execution>
<id>pde-target</id>
<goals>
<goal>add-pom-dependencies</goal>
</goals>
<configuration>
<baseDefinition>${project.basedir}/ch.arenae.funtrade.client.target.rcp.target</baseDefinition>
<outputFile>${project.build.directory}/my-target-pde.target</outputFile>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
If you do "mvn clean verify" for this pom it generates a copy of your target file that includes all the maven-style dependencies like this:
...
<location path="/Users/kup/.m2/repository/org/codehaus/groovy/groovy-all/1.8.6" type="Directory"/>
<location path="/Users/kup/.m2/repository/org/slf4j/slf4j-api/1.7.5" type="Directory"/>
<location path="/Users/kup/.m2/repository/org/objenesis/com.springsource.org.objenesis/1.2.0" type="Directory"/>
...
In the ide you can activate this generated target file and everything should compile.
Regards,
Peter
Am 12.06.2014 um 09:30 schrieb Steinar Bang <sb@xxxxxx>:
> If I have a tycho project with a parent POM
> https://github.com/steinarb/modeler/blob/master/pom.xml
>
> and a target maven module/eclipse project, that has an eclipse .target
> file defining the target platform
> https://github.com/steinarb/modeler/tree/master/modeler.target
>
> and then in eclipse opens the .target file
> https://github.com/steinarb/modeler/blob/master/modeler.target/modeler.target.target
>
> in the target file editor, and click on "Set as Target Platform", then
> this will work both inside the eclipse IDE and when building with "mvn"
> from the command line.
>
>
> However, if I:
> 1. Add a dependency to the parent POM
> https://github.com/steinarb/modeler/blob/using-neoj-osgi-bundle/pom.xml
> like this:
> <dependencies>
> <dependency>
> <groupId>com.smb-tec.neo4j</groupId>
> <artifactId>neo4j-osgi-bundle</artifactId>
> <version>2.2-SNAPSHOT</version>
> </dependency>
> </dependencies>
>
> 2. Have the setting pomDependencies=consider in the same parent POM:
> <build>
> <plugins>
> <plugin>
> <groupId>org.eclipse.tycho</groupId>
> <artifactId>target-platform-configuration</artifactId>
> <version>${tycho.version}</version>
> <configuration>
> <resolver>p2</resolver>
> <pomDependencies>consider</pomDependencies>
> <ignoreTychoRepositories>true</ignoreTychoRepositories>
> <target>
> <artifact>
> <groupId>no.priv.bang</groupId>
> <artifactId>modeler.target</artifactId>
> <version>${project.version}</version>
> </artifact>
> </target>
> </configuration>
> </plugin>
> </plugins>
> </build>
>
> then I can see how this would work when doing "mvn install", but I see
> no mechanism that can add the dependency to the target platform inside
> the eclipse IDE.
>
>
> Is this a correct observation? If so, how can I add the bundle to the
> target platform used by the eclipse IDE?
>
> Thanks!
>
>
> - Steinar
>
> (on a side note I have to find out what the
> <ignoreTychoRepositories>true</ignoreTychoRepositories> setting
> means... it was put there by the archetype...)
>
> _______________________________________________
> tycho-user mailing list
> tycho-user@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/tycho-user
>