Remove staging dir during configure. Fixes #2502.
Warn if prefix exists, error if it's a file.