Loading native things not twice


(Markus Oley) #1

Hi anyone,

we wrote a plugin to handle sever lifecycles (e.g. database and so on). For the windows part we use winp library of jenkins to determine the list of processes in windows. This lib contains native parts so we get the following error when using it:

Caused by: java.lang.UnsatisfiedLinkError: Native Library C:…gradle\caches\modules-2\files-2.1\org.jvnet.winp\winp\1.23\7ea543f14a8108a0e20491202d7e25a2f72859c5\winp.59602D8CF2F93C3D220D46F4C7564C94.dll already loaded in another classloader

So far it is pretty clear. My question: Is there a mechanism in gradle, that can handle such things, especially when we want to use the gradle daemon?

Looking forward to your replies.
Cheers
Markus


Native lib loading fails sometimes w/ gradle daemon