avoid std::cerr to workaround a bug of libc++ in linux