glibc resolve.h for D

John Colvin via Digitalmars-d digitalmars-d at puremagic.com
Wed Feb 8 05:06:55 PST 2017


On Wednesday, 8 February 2017 at 12:49:39 UTC, Márcio Martins 
wrote:
> Anyone has a binding readily available that I can use?
> code.dlang.org is down, so I can't check there - I am in a 
> hurry! :)

I dont' have one, but if you're in a hurry then copy and port the 
C function/constant defs and port them one-by-one as you need 
them (it's not like you're going to call every single function 
and use every single constant are you?). It's a tiny amount of 
work.

I often write as if I *have* ported the header and then just use 
the compiler errors to fill in the gaps.


P.S. there's no need to port the __res_state struct as afaics 
it's never used directly in the API:

struct __res_state;
alias res_state = __res_state*;

will do fine.


More information about the Digitalmars-d mailing list