iconv dependency: try even harder to find working iconv
iconv dependency: try even harder to find working iconv

has_function(prefix: '...') is useless to check the difference between
builtins and external library functions. It has code to detect
"builtins" that misfires and reports that iconv_open is defined as a
builtin on mingw, but only if you include the header.

Instead compile an open-coded test file that this iconv dependency
implementation fully controls, that doesn't get up to imaginative edge
cases like trying to find `__builtin_iconv_open`.

Fixes commit db1fa702f3943c6e4fec142b2bf5468c89173993, which merely
moved the brokenness over one step to the right (by breaking mingw
instead of freebsd)

Fixes https://github.com/mesonbuild/meson/pull/9632#issuecomment-979581509

pexip/meson,pexip/meson,pexip/meson,mesonbuild/meson,mesonbuild/meson,pexip/meson,pexip/meson,pexip/meson,mesonbuild/meson,mesonbuild/meson,mesonbuild/meson,mesonbuild/meson,mesonbuild/meson,pexip/meson,mesonbuild/meson,pexip/meson,pexip/meson,mesonbuild/meson,pexip/meson,mesonbuild/meson