ci: Restore compilation check on PR (#4963)
* ci: Restore compilation check on PR
Restore macos/windows compilation check on pull requests and add react
native as well.
* Trigger build
* Add cache, name
* Speed up check
* Remove clean
* Run in bash even on windows
* Cleanup