AC_TRY_LINK is deprecated and users are encouraged to replace it with
AC_LINK_IFELSE. However, AC_SEARCH_LIBS uses AC_LINK_IFELSE internally
and does exactly what we need here: test whether an fmin symbol is
already resolved or if libm will resolve it, neatly avoiding autoconf
caching and AC_TRY_LINK/AC_LINK_IFELSE pitfalls. So just use that.
AC_TRY_LINK is deprecated and users are encouraged to replace it with AC_LINK_IFELSE. However, AC_SEARCH_LIBS uses AC_LINK_IFELSE internally and does exactly what we need here: test whether an
fmin
symbol is already resolved or if libm will resolve it, neatly avoiding autoconf caching and AC_TRY_LINK/AC_LINK_IFELSE pitfalls. So just use that.