Closed 7sharp9 closed 4 years ago
Hey there, Are you trying to run the examples on MacOS? If so, we sadly cannot support MacOS right now (since we have no Mac around here)...
Yep MacOS, I guess by the error the .so files are unknown.
Hey, yep our native dependencies are not included for MacOS and some other things might no be working too sadly... We've always wanted to make everything work on MacOS but we sadly still don't have one to fix things. Sadly VMs don't help either, since their GPU support is super-bad...
Good news everyone, Rendering/Media things should be working on MacOS now.
A word of warning: When running the Rendering examples themselves you will have to copy
lib/Native/Aardvark.Rendering.GL/mac/AMD64/glvm.dylib
and lib/Native/Aardvark.Application.Slim.GL/mac/AMD64/glfw.dylib
to your startup folder manually
Having a similar error on linux for the hello world .net core example. Seems like this might be a low hanging fruit with a very simple resolution. I have installed and tested vulkan on linux. I may be not understanding what this is doing but it appears like it's trying to write a vulkan dependency to my machine by file instead of using vulkan? I'm on Fedora specifically however I have been able to play many 3d games without issue. I'm happy to put the time in to test and make sure that it works.
https://linuxconfig.org/install-and-test-vulkan-on-linux
/home/alanball/Documents/Projects/aardvark.rendering/src/Aardvark.Rendering.Vulkan/Aardvark.Rendering.Vulkan.fsproj(20,5): warning MSB3030: Could not copy the file "/home/alanball/Documents/Projects/aardvark.rendering/src/Aardvark.Rendering.Vulkan/../../lib/Native/Aardvark.Rendering.Vulkan/linux/AMD64/vkvm.so" because it was not found.
/home/alanball/Documents/Projects/aardvark.rendering/src/Aardvark.Rendering.Vulkan/Aardvark.Rendering.Vulkan.fsproj(21,5): warning MSB3030: Could not copy the file "/home/alanball/Documents/Projects/aardvark.rendering/src/Aardvark.Rendering.Vulkan/../../lib/Native/Aardvark.Rendering.Vulkan/linux/AMD64/vkvm.so" because it was not found.
/home/alanball/Documents/Projects/aardvark.rendering/src/Aardvark.Rendering.Vulkan/Aardvark.Rendering.Vulkan.fsproj(22,5): warning MSB3030: Could not copy the file "/home/alanball/Documents/Projects/aardvark.rendering/src/Aardvark.Rendering.Vulkan/../../lib/Native/Aardvark.Rendering.Vulkan/linux/AMD64/vkvm.so" because it was not found.
0: initializing aardvark ....................................................
0: System Information:
0: System: Linux 5.5.15-200.fc31.x86_64 #1 SMP Thu Apr 2 19:16:17 UTC 2020
0: Processor: 12 core x64
0: Process: x64
0: Framework: .NET Core 3.1.3
0: Loading plugins ................................................ 0.098 s
0: WARNING: could not create symlink to libIL.so (does not exist)
0: WARNING: could not create symlink to libILU.so (does not exist)
0: WARNING: could not create symlink to libILUT.so (does not exist)
0: initializing PixImageDevil .............................................
0: WARNING: failed: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.
---> System.TypeInitializationException: The type initializer for 'Aardvark.Base.PixImageDevil' threw an exception.
---> System.DllNotFoundException: Unable to load shared library 'DevIL' or one of its dependencies. In order to help diagnose loading problems, consider setting the LD_DEBUG environment variable: libDevIL: cannot open shared object file: No such file or directory
at DevILSharp.IL.internalInit()
at DevILSharp.IL.Init()
at Aardvark.Base.PixImageDevil.InitDevil()
at Aardvark.Base.PixImageDevil..cctor()
--- End of inner exception stack trace ---
at Aardvark.Base.PixImageDevil.InitDevil()
--- End of inner exception stack trace ---
at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor, Boolean wrapExceptions)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at Aardvark.Base.Aardvark.LoadAll(IEnumerable`1 xs)
0: initializing PixImageDevil ..................................... 0.017 s
0: initializing CustomPicklerProvider ............................. 0.148 s
0: initializing SceneGraphCompletenessCheck ....................... 0.084 s
0: initializing aardvark ............................................ 0.956 s
Unhandled exception. Aardvark.Base.ImageLoadException: could not load image
---> System.TypeInitializationException: The type initializer for 'Aardvark.Base.PixImageDevil' threw an exception.
---> System.DllNotFoundException: Unable to load shared library 'DevIL' or one of its dependencies. In order to help diagnose loading problems, consider setting the LD_DEBUG environment variable: libDevIL: cannot open shared object file: No such file or directory
at DevILSharp.IL.internalInit()
at DevILSharp.IL.Init()
at Aardvark.Base.PixImageDevil.InitDevil()
at Aardvark.Base.PixImageDevil..cctor()
--- End of inner exception stack trace ---
at Aardvark.Base.PixImageDevil.CreateRawDevil(Stream stream, PixLoadOptions loadFlags)
at Aardvark.Base.PixImage.CreateRaw(Stream stream, PixLoadOptions options)
--- End of inner exception stack trace ---
at Aardvark.Base.PixImage.CreateRaw(Stream stream, PixLoadOptions options)
at Aardvark.Base.PixImage.Create(Stream stream, PixLoadOptions options)
at Glfw.Application..ctor(IRuntime runtime) in /home/alanball/Documents/Projects/aardvark.rendering/src/Application/Aardvark.Application.Slim.GL/GLFW.fs:line 476
at Aardvark.Application.Slim.OpenGlApplication..ctor(Boolean forceNvidia, Boolean enableDebug) in /home/alanball/Documents/Projects/aardvark.rendering/src/Application/Aardvark.Application.Slim.GL/Application.fs:line 18
at Aardvark.Application.Slim.OpenGlApplication..ctor() in /home/alanball/Documents/Projects/aardvark.rendering/src/Application/Aardvark.Application.Slim.GL/Application.fs:line 114
at Program.main(String[] argv) in /home/alanball/Documents/Projects/aardvark.rendering/src/Examples (netcore)/00 - HelloWorld/Program.fs:line 27
Hey @voronoipotato you need to install libdevil manually on linux atm.
dnf install DevIL-devel
and dnf install DevIL-ILUT-devel
Resolved those, I'm still getting the vkvm.so error however. What is this dependency used for?
/home/alanball/Documents/Projects/aardvark.rendering/src/Aardvark.Rendering.Vulkan/Aardvark.Rendering.Vulkan.fsproj(22,5): warning MSB3030: Could not copy the file "/home/alanball/Documents/Projects/aardvark.rendering/src/Aardvark.Rendering.Vulkan/../../lib/Native/Aardvark.Rendering.Vulkan/linux/AMD64/vkvm.so" because it was not found.
I found vkvm in source, but when I tried to make it told me I was missing /vulcan/vulkan.h , so I used dnf install vulkan-headers
however now I get the error /usr/bin/ld: cannot find -lvulkan
Thanks that helped a lot now I'm only getting runtime errors :) .
0: initializing aardvark ....................................................
0: System Information:
0: System: Linux 5.5.15-200.fc31.x86_64 #1 SMP Thu Apr 2 19:16:17 UTC 2020
0: Processor: 12 core x64
0: Process: x64
0: Framework: .NET Core 3.1.3
0: Loading plugins ................................................ 0.085 s
0: initializing PixImageDevil ..................................... 0.018 s
0: initializing CustomPicklerProvider ............................. 0.080 s
0: initializing SceneGraphCompletenessCheck ....................... 0.077 s
0: initializing aardvark ............................................ 0.487 s
0: OpenGL 4.5 working
0: initializing OpenGL runtimeUnhandled exception. System.TypeInitializationException: The type initializer for '<StartupCode$Aardvark-Rendering-GL>.$OpenGL' threw an exception.
---> System.ObjectDisposedException: Cannot access a disposed object.
Object name: 'Library'.
at Aardvark.Base.DynamicLinkerTypes.Library.GetFunction(String name)
at Aardvark.Rendering.GL.OpenGl.getGLVMProcAddress@441.Invoke(String name) in /home/alanball/Documents/Projects/aardvark.rendering/src/Aardvark.Rendering.GL/Instructions/OpenGL.fs:line 442
at <StartupCode$Aardvark-Rendering-GL>.$OpenGL..cctor() in /home/alanball/Documents/Projects/aardvark.rendering/src/Aardvark.Rendering.GL/Instructions/OpenGL.fs:line 719
--- End of inner exception stack trace ---
at Aardvark.Rendering.GL.OpenGl.Unsafe.get_ActiveTexture()
at <StartupCode$Aardvark-Application-Slim-GL>.$Application.-ctor@86-7.Invoke(IDisposable _arg2) in /home/alanball/Documents/Projects/aardvark.rendering/src/Application/Aardvark.Application.Slim.GL/Application.fs:line 94
at Microsoft.FSharp.Core.Operators.Using[T,TResult](T resource, FSharpFunc`2 action)
at <StartupCode$Aardvark-Application-Slim-GL>.$Application.-ctor@75-6.Invoke(Context ctx) in /home/alanball/Documents/Projects/aardvark.rendering/src/Application/Aardvark.Application.Slim.GL/Application.fs:line 86
at Aardvark.Application.Slim.OpenGlApplication..ctor(Boolean forceNvidia, Boolean enableDebug) in /home/alanball/Documents/Projects/aardvark.rendering/src/Application/Aardvark.Application.Slim.GL/Application.fs:line 107
at Aardvark.Application.Slim.OpenGlApplication..ctor() in /home/alanball/Documents/Projects/aardvark.rendering/src/Application/Aardvark.Application.Slim.GL/Application.fs:line 114
at Program.main(String[] argv) in /home/alanball/Documents/Projects/aardvark.rendering/src/Examples (netcore)/00 - HelloWorld/Program.fs:line 27
I get the same error on the triangles example.
0: initializing aardvark ....................................................
0: System Information:
0: System: Linux 5.5.15-200.fc31.x86_64 #1 SMP Thu Apr 2 19:16:17 UTC 2020
0: Processor: 12 core x64
0: Process: x64
0: Framework: .NET Core 3.1.3
0: Loading plugins ................................................ 0.051 s
0: initializing CustomPicklerProvider ............................. 0.253 s
0: initializing PixImageDevil ..................................... 0.016 s
0: initializing SceneGraphCompletenessCheck ....................... 0.090 s
0: initializing aardvark ............................................ 0.700 s
0: OpenGL 4.5 working
0: initializing OpenGL runtimeUnhandled exception. System.TypeInitializationException: The type initializer for '<StartupCode$Aardvark-Rendering-GL>.$OpenGL' threw an exception.
---> System.ObjectDisposedException: Cannot access a disposed object.
Object name: 'Library'.
at Aardvark.Base.DynamicLinkerTypes.Library.GetFunction(String name)
at Aardvark.Rendering.GL.OpenGl.getGLVMProcAddress@441.Invoke(String name) in /home/alanball/Documents/Projects/aardvark.rendering/src/Aardvark.Rendering.GL/Instructions/OpenGL.fs:line 442
at <StartupCode$Aardvark-Rendering-GL>.$OpenGL..cctor() in /home/alanball/Documents/Projects/aardvark.rendering/src/Aardvark.Rendering.GL/Instructions/OpenGL.fs:line 719
--- End of inner exception stack trace ---
at Aardvark.Rendering.GL.OpenGl.Unsafe.get_ActiveTexture()
at <StartupCode$Aardvark-Application-Slim-GL>.$Application.-ctor@86-7.Invoke(IDisposable _arg2) in /home/alanball/Documents/Projects/aardvark.rendering/src/Application/Aardvark.Application.Slim.GL/Application.fs:line 94
at Microsoft.FSharp.Core.Operators.Using[T,TResult](T resource, FSharpFunc`2 action)
at <StartupCode$Aardvark-Application-Slim-GL>.$Application.-ctor@75-6.Invoke(Context ctx) in /home/alanball/Documents/Projects/aardvark.rendering/src/Application/Aardvark.Application.Slim.GL/Application.fs:line 86
at Aardvark.Application.Slim.OpenGlApplication..ctor(Boolean forceNvidia, Boolean enableDebug) in /home/alanball/Documents/Projects/aardvark.rendering/src/Application/Aardvark.Application.Slim.GL/Application.fs:line 107
at Aardvark.Application.Utilities.createApplication(RenderConfig cfg) in /home/alanball/Documents/Projects/aardvark.rendering/src/Application/Aardvark.Application.Utilities/Window.fs:line 426
at Aardvark.Application.Utilities.createMonoScreen(RenderConfig cfg) in /home/alanball/Documents/Projects/aardvark.rendering/src/Application/Aardvark.Application.Utilities/Window.fs:line 440
at Aardvark.Application.Utilities.createWindow(RenderConfig cfg) in /home/alanball/Documents/Projects/aardvark.rendering/src/Application/Aardvark.Application.Utilities/Window.fs:line 751
at Aardvark.Application.Utilities.runConfig(RenderConfig cfg) in /home/alanball/Documents/Projects/aardvark.rendering/src/Application/Aardvark.Application.Utilities/Window.fs:line 756
at Aardvark.Application.Render Utilities.ShowBuilder.Run(RenderConfig cfg) in /home/alanball/Documents/Projects/aardvark.rendering/src/Application/Aardvark.Application.Utilities/Window.fs:line 899
at Program.main(String[] argv) in /home/alanball/Documents/Projects/aardvark.rendering/src/Examples (netcore)/01 - Triangle/Program.fs:line 38
strange - similar problem. sometimes there is a problem loading opengl entry points now although we have a print opengl 4.5 is working. i will check tomorrow. can you also post the print of glxinfo (on ubuntu this one is in mesa-utils i think)? https://dri.freedesktop.org/wiki/glxinfo/
thanks. will check asap.. bests
Alan Ball notifications@github.com schrieb am Do., 23. Apr. 2020, 22:00:
https://gist.github.com/voronoipotato/846cb18627a83da55a4c97c949930158
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/aardvark-platform/aardvark.rendering/issues/59#issuecomment-618632387, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAD5KAI6GPXCRYQE3LOA3E3ROCM5JANCNFSM4JSWK4PQ .
i fixed the copy Task, however "unfortunately" i cannot reproduce your error @voronoipotato. However for me it seems that glvm.so
is not in your output directory (my build has). how did you compile the whole thing - manually using dotnet build or did you use ./build.sh
? if not could you please give using ./build.sh
a try?
dotnet build, I'll give the build.sh a try, is glvm.so aardvark specific?
same as vkvm. this is a c/cpp high performance component which is used by the netcore code
Alan Ball notifications@github.com schrieb am Fr., 24. Apr. 2020, 16:00:
dotnet build, I'll give the build.sh a try, is glvm.so aardvark specific?
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/aardvark-platform/aardvark.rendering/issues/59#issuecomment-619027993, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAD5KANYJUJQQLWLWXS2OWTROGLPDANCNFSM4JSWK4PQ .
It still doesn't work with ./build.sh . I was really excited about this and I'm pretty sad that I can't get hello world working even while compiling Aardvark.rendering myself. Probably not going to be able to move forward with this given the amount of set up that needs to be done to even get hello world up and running. Thanks for helping. I'll probably check back again at a later date.
I'm deeply sorry this happened to you. In fact the nuget packages should be sufficient and all the pain you had was far from normal. To give you some background. Aardvark rendering has native libraries stuff written in C/C++ for performance. Like many other libraries we bundled this into the managed dlls. At runtime, when it is clear what platform you are running we make sure to load the libraries appropriately. Previosuly we copied all native dlls beside the application. With netcore this although heavily depends on LD_LOAD_LIBRARY_PATH and from where and how the application was started.
With netcoreapp3.0 all changed and we were provided with NativeLibrary API. We used this one to make native dependency loading finally modern and awesome. This happened around here in Aardvark.Base quite recently: https://github.com/aardvark-platform/aardvark.base/blob/master/src/Aardvark.Base/Introspection/Introspection.cs#L1252 Slightly associated, those cleanups made mac os support possible.
Here is the exception: https://github.com/aardvark-platform/aardvark.base/blob/master/src/Aardvark.Base.FSharp/Runtime/DynamicLinker.fs#L51 Clearly this is just an implication of failed loading mechanism, which granted could be detected earlier.
So you are hitting recent changes which are not reproducible on our linux machines we have access to.
It could help though if you sent me the Aardvark.log file which is created beside your application or beside your working directory you ran dotnet from. Could you pastebin this one?
bests
thank you very much. just one thing. is glvm.so in your aardvark.rendering/bin/Release/netcoreapp3.1
folder? ./build.sh should have copied it to aardvark.rendering/bin/Release/netcoreapp3.1
at least - so there is actually no chance it cannot be found during runtime - at least when run from the output directory running using dotnet "00 - HelloWorld.dll"
. can you confirm it is there?
yeah glvm.so is there
@7sharp9 old issue, I know, but I couldn't tell from the comments if you ever got this running on macOS.
I managed to get HelloWorld
running on my mac by installing DevIL first:
brew install devil
I'll make a PR to the README/wiki.
Nope never got anything working, gave up.
actually, later we got access to a testing mac and reworked native dependeny loading with netcore 3 which made it more reliable on platforms. when loading textures from file devil is currently needed as commented above. in fact, currently we have some apps running on mac.
Dave Thomas notifications@github.com schrieb am Mo., 28. Sep. 2020, 20:45:
Nope never got anything working, gave up.
— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub https://github.com/aardvark-platform/aardvark.rendering/issues/59#issuecomment-700214072, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAD5KANU55ZVMSRAQFTI4RTSIDKUDANCNFSM4JSWK4PQ .
Im assuming there's something to install, could not find anything mention in the quick start docs...