fix #1866 (darwin gmp build failure)