I have a Plugin that provides JARs for differentPlattforms (f.e. win32, win64, linux, macos).
How to ensure that the right JAR is loaded?
My first attempt was to write a Classloader that dynamical loads the correct JAR on runtime. This would work fine in theroy - except it don't. I figured that the PluginClassLoader would load all JARs at start, and than I try to load the "right" JAR in my Pluging code - apparently to late.
Since there is no way to have any code execuded ( right?) before the PluginClassLoader loads all dependend JARs - what is the way to go? How to tell the Pluging which JAR should be used?
Thanks for your help and input