apply fix #3153 to openlibm also