0
votes

I am just running sample sikuli script in Java on Eclipse & I am getting the following error

Exception in thread "main" java.lang.UnsatisfiedLinkError: C:\Program Files (x86)\Sikuli X\libs\VisionProxy.dll: Can't find dependent libraries at java.lang.ClassLoader$NativeLibrary.load(Native Method) at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1807) at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1703) at java.lang.Runtime.load0(Runtime.java:770) at java.lang.System.load(System.java:1003) at com.wapmx.nativeutils.jniloader.NativeLoader.loadLibrary(NativeLoader.java:44) at org.sikuli.script.Finder.(Finder.java:33) at org.sikuli.script.Region.doFind(Region.java:1034) at org.sikuli.script.Region$RepeatableFind.run(Region.java:1237) at org.sikuli.script.Region$Repeatable.repeat(Region.java:1208) at org.sikuli.script.Region.exists(Region.java:539) at com.testsikuli.SikuliTest.main(SikuliTest.java:25)

public class SikuliTest {

public static void main(String[] args) throws FindFailed {
    System.setProperty("webdriver.ie.driver", "F:\\Softwares\\Selenium\\driver\\IEDriverServer.exe");
    WebDriver driver;
    driver = new InternetExplorerDriver();
driver.get("https://www.google.com");
driver.manage().timeouts().implicitlyWait(3000, TimeUnit.MILLISECONDS);
    driver.manage().window().maximize();

    Pattern userName = new Pattern("img/UserName.png");
    Screen sr = new Screen();
    sr.find(userName);
    sr.type(Key.ENTER);
    sr.type(Key.DELETE);
    sr.type("test");

}

}

I'd followed lot of post & tired ..no luck..

My system environment details,

  1. 64bit Windows 7 SP1,
  2. Java 6 (32bit) & eclipse JUNO (32bit)
  3. Added JAVA_HOME = "C:\Program Files (x86)\Java\jdk1.6.0_45\" & path = %JAVA_HOME%bin;%JAVA_HOME%jre\bin;
  4. Also added SIKULI_HOME = "C:\Program Files (x86)\Sikuli X\" & path = %SIKULI_HOME%libs;
3

3 Answers

0
votes

Was the Sikuli installation moved after it was installed at any time? If using Sikuli X, all required dependencies should be included in the installation.

Make sure your IDE isn't picking up any 64-bit JRE files from somewhere, as this will cause the exact error you are seeing.

0
votes

This user seems to have had the same problem.
Maybe you can try this solution post: Link

Same error reported at the Sikuli buglist.
Java 7 does work for me though. Link

0
votes

Resolved. I had followed the same steps in the following post

Sikuli Windows 7 64 bit : Getting the VisionProxy.dll: Can not find dependent libraries

and modified/selected only "Append environment to native environment" & now its working fine. Thanks all.