Open susliko opened 2 months ago
So to use vcpkg with SN, one thing you need to be aware of is using the correct plugin.
In the examples, I use VcpkgNativePlugin: https://github.com/indoorvivants/sn-bindgen-examples/blob/main/build.sbt#L389 - it differs from vanilla VcpkgPlugin in the fact that it automatically calls the vcpkg configurator to update the NativeConfig flags: https://github.com/indoorvivants/sn-vcpkg?tab=readme-ov-file#sbt
So far this has been the only necessary change to make sure libuv example compiles: https://github.com/indoorvivants/sn-bindgen-examples/blob/main/example-libuv/src/main/resources/scala-native/generated/libuv.c#L2
Also by default static binaries are produced, so you won't need libuv.so copied into the runtime image
Hey 🖖🏻
I'm still trying to wrap my mind around the linking process.
Let's say we're packaging the
libuv
example into Docker.If we try the following Dockerfile
it would fail with
Installing
libuv1-dev
globally via apt helps:but why
vcpkg
didn't download these header files and tuck them in wherever they should be?