Revert "Use my sort patch instead", fix BLS ostree detection
This reverts commit 93004a8494732dca960febe24d987a8ff115de38,
because it broke Rawhide. It also tries to fixes BLS ostree
detection to work in chroots (e.g. during installation) by also
checking for /ostree/repo.