digitalmars.D.learn - Is there a wrapper for libuv?
- Tyler Jameson Little (13/13) Mar 06 2012 I hope this is the right place to ask this.
- James Miller (7/19) Mar 06 2012 sys/types is part of the C runtime if I remember correctly, and
- Tyler Jameson Little (3/8) Mar 06 2012 Thanks! I guess I got a little over-zealous in porting stuff
- James Miller (9/17) Mar 06 2012 Pretty much, yeah. Remember that these declarations are only there to
I hope this is the right place to ask this. libuv is the evented IO library that nodejs uses internally. It is basically glue for a bunch of other libraries (libev, c-ares, libeio and others). https://github.com/joyent/libuv Is there already working on a wrapper? I would very much like to use it, because it's cross-platform, but I couldn't find it anywhere (deimos has libev and libevent though). I started a wrapper, but there were a couple of header files that I couldn't find: sys/types.h netinet/in.h Do these already exist?
Mar 06 2012
On 7 March 2012 13:52, Tyler Jameson Little <beatgammit gmail.com> wrote:I hope this is the right place to ask this. libuv is the evented IO library that nodejs uses internally. It is basically glue for a bunch of other libraries (libev, c-ares, libeio and others). https://github.com/joyent/libuv Is there already working on a wrapper? I would very much like to use it, because it's cross-platform, but I couldn't find it anywhere (deimos has libev and libevent though). I started a wrapper, but there were a couple of header files that I couldn't find: sys/types.h netinet/in.h Do these already exist?sys/types is part of the C runtime if I remember correctly, and netinet/in.h is part of the Unix networking interface. You shouldn't have to do anything with them, just write bindings for the api, with all the correct types. -- James Miller
Mar 06 2012
You shouldn't have to do anything with them, just write bindings for the api, with all the correct types. -- James MillerThanks! I guess I got a little over-zealous in porting stuff over. I just need to create extern (C) bindings for the functions that will be used, right?
Mar 06 2012
On 7 March 2012 14:47, Tyler Jameson Little <beatgammit gmail.com> wrote:Pretty much, yeah. Remember that these declarations are only there to keep the compiler happy, and to provide some information to the linker when you link against the library, Ultimately you should be able to port any C code written for the library into D directly without significant changes (syntax changes etc), once the wrapper is done. Also, when you're done, submit the wrapper to Deimos. -- James MillerYou shouldn't have to do anything with them, just write bindings for the api, with all the correct types. -- James MillerThanks! I guess I got a little over-zealous in porting stuff over. I just need to create extern (C) bindings for the functions that will be used, right?
Mar 06 2012