
See https://cmake.org/cmake/help/latest/command/endif.html and https://cmake.org/cmake/help/latest/command/if.html. If the else/endif condition does not match the if condition verbatim, an error is produced on some versions of cmake. This change removes these "legacy conditions."