iconv debugging aids

I made these commits while looking into the `precomposeunicode` support. The first lets you compile with ICONV on Linux, and the second is a short test-program that exercises the ref iteration.

/cc @arrbee