configure: Drop check_lib()/require() in favor of check_lib2()/require2()