Lambda-term: fix compilation under OpenBSD.

Patch taken from the OpenBSD ports tree and unified.

@diml this is due to a local bug in OpenBSD and so switches to requiring libiconv; ok with you?  It shouldn't affect non-OpenBSD since the patch isn't applied.