That problem is occurring because libidn is using an old version of gnulib's m4/longlong.m4. This bug was fixed on 2007-11-12 in gnulib. Time to upgrade, I expect.
Plus, the libidn maintainers might consider upgrading from gnulib regularly, before doing a libidn release.