Using the 64bit XulRunner in Eclipse SWT under Windows
Asked Answered
B

3

5

Is it possible to use the 64bit XulRunner for Windows (available from here) with the Eclipse browser widget? It works fine under 32bit Windows and the answer to this question explains how this works. But when I try this under 64bit Windows I get the following exception:

 org.eclipse.swt.SWTError: No more handles (java.lang.UnsatisfiedLinkError: Could not   
 load SWT library. Reasons: 
   no swt-xulrunner-win32-3834 in java.library.path
   no swt-xulrunner-win32 in java.library.path
   Can't load library: 
     C:\Users\...\.swt\lib\win32\x86_64\swt-xulrunner-win32- 3834.dll
     Can't load library: C:\Users\...\.swt\lib\win32\x86_64\swt-xulrunner-win32.dll
    at org.eclipse.swt.SWT.error(SWT.java:4387)
    at org.eclipse.swt.SWT.error(SWT.java:4276)
    at org.eclipse.swt.browser.Mozilla.initXULRunner(Mozilla.java:2594)
    at org.eclipse.swt.browser.Mozilla.create(Mozilla.java:684)
    at org.eclipse.swt.browser.Browser.<init>(Browser.java:99)
    at org.openlca.ui.BrowserFactory.createMozilla(BrowserFactory.java:52)

Thanks for help, Michael

Edit: I found it in the Eclipse bug-tracker (link here):

swt's 64-bit Windows port does not have xulrunner support because mozilla.org does not provide a 64-bit xulrunner on Windows

But as the last comment on this bug says, there is a 64bit XulRunner available

Banda answered 21/1, 2013 at 20:59 Comment(4)
Two questions: Do you use a 64bit JVM and a 64 eclipse? If not you cannot load the 64bit dll to your eclipseInweave
Sorry forgot this in the question: yes, 64bit JVM and Eclipse.Banda
Have you set a java.library.path? It is possible, that there is another dll, which is in you %path% variable.Inweave
Thanks for the comment, but I think the problem is more that there is a swt-xulrunner-win32-4234.dll lib provided for the 32bit version of SWT for Windows but this library is not in the 64bit package. So the question is more why is this library not included in the 64bit package?Banda
W
2

Yes, XULRunner support on Windows x86_64 is now in place for the upcoming Eclipse/SWT 4.3 release.

Regarding the XPCOM error 0x80004005, if you're trying to use XULRunner 3.6.x (like the poster in the other question) then support for this was released even more recently, see https://bugs.eclipse.org/bugs/show_bug.cgi?id=406912 .

Whipsaw answered 2/5, 2013 at 14:30 Comment(0)
C
2

So I came here with similar problem: trying to run DJ Project browser within Java Swing - more specifically within that the Mozilla XPCOM Download Manager sample which requires SWT and XULRunner.

Following the eclipse bug link in your OP - I found another (eclipse bugzilla) - looks like this has been a long-standing issue (only 5+ years!!) - which is actually now (as of 11/4/13 - 2 days ago!) fixed.

I have downloaded SWT package from Eclipse nightly builds and I can confirm it does now contain the swt-xulrunner-win32-xxxx.dll. Unfortunately I now have other problems stopping my test working, but thought I'd post what I'd found here.

Edit: Actually my problem now is identical to this XPCOM error 0x80004005

Carouse answered 13/4, 2013 at 14:39 Comment(0)
W
2

Yes, XULRunner support on Windows x86_64 is now in place for the upcoming Eclipse/SWT 4.3 release.

Regarding the XPCOM error 0x80004005, if you're trying to use XULRunner 3.6.x (like the poster in the other question) then support for this was released even more recently, see https://bugs.eclipse.org/bugs/show_bug.cgi?id=406912 .

Whipsaw answered 2/5, 2013 at 14:30 Comment(0)
T
1

I realize that this question is old and already has an accepted answer, but in regards to the XPCOM error 0x80004005, I may be able to help.

With 64-bit 4.3 SWT I was able to fix this exception by using XULRunner version 1.9.2.25 runtimes. Originally I found the download from here: https://osdn.net/projects/sfnet_runawfe/downloads/SRC%20and%20BIN%20files/extras/xulrunner-1.9.2.25-win64.zip/

However, I have also re-hosted it as xulrunner-1.9.2.25.en-US.win64.zip.

Full explanation posted in my answer here: https://mcmap.net/q/1919937/-exception-in-thread-quot-main-quot-org-eclipse-swt-swterror-xpcom-error-0x80004005-in-swt-mozilla

Talanta answered 7/7, 2017 at 3:33 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.