Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [tycho-user] LinkageError when running Tycho Surefire tests

If I understood you right, you don’t want the SWT fragment org.eclipse.swt.gtk.linux.x86_64 at all in your target platform

Check https://wiki.eclipse.org/Tycho/Target_Platform on how to control the content of your target platform

Regards
Jan

On 15/03/2017, 03:57, "tycho-user-bounces@xxxxxxxxxxx on behalf of Setya Djajadinata" <tycho-user-bounces@xxxxxxxxxxx on behalf of jsetya@xxxxxxxxx> wrote:

Hi all,


We're running Eclipse RAP based application tests using Tycho which throws the following errors:


java.lang.LinkageError: loader constraint violation: loader (instance of org/eclipse/osgi/internal/loader/EquinoxClassLoader) previously initiated loading for a different type with name
 "org/eclipse/swt/widgets/Control"


Using -verbose:class reveals that org.eclipse.swt.widgets.Control class was loaded by 2 different classloaders, i.e:


[Loaded org.eclipse.swt.widgets.Control from file:/home/setya/.m2/repository/p2/osgi/bundle/org.eclipse.rap.rwt/3.0.2.20160201-1220/org.eclipse.rap.rwt-3.0.2.20160201-1220.jar]


and


[Loaded org.eclipse.swt.widgets.Control from file:/home/setya/.m2/repository/p2/osgi/bundle/org.eclipse.swt.gtk.linux.x86_64/3.104.2.v20160212-1350/org.eclipse.swt.gtk.linux.x86_64-3.10
4.2.v20160212-1350.jar]


Obviously we only want it loaded by RWT classloader, not SWT one.


The tests run fine when executed by RAP Tooling.


How to instruct Tycho to resolve this ?


Any help would be greatly appreciated.


Thanks & Regards,
Setya




Back to the top