Discussion:
[tycho-user] Can't run Tycho against Eclipse installed from RPM
Lukas Valach
2017-05-30 08:59:25 UTC
Permalink
Hi,

I am trying to run integration tests using Tycho against eclipse installed
from RPM and I am having troubles during the installation of IUs.

I have configured tycho-surefire-plugin to use p2Installed runtime and
"work" property to directory where the eclipse is installed. Profile name
match the profile name configured in
/opt/rh/rh-eclipse46/root/lib64/eclipse/configuration/config.ini

<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>tycho-surefire-plugin</artifactId>
<configuration>
<testRuntime>p2Installed</testRuntime>
<work>/opt/rh/rh-eclipse46/root/lib64/eclipse</work>
<profileName>SDKProfile</profileName>
</configuration>
</plugin>

Problem is that eclipse directory is read only, so the tycho fails during
installation of IUs with this erros message:

"The operation you've requested can not be performed because the folder
/opt/rh/rh-eclipse46/root/lib64/eclipse is read only."

Eclipse is configured to store configuration in
/home/<USER>/.eclipse/org.eclipse.platform_283378046_linux_gtk_x86_64. It
seems that p2 director doesn't consider some configuration e.q. eclipse.ini.

I have tried to run p2 director directly (without tycho), according to p2
director documentation \[1\] it should be able to work "outsite" of target
platform. I have experimented with some director arguments e.q. -shared,
-bundlePool, -profile, etc but without success. It seems that the only way
to get it running is to run p2 director inside the target application.

/opt/rh/rh-eclipse46/root/lib64/eclipse/eclipse
-application org.eclipse.equinox.p2.director \
-metadataRepository ... \
-artifactRepository ... \
-installIU ...

P2 director loads configuration properly in this case and installs IUs into
~/.eclipse/org.eclipse.platform_283378046_linux_gtk_x86_64 but it seems
that it isn't possible to configure Tycho to start director in this way, is
it?

How to get it working? Is it Tycho or P2 diretor bug? Or are we missing
some feature in Tycho/p2 director?


Thank you very much for any response.

Lukas


\[1\]
http://help.eclipse.org/kepler/index.jsp?topic=/org.eclipse.platform.doc.isv/guide/p2_director.html
Loading...