Suppress tar errors
With non-GNU tar, passing the --sort option may print out an error message saying the option isn't supported; that's confusing and not useful to the consumer.
It looks something like this at CMake-time:
This warning is for project developers. Use -Wno-dev to suppress it.
tar: Option --sort=name is not supported
Usage:
List: tar -tf <archive-filename>
Extract: tar -xf <archive-filename>
Create: tar -cf <archive-filename> [filenames...]
Help: tar --help
So instead, just eat the stderr; the code is looking at version output from tar, as well as the exit value of tar, anyway.