Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Could not locate the required V8 native libraries" on macOS (.NET Core) #19

Closed
jeffijoe opened this issue Jul 3, 2019 · 3 comments

Comments

Projects
None yet
2 participants
@jeffijoe
Copy link

commented Jul 3, 2019

Hi James! Thank you for this library!

I created a dotnet new console project using the .NET Core 2 as the target, and used dotnet add package to install V8.NET. This is on macOS.

However, I'm getting the Could not locate the required V8 native libraries error, even though I've checked the paths for the DLL, and it is indeed there.

Any ideas?

@rjamesnw

This comment has been minimized.

Copy link
Owner

commented Jul 3, 2019

Hi Jeff, glad you like it. ;)

While the Net Standard wrapper code will compile anywhere, I did not compile any V8 (C++) libraries for Mac because I don’t own one (nor would I know how to at the moment). The V8 libraries that are included are only compiled for Windows PCs. Someone would have to compile V8 on the Mac. If anyone is interested in taking up that task all they have to do is download the V8 source and compile it, or find the Mac compiled libraries online somewhere, download them, then give the the same names. I did put in Support to load Linux and Mac libraries if found.

@rjamesnw rjamesnw closed this Jul 3, 2019

@jeffijoe

This comment has been minimized.

Copy link
Author

commented Jul 3, 2019

Gotcha!

So I would need to download the source for V8 .NET, download the source for V8 or find a precompiled binary, then build V8 .NET on my Mac, this would yield a V8_NET_Proxy_x64.dll with the V8-darwin library statically linked?

@rjamesnw

This comment has been minimized.

Copy link
Owner

commented Jul 3, 2019

.dll is Windows. It will yield a .so or .dylib library. You are correct about the name - it should be the same, only the extension should change. :)

https://stackoverflow.com/questions/2339679/what-are-the-differences-between-so-and-dylib-on-osx

NuGet does have some precompiled ones that may work; here is one I found when searching: https://www.nuget.org/packages/V8.Simple-macOS/
I haven’t tried them though. Make sure you match 32-bit vs 64-bit properly. ;) If you only need 64-bit you can ignore the 32-bit one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.