file: Restore error capture in undocumented READ_ELF mode

Revise the error message added by commit 115ff6a3 (cmELF: Include the
ELF parsing code unconditionally, 2021-06-17, v3.22.0-rc1~557^2) to
honor the `CAPTURE_ERROR` option.  This is needed by the call site in
`BundleUtilities` to suppress errors on non-ELF files.

Fixes: #23074
38 jobs for !6853 with file-READ_ELF-capture-error in 25 minutes and 15 seconds (queued for 4 seconds)
latest merge request