Fix configuration generation to not crash source import

As pointed out by @iguananaut in #498 (after it was merged), the changes in #498 cause astropy to fail if you import it directly from source instead of building first.  This PR corrects that by allowing the import to succeed (but not installing the configuration files, as it has no defaults to copy from).