mzsocket

mzsocket is a native extension library for mzscheme, that provides the BSD/POSIX socket interface.
It supports IPv4, IPv6, Unix domain, and raw sockets depending on availability on the host platform.
The library is available under the GNU LGPL.

Current version (2009-04-27):
PLaneT: (require (planet vyzo/socket))
mzsocket-20090427.tar.gz 41KB [sig]
mzsocket-20090427.plt 53KB [sig]
Documentation

Last version for mzscheme-3xx (2007-04-25):
PLaneT: (require (planet "socket.ss" ("vyzo" "socket.plt" 1 2)))
mzsocket-20070425.tar.gz 34KB [sig]
mzsocket-20070425.plt 44KB [sig]
Documentation

Installation:
Unpack the archive into your collects directory and run setup-plt: setup-plt -l socket

Notes

You need a working C compiler.

Some GNU/Linux distributions ship with gcc configured to compile with -fstack-protector (Ubuntu Edgy is one of them). The linker will complain about __stack_chk_fail_local if this is the case.
You can resolve this in two ways:

  1. Push -fno-stack-protector to CFLAGS:
    export MZSCHEME_DYNEXT_COMPILER_FLAGS=-fno-stack-protector
  2. Use gcc as the linker:
    export MZSCHEME_DYNEXT_LINKER=/usr/bin/gcc

History

2009-04-27
Minor fixes

2008-11-06
Added dns resolution for inet4/inet6 constructor wrappers

2008-10-17
Update for plt-scheme 4.x Minor API changes

2007-04-25
Minor fix in version detection (369.10) for tests

2007-03-27
Use scheme_add_global instead of scheme_add_global_constant

2007-03-22
Initial version