nodejs / uvwasi

WASI syscall API built atop libuv
MIT License
226 stars 50 forks source link

How to avoid pulling in libuv? #165

Closed saghul closed 2 years ago

saghul commented 3 years ago

👋

I'm trying to use uvwasi in txiki.js through wasm3. I'm already using libuv, in my project and thus embedding it again with uvwasi is being problematic.

What would be the way to accomplish this? Perhaps have a CMake option to skip pulling libuv, so the one already provided is used?

Thanks!

cjihrig commented 3 years ago

I think that sounds like a good idea. Node recently did something similar in their gyp file.

cjihrig commented 2 years ago

@saghul compared to what is currently done, would something like this work for you?

FetchContent_Declare(
        libuv
        URL /path/to/your/libuv)

EDIT: Alternatively, would https://github.com/nodejs/uvwasi/pull/164 (which I completely forgot about) work for you?

saghul commented 2 years ago

I think #164 would work best.