Repository navigation
82 lines (80 loc) · 3.41 KB
/
Copy pathBuildPR.yml
File metadata and controls
82 lines (80 loc) · 3.41 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
name: PullRequest
on:
push:
branches:
- master
pull_request:
jobs:
build-objective-git:
name: Build
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- xcode: 26.3
os: macos-15-intel
abi: x86_64
- xcode: 26.3
os: macos-26
abi: arm64
steps:
- name: ls Xcode
run: ls -la /Applications/Xcode*
- name: Show openssl version
run: |
openssl version
# Fully remove any pre-existing openssl kegs/config first so the
# reinstall below has a clean slate. Otherwise `brew install`
# finds leftover files at the link destination (etc config,
# opt symlink, Cellar keg) and prints noisy
# "have not been removed!" / "overwritten during the `brew link`
# step" warnings. Newer runner images (e.g. macos-26) preinstall
# openssl@4 as the default "openssl" formula, so that must be
# cleaned up too or linking openssl@3 afterwards fails.
brew uninstall --ignore-dependencies --force openssl@1.1 openssl@3 openssl@4 openssl || true
rm -rf /usr/local/etc/openssl@1.1 /usr/local/etc/openssl@3 /usr/local/etc/openssl@4 /usr/local/etc/openssl
rm -rf /usr/local/opt/openssl@1.1 /usr/local/opt/openssl@3 /usr/local/opt/openssl@4 /usr/local/opt/openssl
rm -rf /usr/local/Cellar/openssl@1.1 /usr/local/Cellar/openssl@3 /usr/local/Cellar/openssl@4 /usr/local/Cellar/openssl
rm -rf /opt/homebrew/etc/openssl@1.1 /opt/homebrew/etc/openssl@3 /opt/homebrew/etc/openssl@4 /opt/homebrew/etc/openssl
rm -rf /opt/homebrew/opt/openssl@1.1 /opt/homebrew/opt/openssl@3 /opt/homebrew/opt/openssl@4 /opt/homebrew/opt/openssl
rm -rf /opt/homebrew/Cellar/openssl@1.1 /opt/homebrew/Cellar/openssl@3 /opt/homebrew/Cellar/openssl@4 /opt/homebrew/Cellar/openssl
# The uninstalls/removes above don't always clear out the actual
# bin/ symlinks left behind by a previously linked keg, which then
# blocks `brew link` below with "already exists" conflicts.
rm -f /usr/local/bin/openssl /usr/local/bin/c_rehash
rm -f /opt/homebrew/bin/openssl /opt/homebrew/bin/c_rehash
brew install openssl@3
brew link --overwrite openssl@3
openssl version
- name: Checkout
uses: actions/checkout@v7
with:
fetch-depth: 0
submodules: true
- uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: ${{ matrix.xcode }}
- run: script/bootstrap
- run: script/update_libgit2
- name: Show openssl version
run: |
openssl version
- name: Unlink openssl 3
run: |
brew unlink openssl@3
- name: Test project
id: run-unit-tests
run: |
make test \
ARCH=${{ matrix.abi }} \
RESULT_BUNDLE=UnitTestResults-${{ matrix.abi }}.xcresult
- name: Upload unit test results
if: ${{ failure() && steps.run-unit-tests.outcome == 'failure' }}
uses: actions/upload-artifact@v7
with:
name: UnitTestResults-${{ matrix.abi }}.xcresult
path: UnitTestResults-${{ matrix.abi }}.xcresult
retention-days: ${{ github.event_name == 'pull_request' && 7 || 90 }}
- name: Archive project
run: make archive ARCH=${{ matrix.abi }}