tcp: add support for darwin, dragonfly and openbsd