Replace bare if statements with AS_IF in configure.ac.