Fixes submitted upstream. Note on the change from `rm -r` to
`rm -rf`: there is a directory named `test` nested in another
directory named `test` (`pcs/test/tools/test`). Depending on
the order in which they're found, `rm -r` might wind up trying
to remove `pcs/test/tools/test` after `pcs/test`, which is an
error and causes %check to fail. `rm -rf` ignores missing
targets, so it succeeds even in this scenario.