aspnet / libuv-build

Libuv build automation for ASP.NET Core
Other
22 stars 18 forks source link

Add uuid helper for all kinds of unix os #34

Closed ghost closed 6 years ago

ghost commented 6 years ago

Was trying to build on Alpine (https://github.com/aspnet/libuv-package/issues/23) using:

docker run -it microsoft/dotnet:2.1-sdk-alpine

then inside the docker

apk add git bash wget curl ncurses openssl-dev icu-dev libunwind-dev
git clone https://github.com/aspnet/libuv-build
cd $_
./build.sh

There is no uuidgen package/utility available on Alpine and some other distros.

Still some errors from Korebuild, but it's a start.

natemcmaster commented 6 years ago

Thanks for attempting to start on this. This is one step in the right direction, but there is a lot more work to be done in order to get our Libuv package to support Alpine 3.6, and at the moment, have punted this to 2.2.0 per discussion on aspnet/libuv-package#23. We're not planning on doing the rest of the work in the next few months, so I'm not sure this is something we'll take in right now.

ghost commented 6 years ago

Thanks @natemcmaster. I had to tweak couple of scripts to make it build. Although, switching from KoreBuild-Legacy to modern aspnet BuildTools would be nice. I can work on it passively.

BTW, if I install libuv from the package manager of OS/distro, shouldn't Kestrel pick up that one by design (or even as a fallback)? Most of the CoreFX native bindings work in this manner without having to build the native so inbox.

natemcmaster commented 6 years ago

modern aspnet BuildTools would be nice

Indeed. https://github.com/aspnet/libuv-build/issues/25 We also had planned to merge this repo and aspnet/libuv-package at some point. But we were waiting to do all this until we actually needed a new version of libuv. We rarely build this code so it's not something we worry about much.

Coreclr uses ldopen on Linux, so yes, it will fallback to system defaults for library locations and honor config like LD_LIBRARY_PATH. See https://github.com/dotnet/dotnet-docker/blob/nightly/2.1/aspnetcore-runtime/alpine/amd64/Dockerfile for example. This is one reason why we decided it was okay to punt rebuilding for alpine.