fix --with-gmp (broken by r57490)
Looking at the generated shell script (also the autoconf manual), it
seems AC_SEARCH_LIBS() m4 macro does not define HAVE_LIBsomething C
preprocessor macros, unlike AC_CHECK_LIB() which does define them.
This previous change effectively killed building with GMP because
building that mode depends on existence of HAVE_LIBGMP. [Bug #13402]
merge revision(s) 58254: [Backport #13402]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_4@59914 b2dd03c8-39d4-4d8f-98ff-823fe69b080e