[FIXED] applet loader + natives

Started by NateS, January 12, 2011, 14:18:15

Previous topic - Next topic

NateS

I had trouble loading my own natives when using the applet loader. My native was extracted to the temp dir, but not found when my code did System.loadLibrary("name"). I see the applet loader sets java.library.path, not sure why that wasn't enough. I added this code to the URLClassLoader in the applet loader:

protected String findLibrary (String libname) {
	return path + "natives/" + System.mapLibraryName(libname);
}


This allowed my native to be loaded.

kappa