Paravim icon indicating copy to clipboard operation
Paravim copied to clipboard

Running on mac gives `Failed to locate library: libobjc.dylib` error

Open zcaudate opened this issue 5 years ago • 9 comments

I'm getting this error while running on OSX

$ clojure -Sdeps "{:deps {paravim {:mvn/version ""RELEASE""}}}" -J-XstartOnFirstThread -m paravim.start

[LWJGL] Failed to load a library. Possible solutions: a) Install the library or the driver that provides the library. b) Ensure that the library is accessible from the system library paths. [LWJGL] Enable debug mode with -Dorg.lwjgl.util.Debug=true for better diagnostics. [LWJGL] Enable the SharedLibraryLoader debug mode with -Dorg.lwjgl.util.DebugLoader=true for better diagnostics. Exception in thread "main" java.lang.UnsatisfiedLinkError: Failed to locate library: libobjc.dylib

zcaudate avatar Sep 10 '19 16:09 zcaudate

Interesting. What version of OSX are you on?

oakes avatar Sep 10 '19 16:09 oakes

I'm running Mojave 10.14.5

zcaudate avatar Sep 10 '19 16:09 zcaudate

I just pushed a snapshot, can you let me know if this fixes it for you?

clojure -Sdeps "{:deps {paravim {:mvn/version \""0.3.0-SNAPSHOT\""}}}" -J-XstartOnFirstThread -m paravim.start

oakes avatar Sep 10 '19 17:09 oakes

I'm still getting the same problem:

$  clojure -Sdeps "{:deps {paravim {:mvn/version \""0.3.0-SNAPSHOT\""}}}" -J-XstartOnFirstThread -m paravim.start


Downloading: paravim/paravim/0.3.0-SNAPSHOT/maven-metadata.xml from https://repo.clojars.org/
Downloading: paravim/paravim/0.3.0-SNAPSHOT/paravim-0.3.0-20190910.170230-1.pom from https://repo.clojars.org/
Downloading: libvim-clj/libvim-clj/0.5.0/libvim-clj-0.5.0.pom from https://repo.clojars.org/
Downloading: libvim-clj/libvim-clj/0.5.0/libvim-clj-0.5.0.jar from https://repo.clojars.org/
Downloading: paravim/paravim/0.3.0-SNAPSHOT/paravim-0.3.0-20190910.170230-1.jar from https://repo.clojars.org/
[LWJGL] Failed to load a library. Possible solutions:
	a) Install the library or the driver that provides the library.
	b) Ensure that the library is accessible from the system library paths.
[LWJGL] Enable debug mode with -Dorg.lwjgl.util.Debug=true for better diagnostics.
[LWJGL] Enable the SharedLibraryLoader debug mode with -Dorg.lwjgl.util.DebugLoader=true for better diagnostics.
Exception in thread "main" java.lang.UnsatisfiedLinkError: Failed to locate library: libobjc.dylib
	at org.lwjgl.system.Library.loadNative(Library.java:324)
	at org.lwjgl.system.Library.loadNative(Library.java:222)
	at org.lwjgl.system.Library.loadNative(Library.java:203)
	at org.lwjgl.system.macosx.ObjCRuntime.<clinit>(ObjCRuntime.java:103)
	at org.lwjgl.glfw.EventLoop.isMainThread(EventLoop.java:85)
	at org.lwjgl.glfw.EventLoop.access$000(EventLoop.java:26)
	at org.lwjgl.glfw.EventLoop$OffScreen.<clinit>(EventLoop.java:30)
	at org.lwjgl.glfw.GLFW.glfwCreateWindow(GLFW.java:1892)
	at paravim.start$__GT_window.invokeStatic(start.clj:171)

zcaudate avatar Sep 10 '19 17:09 zcaudate

Alright maybe i rebuilt the binary wrong. I did it again but starting from a clean repo. I pushed a new snapshot with the same name, can you try it again? You'll need to kill the old one unfortunately...

cd ~
rm -r .m2/repository/paravim/paravim/0.3.0-SNAPSHOT/
rm -r .clojure/.cpcache/

oakes avatar Sep 10 '19 17:09 oakes

If that still doesn't work, i'll probably need to update my mac to mojave and try it myself.

oakes avatar Sep 10 '19 17:09 oakes

I decided to update to mojave anyway and I can't reproduce this error, either with the snapshot or the current release =\

oakes avatar Sep 10 '19 19:09 oakes

yeah. it's really weird. libobjc.dylib for me is in /usr/lib/. I also tried different java versions as well but it's still giving the same message.

zcaudate avatar Sep 11 '19 01:09 zcaudate

the same thing happens if I clone the repo and run clj -A:dev:macos native:

Downloading: org/clojure/clojure/1.10.1/clojure-1.10.1.jar from https://repo1.maven.org/maven2/
[LWJGL] Failed to load a library. Possible solutions:
	a) Install the library or the driver that provides the library.
	b) Ensure that the library is accessible from the system library paths.
[LWJGL] Enable debug mode with -Dorg.lwjgl.util.Debug=true for better diagnostics.
[LWJGL] Enable the SharedLibraryLoader debug mode with -Dorg.lwjgl.util.DebugLoader=true for better diagnostics.
Syntax error (UnsatisfiedLinkError) compiling at (dev.clj:23:1).
Failed to locate library: libobjc.dylib

clojure-15479912811981949528.txt

zcaudate avatar Sep 11 '19 01:09 zcaudate