-
Notifications
You must be signed in to change notification settings - Fork 27
669 lines (616 loc) · 28.5 KB
/
build.yaml
File metadata and controls
669 lines (616 loc) · 28.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
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
name: Build
on:
workflow_dispatch:
inputs:
channel:
description: "Channel to configure the build"
required: true
type: choice
default: "Auto"
options:
- "Auto"
- "Test"
- "Develop"
- "Project"
- "Beta"
- "Release"
- "Release edu"
project:
description: "Project Name (used for channel name in Project builds)"
required: true
type: string
default: "hippo"
pull_request:
push:
branches: ["main", "release/*", "beta/*", "project/*"]
tags: ["Alchemy*"]
jobs:
# The whole point of the setup job is that we want to set variables once
# that will be consumed by multiple subsequent jobs.
setup:
runs-on: ubuntu-latest
outputs:
viewer_branch: ${{ steps.which-branch.outputs.branch }}
relnotes: ${{ steps.which-branch.outputs.relnotes }}
release_run: ${{ steps.setvar.outputs.release_run }}
build_type: ${{ steps.setvar.outputs.build_type }}
bugsplat_db: ${{ steps.setvar.outputs.bugsplat_db }}
viewer_channel: ${{ steps.setvar.outputs.viewer_channel }}
is_private_build: ${{ steps.setvar.outputs.is_private_build }}
env:
# Build with a tag like "Alchemy#abcdef0" to generate a release page
# (used for builds we are planning to deploy).
# When you want to use a string variable as a workflow YAML boolean, it's
# important to ensure it's the empty string when false. If you omit || '',
# its value when false is "false", which is interpreted as true.
RELEASE_RUN: ${{ (github.event.inputs.release_run || github.ref_type == 'tag' && startsWith(github.ref_name, 'Alchemy')) && 'Y' || '' }}
FROM_FORK: ${{ github.event.pull_request.head.repo.fork }}
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
ref: ${{ github.event.pull_request.head.sha || github.sha }}
- name: Setup python
uses: actions/setup-python@v6
with:
python-version: "3.13"
- name: Determine source branch
id: which-branch
uses: AlchemyViewer/viewer-build-util/which-branch@v3
with:
token: ${{ github.token }}
- name: Set Variables
id: setvar
shell: bash
env:
BUILD_VCS_BRANCH: ${{ steps.which-branch.outputs.branch }}
VIEWER_CHANNEL_BASE: "Alchemy"
run: |
echo "release_run=$RELEASE_RUN" >> "$GITHUB_OUTPUT"
if [[ "x$GITHUB_REPOSITORY" == "xAlchemyViewer/AlchemyInternal" ]]; then
echo 'is_private_build=true' >> $GITHUB_OUTPUT
else
echo 'is_private_build=false' >> $GITHUB_OUTPUT
fi
if [[ "x$GITHUB_REPOSITORY" != "xAlchemyViewer/Alchemy" || "x$GITHUB_REPOSITORY" != "xAlchemyViewer/AlchemyInternal" ]]; then
# Non-linden viewer repository run OSS build
echo 'build_type=opensource' >> $GITHUB_OUTPUT
echo "bugsplat_db=" >> $GITHUB_OUTPUT
elif [[ "$FROM_FORK" == "true" ]]; then
# PR from fork; don't build with Bugsplat, proprietary libs
echo 'build_type=opensource' >> $GITHUB_OUTPUT
echo "bugsplat_db=" >> $GITHUB_OUTPUT
else
echo 'build_type=proprietary' >> $GITHUB_OUTPUT
echo "bugsplat_db=" >> $GITHUB_OUTPUT
fi
# determine the viewer channel from the branch or tag name
# trigger an EDU build by including "edu" in the tag
edu=${{ github.ref_type == 'tag' && contains(github.ref_name, 'edu') }}
echo "ref_type=${{ github.ref_type }}, ref_name=${{ github.ref_name }}, edu='$edu'"
branch=$BUILD_VCS_BRANCH
if [[ "${{inputs.channel}}" != "" && "${{inputs.channel}}" != "Auto" ]];
then
if [[ "${{inputs.channel}}" == "Project" ]];
then
export viewer_channel="${{ env.VIEWER_CHANNEL_BASE }} Project ${{inputs.project}}"
else
export viewer_channel="${{ env.VIEWER_CHANNEL_BASE }} ${{inputs.channel}}"
fi
elif [[ "$edu" == "true" ]];
then
export viewer_channel="${{ env.VIEWER_CHANNEL_BASE }} Release edu"
elif [[ "$branch" == "develop" ]];
then
export viewer_channel="${{ env.VIEWER_CHANNEL_BASE }} Develop"
else
IFS='/' read -ra ba <<< "$branch"
prefix=${ba[0]}
if [ "$prefix" == "project" ]; then
IFS='_' read -ra prj <<< "${ba[1]}"
prj_str="${prj[*]}"
# uppercase first letter of each word
capitalized=$(echo "$prj_str" | awk '{for (i=1; i<=NF; i++) $i = toupper(substr($i,1,1)) substr($i,2); print}')
export viewer_channel="${{ env.VIEWER_CHANNEL_BASE }} Project $capitalized"
elif [[ "$prefix" == "release" || "$prefix" == "main" ]];
then
export viewer_channel="${{ env.VIEWER_CHANNEL_BASE }} Release"
else
export viewer_channel="${{ env.VIEWER_CHANNEL_BASE }} Test"
fi
fi
echo "viewer_channel=$viewer_channel" >> "$GITHUB_OUTPUT"
build:
needs: setup
permissions:
packages: write
strategy:
matrix:
runner: ["windows-2025-vs2026", "macos-26", "ubuntu-24.04"]
configuration: [release]
arch: [x64, arm64]
build_variant: [Viewer, Tests]
exclude:
- runner: ubuntu-24.04
arch: arm64
- runner: windows-2025-vs2026
arch: arm64
- build_variant: Viewer
configuration: relwithdebinfo
- build_variant: Viewer
configuration: optdebug
- runner: macos-26
configuration: relwithdebinfo
- runner: macos-26
configuration: optdebug
runs-on: ${{ matrix.runner }}
outputs:
viewer_version: ${{ steps.build.outputs.viewer_version }}
imagename: ${{ steps.build.outputs.imagename }}
# Windows Velopack outputs (passed to sign-pkg-windows)
velopack_pack_id: ${{ steps.build.outputs.velopack_pack_id }}
velopack_pack_version: ${{ steps.build.outputs.velopack_pack_version }}
velopack_pack_title: ${{ steps.build.outputs.velopack_pack_title }}
velopack_main_exe: ${{ steps.build.outputs.velopack_main_exe }}
velopack_exclude: ${{ steps.build.outputs.velopack_exclude }}
velopack_icon: ${{ steps.build.outputs.velopack_icon }}
velopack_installer_base: ${{ steps.build.outputs.velopack_installer_base }}
# macOS Velopack outputs (passed to sign-pkg-mac)
velopack_mac_pack_id: ${{ steps.build.outputs.velopack_mac_pack_id }}
velopack_mac_pack_version: ${{ steps.build.outputs.velopack_mac_pack_version }}
velopack_mac_pack_title: ${{ steps.build.outputs.velopack_mac_pack_title }}
velopack_mac_main_exe: ${{ steps.build.outputs.velopack_mac_main_exe }}
velopack_mac_bundle_id: ${{ steps.build.outputs.velopack_mac_bundle_id }}
env:
# Sets Xcode version used for build
DEVELOPER_DIR: "/Applications/Xcode_26.2.app/Contents/Developer"
# Ensure that Linden viewer builds engage Bugsplat.
BUGSPLAT_DB: ${{ needs.setup.outputs.bugsplat_db }}
# Decide if we're building tests or the viewer
BUILD_VIEWER: ${{ matrix.build_variant == 'Viewer' }}
BUILD_APPEARANCE_UTIL: false # ${{ startsWith(matrix.runner, 'ubuntu-') && matrix.build_variant == 'Viewer' }}
BUILD_TESTS: ${{ matrix.build_variant == 'Tests' }}
# Build Config
BUILD_ARCH: ${{ matrix.arch }}
BUILD_CONFIG: ${{ matrix.configuration }}
BUILD_TYPE: ${{ needs.setup.outputs.build_type }}
# Crash Reporting - Disabled on linux
RELEASE_CRASH_REPORTING: ${{ !startsWith(matrix.runner, 'ubuntu-') && needs.setup.outputs.build_type == 'proprietary' }}
# Viewer Channel
VIEWER_CHANNEL: ${{ needs.setup.outputs.viewer_channel }}
VIEWER_GRID: "agni"
# Link Time Optimization
USE_LTO: ${{ matrix.configuration == 'release' }}
# Setting this variable directs Linden's TUT test driver code to capture
# test-program log output at the specified level, but to display it only if
# the individual test fails.
LOGFAIL: DEBUG
master_message_template_checkout: ${{ github.workspace }}/.master-message-template
# vcpkg Setup
VCPKG_ROOT: ${{ github.workspace }}/vcpkg
VCPKG_USERNAME: ${{ github.repository_owner }}
VCPKG_FEED_URL: https://nuget.pkg.github.com/${{ github.repository_owner }}/index.json
VCPKG_BINARY_SOURCES: "clear;nuget,https://nuget.pkg.github.com/${{ github.repository_owner }}/index.json,readwrite"
steps:
- name: Linux Dependency Install and Disk Cleanup
if: runner.os == 'Linux'
run: |
sudo apt update
sudo apt install -y \
autoconf autoconf-archive automake bison build-essential cmake curl flex gettext \
libasound2-dev libaudio-dev libdbus-1-dev libdbus-1-dev libdecor-0-dev libdrm-dev \
libegl1-mesa-dev libfribidi-dev libgbm-dev libgl1-mesa-dev libgles2-mesa-dev \
libgstreamer-plugins-base1.0-dev libgstreamer1.0-dev libibus-1.0-dev libjack-dev libltdl-dev \
libosmesa6-dev libpipewire-0.3-dev libpulse-dev libsndio-dev libtext-unidecode-perl \
libthai-dev libtool libudev-dev libunwind-dev liburing-dev libvlc-dev libwayland-dev \
libx11-dev libxcursor-dev libxext-dev libxfixes-dev libxft-dev libxi-dev libxinerama-dev \
libxkbcommon-dev libxrandr-dev libxss-dev libxtst-dev linux-libc-dev mono-complete \
nasm ninja-build pkgconf tar tex-common texinfo unzip zip
sudo locale-gen en_US.UTF-8
sudo locale-gen en_GB.UTF-8
sudo locale-gen fr_FR.UTF-8
df -h
sudo docker container prune -f
sudo docker image prune -a -f
sudo rm -rf /usr/local/lib/android
sudo rm -rf /opt/ghc
sudo rm -rf /usr/local/.ghcup
df -h
- name: macOS Homebrew Dependency Install
if: runner.os == 'macOS'
run: |
brew install autoconf autoconf-archive automake libtool mono nasm unzip zip
- name: Checkout code
uses: actions/checkout@v6
with:
submodules: recursive
ref: ${{ github.event.pull_request.head.sha || github.sha }}
- name: Checkout master-message-template
uses: actions/checkout@v6
with:
repository: secondlife/master-message-template
path: .master-message-template
- name: Setup python
uses: actions/setup-python@v6
with:
python-version: "3.14"
- name: Install python dependencies
run: pip3 install llsd cmake ninja
- name: Setup .NET for Velopack
uses: actions/setup-dotnet@v5
with:
dotnet-version: '10.x'
- name: Install Velopack CLI
run: dotnet tool restore
- name: Bootstrap vcpkg Windows
if: runner.os == 'Windows'
run: |
./vcpkg/bootstrap-vcpkg.bat
- name: Bootstrap vcpkg non-Windows
if: runner.os == 'macOS' || runner.os == 'Linux'
run: |
./vcpkg/bootstrap-vcpkg.sh
- name: Set up vcpkg nuget caching
shell: bash
run: |
if [[ "$RUNNER_OS" == "Windows" ]]
then
$(${VCPKG_ROOT}/vcpkg fetch nuget | tail -n 1) \
sources add \
-Source "${{ env.VCPKG_FEED_URL }}" \
-StorePasswordInClearText \
-Name GitHubPackages \
-UserName "${{ env.VCPKG_USERNAME }}" \
-Password "${{ secrets.GITHUB_TOKEN }}"
$(${VCPKG_ROOT}/vcpkg fetch nuget | tail -n 1) \
setapikey "${{ secrets.GITHUB_TOKEN }}" \
-Source "${{ env.VCPKG_FEED_URL }}"
else
mono $(${VCPKG_ROOT}/vcpkg fetch nuget | tail -n 1) \
sources add \
-Source "${{ env.VCPKG_FEED_URL }}" \
-StorePasswordInClearText \
-Name GitHubPackages \
-UserName "${{ env.VCPKG_USERNAME }}" \
-Password "${{ secrets.GITHUB_TOKEN }}"
mono $(${VCPKG_ROOT}/vcpkg fetch nuget | tail -n 1) \
setapikey "${{ secrets.GITHUB_TOKEN }}" \
-Source "${{ env.VCPKG_FEED_URL }}"
fi
- name: Cache Rust Dependencies
uses: actions/cache@v5
with:
path: |
~/.cargo/registry
~/.cargo/git
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- name: Configure
id: configure
shell: bash
env:
HAVOK: false # ${{ needs.setup.outputs.build_type == 'proprietary' }}
run: |
set -x
# Set VCPKG root
export VCPKG_ROOT=$VCPKG_INSTALLATION_ROOT
[ -n "$master_message_template_checkout" ] \
&& [ -r "$master_message_template_checkout/message_template.msg" ] \
&& template_verifier_master_url="-DTEMPLATE_VERIFIER_MASTER_URL=file://$master_message_template_checkout/message_template.msg"
cmake_preset_postfix=""
if [[ "$BUILD_TYPE" != "proprietary" ]]
then
cmake_preset_postfix="-os"
fi
SIGNING=()
case "$RUNNER_OS" in
Windows)
cmake_preset_name="vs2026$cmake_preset_postfix"
build_directory="build-Windows-$cmake_preset_name"
vcpkg_triplet="x64-windows-secondlife-release"
;;
macOS)
cmake_preset_name="ninja$cmake_preset_postfix-$BUILD_ARCH"
build_directory="build-Darwin-$cmake_preset_name"
vcpkg_triplet="$BUILD_ARCH-osx-secondlife-release"
;;
Linux)
cmake_preset_name="ninja$cmake_preset_postfix"
build_directory="build-Linux-$cmake_preset_name"
vcpkg_triplet="x64-linux-secondlife-release"
;;
esac
echo "build_directory=$build_directory" >> "$GITHUB_OUTPUT"
echo "cmake_preset=$cmake_preset_name" >> "$GITHUB_OUTPUT"
cmake -S indra --preset $cmake_preset_name \
-DVCPKG_TARGET_TRIPLET="$vcpkg_triplet" \
-DBUILD_VIEWER:BOOL="$BUILD_VIEWER" \
-DBUILD_APPEARANCE_UTIL:BOOL="$BUILD_APPEARANCE_UTIL" \
-DBUILD_TESTING:BOOL="$BUILD_TESTS" \
-DPACKAGE:BOOL=ON \
-DUSE_VELOPACK:BOOL=ON \
-DHAVOK:BOOL="$HAVOK" \
-DUSE_LTO:BOOL="$USE_LTO" \
-DDISABLE_RELEASE_DEBUG_LOGGING=ON \
-DRELEASE_CRASH_REPORTING:BOOL="$RELEASE_CRASH_REPORTING" \
-DBUGSPLAT_DB:STRING="${BUGSPLAT_DB:-}" \
-DVIEWER_CHANNEL:STRING="${VIEWER_CHANNEL}" \
-DGRID:STRING="\"$VIEWER_GRID\"" \
-DTEMPLATE_VERIFIER_OPTIONS:STRING="$template_verifier_options" $template_verifier_master_url \
"${SIGNING[@]}"
- name: Build
id: build
shell: bash
env:
BUILD_DIRECTORY: ${{ steps.configure.outputs.build_directory }}
CMAKE_PRESET_NAME: ${{ steps.configure.outputs.cmake_preset }}
CTEST_OUTPUT_ON_FAILURE: 1 # Output log on test failure
working-directory: "${{ github.workspace }}/indra"
run: |
set -x
# Set VCPKG root
export VCPKG_ROOT=$VCPKG_INSTALLATION_ROOT
if $BUILD_TESTS
then
# Now build the tests. We want to build them in a separate step before running them.
cmake --build --preset $CMAKE_PRESET_NAME-$BUILD_CONFIG
# Now that we've built the tests, we can run them to validate the build.
# If the tests fail, their output will be visible in the logs due to
# CTEST_OUTPUT_ON_FAILURE above, and the build step will be marked as failed.
cmake --build --preset $CMAKE_PRESET_NAME-$BUILD_CONFIG --target BUILD_AND_RUN_TESTS
elif $BUILD_VIEWER
then
cmake --build --preset $CMAKE_PRESET_NAME-$BUILD_CONFIG || fatal "failed building $BUILD_CONFIG viewer"
else
echo "::notice::Skipping build due to both viewer and tests being disabled"
fi
# Each artifact is downloaded as a distinct .zip file. Multiple jobs
# (per the matrix above) writing the same filepath to the same
# artifact name will *overwrite* that file. Moreover, they can
# interfere with each other, causing the upload to fail.
# https://github.com/actions/upload-artifact#uploading-to-the-same-artifact
# Given the size of our installers, and the fact that we typically
# only want to download just one instead of a single zip containing
# several, generate a distinct artifact name for each installer.
# If the matrix above can run multiple builds on the same
# platform, we must disambiguate on more than the platform name.
# e.g. if we were still running Windows 32-bit builds, we'd need to
# qualify the artifact with bit width.
if [[ "$BUILD_TYPE" != "proprietary" ]]
then cfg_suffix='-OS'
else cfg_suffix=''
fi
echo "artifact=$RUNNER_OS$cfg_suffix-$BUILD_ARCH" >> $GITHUB_OUTPUT
# Gather version metadata
if [ -r "$BUILD_DIRECTORY/newview/viewer_version.txt" ]
then
viewer_version="$(<"$BUILD_DIRECTORY/newview/viewer_version.txt")"
echo "viewer_version=$viewer_version" >> "$GITHUB_OUTPUT"
fi
- name: Upload executable
uses: actions/upload-artifact@v7
if: matrix.configuration == 'release' && matrix.build_variant == 'Viewer'
with:
name: "${{ steps.build.outputs.artifact }}-app"
if-no-files-found: error
compression-level: 9
path: |
${{ steps.build.outputs.viewer_app }}
# The other upload of nontrivial size is the symbol file. Use a distinct
# artifact for that too.
- name: Upload Windows symbol file
uses: actions/upload-artifact@v7
if: runner.os == 'Windows' && matrix.configuration == 'release' && matrix.build_variant == 'Viewer' && needs.setup.outputs.build_type == 'proprietary'
with:
name: "${{ steps.build.outputs.artifact }}-symbols"
if-no-files-found: error
path: |
${{ steps.configure.outputs.build_directory }}/symbols/Release/${{ needs.setup.outputs.viewer_channel }}.sym.tar.xz
- name: Upload macOS symbol file
uses: actions/upload-artifact@v7
if: runner.os == 'macOS' && matrix.configuration == 'release' && matrix.build_variant == 'Viewer' && needs.setup.outputs.build_type == 'proprietary'
with:
name: "${{ steps.build.outputs.artifact }}-symbols"
if-no-files-found: error
path: |
${{ steps.configure.outputs.build_directory }}/symbols/Release/${{ needs.setup.outputs.viewer_channel }}.xcarchive.zip
- name: Upload metadata
uses: actions/upload-artifact@v7
if: matrix.configuration == 'release' && matrix.build_variant == 'Viewer'
with:
name: "${{ steps.build.outputs.artifact }}-metadata"
if-no-files-found: error
compression-level: 9
path: |
${{ steps.configure.outputs.build_directory }}/newview/viewer_version.txt
# - name: Upload appearance utility package
# uses: actions/upload-artifact@v7
# if: runner.os == 'Linux' && matrix.configuration == 'release' && matrix.build_variant == 'Viewer'
# with:
# name: "${{ steps.build.outputs.artifact }}-appearanceutility"
# path: |
# ${{ steps.configure.outputs.build_directory }}/llappearanceutility/Release/appearance-utility-bin
# ${{ steps.configure.outputs.build_directory }}/llappearanceutility/Release/appearance-utility-headless-bin
# sign-and-package-windows:
# env:
# AZURE_KEY_VAULT_URI: ${{ secrets.AZURE_KEY_VAULT_URI }}
# AZURE_CERT_NAME: ${{ secrets.AZURE_CERT_NAME }}
# AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }}
# AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }}
# AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }}
# needs: [setup, build]
# runs-on: windows-2022
# if: needs.setup.outputs.build_type == 'proprietary'
# steps:
# - name: Sign and package Windows viewer
# if: env.AZURE_KEY_VAULT_URI && env.AZURE_CERT_NAME && env.AZURE_CLIENT_ID && env.AZURE_CLIENT_SECRET && env.AZURE_TENANT_ID
# uses: secondlife/viewer-build-util/sign-pkg-windows@geenz/velopack
# with:
# vault_uri: "${{ env.AZURE_KEY_VAULT_URI }}"
# cert_name: "${{ env.AZURE_CERT_NAME }}"
# client_id: "${{ env.AZURE_CLIENT_ID }}"
# client_secret: "${{ env.AZURE_CLIENT_SECRET }}"
# tenant_id: "${{ env.AZURE_TENANT_ID }}"
# installer_type: "${{ github.event.inputs.installer_type || 'velopack' }}"
# velopack_pack_id: "${{ needs.build.outputs.velopack_pack_id }}"
# velopack_pack_version: "${{ needs.build.outputs.velopack_pack_version }}"
# velopack_pack_title: "${{ needs.build.outputs.velopack_pack_title }}"
# velopack_main_exe: "${{ needs.build.outputs.velopack_main_exe }}"
# velopack_exclude: "${{ needs.build.outputs.velopack_exclude }}"
# velopack_icon: "${{ needs.build.outputs.velopack_icon }}"
# velopack_installer_base: "${{ needs.build.outputs.velopack_installer_base }}"
# sign-and-package-mac:
# env:
# NOTARIZE_CREDS_MACOS: ${{ secrets.NOTARIZE_CREDS_MACOS }}
# SIGNING_CERT_MACOS: ${{ secrets.SIGNING_CERT_MACOS }}
# SIGNING_CERT_MACOS_IDENTITY: ${{ secrets.SIGNING_CERT_MACOS_IDENTITY }}
# SIGNING_CERT_MACOS_PASSWORD: ${{ secrets.SIGNING_CERT_MACOS_PASSWORD }}
# needs: [setup, build]
# runs-on: macos-latest
# if: needs.setup.outputs.build_type == 'proprietary'
# steps:
# - name: Unpack Mac notarization credentials
# if: env.NOTARIZE_CREDS_MACOS
# id: note-creds
# shell: bash
# run: |
# # In NOTARIZE_CREDS_MACOS we expect to find:
# # USERNAME="..."
# # PASSWORD="..."
# # TEAM_ID="..."
# eval "${{ env.NOTARIZE_CREDS_MACOS }}"
# echo "::add-mask::$USERNAME"
# echo "::add-mask::$PASSWORD"
# echo "::add-mask::$TEAM_ID"
# echo "note_user=$USERNAME" >> "$GITHUB_OUTPUT"
# echo "note_pass=$PASSWORD" >> "$GITHUB_OUTPUT"
# echo "note_team=$TEAM_ID" >> "$GITHUB_OUTPUT"
# # If we didn't manage to retrieve all of these credentials, better
# # find out sooner than later.
# [[ -n "$USERNAME" && -n "$PASSWORD" && -n "$TEAM_ID" ]]
# - name: Sign and package Mac viewer
# if: env.SIGNING_CERT_MACOS && env.SIGNING_CERT_MACOS_IDENTITY && env.SIGNING_CERT_MACOS_PASSWORD && steps.note-creds.outputs.note_user && steps.note-creds.outputs.note_pass && steps.note-creds.outputs.note_team
# uses: secondlife/viewer-build-util/sign-pkg-mac@v2
# with:
# channel: ${{ needs.setup.outputs.viewer_channel }}
# imagename: ${{ needs.build.outputs.imagename }}
# cert_base64: ${{ env.SIGNING_CERT_MACOS }}
# cert_name: ${{ env.SIGNING_CERT_MACOS_IDENTITY }}
# cert_pass: ${{ env.SIGNING_CERT_MACOS_PASSWORD }}
# note_user: ${{ steps.note-creds.outputs.note_user }}
# note_pass: ${{ steps.note-creds.outputs.note_pass }}
# note_team: ${{ steps.note-creds.outputs.note_team }}
# post-windows-symbols:
# env:
# BUGSPLAT_DATABASE: "${{ secrets.BUGSPLAT_DATABASE }}"
# SYMBOL_UPLOAD_CLIENT_ID: "${{ secrets.BUGSPLAT_SYMBOL_UPLOAD_CLIENT_ID }}"
# SYMBOL_UPLOAD_CLIENT_SECRET: "${{ secrets.BUGSPLAT_SYMBOL_UPLOAD_CLIENT_SECRET }}"
# needs: [setup, build]
# if: needs.setup.outputs.build_type == 'proprietary'
# runs-on: ubuntu-latest
# steps:
# - name: Download viewer exe
# uses: actions/download-artifact@v8
# with:
# name: Windows-x64-app
# path: _artifacts
# - name: Download Windows Symbols
# if: env.BUGSPLAT_DATABASE && env.SYMBOL_UPLOAD_CLIENT_ID
# uses: actions/download-artifact@v8
# with:
# name: Windows-x64-symbols
# - name: Extract viewer pdb
# if: env.BUGSPLAT_DATABASE && env.SYMBOL_UPLOAD_CLIENT_ID
# shell: bash
# run: |
# tar -xJf "${{ needs.setup.outputs.viewer_channel }}.sym.tar.xz" -C _artifacts
# - name: Post Windows symbols
# if: env.BUGSPLAT_DATABASE && env.SYMBOL_UPLOAD_CLIENT_ID
# uses: BugSplat-Git/symbol-upload@2a0d2b8cf9c54c494144048f25da863d93a02ccd
# with:
# clientId: "${{ env.SYMBOL_UPLOAD_CLIENT_ID }}"
# clientSecret: "${{ env.SYMBOL_UPLOAD_CLIENT_SECRET }}"
# database: "${{ env.BUGSPLAT_DATABASE }}"
# application: ${{ needs.setup.outputs.viewer_channel }}
# version: ${{ needs.build.outputs.viewer_version }}
# directory: _artifacts
# files: "**/{SecondLifeViewer.exe,llwebrtc.dll,*.pdb}"
# node-version: "22"
# dumpSyms: false
# post-mac-symbols:
# env:
# BUGSPLAT_DATABASE: "${{ secrets.BUGSPLAT_DATABASE }}"
# SYMBOL_UPLOAD_CLIENT_ID: "${{ secrets.BUGSPLAT_SYMBOL_UPLOAD_CLIENT_ID }}"
# SYMBOL_UPLOAD_CLIENT_SECRET: "${{ secrets.BUGSPLAT_SYMBOL_UPLOAD_CLIENT_SECRET }}"
# needs: [setup, build]
# if: needs.setup.outputs.build_type == 'proprietary'
# runs-on: ubuntu-latest
# steps:
# - name: Download Mac Symbols
# if: env.BUGSPLAT_DATABASE && env.SYMBOL_UPLOAD_CLIENT_ID
# uses: actions/download-artifact@v8
# with:
# name: macOS-x64-symbols
# - name: Post Mac symbols
# if: env.BUGSPLAT_DATABASE && env.SYMBOL_UPLOAD_CLIENT_ID
# uses: BugSplat-Git/symbol-upload@2a0d2b8cf9c54c494144048f25da863d93a02ccd
# with:
# clientId: "${{ env.SYMBOL_UPLOAD_CLIENT_ID }}"
# clientSecret: "${{ env.SYMBOL_UPLOAD_CLIENT_SECRET }}"
# database: "${{ env.BUGSPLAT_DATABASE }}"
# application: ${{ needs.setup.outputs.viewer_channel }}
# version: ${{ needs.build.outputs.viewer_version }} (${{ needs.build.outputs.viewer_version }})
# directory: .
# files: "**/*.xcarchive.zip"
# node-version: "22"
# dumpSyms: false
# release:
# needs: [setup, build, sign-and-package-windows, sign-and-package-mac]
# runs-on: ubuntu-latest
# if: needs.setup.outputs.release_run
# steps:
# # - uses: actions/download-artifact@v8
# # with:
# # pattern: "*-installer"
# - uses: actions/download-artifact@v8
# with:
# pattern: "*-metadata"
# - uses: actions/download-artifact@v8
# with:
# pattern: "*-releases"
# - uses: actions/download-artifact@v8
# with:
# name: "Linux-app"
# - name: Rename metadata
# run: |
# cp Windows-metadata/newview/viewer_version.txt Windows-viewer_version.txt
# cp macOS-metadata/newview/viewer_version.txt macOS-viewer_version.txt
# cp Linux-metadata/newview/viewer_version.txt Linux-viewer_version.txt
# # forked from softprops/action-gh-release
# - name: Create GitHub release
# id: release
# uses: AlchemyViewer/action-gh-release@v2
# with:
# # name the release page for the branch
# name: "${{ needs.setup.outputs.viewer_branch }}"
# # SL-20546: want the channel and version to be visible on the
# # release page
# body: |
# Build ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
# ${{ needs.setup.outputs.viewer_channel }}
# ${{ needs.build.outputs.viewer_version }}
# ${{ needs.setup.outputs.relnotes }}
# prerelease: true
# generate_release_notes: true
# target_commitish: ${{ github.sha }}
# append_body: true
# fail_on_unmatched_files: true
# files: |
# macOS-installer/*.dmg
# Windows-installer/*.exe
# *.tar.xz
# *-viewer_version.txt
# Windows-releases/*
# macOS-releases/*
# - name: post release URL
# run: |
# echo "::notice::Release ${{ steps.release.outputs.url }}"