Use #if, not #ifdef in test for HAVE_CONFIG_H.