rewrite to full satisfact to original config.h.in