Cirrus CI: Only trigger amd64-gcc12 on pull requests
Since Cirrus Labs is limiting their free usage tier [1], limit gcc CI
runs to pull requests only.
[1]: https://cirrus-ci.org/blog/2023/07/17/limiting-free-usage-of-cirrus-ci/
(cherry picked from commit 57b9a104a26d0761c4cba5726f0ab78b50a57ded)