CMakeDependentOption: Revert "Allow parentheses in the depends string"
Revert !6225 (merged). It broke existing use cases with parentheses in regular expressions. Also add a test for this.
Fixes: #22447 (closed)
Issue: #22303 (closed)
Backport: release
Edited by Brad King