Fixes for ROOT-5755 (2) (CMake)