This reverts commit 392c1eec4d. See: https://gitlab.kitware.com/cmake/cmake/-/issues/22024
392c1eec4d