Migrate remaining macOS tests to GHA actions

PiperOrigin-RevId: 506744609
diff --git a/php/generate_descriptor_protos.sh b/php/generate_descriptor_protos.sh
index 0e5be35..a9af40c 100755
--- a/php/generate_descriptor_protos.sh
+++ b/php/generate_descriptor_protos.sh
@@ -9,7 +9,7 @@
   PROTOC=$(realpath protoc)
 fi
 if [ ! -f $PROTOC ]; then
-  bazel build -c opt //:protoc
+  ${BAZEL:-bazel} $BAZEL_STARTUP_FLAGS build -c opt //:protoc $BAZEL_FLAGS
   PROTOC=$(realpath bazel-bin/protoc)
 fi
 
diff --git a/php/generate_test_protos.sh b/php/generate_test_protos.sh
index 6d06f95..51df6f8 100755
--- a/php/generate_test_protos.sh
+++ b/php/generate_test_protos.sh
@@ -8,7 +8,7 @@
   PROTOC=$(pwd)/protoc
 fi
 if [ ! -f $PROTOC ]; then
-  bazel build -c opt //:protoc
+  ${BAZEL:-bazel} $BAZEL_STARTUP_FLAGS build -c opt //:protoc $BAZEL_FLAGS
   PROTOC=$(pwd)/bazel-bin/protoc
 fi