Skip to content

v0.33.0-libuv

Pre-release
Pre-release
Compare
Choose a tag to compare
@haf haf released this 23 Oct 12:59
· 1521 commits to master since this release

v0.33 libuv

This is a pre-release to let you play around with libuv and Suave in a cross-platform manner. We have currently no known bugs in the code; hopefully some will be found and fixed during this testing period. It should work on Linux, OS X and Windows.

We'd also like to get help with documentation; perhaps something we can cross-post in our docs and you on your blog/medium of choice – contact us through the issue tracker or on twitter: @suaveio.

First you need to pull down the nuget with this paket config and paket install in your solution:

source https://nuget.org/api/v2
nuget Suave
nuget Suave.LibUv

And now you can use it:

open Suave
open Suave.Web
open Suave.LibUv.Tcp

let cfg = { defaultConfig with tcpServerFactory = LibUvServerFactory() }
startWebServer cfg Api.app

Installing libuv

On OS X:

brew install libuv --universal
export LD_LIBRARY_PATH=/usr/local/lib:/usr/lib:/lib

On Windows:

@powershell -NoProfile -ExecutionPolicy Bypass -Command "Start-FileDownload 'https://github.com/libuv/libuv/archive/v1.7.5.zip'"
7z x v1.7.5.zip & cd libuv-1.7.5 & vcbuild.bat x86 shared debug
mkdir src\\Suave.Tests\\bin\\Release\\ & cp libuv-1.7.5\\Debug\\libuv.dll src\\Suave.Tests\\bin\\Release\\libuv.dll

On Linux you can follow these instructions.

Creds to @ademar for writing the libuv layer!

LibUV Logo

/Henrik and Ademar