forked from googleapis/google-cloud-cpp
-
Notifications
You must be signed in to change notification settings - Fork 0
141 lines (138 loc) · 4.5 KB
/
macos-bazel.yml
File metadata and controls
141 lines (138 loc) · 4.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
name: macOS-Bazel-Builds
on:
workflow_call:
inputs:
checkout-ref:
required: true
description: "The ref we want to compile"
type: string
permissions:
contents: read
jobs:
bazel:
name: bazel + ${{ matrix.os }} + ${{ matrix.shard }}
runs-on: ${{ matrix.os }}-xlarge
permissions:
contents: 'read'
id-token: 'write'
strategy:
# Continue other builds even if one fails
fail-fast: false
matrix:
os: [ macos-13 ]
shard:
- Core
- Bigtable
- Pub/Sub
- Spanner
- Storage
- Compute
- Larger Libraries
- Other
include:
- shard: Core
targets:
- //google/cloud:all
# - //generator/... # Does not build on macOS
# - //docfx/... # Does not build on macOS
- +//examples/...
- shard: Bigtable
targets:
- //google/cloud/bigtable/...
- shard: Pub/Sub
targets:
- //google/cloud/pubsub/...
- +//google/cloud/pubsublite/...
- shard: Spanner
targets:
- //google/cloud/spanner/...
- shard: Storage
targets:
- //google/cloud/storage/...
# Include the top-level examples because they require the libs anyway.
- shard: Compute
targets:
- //google/cloud/compute/...
- shard: Larger Libraries
targets:
# Run this:
#
# git grep -l 'class.*Client' 'google/cloud/**_client.h' |
# egrep -v "(bigtable/|internal/|pubsub/|spanner/|storage/)" |
# cut -f -3 -d/| sort | uniq -c | sort -n |
# awk '{ s += $1; print s, $0}'
#
# and pick the approximate midpoint
- //google/cloud/servicecontrol/...
- +//google/cloud/support/...
- +//google/cloud/video/...
- +//google/cloud/datacatalog/...
- +//google/cloud/iam/...
- +//google/cloud/kms/...
- +//google/cloud/beyondcorp/...
- +//google/cloud/contentwarehouse/...
- +//google/cloud/dataproc/...
- +//google/cloud/talent/...
- +//google/cloud/retail/...
- +//google/cloud/bigquery/...
- +//google/cloud/appengine/...
- +//google/cloud/monitoring/...
- +//google/cloud/sql/...
- +//google/cloud/dialogflow_cx/...
- +//google/cloud/aiplatform/...
- +//google/cloud/dialogflow_es/...
- shard: Other
targets:
- //...
# Skip top-level targets (e.g. //:bigtable).
- -//:all
# From Core
- -//generator/...
- -//docfx/...
- -//google/cloud:all
- -//examples/...
# From Bigtable
- -//google/cloud/bigtable/...
# From Pub/Sub
- -//google/cloud/pubsub/...
- -//google/cloud/pubsublite/...
# From Spanner
- -//google/cloud/spanner/...
# From Storage
- -//google/cloud/storage/...
# From Compute
- -//google/cloud/compute/...
# From Large Libraries
- -//google/cloud/servicecontrol/...
- -//google/cloud/support/...
- -//google/cloud/video/...
- -//google/cloud/datacatalog/...
- -//google/cloud/iam/...
- -//google/cloud/kms/...
- -//google/cloud/beyondcorp/...
- -//google/cloud/contentwarehouse/...
- -//google/cloud/dataproc/...
- -//google/cloud/talent/...
- -//google/cloud/retail/...
- -//google/cloud/bigquery/...
- -//google/cloud/appengine/...
- -//google/cloud/monitoring/...
- -//google/cloud/sql/...
- -//google/cloud/dialogflow_cx/...
- -//google/cloud/aiplatform/...
- -//google/cloud/dialogflow_es/...
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
with:
ref: ${{ inputs.checkout-ref }}
- uses: google-github-actions/auth@v2
with:
create_credentials_file: true
credentials_json: ${{ secrets.BUILD_CACHE_KEY }}
- name: Install bash >= 5.x
run: brew install bash
- name: Build google-cloud-cpp
run: |
/opt/homebrew/bin/bash ci/gha/builds/macos-bazel.sh ${{ join(matrix.targets, ' ') }}
env:
BAZEL_REMOTE_CACHE: https://storage.googleapis.com/cloud-cpp-gha-cache/bazel-cache/${{ matrix.os }}