clean up usage of if(... MATCHES regex) followed string(REGEX REPLACE regex)

The matches have already been calculated and can simply be taken from
CMAKE_MATCH_n variables. This avoids multiple compilations of the same or very
similar regular expressions.
replace string(REGEX REPLACE) with string(REPLACE) where possible

The simple replacement is much faster.
Revert "Modules: Add an Andriod platform file"

This reverts commit 77f06b145d57c4665ff5d71b89a70c54a009ad14.

It may be re-added in the future when the requirements for that
platform are better known and supported by CMake.
Merge topic 'matches-cleanup' into next

6adc0bd8 replace string(REGEX REPLACE) with string(REPLACE) where possible
10a9784a clean up usage of if(... MATCHES regex) followed string(REGEX REPLACE regex)
Merge topic 'revert-Android-platform' into next

4b31f064 Revert "Modules: Add an Andriod platform file"