1

when starting a java program I get the following error message:

Cannot open JVM dynamic library
Dynamic library location: /Library/Java/JavaVirtualMachines/amazon-corretto-17.jdk/Contents/Home/lib/libjli.dylib

But the file exists:

-rw-r--r--  1 root  wheel  97616 17 Jan 06:40 /Library/Java/JavaVirtualMachines/amazon-corretto-17.jdk/Contents/Home/lib/libjli.dylib

The issue occured when I updated the java program itself. Older version of this java program still work. The developer of this java program wasn´t able to help me with this issue. I got the same issue before with another jdk, i.e. adoptopenjdk-11.jdk. So it seems not to be the jdk itself, but the update of the java program. Wrong format of the dylib ?

Any suggestions what is going wrong and how I can check and cure this ?

I am running on macOS 12.3.1 (Monterey)

tab
  • 11
  • 1
  • Could be file permissions? Was the file readable be all before or some other permission flag has changed? Put java on a new dir or uninstall and reinstall or run as sudo ... (not good to run as sudo always but till u figure it out) – tgkprog Apr 27 '22 at 22:41

1 Answers1

1

here is what I found online regarding the format of your file,

"Most DYLIB files are probably dynamic library files, but if you suspect that yours isn't and that it's instead used by a different program for a different purpose, try opening the file in a free text editor. If your specific DYLIB file isn't a dynamic library file, then being able to see the contents of the file as a text document may shed some light on the type of format the file is in, which may help you determine what program should be used to open that particular DYLIB file." -Link here

typically, dylib files should not have problems opening up. Maybe it is the way you are opening it, or the file type is different than what we think? Try and provide more information.

Felos9001
  • 11
  • 2