Fix cmake builds from checkouts with multiple remotes
- newlines from GetRepositoryPath output were interfering with ninja builds
- replace newlines with spaces
- remove *only* trailing spaces from repo path



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@181899 91177308-0d34-0410-b5e6-96231b3b80d8