From 5b4846046bb0700d749f017916e1d34294d830e0 Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Mon, 10 Oct 2022 09:33:04 -0700 Subject: Add build action --- .github/workflows/build.yaml | 53 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 .github/workflows/build.yaml (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml new file mode 100644 index 0000000000..7ba97b6d53 --- /dev/null +++ b/.github/workflows/build.yaml @@ -0,0 +1,53 @@ +name: Build + +on: + workflow_dispatch: + pull_request: + push: + branches: ["actions"] + +jobs: + build: + strategy: + matrix: + os: [windows-2019, macos-11] + configuration: [RelWithDebInfoOS] + arch: [64] + include: + - os: windows-2019 + configuration: RelWithDebInfoOS + arch: 32 + runs-on: ${{ matrix.os }} + env: + AUTOBUILD_ADDRSIZE: ${{ matrix.arch }} + AUTOBUILD_INSTALLABLE_CACHE: ${{ github.workspace }}/.autobuild-installables + AUTOBUILD_VARIABLES_FILE: ${{ github.workspace }}/.build-variables/variables + steps: + - uses: actions/checkout@v3 + + - uses: actions/checkout@v3 + with: + repository: secondlife/build-variables + ref: viewer + token: ${{ secrets.SHARED_GITHUB_TOKEN }} + path: .build-variables + + - uses: actions/setup-python@v4 + with: + python-version: 3.x + + - name: Install autobuild + run: pip install autobuild<4 + + - uses: actions/cache@v3 + id: cache-installables + with: + path: .autobuild-installables + key: ${{ matrix.os }}-${{ matrix.arch }}-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} + + - name: Build + shell: bash + run: | + autobuild install + autobuild configure -c ${{ matrix.configuration }} + autobuild build --no-configure -- cgit v1.2.3 From 28ec3a63b8f9c5f97b1024f18036af72f9d3b281 Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Mon, 10 Oct 2022 09:35:04 -0700 Subject: Pip install autobuild --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 7ba97b6d53..3fce1da35f 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -37,7 +37,7 @@ jobs: python-version: 3.x - name: Install autobuild - run: pip install autobuild<4 + run: pip install autobuild - uses: actions/cache@v3 id: cache-installables -- cgit v1.2.3 From 9a84b3923db0653f01ab7d8541645007347c4db4 Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Mon, 10 Oct 2022 09:40:32 -0700 Subject: Separate autobuild install from build --- .github/workflows/build.yaml | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 3fce1da35f..16c794cde5 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -12,14 +12,15 @@ jobs: matrix: os: [windows-2019, macos-11] configuration: [RelWithDebInfoOS] - arch: [64] + addrsize: [64] include: - os: windows-2019 configuration: RelWithDebInfoOS - arch: 32 + addrsize: 32 runs-on: ${{ matrix.os }} env: - AUTOBUILD_ADDRSIZE: ${{ matrix.arch }} + AUTOBUILD_CONFIGURATION: ${{ matrix.configuration }} + AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} AUTOBUILD_INSTALLABLE_CACHE: ${{ github.workspace }}/.autobuild-installables AUTOBUILD_VARIABLES_FILE: ${{ github.workspace }}/.build-variables/variables steps: @@ -45,9 +46,10 @@ jobs: path: .autobuild-installables key: ${{ matrix.os }}-${{ matrix.arch }}-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} + - name: Install autobuild packages + run: autobuild install + - name: Build - shell: bash run: | - autobuild install autobuild configure -c ${{ matrix.configuration }} autobuild build --no-configure -- cgit v1.2.3 From 7da93ab373a145392e51af0d3fdf7b61dd55ce0b Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Mon, 10 Oct 2022 09:45:17 -0700 Subject: Force RelWithDebInfoOS configuration --- .github/workflows/build.yaml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 16c794cde5..8a13ac0374 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -30,7 +30,6 @@ jobs: with: repository: secondlife/build-variables ref: viewer - token: ${{ secrets.SHARED_GITHUB_TOKEN }} path: .build-variables - uses: actions/setup-python@v4 @@ -47,7 +46,7 @@ jobs: key: ${{ matrix.os }}-${{ matrix.arch }}-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} - name: Install autobuild packages - run: autobuild install + run: autobuild install -c ${{ matrix.configuration }} - name: Build run: | -- cgit v1.2.3 From 6b137c7fd65b50cdba69b789e3ead1728fc1f000 Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Mon, 10 Oct 2022 09:50:40 -0700 Subject: Allow CMAKE to run autobuild install --- .github/workflows/build.yaml | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 8a13ac0374..3d66c02e75 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -24,31 +24,32 @@ jobs: AUTOBUILD_INSTALLABLE_CACHE: ${{ github.workspace }}/.autobuild-installables AUTOBUILD_VARIABLES_FILE: ${{ github.workspace }}/.build-variables/variables steps: - - uses: actions/checkout@v3 + - name: Checkout code + uses: actions/checkout@v3 - - uses: actions/checkout@v3 + - name: Checkout build variables + uses: actions/checkout@v3 with: repository: secondlife/build-variables ref: viewer path: .build-variables - - uses: actions/setup-python@v4 + - name: Install python + uses: actions/setup-python@v4 with: python-version: 3.x - name: Install autobuild run: pip install autobuild - - uses: actions/cache@v3 + - name: Cache autobuild packages + uses: actions/cache@v3 id: cache-installables with: path: .autobuild-installables key: ${{ matrix.os }}-${{ matrix.arch }}-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} - - name: Install autobuild packages - run: autobuild install -c ${{ matrix.configuration }} - - name: Build run: | - autobuild configure -c ${{ matrix.configuration }} + autobuild configure autobuild build --no-configure -- cgit v1.2.3 From f2f9b32e753972d83087b9201a0073e208a0dd75 Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Mon, 10 Oct 2022 09:57:29 -0700 Subject: Use pre-installed python --- .github/workflows/build.yaml | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 3d66c02e75..bb0fb2efd8 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -33,21 +33,16 @@ jobs: repository: secondlife/build-variables ref: viewer path: .build-variables - - - name: Install python - uses: actions/setup-python@v4 - with: - python-version: 3.x - name: Install autobuild - run: pip install autobuild + run: pip3 install autobuild - name: Cache autobuild packages uses: actions/cache@v3 id: cache-installables with: path: .autobuild-installables - key: ${{ matrix.os }}-${{ matrix.arch }}-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} + key: ${{ matrix.os }}-${{ matrix.addrsize }}-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} - name: Build run: | -- cgit v1.2.3 From 7dc98ef96a871eed413a3fd5a578e3d8b143026d Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Mon, 10 Oct 2022 10:01:27 -0700 Subject: Build with VS2k22 --- .github/workflows/build.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index bb0fb2efd8..b58d426966 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -10,7 +10,7 @@ jobs: build: strategy: matrix: - os: [windows-2019, macos-11] + os: [windows-2022, macos-11] configuration: [RelWithDebInfoOS] addrsize: [64] include: @@ -46,5 +46,5 @@ jobs: - name: Build run: | - autobuild configure + autobuild configure -c ${{ matrix.configuration }} autobuild build --no-configure -- cgit v1.2.3 From 5fadc18c6c4d80f0338265b7e3361960c28b00d4 Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Mon, 10 Oct 2022 10:02:12 -0700 Subject: Also build win32 with VS2k22 --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index b58d426966..39e5d1597d 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -14,7 +14,7 @@ jobs: configuration: [RelWithDebInfoOS] addrsize: [64] include: - - os: windows-2019 + - os: windows-2022 configuration: RelWithDebInfoOS addrsize: 32 runs-on: ${{ matrix.os }} -- cgit v1.2.3 From 1f8671f3ac46f268dbf043753aad34489778b673 Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Mon, 10 Oct 2022 10:18:21 -0700 Subject: Perform source_environment --- .github/workflows/build.yaml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 39e5d1597d..80a1498fce 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -45,6 +45,10 @@ jobs: key: ${{ matrix.os }}-${{ matrix.addrsize }}-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} - name: Build + shell: bash run: | - autobuild configure -c ${{ matrix.configuration }} + autobuild --quiet source_environment > .env + source .env + + autobuild configure autobuild build --no-configure -- cgit v1.2.3 From 2e53204e774a24483653d8a4d4c31bff2d7a5f97 Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Mon, 10 Oct 2022 10:28:04 -0700 Subject: Explicitly set AUTOBUILD_VSVER --- .github/workflows/build.yaml | 1 + 1 file changed, 1 insertion(+) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 80a1498fce..e2abb3ce7c 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -23,6 +23,7 @@ jobs: AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} AUTOBUILD_INSTALLABLE_CACHE: ${{ github.workspace }}/.autobuild-installables AUTOBUILD_VARIABLES_FILE: ${{ github.workspace }}/.build-variables/variables + AUTOBUILD_VSVER: "170" steps: - name: Checkout code uses: actions/checkout@v3 -- cgit v1.2.3 From 82d76fc0a36d62ba34ce2b38b9e14a105c899066 Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Mon, 10 Oct 2022 10:44:04 -0700 Subject: Use cygwin --- .github/workflows/build.yaml | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index e2abb3ce7c..06aac0c8ab 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -35,6 +35,22 @@ jobs: ref: viewer path: .build-variables + - name: Install cygwin + if: runner.os == 'Windows' + uses: secondlife/setup-cygwin@v1 + + - name: Determine shell + id: shell + shell: bash + env: + WINDOWS: ${{ runner.os == 'Windows' }} + run: | + if [[ $WINDOWS == 'true' ]]; then + echo "::set-output name=shell::C:\cygwin64\bin\bash.exe --login --norc -eo pipefail -o igncr '{0}'" + else + echo '::set-output name=shell::bash' + fi + - name: Install autobuild run: pip3 install autobuild @@ -46,8 +62,12 @@ jobs: key: ${{ matrix.os }}-${{ matrix.addrsize }}-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} - name: Build - shell: bash + shell: ${{ steps.shell.outputs.shell }} + env: + WORKSPACE: ${{ github.workspace }} run: | + cd "$WORKSPACE" + autobuild --quiet source_environment > .env source .env -- cgit v1.2.3 From a05c7312c52c7261c2473a8163bf2a4b99b8b059 Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Mon, 10 Oct 2022 10:54:13 -0700 Subject: Call load_vsvars --- .github/workflows/build.yaml | 25 +++++-------------------- 1 file changed, 5 insertions(+), 20 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 06aac0c8ab..10b02783bc 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -35,22 +35,6 @@ jobs: ref: viewer path: .build-variables - - name: Install cygwin - if: runner.os == 'Windows' - uses: secondlife/setup-cygwin@v1 - - - name: Determine shell - id: shell - shell: bash - env: - WINDOWS: ${{ runner.os == 'Windows' }} - run: | - if [[ $WINDOWS == 'true' ]]; then - echo "::set-output name=shell::C:\cygwin64\bin\bash.exe --login --norc -eo pipefail -o igncr '{0}'" - else - echo '::set-output name=shell::bash' - fi - - name: Install autobuild run: pip3 install autobuild @@ -62,14 +46,15 @@ jobs: key: ${{ matrix.os }}-${{ matrix.addrsize }}-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} - name: Build - shell: ${{ steps.shell.outputs.shell }} + shell: bash env: - WORKSPACE: ${{ github.workspace }} + WINDOWS: ${{ runner.os == 'Windows' }} run: | - cd "$WORKSPACE" - autobuild --quiet source_environment > .env source .env + if [[ "$WINDOWS" == "true" ]]; then + load_vsvars + fi autobuild configure autobuild build --no-configure -- cgit v1.2.3 From 271e6e367e8a44b33e3dd1e77c2972774a1c1de9 Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Mon, 10 Oct 2022 11:23:05 -0700 Subject: Remove cygwin artifacts --- .github/workflows/build.yaml | 8 -------- 1 file changed, 8 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 10b02783bc..66ee864a77 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -47,14 +47,6 @@ jobs: - name: Build shell: bash - env: - WINDOWS: ${{ runner.os == 'Windows' }} run: | - autobuild --quiet source_environment > .env - source .env - if [[ "$WINDOWS" == "true" ]]; then - load_vsvars - fi - autobuild configure autobuild build --no-configure -- cgit v1.2.3 From 13ab3e3f0658a26ae8345a1b8916240bafae302b Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Tue, 11 Oct 2022 14:17:57 -0700 Subject: Omit macOS until I have a mac laptop --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 66ee864a77..f2bba6dc45 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -10,7 +10,7 @@ jobs: build: strategy: matrix: - os: [windows-2022, macos-11] + os: [windows-2022] configuration: [RelWithDebInfoOS] addrsize: [64] include: -- cgit v1.2.3 From 8d7cde22c31a59d0503230334b1d68e858364c9a Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Tue, 11 Oct 2022 15:10:04 -0700 Subject: Replace llbase with llsd module --- .github/workflows/build.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index f2bba6dc45..91788c4076 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -10,7 +10,7 @@ jobs: build: strategy: matrix: - os: [windows-2022] + os: [windows-2022, macos-11] configuration: [RelWithDebInfoOS] addrsize: [64] include: @@ -48,5 +48,6 @@ jobs: - name: Build shell: bash run: | + pip install llsd # Required by viewer tests autobuild configure autobuild build --no-configure -- cgit v1.2.3 From 6112e92b61c334d3c0656bacdea92690cea1a76b Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Wed, 12 Oct 2022 11:49:47 -0700 Subject: Upload installer, build Release, use large runner --- .github/workflows/build.yaml | 27 ++++++++++++++++++++++----- 1 file changed, 22 insertions(+), 5 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 91788c4076..d6916a4808 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -10,14 +10,14 @@ jobs: build: strategy: matrix: - os: [windows-2022, macos-11] - configuration: [RelWithDebInfoOS] + runner: [windows_2022_public] + configuration: [ReleaseOS] addrsize: [64] include: - - os: windows-2022 - configuration: RelWithDebInfoOS + - runner: windows_2022_public + configuration: ReleaseOS addrsize: 32 - runs-on: ${{ matrix.os }} + runs-on: ${{ matrix.runner }} env: AUTOBUILD_CONFIGURATION: ${{ matrix.configuration }} AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} @@ -45,9 +45,26 @@ jobs: path: .autobuild-installables key: ${{ matrix.os }}-${{ matrix.addrsize }}-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} + - name: Install windows dependencies + if: runner.os == 'Windows' + run: choco install nsis-unicode + - name: Build + id: build shell: bash run: | pip install llsd # Required by viewer tests autobuild configure autobuild build --no-configure + + installer_path=$(find ./build-*/newview/ | grep '_Setup\.exe') + installer_name="$(basename $installer_path)" + echo "::set-output name=installer_path::$installer_path" + echo "::set-output name=installer_name::$installer_name" + + - name: Upload installer + if: runner.os == 'Windows' + uses: actions/upload-artifact@v3 + with: + name: ${{ steps.build.outputs.installer_name }} + path: ${{ steps.build.outputs.installer_path }} -- cgit v1.2.3 From efb987f595d6749d42e3148bf0e071f5bafce450 Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Wed, 12 Oct 2022 12:59:12 -0700 Subject: Run on windows-2022-large --- .github/workflows/build.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index d6916a4808..e90448425b 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -10,14 +10,14 @@ jobs: build: strategy: matrix: - runner: [windows_2022_public] + runner: [windows-2022-large] configuration: [ReleaseOS] addrsize: [64] include: - - runner: windows_2022_public + - runner: windows-2022-large configuration: ReleaseOS addrsize: 32 - runs-on: ${{ matrix.runner }} + runs-on: [${{ matrix.runner }}] env: AUTOBUILD_CONFIGURATION: ${{ matrix.configuration }} AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} @@ -43,7 +43,7 @@ jobs: id: cache-installables with: path: .autobuild-installables - key: ${{ matrix.os }}-${{ matrix.addrsize }}-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} + key: ${{ matrix.runner }}-${{ matrix.addrsize }}-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} - name: Install windows dependencies if: runner.os == 'Windows' -- cgit v1.2.3 From 97f84f7051a318e8beb8abf02505a2b423ba9c72 Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Wed, 12 Oct 2022 13:15:18 -0700 Subject: Fix YAML syntax --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index e90448425b..1dc58a404a 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -17,7 +17,7 @@ jobs: - runner: windows-2022-large configuration: ReleaseOS addrsize: 32 - runs-on: [${{ matrix.runner }}] + runs-on: ${{ matrix.runner }} env: AUTOBUILD_CONFIGURATION: ${{ matrix.configuration }} AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} -- cgit v1.2.3 From aa85ed00f8536b7bbe66545576d2e1d96bee9d4e Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Wed, 12 Oct 2022 14:55:42 -0700 Subject: Run build with default runner --- .github/workflows/build.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 1dc58a404a..893bdfe3ca 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -10,11 +10,11 @@ jobs: build: strategy: matrix: - runner: [windows-2022-large] + runner: [windows-2022] configuration: [ReleaseOS] addrsize: [64] include: - - runner: windows-2022-large + - runner: windows-2022 configuration: ReleaseOS addrsize: 32 runs-on: ${{ matrix.runner }} -- cgit v1.2.3 From 937495863cd90f3f031a9c6d1d03fe02e70332e1 Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Wed, 12 Oct 2022 15:02:02 -0700 Subject: Build on 16-core machine --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 893bdfe3ca..6fa57b6d7c 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -10,7 +10,7 @@ jobs: build: strategy: matrix: - runner: [windows-2022] + runner: [windows-2022-public-002] configuration: [ReleaseOS] addrsize: [64] include: -- cgit v1.2.3 From 75499351dc0480bd62bf9fab5366fa3c668443da Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Wed, 12 Oct 2022 15:05:11 -0700 Subject: Build on 8-core machine --- .github/workflows/build.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 6fa57b6d7c..cef0d32519 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -10,11 +10,11 @@ jobs: build: strategy: matrix: - runner: [windows-2022-public-002] + runner: [windows-2022-public-003] configuration: [ReleaseOS] addrsize: [64] include: - - runner: windows-2022 + - runner: windows-2022-public-003 configuration: ReleaseOS addrsize: 32 runs-on: ${{ matrix.runner }} -- cgit v1.2.3 From 7c4a1668462a4c655f5c3875fcff863b96565c49 Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Wed, 12 Oct 2022 15:08:00 -0700 Subject: Add macOS build back --- .github/workflows/build.yaml | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index cef0d32519..57018823aa 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -10,11 +10,11 @@ jobs: build: strategy: matrix: - runner: [windows-2022-public-003] + runner: [windows-2022, macos-11] configuration: [ReleaseOS] addrsize: [64] include: - - runner: windows-2022-public-003 + - runner: windows-2022 configuration: ReleaseOS addrsize: 32 runs-on: ${{ matrix.runner }} @@ -52,15 +52,19 @@ jobs: - name: Build id: build shell: bash + env: + RUNNER_OS: ${{ runner.os }} run: | pip install llsd # Required by viewer tests autobuild configure autobuild build --no-configure - installer_path=$(find ./build-*/newview/ | grep '_Setup\.exe') - installer_name="$(basename $installer_path)" - echo "::set-output name=installer_path::$installer_path" - echo "::set-output name=installer_name::$installer_name" + if [[ "$RUNNER_OS" == "Windows" ]]; then + installer_path=$(find ./build-*/newview/ | grep '_Setup\.exe') + installer_name="$(basename $installer_path)" + echo "::set-output name=installer_path::$installer_path" + echo "::set-output name=installer_name::$installer_name" + fi - name: Upload installer if: runner.os == 'Windows' -- cgit v1.2.3 From d842eb988302bd4ea25433d6ce305360a0402b75 Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Wed, 12 Oct 2022 15:35:28 -0700 Subject: Build on 64-core machine --- .github/workflows/build.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 57018823aa..e6771e422b 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -10,11 +10,11 @@ jobs: build: strategy: matrix: - runner: [windows-2022, macos-11] + runner: [windows-2022-public-005] configuration: [ReleaseOS] addrsize: [64] include: - - runner: windows-2022 + - runner: windows-2022-public-005 configuration: ReleaseOS addrsize: 32 runs-on: ${{ matrix.runner }} -- cgit v1.2.3 From 3afde25ba81734b48cc557a257d91c7b9cc830f2 Mon Sep 17 00:00:00 2001 From: Signal Linden Date: Wed, 12 Oct 2022 16:04:04 -0700 Subject: Upload macos installer --- .github/workflows/build.yaml | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index e6771e422b..adaa7bbff7 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -10,11 +10,11 @@ jobs: build: strategy: matrix: - runner: [windows-2022-public-005] + runner: [windows-2022, macos-11] configuration: [ReleaseOS] addrsize: [64] include: - - runner: windows-2022-public-005 + - runner: windows-2022 configuration: ReleaseOS addrsize: 32 runs-on: ${{ matrix.runner }} @@ -43,7 +43,7 @@ jobs: id: cache-installables with: path: .autobuild-installables - key: ${{ matrix.runner }}-${{ matrix.addrsize }}-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} + key: ${{ runner.os }}-${{ matrix.addrsize }}-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} - name: Install windows dependencies if: runner.os == 'Windows' @@ -62,12 +62,14 @@ jobs: if [[ "$RUNNER_OS" == "Windows" ]]; then installer_path=$(find ./build-*/newview/ | grep '_Setup\.exe') installer_name="$(basename $installer_path)" - echo "::set-output name=installer_path::$installer_path" - echo "::set-output name=installer_name::$installer_name" + elif [[ "$RUNNER_OS" == "macOS" ]]; then + installer_path=$(find ./build-*/newview/ | grep '\.dmg') + installer_name="$(basename $installer_path)" fi + echo "::set-output name=installer_path::$installer_path" + echo "::set-output name=installer_name::$installer_name" - name: Upload installer - if: runner.os == 'Windows' uses: actions/upload-artifact@v3 with: name: ${{ steps.build.outputs.installer_name }} -- cgit v1.2.3 From 8871e8d732f6210c3c1b8ba0ca63d5ad816be4bf Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Fri, 24 Mar 2023 12:02:57 -0400 Subject: SL-18837: Try building Release viewer config on GH. --- .github/workflows/build.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index adaa7bbff7..b18e4bd9ca 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -11,11 +11,11 @@ jobs: strategy: matrix: runner: [windows-2022, macos-11] - configuration: [ReleaseOS] + configuration: [Release] addrsize: [64] include: - runner: windows-2022 - configuration: ReleaseOS + configuration: Release addrsize: 32 runs-on: ${{ matrix.runner }} env: -- cgit v1.2.3 From 1bdea0b46f5ef02535ac7fbaeb18c626df8a58ff Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Mon, 15 May 2023 11:36:08 -0400 Subject: SL-18837: AUTOBUILD_GITHUB_TOKEN to authenticate private packages. --- .github/workflows/build.yaml | 2 ++ 1 file changed, 2 insertions(+) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index b18e4bd9ca..b64f9b709f 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -21,6 +21,8 @@ jobs: env: AUTOBUILD_CONFIGURATION: ${{ matrix.configuration }} AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} + # authorizes fetching private constituent packages + AUTOBUILD_GITHUB_TOKEN: ${{ secrets.SHARED_AUTOBUILD_GITHUB_TOKEN }} AUTOBUILD_INSTALLABLE_CACHE: ${{ github.workspace }}/.autobuild-installables AUTOBUILD_VARIABLES_FILE: ${{ github.workspace }}/.build-variables/variables AUTOBUILD_VSVER: "170" -- cgit v1.2.3 From 7a7af9a3993dad65d2574d1408a4b64d2b1778d8 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Mon, 5 Jun 2023 14:35:10 -0400 Subject: SL-18837: pip install llsd as well as autobuild. The Python child processes used by llprocess_test.cpp and llleap_test.cpp need the Python llsd module to communicate with the C++ parent process. Also set LOGFAIL and BUGSPLAT_DB environment variables. --- .github/workflows/build.yaml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index b64f9b709f..f7062d83dc 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -26,6 +26,12 @@ jobs: AUTOBUILD_INSTALLABLE_CACHE: ${{ github.workspace }}/.autobuild-installables AUTOBUILD_VARIABLES_FILE: ${{ github.workspace }}/.build-variables/variables AUTOBUILD_VSVER: "170" + # 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 + # Ensure that viewer builds engage Bugsplat. + BUGSPLAT_DB: "SecondLife_Viewer_2018" steps: - name: Checkout code uses: actions/checkout@v3 @@ -38,7 +44,7 @@ jobs: path: .build-variables - name: Install autobuild - run: pip3 install autobuild + run: pip3 install autobuild llsd - name: Cache autobuild packages uses: actions/cache@v3 -- cgit v1.2.3 From aa906a9b7f8dbb24c97ba09852284f093cc4e525 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Wed, 7 Jun 2023 12:17:15 -0400 Subject: SL-18837: Try setting PY_PYTHON and PYLAUNCHER_DEBUG which should only affect Windows unit tests, but should hopefully improve our chances that Windows unit tests will succeed. --- .github/workflows/build.yaml | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index f7062d83dc..955493dd24 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -19,19 +19,24 @@ jobs: addrsize: 32 runs-on: ${{ matrix.runner }} env: - AUTOBUILD_CONFIGURATION: ${{ matrix.configuration }} AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} + AUTOBUILD_CONFIGURATION: ${{ matrix.configuration }} # authorizes fetching private constituent packages AUTOBUILD_GITHUB_TOKEN: ${{ secrets.SHARED_AUTOBUILD_GITHUB_TOKEN }} AUTOBUILD_INSTALLABLE_CACHE: ${{ github.workspace }}/.autobuild-installables AUTOBUILD_VARIABLES_FILE: ${{ github.workspace }}/.build-variables/variables AUTOBUILD_VSVER: "170" + # Ensure that viewer builds engage Bugsplat. + BUGSPLAT_DB: "SecondLife_Viewer_2018" # 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 - # Ensure that viewer builds engage Bugsplat. - BUGSPLAT_DB: "SecondLife_Viewer_2018" + # Force py.exe to select python3 rather than plain python (2) + PY_PYTHON: 3 + # but if unit tests fail to import llsd (i.e. wrong Python interpreter), + # make py.exe enumerate the possibilities and explain its choice + PYLAUNCHER_DEBUG: 1 steps: - name: Checkout code uses: actions/checkout@v3 -- cgit v1.2.3 From da72e958fe0c2ee88d39139f93c4d73897f711ee Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Wed, 7 Jun 2023 12:30:46 -0400 Subject: SL-18837: Quote integers used for environment variables --- .github/workflows/build.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 955493dd24..7df15f0668 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -33,10 +33,10 @@ jobs: # the individual test fails. LOGFAIL: DEBUG # Force py.exe to select python3 rather than plain python (2) - PY_PYTHON: 3 + PY_PYTHON: "3" # but if unit tests fail to import llsd (i.e. wrong Python interpreter), # make py.exe enumerate the possibilities and explain its choice - PYLAUNCHER_DEBUG: 1 + PYLAUNCHER_DEBUG: "1" steps: - name: Checkout code uses: actions/checkout@v3 -- cgit v1.2.3 From 104ae678a60a09df1e500f3ded920b5d515ee99a Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Wed, 7 Jun 2023 14:54:56 -0400 Subject: SL-18837: Tell py.exe to use Python 3.9 instead of 3.11 --- .github/workflows/build.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 7df15f0668..0d7943ec4a 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -32,8 +32,9 @@ jobs: # test-program log output at the specified level, but to display it only if # the individual test fails. LOGFAIL: DEBUG - # Force py.exe to select python3 rather than plain python (2) - PY_PYTHON: "3" + # Force py.exe to select python3.9 rather than the newest install 3.11, + # since the 'pip3' command below seems to be associated with Python 3.9 + PY_PYTHON: "3.9" # but if unit tests fail to import llsd (i.e. wrong Python interpreter), # make py.exe enumerate the possibilities and explain its choice PYLAUNCHER_DEBUG: "1" -- cgit v1.2.3 From 8140dd050e8eddcb8c513200fdca3adfa566853a Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Wed, 7 Jun 2023 16:31:11 -0400 Subject: SL-18837: Try to install llsd in the Python used by py.exe --- .github/workflows/build.yaml | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 0d7943ec4a..4c668d5e99 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -32,10 +32,7 @@ jobs: # test-program log output at the specified level, but to display it only if # the individual test fails. LOGFAIL: DEBUG - # Force py.exe to select python3.9 rather than the newest install 3.11, - # since the 'pip3' command below seems to be associated with Python 3.9 - PY_PYTHON: "3.9" - # but if unit tests fail to import llsd (i.e. wrong Python interpreter), + # if unit tests fail to import llsd (i.e. wrong Python interpreter), # make py.exe enumerate the possibilities and explain its choice PYLAUNCHER_DEBUG: "1" steps: @@ -61,7 +58,13 @@ jobs: - name: Install windows dependencies if: runner.os == 'Windows' - run: choco install nsis-unicode + # Use 'py -m pip' because our autobuild.xml specifies py.exe as + # PYTHON_EXECUTABLE, and we've tried all kinds of tricks to make pip + # install the 'llsd' package into the Python interpreter selected by + # py.exe. + run: | + choco install nsis-unicode + py -m pip install autobuild llsd - name: Build id: build @@ -69,7 +72,6 @@ jobs: env: RUNNER_OS: ${{ runner.os }} run: | - pip install llsd # Required by viewer tests autobuild configure autobuild build --no-configure -- cgit v1.2.3 From f57de07f73871bc7be6c338ea18893a494d104eb Mon Sep 17 00:00:00 2001 From: Brad Linden Date: Wed, 7 Jun 2023 13:46:29 -0700 Subject: Attempt to port some build.yaml improvements from DRTVWR-559 over to actions branch --- .github/workflows/build.yaml | 47 ++++++++++++++++++++++++++++++++------------ 1 file changed, 34 insertions(+), 13 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 4c668d5e99..7731a837e9 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -5,18 +5,22 @@ on: pull_request: push: branches: ["actions"] + tags: ["*"] jobs: build: strategy: matrix: - runner: [windows-2022, macos-11] + runner: [windows-large, macos-12-xl] configuration: [Release] addrsize: [64] + python-version: ["3.11"] include: - - runner: windows-2022 + - runner: windows-large configuration: Release addrsize: 32 + - runner: macos-12-xl + developer_dir: "/Applications/Xcode_14.0.1.app/Contents/Developer" runs-on: ${{ matrix.runner }} env: AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} @@ -26,6 +30,7 @@ jobs: AUTOBUILD_INSTALLABLE_CACHE: ${{ github.workspace }}/.autobuild-installables AUTOBUILD_VARIABLES_FILE: ${{ github.workspace }}/.build-variables/variables AUTOBUILD_VSVER: "170" + DEVELOPER_DIR: ${{ matrix.developer_dir }} # Ensure that viewer builds engage Bugsplat. BUGSPLAT_DB: "SecondLife_Viewer_2018" # Setting this variable directs Linden's TUT test driver code to capture @@ -35,9 +40,18 @@ jobs: # if unit tests fail to import llsd (i.e. wrong Python interpreter), # make py.exe enumerate the possibilities and explain its choice PYLAUNCHER_DEBUG: "1" + GIT_REF: ${{ github.head_ref || github.ref }} + LL_SKIP_REQUIRE_SYSROOT: 1 steps: - name: Checkout code uses: actions/checkout@v3 + with: + ref: ${{ github.event.pull_request.head.sha || github.sha }} + + - name: Setup python + uses: actions/setup-python@v4 + with: + python-version: ${{ matrix.python-version }} - name: Checkout build variables uses: actions/checkout@v3 @@ -55,16 +69,13 @@ jobs: with: path: .autobuild-installables key: ${{ runner.os }}-${{ matrix.addrsize }}-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} + restore-keys: | + ${{ runner.os }}-${{ matrix.addrsize }}-${{ matrix.configuration }}- + ${{ runner.os }}-${{ matrix.addrsize }}- - name: Install windows dependencies if: runner.os == 'Windows' - # Use 'py -m pip' because our autobuild.xml specifies py.exe as - # PYTHON_EXECUTABLE, and we've tried all kinds of tricks to make pip - # install the 'llsd' package into the Python interpreter selected by - # py.exe. - run: | - choco install nsis-unicode - py -m pip install autobuild llsd + run: choco install nsis-unicode - name: Build id: build @@ -72,9 +83,18 @@ jobs: env: RUNNER_OS: ${{ runner.os }} run: | - autobuild configure - autobuild build --no-configure + # On windows we need to point the build to the correct python + # as neither CMake's FindPython nor our custom Python.cmake module + # will resolve the correct interpreter location. + if [[ "$RUNNER_OS" == "Windows" ]]; then + export PYTHON="$(cygpath -m "$(which python)")" + echo "Python location: $PYTHON" + fi + autobuild configure -- -DVIEWER_CHANNEL="Second Life Test ${GIT_REF##*/}" + autobuild build --no-configure + + # Find artifacts if [[ "$RUNNER_OS" == "Windows" ]]; then installer_path=$(find ./build-*/newview/ | grep '_Setup\.exe') installer_name="$(basename $installer_path)" @@ -82,8 +102,9 @@ jobs: installer_path=$(find ./build-*/newview/ | grep '\.dmg') installer_name="$(basename $installer_path)" fi - echo "::set-output name=installer_path::$installer_path" - echo "::set-output name=installer_name::$installer_name" + + echo "installer_path=$installer_path" >> $GITHUB_OUTPUT + echo "installer_name=$installer_name" >> $GITHUB_OUTPUT - name: Upload installer uses: actions/upload-artifact@v3 -- cgit v1.2.3 From 68a57566b7520608ae242032788c3f472b54ad10 Mon Sep 17 00:00:00 2001 From: Brad Linden Date: Wed, 7 Jun 2023 16:28:11 -0700 Subject: SL-18837 fix win32 build warning about missing python-version setting --- .github/workflows/build.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 7731a837e9..d0f1b59ae6 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -19,6 +19,7 @@ jobs: - runner: windows-large configuration: Release addrsize: 32 + python-version: "3.11" - runner: macos-12-xl developer_dir: "/Applications/Xcode_14.0.1.app/Contents/Developer" runs-on: ${{ matrix.runner }} @@ -59,7 +60,7 @@ jobs: repository: secondlife/build-variables ref: viewer path: .build-variables - + - name: Install autobuild run: pip3 install autobuild llsd -- cgit v1.2.3 From bbd077bda8118c534d58cbcdc697875147cf09b7 Mon Sep 17 00:00:00 2001 From: Brad Linden Date: Fri, 9 Jun 2023 17:58:00 -0700 Subject: SL-18837 set build id based on github workflow run id --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index d0f1b59ae6..71b2a62618 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -92,7 +92,7 @@ jobs: echo "Python location: $PYTHON" fi - autobuild configure -- -DVIEWER_CHANNEL="Second Life Test ${GIT_REF##*/}" + autobuild configure --id "${{ github.run_id }}" -- -DVIEWER_CHANNEL="Second Life Test ${GIT_REF##*/}" autobuild build --no-configure # Find artifacts -- cgit v1.2.3 From ee453bc2d9df82dabf425ad61363dacf91338a48 Mon Sep 17 00:00:00 2001 From: Brad Linden Date: Thu, 22 Jun 2023 18:27:30 -0700 Subject: SL-18837 fixes for test failures. VERSION_BUILD is now too big to fit in 32 bits, and cpuid doesn't do what we expect under rosetta --- .github/workflows/build.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 71b2a62618..00dd7ed116 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -31,6 +31,7 @@ jobs: AUTOBUILD_INSTALLABLE_CACHE: ${{ github.workspace }}/.autobuild-installables AUTOBUILD_VARIABLES_FILE: ${{ github.workspace }}/.build-variables/variables AUTOBUILD_VSVER: "170" + AUTOBUILD_BUILD_ID: ${{ github.run_id }} DEVELOPER_DIR: ${{ matrix.developer_dir }} # Ensure that viewer builds engage Bugsplat. BUGSPLAT_DB: "SecondLife_Viewer_2018" @@ -93,7 +94,7 @@ jobs: fi autobuild configure --id "${{ github.run_id }}" -- -DVIEWER_CHANNEL="Second Life Test ${GIT_REF##*/}" - autobuild build --no-configure + autobuild build --no-configure # Find artifacts if [[ "$RUNNER_OS" == "Windows" ]]; then -- cgit v1.2.3 From 8a6247e34b1f77a248fc37b62852d4924df97d28 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 27 Jun 2023 17:28:58 -0400 Subject: SL-18837: Try doing necessary setup to run viewer's own build.sh. --- .github/workflows/build.yaml | 118 ++++++++++++++++++++++++++++++++++++++----- 1 file changed, 105 insertions(+), 13 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index d0f1b59ae6..fbb073968d 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -19,12 +19,12 @@ jobs: - runner: windows-large configuration: Release addrsize: 32 - python-version: "3.11" - runner: macos-12-xl developer_dir: "/Applications/Xcode_14.0.1.app/Contents/Developer" runs-on: ${{ matrix.runner }} env: AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} + AUTOBUILD_BUILD_ID: ${{ github.run_id }} AUTOBUILD_CONFIGURATION: ${{ matrix.configuration }} # authorizes fetching private constituent packages AUTOBUILD_GITHUB_TOKEN: ${{ secrets.SHARED_AUTOBUILD_GITHUB_TOKEN }} @@ -32,17 +32,23 @@ jobs: AUTOBUILD_VARIABLES_FILE: ${{ github.workspace }}/.build-variables/variables AUTOBUILD_VSVER: "170" DEVELOPER_DIR: ${{ matrix.developer_dir }} - # Ensure that viewer builds engage Bugsplat. - BUGSPLAT_DB: "SecondLife_Viewer_2018" + build_coverity: false + build_log_dir: ${{ github.workspace }}/.logs + build_secrets_checkout: ${{ github.workspace }}/.build-secrets + build_viewer: true + BUILDSCRIPTS_SHARED: ${{ github.workspace }}/.shared + BUILDSCRIPTS_SUPPORT_FUNCTIONS: ${{ github.workspace }}/.buildscripts/hg/bin/buildscripts_support_functions + git_hooks_checkout: ${{ github.workspace }}/.git-hooks + GIT_REF: ${{ github.head_ref || github.ref }} + LL_SKIP_REQUIRE_SYSROOT: 1 # 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 - # if unit tests fail to import llsd (i.e. wrong Python interpreter), - # make py.exe enumerate the possibilities and explain its choice - PYLAUNCHER_DEBUG: "1" - GIT_REF: ${{ github.head_ref || github.ref }} - LL_SKIP_REQUIRE_SYSROOT: 1 + master_message_template_checkout: ${{ github.workspace }}/.master-message-template + # Only set variants to the one configuration: don't let build.sh loop + # over variants, let GitHub distribute variants over multiple hosts. + variants: ${{ matrix.configuration }} steps: - name: Checkout code uses: actions/checkout@v3 @@ -54,6 +60,12 @@ jobs: with: python-version: ${{ matrix.python-version }} + - name: Checkout build secrets + uses: actions/checkout@v3 + with: + repository: secondlife/build-secrets + path: .build-secrets + - name: Checkout build variables uses: actions/checkout@v3 with: @@ -61,7 +73,25 @@ jobs: ref: viewer path: .build-variables - - name: Install autobuild + - name: Checkout buildscripts + uses: actions/checkout@v3 + with: + repository: secondlife/sling-buildscripts + path: .buildscripts + + - name: Checkout git-hooks + uses: actions/checkout@v3 + with: + repository: secondlife/git-hooks + path: .git-hooks + + - name: Checkout master-message-template + uses: actions/checkout@v3 + with: + repository: secondlife/master-message-template + path: .master-message-template + + - name: Install autobuild run: pip3 install autobuild llsd - name: Cache autobuild packages @@ -84,16 +114,78 @@ jobs: env: RUNNER_OS: ${{ runner.os }} run: | + # set up things the viewer's build.sh script expects + mkdir -p "$build_log_dir" + mkdir -p "$BUILDSCRIPTS_SHARED/packages/lib/python" + source "$BUILDSCRIPTS_SUPPORT_FUNCTIONS" + if [[ "$OSTYPE" == "cygwin" ]] + then + native_path() { cygpath --windows "$1"; } + shell_path() { cygpath --unix "$1"; } + else + native_path() { echo "$1"; } + shell_path() { echo "$1"; } + fi + initialize_build() + { + echo "initialize_build" + } + initialize_version() + { + export revision="$AUTOBUILD_BUILD_ID" + } + python_cmd() + { + if [[ "x${1:0:1}" == "x-" ]] # -m, -c, etc. + then # if $1 is a switch, don't try to twiddle paths + "$(shell_path "$PYTHON_COMMAND")" "$@" + elif [[ "$(basename "$1")" == "codeticket.py" ]] + then # ignore any attempt to contact codeticket + echo "## $@" + else # running a script at an explicit path: fix path for Python + local script="$1" + shift + "$(shell_path "$PYTHON_COMMAND")" "$(native_path "$script")" "$@" + fi + } + repo_branch() + { + git -C "$1" branch | grep '^* ' | cut -c 3- + } + record_dependencies_graph() + { + echo "TODO: generate and post dependency graph" + } + # Since we're not uploading to codeticket, DO NOT sleep for minutes. + sleep() + { + echo "Not sleeping for $1 seconds" + } + export -f native_path shell_path initialize_build initialize_version + export -f python_cmd repo_branch record_dependencies_graph sleep + export arch=$(uname | cut -b-6) + export AUTOBUILD="$(which autobuild)" + # Build with a tag like "Second Life Project Shiny:abcdef0" to get a + # viewer channel "Second Life Project Shiny" (ignoring ":hash", + # needed to disambiguate tags). + if [[ "${GIT_REF:0:12}" == "Second Life " ]] + then export viewer_channel="${GIT_REF%:*}" + else export viewer_channel="Second Life Test" + fi + # On windows we need to point the build to the correct python # as neither CMake's FindPython nor our custom Python.cmake module # will resolve the correct interpreter location. if [[ "$RUNNER_OS" == "Windows" ]]; then - export PYTHON="$(cygpath -m "$(which python)")" + export PYTHON="$(native_path "$(which python)")" echo "Python location: $PYTHON" + export PYTHON_COMMAND="$PYTHON" + else + export PYTHON_COMMAND="python3" fi + export PYTHON_COMMAND_NATIVE="$(native_path "$PYTHON_COMMAND")" - autobuild configure -- -DVIEWER_CHANNEL="Second Life Test ${GIT_REF##*/}" - autobuild build --no-configure + ./build.sh # Find artifacts if [[ "$RUNNER_OS" == "Windows" ]]; then @@ -106,7 +198,7 @@ jobs: echo "installer_path=$installer_path" >> $GITHUB_OUTPUT echo "installer_name=$installer_name" >> $GITHUB_OUTPUT - + - name: Upload installer uses: actions/upload-artifact@v3 with: -- cgit v1.2.3 From ce3508613bc1db3ad05758f452ffecf293fba643 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Wed, 28 Jun 2023 09:36:25 -0400 Subject: SL-18837: Include actions-build-sh branch in build trigger pushes. --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index fbb073968d..f7a3eb5e7d 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -4,7 +4,7 @@ on: workflow_dispatch: pull_request: push: - branches: ["actions"] + branches: ["actions", "actions-build-sh"] tags: ["*"] jobs: -- cgit v1.2.3 From 853cf3928cba51fe1e84a51316f9698c55ba4ad4 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Wed, 28 Jun 2023 16:44:03 -0400 Subject: SL-18837: Don't fetch (unmigrated) build-secrets, use GH secrets. --- .github/workflows/build.yaml | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index f7a3eb5e7d..dda5867a9f 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -4,7 +4,7 @@ on: workflow_dispatch: pull_request: push: - branches: ["actions", "actions-build-sh"] + branches: ["actions*"] tags: ["*"] jobs: @@ -19,6 +19,7 @@ jobs: - runner: windows-large configuration: Release addrsize: 32 + python-version: "3.11" - runner: macos-12-xl developer_dir: "/Applications/Xcode_14.0.1.app/Contents/Developer" runs-on: ${{ matrix.runner }} @@ -32,9 +33,12 @@ jobs: AUTOBUILD_VARIABLES_FILE: ${{ github.workspace }}/.build-variables/variables AUTOBUILD_VSVER: "170" DEVELOPER_DIR: ${{ matrix.developer_dir }} + # Ensure that viewer builds engage Bugsplat. + BUGSPLAT_DB: "SecondLife_Viewer_2018" + BUGSPLAT_PASS: ${{ secrets.BUGSPLAT_PASS }} + BUGSPLAT_USER: ${{ secrets.BUGSPLAT_USER }} build_coverity: false build_log_dir: ${{ github.workspace }}/.logs - build_secrets_checkout: ${{ github.workspace }}/.build-secrets build_viewer: true BUILDSCRIPTS_SHARED: ${{ github.workspace }}/.shared BUILDSCRIPTS_SUPPORT_FUNCTIONS: ${{ github.workspace }}/.buildscripts/hg/bin/buildscripts_support_functions @@ -60,12 +64,6 @@ jobs: with: python-version: ${{ matrix.python-version }} - - name: Checkout build secrets - uses: actions/checkout@v3 - with: - repository: secondlife/build-secrets - path: .build-secrets - - name: Checkout build variables uses: actions/checkout@v3 with: -- cgit v1.2.3 From d2294841b2df66f4e684b5eed1cae955cea21cf8 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Wed, 28 Jun 2023 16:58:32 -0400 Subject: SL-18837: Get buildscripts_support_functions from sling-buildscripts and use these variants for GitHub builds. --- .github/workflows/build.yaml | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index dda5867a9f..e7608657e3 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -41,7 +41,8 @@ jobs: build_log_dir: ${{ github.workspace }}/.logs build_viewer: true BUILDSCRIPTS_SHARED: ${{ github.workspace }}/.shared - BUILDSCRIPTS_SUPPORT_FUNCTIONS: ${{ github.workspace }}/.buildscripts/hg/bin/buildscripts_support_functions + # extracted and committed to viewer repo + BUILDSCRIPTS_SUPPORT_FUNCTIONS: ${{ github.workspace }}/buildscripts_support_functions git_hooks_checkout: ${{ github.workspace }}/.git-hooks GIT_REF: ${{ github.head_ref || github.ref }} LL_SKIP_REQUIRE_SYSROOT: 1 @@ -71,12 +72,6 @@ jobs: ref: viewer path: .build-variables - - name: Checkout buildscripts - uses: actions/checkout@v3 - with: - repository: secondlife/sling-buildscripts - path: .buildscripts - - name: Checkout git-hooks uses: actions/checkout@v3 with: -- cgit v1.2.3 From 41d937d2c03502c31c4366e75ebe5dbcf7b0d906 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Wed, 28 Jun 2023 17:15:06 -0400 Subject: SL-18837: Don't try to engage git-hooks explicitly at all. --- .github/workflows/build.yaml | 7 ------- 1 file changed, 7 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index e7608657e3..40759823ad 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -43,7 +43,6 @@ jobs: BUILDSCRIPTS_SHARED: ${{ github.workspace }}/.shared # extracted and committed to viewer repo BUILDSCRIPTS_SUPPORT_FUNCTIONS: ${{ github.workspace }}/buildscripts_support_functions - git_hooks_checkout: ${{ github.workspace }}/.git-hooks GIT_REF: ${{ github.head_ref || github.ref }} LL_SKIP_REQUIRE_SYSROOT: 1 # Setting this variable directs Linden's TUT test driver code to capture @@ -72,12 +71,6 @@ jobs: ref: viewer path: .build-variables - - name: Checkout git-hooks - uses: actions/checkout@v3 - with: - repository: secondlife/git-hooks - path: .git-hooks - - name: Checkout master-message-template uses: actions/checkout@v3 with: -- cgit v1.2.3 From 2ab14316488185496ec5c72fafcccd2ffdc43dfd Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 29 Jun 2023 09:08:41 -0400 Subject: SL-18837: Temporarily suppress Windows builds; add finalize function Also pretend novel arch value MINGW6 is really CYGWIN so we'll recognize it. --- .github/workflows/build.yaml | 30 +++++++++++++++++++++++------- 1 file changed, 23 insertions(+), 7 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 40759823ad..f5ed5ce2ae 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -13,15 +13,17 @@ jobs: matrix: runner: [windows-large, macos-12-xl] configuration: [Release] - addrsize: [64] + addrsize: [32,64] python-version: ["3.11"] - include: - - runner: windows-large - configuration: Release - addrsize: 32 - python-version: "3.11" + developer_dir: ["", "/Applications/Xcode_14.0.1.app/Contents/Developer"] + exclude: - runner: macos-12-xl + addrsize: 32 + - runner: windows-large developer_dir: "/Applications/Xcode_14.0.1.app/Contents/Developer" + ## nat 2023-06-29: until we've resolved the !@#$%! Windows Python + ## permissions problem, don't even bother running Windows builds. + - runner: windows-large runs-on: ${{ matrix.runner }} env: AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} @@ -112,6 +114,17 @@ jobs: native_path() { echo "$1"; } shell_path() { echo "$1"; } fi + finalize() + { + case "$1" in + true|0) + record_success "Build Succeeded" + ;; + *) + record_failure "Build Failed with $1" + ;; + esac + } initialize_build() { echo "initialize_build" @@ -147,9 +160,12 @@ jobs: { echo "Not sleeping for $1 seconds" } - export -f native_path shell_path initialize_build initialize_version + export -f native_path shell_path finalize initialize_build initialize_version export -f python_cmd repo_branch record_dependencies_graph sleep export arch=$(uname | cut -b-6) + # Surprise! GH Windows runner's MINGW6 is a $arch value we've never + # seen before, so numerous tests don't know about it. + [[ "$arch" == "MINGW6" ]] && arch=CYGWIN export AUTOBUILD="$(which autobuild)" # Build with a tag like "Second Life Project Shiny:abcdef0" to get a # viewer channel "Second Life Project Shiny" (ignoring ":hash", -- cgit v1.2.3 From d62e7039dafe4a49d548225203785eeda0eeb44a Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 29 Jun 2023 14:03:31 -0400 Subject: SL-18837: Install autobuild from source repo, not PyPI. Bug in autobuild 3.9.2? The TC viewer build can successfully build llphysicsextensions/autobuild-tpv.xml, but the previous GH actions build failed: "no configuration for Release found" despite -c Tpv. The difference seems to be that we used 'pip3 install autobuild' from PyPI, whereas the TC buildscripts setup clones secondlife/autobuild branch v3 and installs from that repo. --- .github/workflows/build.yaml | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index f5ed5ce2ae..18e07aae5e 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -28,6 +28,7 @@ jobs: env: AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} AUTOBUILD_BUILD_ID: ${{ github.run_id }} + autobuild_checkout: ${{ github.workspace}}/.autobuild AUTOBUILD_CONFIGURATION: ${{ matrix.configuration }} # authorizes fetching private constituent packages AUTOBUILD_GITHUB_TOKEN: ${{ secrets.SHARED_AUTOBUILD_GITHUB_TOKEN }} @@ -66,6 +67,19 @@ jobs: with: python-version: ${{ matrix.python-version }} + - name: Checkout autobuild + uses: actions/checkout@v3 + # Bug in autobuild 3.9.2? The TC viewer build can successfully build + # llphysicsextensions/autobuild-tpv.xml, but the previous GH actions + # build failed: "no configuration for Release found" despite -c Tpv. + # The difference seems to be that we used 'pip3 install autobuild' + # from PyPI, whereas the TC buildscripts setup clones + # secondlife/autobuild branch v3 and installs from that repo. + with: + repository: secondlife/autobuild + ref: v3 + path: .autobuild + - name: Checkout build variables uses: actions/checkout@v3 with: @@ -80,7 +94,10 @@ jobs: path: .master-message-template - name: Install autobuild - run: pip3 install autobuild llsd + shell: bash + run: | + pip3 install "$autobuild_checkout" + pip3 install llsd - name: Cache autobuild packages uses: actions/cache@v3 -- cgit v1.2.3 From 153f5cdb9f060806472d76c7b57837cdbdf21b68 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Fri, 30 Jun 2023 10:44:17 -0400 Subject: SL-18837: Revert "Install autobuild from source repo, not PyPI." That doesn't seem to be the distinction between TC builds and GH builds. Instead, we'll try unsetting AUTOBUILD_CONFIGURATION. This reverts commit d62e7039dafe4a49d548225203785eeda0eeb44a. --- .github/workflows/build.yaml | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 18e07aae5e..f5ed5ce2ae 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -28,7 +28,6 @@ jobs: env: AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} AUTOBUILD_BUILD_ID: ${{ github.run_id }} - autobuild_checkout: ${{ github.workspace}}/.autobuild AUTOBUILD_CONFIGURATION: ${{ matrix.configuration }} # authorizes fetching private constituent packages AUTOBUILD_GITHUB_TOKEN: ${{ secrets.SHARED_AUTOBUILD_GITHUB_TOKEN }} @@ -67,19 +66,6 @@ jobs: with: python-version: ${{ matrix.python-version }} - - name: Checkout autobuild - uses: actions/checkout@v3 - # Bug in autobuild 3.9.2? The TC viewer build can successfully build - # llphysicsextensions/autobuild-tpv.xml, but the previous GH actions - # build failed: "no configuration for Release found" despite -c Tpv. - # The difference seems to be that we used 'pip3 install autobuild' - # from PyPI, whereas the TC buildscripts setup clones - # secondlife/autobuild branch v3 and installs from that repo. - with: - repository: secondlife/autobuild - ref: v3 - path: .autobuild - - name: Checkout build variables uses: actions/checkout@v3 with: @@ -94,10 +80,7 @@ jobs: path: .master-message-template - name: Install autobuild - shell: bash - run: | - pip3 install "$autobuild_checkout" - pip3 install llsd + run: pip3 install autobuild llsd - name: Cache autobuild packages uses: actions/cache@v3 -- cgit v1.2.3 From 5f1de35f39aa3a13f6dbb98b117bb6897c792910 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Fri, 30 Jun 2023 10:51:03 -0400 Subject: SL-18837: Unset AUTOBUILD_CONFIGURATION. We suspect that autobuild incorrectly prioritizes AUTOBUILD_CONFIGURATION over its command-line -c switch. The autobuild command to build the TPV package for llphysicsextensions specifies -c Tpv (the configuration in the specified config file), but with AUTOBUILD_CONFIGURATION=Release set, autobuild fails: "ERROR: no configuration for build configuration 'Release' found" --- .github/workflows/build.yaml | 1 - 1 file changed, 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index f5ed5ce2ae..a3d5269d5a 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -28,7 +28,6 @@ jobs: env: AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} AUTOBUILD_BUILD_ID: ${{ github.run_id }} - AUTOBUILD_CONFIGURATION: ${{ matrix.configuration }} # authorizes fetching private constituent packages AUTOBUILD_GITHUB_TOKEN: ${{ secrets.SHARED_AUTOBUILD_GITHUB_TOKEN }} AUTOBUILD_INSTALLABLE_CACHE: ${{ github.workspace }}/.autobuild-installables -- cgit v1.2.3 From ca5f3e3b35dedd3674df91ec5aabae1e6bab4acd Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 6 Jul 2023 17:29:40 -0400 Subject: SL-18837: Add addoutput, addarrayoutput functions to build.sh and use them instead of codeticket addoutput to pass GitHub xxx_name, xxx_path outputs to build.yaml. Add upload steps to build.yaml to try to upload build products identified in build.sh. --- .github/workflows/build.yaml | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index a3d5269d5a..cd82fe5a54 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -205,3 +205,41 @@ jobs: with: name: ${{ steps.build.outputs.installer_name }} path: ${{ steps.build.outputs.installer_path }} + + - name: Upload metadata + uses: actions/upload-artifact@v3 + with: + name: ${{ steps.build.outputs.autobuild_package_name }} + path: ${{ steps.build.outputs.autobuild_package_path }} + + - name: Upload version + uses: actions/upload-artifact@v3 + with: + name: viewer_version.txt + path: ${{ steps.build.outputs.viewer_version_name }} + + - name: Upload Doxygen Log + if: steps.build.outputs.doxygen_log_path + uses: actions/upload-artifact@v3 + with: + name: ${{ steps.build.outputs.doxygen_log_name }} + path: ${{ steps.build.outputs.doxygen_log_path }} + + - name: Upload Doxygen Tarball + if: steps.build.outputs.doxygen_tarball_path + uses: actions/upload-artifact@v3 + with: + name: ${{ steps.build.outputs.doxygen_tarball_name }} + path: ${{ steps.build.outputs.doxygen_tarball_path }} + + - name: Upload viewer package installers + uses: actions/upload-artifact@v3 + with: + name: ${{ steps.build.outputs.installer_name }} + path: ${{ steps.build.outputs.packages }} + + - name: Upload symbol file + uses: actions/upload-artifact@v3 + with: + name: ${{ steps.build.outputs.symbolfile_name }} + path: ${{ steps.build.outputs.symbolfile_path }} -- cgit v1.2.3 From 07b47160f1d93c1ed0ee5e61c0c8330f66e20857 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 6 Jul 2023 17:38:58 -0400 Subject: SL-18837: Ding Dong, 32-bit is dead! --- .github/workflows/build.yaml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index cd82fe5a54..e55a799825 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -13,12 +13,10 @@ jobs: matrix: runner: [windows-large, macos-12-xl] configuration: [Release] - addrsize: [32,64] + addrsize: [64] python-version: ["3.11"] developer_dir: ["", "/Applications/Xcode_14.0.1.app/Contents/Developer"] exclude: - - runner: macos-12-xl - addrsize: 32 - runner: windows-large developer_dir: "/Applications/Xcode_14.0.1.app/Contents/Developer" ## nat 2023-06-29: until we've resolved the !@#$%! Windows Python -- cgit v1.2.3 From 2b1a3cf9cdb4cde92d14217b743545eccdcb2991 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Fri, 7 Jul 2023 06:38:03 -0400 Subject: SL-18837: Use multi-line GitHub outputs to upload artifacts. Having observed installer upload failures, I discovered the warning in actions/upload-artifact/README.md about multiple concurrent jobs trying to post the same pathname to the same artifact name. Try to disambiguate artifacts not only for different platforms, but for different jobs running on the same platform. This change also reflects my understanding that an artifact is (effectively) a distinct zip file that can contain multiple uploaded files. Because we'll want to download metadata without having to download enormous installers, create a separate metadata artifact per platform. Similarly, symbol files can get large: use a third distinct artifact for symbol files. But with those artifacts defined, leverage actions/upload-artifact's ability to upload multiple paths to the same artifact. In build.sh, define bash arrays installer, metadata, symbolfile and set up so that, on exit, each is written to a GITHUB_OUTPUT variable with the corresponding name. This involves a little magic to get macOS bash 3 to indirectly access an array. These multi-line output variables are then used to drive the upload-artifact step for each of the defined artifacts. --- .github/workflows/build.yaml | 80 +++++++++++++++++++------------------------- 1 file changed, 35 insertions(+), 45 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index e55a799825..574a83246c 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -186,58 +186,48 @@ jobs: ./build.sh - # Find artifacts - if [[ "$RUNNER_OS" == "Windows" ]]; then - installer_path=$(find ./build-*/newview/ | grep '_Setup\.exe') - installer_name="$(basename $installer_path)" - elif [[ "$RUNNER_OS" == "macOS" ]]; then - installer_path=$(find ./build-*/newview/ | grep '\.dmg') - installer_name="$(basename $installer_path)" - fi - - echo "installer_path=$installer_path" >> $GITHUB_OUTPUT - echo "installer_name=$installer_name" >> $GITHUB_OUTPUT + # 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. + # Since the matrix above can run multiple builds on the same + # platform, we must disambiguate on more than the platform name. + # If we were still running Windows 32-bit builds, we'd need to + # qualify the artifact with bit width. + # DEVELOPER_DIR="/Applications/Xcode_14.0.1.app/Contents/Developer" + # or the empty string, so this produces dev="Xcode_14.0.1" or ".". + dev="$(basename "$(dirname "$(dirname "$DEVELOPER_DIR")")" .app)" + artifact="$RUNNER_OS $dev" + # For empty DEVELOPER_DIR, dev is ".", so artifact can end up with + # appended " ." -- ditch that if present. + artifact="${artifact% .}" + echo "artifact=$artifact" >> $GITHUB_OUTPUT - name: Upload installer uses: actions/upload-artifact@v3 with: - name: ${{ steps.build.outputs.installer_name }} - path: ${{ steps.build.outputs.installer_path }} - - - name: Upload metadata - uses: actions/upload-artifact@v3 - with: - name: ${{ steps.build.outputs.autobuild_package_name }} - path: ${{ steps.build.outputs.autobuild_package_path }} - - - name: Upload version - uses: actions/upload-artifact@v3 - with: - name: viewer_version.txt - path: ${{ steps.build.outputs.viewer_version_name }} + name: "${{ steps.build.outputs.artifact }} installer" + # emitted by build.sh, possibly multiple lines + path: | + ${{ steps.build.outputs.installer }} - - name: Upload Doxygen Log - if: steps.build.outputs.doxygen_log_path - uses: actions/upload-artifact@v3 - with: - name: ${{ steps.build.outputs.doxygen_log_name }} - path: ${{ steps.build.outputs.doxygen_log_path }} - - - name: Upload Doxygen Tarball - if: steps.build.outputs.doxygen_tarball_path - uses: actions/upload-artifact@v3 - with: - name: ${{ steps.build.outputs.doxygen_tarball_name }} - path: ${{ steps.build.outputs.doxygen_tarball_path }} - - - name: Upload viewer package installers + # The other upload of nontrivial size is the symbol file. Use a distinct + # artifact for that too. + - name: Upload symbol file uses: actions/upload-artifact@v3 with: - name: ${{ steps.build.outputs.installer_name }} - path: ${{ steps.build.outputs.packages }} + name: "${{ steps.build.outputs.artifact }} symbols" + path: | + ${{ steps.build.outputs.symbolfile }} - - name: Upload symbol file + - name: Upload metadata uses: actions/upload-artifact@v3 with: - name: ${{ steps.build.outputs.symbolfile_name }} - path: ${{ steps.build.outputs.symbolfile_path }} + name: "${{ steps.build.outputs.artifact }} metadata" + # emitted by build.sh, possibly multiple lines + path: | + ${{ steps.build.outputs.metadata }} -- cgit v1.2.3 From f54c1215676f26480d88b4588bb0eeb9c05f50d9 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Fri, 7 Jul 2023 10:06:02 -0400 Subject: SL-18837: Try putting generated Python scripts in RUNNER_TEMP dir. The claim is that the Windows Python interpreter is integrated somehow with the OS such that a command line that tries to run Python with a script that "looks suspicious" (i.e. in a system temp directory) fails with "Access denied" without even loading the interpreter. At least that theory would explain the "Access denied" errors we've been getting trying to run Python scripts generated into the system temp directory by our integration tests. Our hope is that generating such scripts into the GitHub RUNNER_TEMP directory will work better. As this test is specific to Windows, don't even bother running Mac builds. --- .github/workflows/build.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 574a83246c..dc8f9f15cd 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -19,9 +19,9 @@ jobs: exclude: - runner: windows-large developer_dir: "/Applications/Xcode_14.0.1.app/Contents/Developer" - ## nat 2023-06-29: until we've resolved the !@#$%! Windows Python - ## permissions problem, don't even bother running Windows builds. - - runner: windows-large + ## nat 2023-07-07: trying to resolve the Windows Python permissions + ## problem; don't bother running Mac builds. + - runner: macos-12-xl runs-on: ${{ matrix.runner }} env: AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} -- cgit v1.2.3 From 1ec6c744048a2905b0f2bf83f035a8fb8798dbdf Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Sat, 8 Jul 2023 11:08:16 -0400 Subject: SL-18837: Set APR_LOG once for the whole job instead of a new value for each LLProcess::create() invocation. Since the internal apr_log() function only looks at APR_LOG once per process, the first test (which succeeded, hence no log file dump) left the log file open with that same original pathname. Resetting the APR_LOG environment variable for subsequent runs only made the new code in llprocess_test look for files that were never created. --- .github/workflows/build.yaml | 1 + 1 file changed, 1 insertion(+) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index dc8f9f15cd..f585fa1c39 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -24,6 +24,7 @@ jobs: - runner: macos-12-xl runs-on: ${{ matrix.runner }} env: + APR_LOG: "$RUNNER_TEMP/apr.log" AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} AUTOBUILD_BUILD_ID: ${{ github.run_id }} # authorizes fetching private constituent packages -- cgit v1.2.3 From 0d4e5b6bf8804806260c8295456410bca63c8874 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Sat, 8 Jul 2023 13:12:25 -0400 Subject: SL-18837: Use runner.temp rather than $RUNNER_TEMP. --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index f585fa1c39..729b0c54e5 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -24,7 +24,7 @@ jobs: - runner: macos-12-xl runs-on: ${{ matrix.runner }} env: - APR_LOG: "$RUNNER_TEMP/apr.log" + APR_LOG: "${{ runner.temp }}/apr.log" AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} AUTOBUILD_BUILD_ID: ${{ github.run_id }} # authorizes fetching private constituent packages -- cgit v1.2.3 From eff1c0b55c075eca88690b3547f58eb57c789b85 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Sat, 8 Jul 2023 13:15:01 -0400 Subject: SL-18837: Set APR_LOG within build step, not at job level. --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 729b0c54e5..c0bc5f30e1 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -24,7 +24,6 @@ jobs: - runner: macos-12-xl runs-on: ${{ matrix.runner }} env: - APR_LOG: "${{ runner.temp }}/apr.log" AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} AUTOBUILD_BUILD_ID: ${{ github.run_id }} # authorizes fetching private constituent packages @@ -160,6 +159,7 @@ jobs: } export -f native_path shell_path finalize initialize_build initialize_version export -f python_cmd repo_branch record_dependencies_graph sleep + export APR_LOG="${RUNNER_TEMP}/apr.log" export arch=$(uname | cut -b-6) # Surprise! GH Windows runner's MINGW6 is a $arch value we've never # seen before, so numerous tests don't know about it. -- cgit v1.2.3 From ca4288edaa226507e2a44182689a167bd4ea7948 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Sat, 8 Jul 2023 13:35:53 -0400 Subject: SL-18837: Try running just 'python' for Windows integration tests. --- .github/workflows/build.yaml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index c0bc5f30e1..47b1f421e5 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -177,7 +177,11 @@ jobs: # as neither CMake's FindPython nor our custom Python.cmake module # will resolve the correct interpreter location. if [[ "$RUNNER_OS" == "Windows" ]]; then - export PYTHON="$(native_path "$(which python)")" + ##export PYTHON="$(native_path "$(which python)")" + ## Weirdly, on GitHub's Windows runners, the integration test that + ## runs just 'python' succeeds while the integration tests that + ## run the full path to the .exe fail with "Access is denied." + export PYTHON=python echo "Python location: $PYTHON" export PYTHON_COMMAND="$PYTHON" else -- cgit v1.2.3 From 7dc6211ad5ea83685a35c6fff740278343aa8b9d Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Sat, 8 Jul 2023 14:08:16 -0400 Subject: SL-18837: Force llprocess_test and llleap_test to use just 'python'. On GitHub Windows runners, trying to make build.yaml set PYTHON=python in the environment doesn't work: integration tests still fail with "Access is denied" because they're still trying to execute the interpreter's full pathname. Instead, make llprocess_test and llleap_test detect the case of GitHub Windows and override the environment variable PYTHON with a baked-in string constant "python". --- .github/workflows/build.yaml | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 47b1f421e5..c0bc5f30e1 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -177,11 +177,7 @@ jobs: # as neither CMake's FindPython nor our custom Python.cmake module # will resolve the correct interpreter location. if [[ "$RUNNER_OS" == "Windows" ]]; then - ##export PYTHON="$(native_path "$(which python)")" - ## Weirdly, on GitHub's Windows runners, the integration test that - ## runs just 'python' succeeds while the integration tests that - ## run the full path to the .exe fail with "Access is denied." - export PYTHON=python + export PYTHON="$(native_path "$(which python)")" echo "Python location: $PYTHON" export PYTHON_COMMAND="$PYTHON" else -- cgit v1.2.3 From d8292a629149c2cfdda6ae9df4e87aa117153c21 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Mon, 10 Jul 2023 14:46:14 -0400 Subject: SL-18837: Disable APR_LOG for now, but leave notes for the future. --- .github/workflows/build.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index c0bc5f30e1..dc5fef4177 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -159,7 +159,8 @@ jobs: } export -f native_path shell_path finalize initialize_build initialize_version export -f python_cmd repo_branch record_dependencies_graph sleep - export APR_LOG="${RUNNER_TEMP}/apr.log" + ## Useful for diagnosing Windows LLProcess/LLLeap test failures + ##export APR_LOG="${RUNNER_TEMP}/apr.log" export arch=$(uname | cut -b-6) # Surprise! GH Windows runner's MINGW6 is a $arch value we've never # seen before, so numerous tests don't know about it. -- cgit v1.2.3 From 0998d46f47927badbd3f7d3a4b7a83a11896a5c9 Mon Sep 17 00:00:00 2001 From: Brad Linden Date: Fri, 14 Jul 2023 18:04:14 -0700 Subject: Fix "intermittent" llrand unit test failure on windows on DRTVWR-578. we must return less than 1.0 when rand() returns RAND_MAX also, disable 32 bit build now that we have deprecated it. https://community.secondlife.com/blogs/entry/13464-end-of-support-for-second-life-32-bit-windows-viewer-and-updated-minimum-system-requirements-for-macos-to-1013/ --- .github/workflows/build.yaml | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 00dd7ed116..3e0330d77b 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -13,18 +13,14 @@ jobs: matrix: runner: [windows-large, macos-12-xl] configuration: [Release] - addrsize: [64] python-version: ["3.11"] include: - - runner: windows-large - configuration: Release - addrsize: 32 - python-version: "3.11" - runner: macos-12-xl developer_dir: "/Applications/Xcode_14.0.1.app/Contents/Developer" + python-version: "3.11" runs-on: ${{ matrix.runner }} env: - AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} + AUTOBUILD_ADDRSIZE: 64 AUTOBUILD_CONFIGURATION: ${{ matrix.configuration }} # authorizes fetching private constituent packages AUTOBUILD_GITHUB_TOKEN: ${{ secrets.SHARED_AUTOBUILD_GITHUB_TOKEN }} -- cgit v1.2.3 From 54f9ca5404c05a4031c1c12caf24b88048704cbd Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Mon, 17 Jul 2023 15:41:26 -0400 Subject: SL-18837: Merge branch 'actions' into actions-build-sh --- .github/workflows/build.yaml | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index dc5fef4177..1cc29d95ea 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -13,19 +13,15 @@ jobs: matrix: runner: [windows-large, macos-12-xl] configuration: [Release] - addrsize: [64] python-version: ["3.11"] - developer_dir: ["", "/Applications/Xcode_14.0.1.app/Contents/Developer"] - exclude: - - runner: windows-large - developer_dir: "/Applications/Xcode_14.0.1.app/Contents/Developer" - ## nat 2023-07-07: trying to resolve the Windows Python permissions - ## problem; don't bother running Mac builds. + include: - runner: macos-12-xl + developer_dir: "/Applications/Xcode_14.0.1.app/Contents/Developer" runs-on: ${{ matrix.runner }} env: - AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} + AUTOBUILD_ADDRSIZE: 64 AUTOBUILD_BUILD_ID: ${{ github.run_id }} + AUTOBUILD_CONFIGURATION: ${{ matrix.configuration }} # authorizes fetching private constituent packages AUTOBUILD_GITHUB_TOKEN: ${{ secrets.SHARED_AUTOBUILD_GITHUB_TOKEN }} AUTOBUILD_INSTALLABLE_CACHE: ${{ github.workspace }}/.autobuild-installables -- cgit v1.2.3 From 479fa3e1964d792ba9483b21b272d52f377f48a2 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 18 Jul 2023 09:56:11 -0400 Subject: SL-18837: Conditionally upload llphysicsextensions-tpv package but only when building viewer-private. Also re-fix SL-19942 workaround by deleting AUTOBUILD_CONFIGURATION before trying to build llphysicsextensions-tpv. --- .github/workflows/build.yaml | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 1cc29d95ea..f0c7fdd496 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -192,18 +192,11 @@ jobs: # 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. - # Since the matrix above can run multiple builds on the same + # If the matrix above can run multiple builds on the same # platform, we must disambiguate on more than the platform name. - # If we were still running Windows 32-bit builds, we'd need to + # e.g. if we were still running Windows 32-bit builds, we'd need to # qualify the artifact with bit width. - # DEVELOPER_DIR="/Applications/Xcode_14.0.1.app/Contents/Developer" - # or the empty string, so this produces dev="Xcode_14.0.1" or ".". - dev="$(basename "$(dirname "$(dirname "$DEVELOPER_DIR")")" .app)" - artifact="$RUNNER_OS $dev" - # For empty DEVELOPER_DIR, dev is ".", so artifact can end up with - # appended " ." -- ditch that if present. - artifact="${artifact% .}" - echo "artifact=$artifact" >> $GITHUB_OUTPUT + echo "artifact=$RUNNER_OS" >> $GITHUB_OUTPUT - name: Upload installer uses: actions/upload-artifact@v3 @@ -229,3 +222,13 @@ jobs: # emitted by build.sh, possibly multiple lines path: | ${{ steps.build.outputs.metadata }} + + - name: Upload physics package + uses: actions/upload-artifact@v3 + # should only be set for viewer-private + if: steps.build.outputs.physicstpv + with: + name: "${{ steps.build.outputs.artifact }} physics" + # emitted by build.sh, zero or one lines + path: | + ${{ steps.build.outputs.physicstpv }} -- cgit v1.2.3 From 6fd46b85f516d47626090e6c363b978519b3e1a3 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 18 Jul 2023 10:54:12 -0400 Subject: SL-18837: Detect msys bash as well as cygwin for native_path et al. --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index f0c7fdd496..9b56d800f7 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -99,7 +99,7 @@ jobs: mkdir -p "$build_log_dir" mkdir -p "$BUILDSCRIPTS_SHARED/packages/lib/python" source "$BUILDSCRIPTS_SUPPORT_FUNCTIONS" - if [[ "$OSTYPE" == "cygwin" ]] + if [[ "$OSTYPE" =~ cygwin|msys ]] then native_path() { cygpath --windows "$1"; } shell_path() { cygpath --unix "$1"; } -- cgit v1.2.3 From dcb1403661f227b16fd5d5622c7e1a692b461c5b Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 18 Jul 2023 11:41:32 -0400 Subject: SL-18837: Re-delete redundant matrix.include python-version. This clarifies that the matrix.include entry is intended to supplement an existing runner configuration, rather than adding a new configuration for the same runner. --- .github/workflows/build.yaml | 1 - 1 file changed, 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index a3097c9b36..9b56d800f7 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -17,7 +17,6 @@ jobs: include: - runner: macos-12-xl developer_dir: "/Applications/Xcode_14.0.1.app/Contents/Developer" - python-version: "3.11" runs-on: ${{ matrix.runner }} env: AUTOBUILD_ADDRSIZE: 64 -- cgit v1.2.3 From 2b97587a14c596514cdea2f2c624445e272cc127 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 18 Jul 2023 15:25:09 -0400 Subject: SL-18837: Try to post installer and metadata for GH viewer release. --- .github/release.yaml | 18 ++++++++++++++++++ .github/workflows/build.yaml | 12 ++++++++++++ 2 files changed, 30 insertions(+) create mode 100644 .github/release.yaml (limited to '.github') diff --git a/.github/release.yaml b/.github/release.yaml new file mode 100644 index 0000000000..0f4884c944 --- /dev/null +++ b/.github/release.yaml @@ -0,0 +1,18 @@ +changelog: + exclude: + labels: + - ignore-for-release + authors: + - dependabot + categories: + - title: Breaking Changes 🛠 + labels: + - semver-major + - breaking-change + - title: New Features 🎉 + labels: + - semver-minor + - enhancement + - title: Other Changes + labels: + - '*' diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 9b56d800f7..517efa6fc6 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -232,3 +232,15 @@ jobs: # emitted by build.sh, zero or one lines path: | ${{ steps.build.outputs.physicstpv }} + + release: + needs: build + runs-on: [ubuntu-latest] + if: startsWith(github.ref, 'refs/tags/v') + steps: + - uses: softprops/action-gh-release@v1 + with: + generate_release_notes: true + files: | + ${{ steps.build.outputs.installer }} + ${{ steps.build.outputs.metadata }} -- cgit v1.2.3 From 0d4228b55aa786c3cbe0512acc5f0d9f91c6b87b Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 18 Jul 2023 15:38:44 -0400 Subject: SL-18837: Use secondlife -3p/action-gh-release instead of the original softprops/action-gh-release repo, because organization rules forbid directly using the softprops repo. --- .github/workflows/build.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 517efa6fc6..9930762167 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -238,7 +238,8 @@ jobs: runs-on: [ubuntu-latest] if: startsWith(github.ref, 'refs/tags/v') steps: - - uses: softprops/action-gh-release@v1 + # forked from softprops/action-gh-release + - uses: secondlife-3p/action-gh-release@v1 with: generate_release_notes: true files: | -- cgit v1.2.3 From 7cca3506b66cd6cbc04e795d84b1991b42b224d6 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Fri, 21 Jul 2023 14:02:00 -0400 Subject: SL-18837: Try triggering GH release for tag like "Second Life "... --- .github/workflows/build.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 9930762167..35db50ef00 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -96,6 +96,7 @@ jobs: RUNNER_OS: ${{ runner.os }} run: | # set up things the viewer's build.sh script expects + set -x mkdir -p "$build_log_dir" mkdir -p "$BUILDSCRIPTS_SHARED/packages/lib/python" source "$BUILDSCRIPTS_SUPPORT_FUNCTIONS" @@ -165,7 +166,7 @@ jobs: # Build with a tag like "Second Life Project Shiny:abcdef0" to get a # viewer channel "Second Life Project Shiny" (ignoring ":hash", # needed to disambiguate tags). - if [[ "${GIT_REF:0:12}" == "Second Life " ]] + if [[ "$GITHUB_REF_TYPE" == "tag" && "${GITHUB_REF_NAME:0:12}" == "Second Life " ]] then export viewer_channel="${GIT_REF%:*}" else export viewer_channel="Second Life Test" fi @@ -236,7 +237,7 @@ jobs: release: needs: build runs-on: [ubuntu-latest] - if: startsWith(github.ref, 'refs/tags/v') + if: github.ref_type == 'tag' && startsWith(github.ref_name, 'Second Life ') steps: # forked from softprops/action-gh-release - uses: secondlife-3p/action-gh-release@v1 -- cgit v1.2.3 From 6605403661da96dde7ff6dfb6bcfa87fc087ff0e Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Fri, 21 Jul 2023 15:24:11 -0400 Subject: SL-18837: Tags can't have spaces or colons. Look for valid ones. --- .github/workflows/build.yaml | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 35db50ef00..4262d3b6ef 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -163,11 +163,12 @@ jobs: # seen before, so numerous tests don't know about it. [[ "$arch" == "MINGW6" ]] && arch=CYGWIN export AUTOBUILD="$(which autobuild)" - # Build with a tag like "Second Life Project Shiny:abcdef0" to get a - # viewer channel "Second Life Project Shiny" (ignoring ":hash", + # Build with a tag like "Second_Life_Project_Shiny#abcdef0" to get a + # viewer channel "Second Life Project Shiny" (ignoring "#hash", # needed to disambiguate tags). - if [[ "$GITHUB_REF_TYPE" == "tag" && "${GITHUB_REF_NAME:0:12}" == "Second Life " ]] - then export viewer_channel="${GIT_REF%:*}" + if [[ "$GITHUB_REF_TYPE" == "tag" && "${GITHUB_REF_NAME:0:12}" == "Second_Life_" ]] + then viewer_channel="${GITHUB_REF_NAME%#*}" + export viewer_channel="${viewer_channel//_/ }" else export viewer_channel="Second Life Test" fi @@ -237,7 +238,7 @@ jobs: release: needs: build runs-on: [ubuntu-latest] - if: github.ref_type == 'tag' && startsWith(github.ref_name, 'Second Life ') + if: github.ref_type == 'tag' && startsWith(github.ref_name, 'Second_Life_') steps: # forked from softprops/action-gh-release - uses: secondlife-3p/action-gh-release@v1 -- cgit v1.2.3 From f9a30e7ed13091f81686d183c25e57d732cee957 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Sat, 22 Jul 2023 08:18:13 -0400 Subject: SL-18837: Try posting build.yaml step outputs as job outputs. --- .github/workflows/build.yaml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 4262d3b6ef..3ea58d9c09 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -18,6 +18,10 @@ jobs: - runner: macos-12-xl developer_dir: "/Applications/Xcode_14.0.1.app/Contents/Developer" runs-on: ${{ matrix.runner }} + outputs: + # pass these from build job to release job + installer: ${{ steps.build.outputs.installer }} + metadata: ${{ steps.build.outputs.metadata }} env: AUTOBUILD_ADDRSIZE: 64 AUTOBUILD_BUILD_ID: ${{ github.run_id }} @@ -245,5 +249,5 @@ jobs: with: generate_release_notes: true files: | - ${{ steps.build.outputs.installer }} - ${{ steps.build.outputs.metadata }} + ${{ jobs.build.outputs.installer }} + ${{ jobs.build.outputs.metadata }} -- cgit v1.2.3 From 73a857ba31a21add60db349fc29fb9f7a5edfa00 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Sat, 22 Jul 2023 08:32:21 -0400 Subject: SL-18837: Use 'needs' context, not 'jobs' context in release job to reference outputs from the build job. Also mark the release as prerelease, and fail the release action if we still can't find the files we're trying to post. --- .github/workflows/build.yaml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 3ea58d9c09..01f7f2bd7b 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -247,7 +247,10 @@ jobs: # forked from softprops/action-gh-release - uses: secondlife-3p/action-gh-release@v1 with: + prerelease: true generate_release_notes: true + # the only reason we generate a GH release is to post build products + fail_on_unmatched_files: true files: | - ${{ jobs.build.outputs.installer }} - ${{ jobs.build.outputs.metadata }} + ${{ needs.build.outputs.installer }} + ${{ needs.build.outputs.metadata }} -- cgit v1.2.3 From 70e4c73baae5759b6a2bae9722fa64cfb8b0bb20 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Fri, 18 Aug 2023 11:28:15 -0400 Subject: SL-18837: Engage initial GH viewer release script. --- .github/workflows/build.yaml | 38 +++++++++++++++++++++++++++---------- .github/workflows/post_artifacts.py | 31 ++++++++++++++++++++++++++++++ 2 files changed, 59 insertions(+), 10 deletions(-) create mode 100755 .github/workflows/post_artifacts.py (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 01f7f2bd7b..1cdef55f5f 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -241,16 +241,34 @@ jobs: release: needs: build - runs-on: [ubuntu-latest] + runs-on: ubuntu-latest if: github.ref_type == 'tag' && startsWith(github.ref_name, 'Second_Life_') steps: - # forked from softprops/action-gh-release - - uses: secondlife-3p/action-gh-release@v1 + - name: Checkout code + uses: actions/checkout@v3 + with: + ref: ${{ github.sha }} + + - name: Setup python + uses: actions/setup-python@v4 with: - prerelease: true - generate_release_notes: true - # the only reason we generate a GH release is to post build products - fail_on_unmatched_files: true - files: | - ${{ needs.build.outputs.installer }} - ${{ needs.build.outputs.metadata }} + python-version: "3.11" + + - name: Install PyGithub + run: pip3 install PyGithub + + - name: Unpack artifacts + env: + BUILD: ${{ toJSON(needs.build) }} + run: .github/workflows/post_artifacts.py + +## # forked from softprops/action-gh-release +## - uses: secondlife-3p/action-gh-release@v1 +## with: +## prerelease: true +## generate_release_notes: true +## # the only reason we generate a GH release is to post build products +## fail_on_unmatched_files: true +## files: | +## ${{ needs.build.outputs.installer }} +## ${{ needs.build.outputs.metadata }} diff --git a/.github/workflows/post_artifacts.py b/.github/workflows/post_artifacts.py new file mode 100755 index 0000000000..bb51feb0a9 --- /dev/null +++ b/.github/workflows/post_artifacts.py @@ -0,0 +1,31 @@ +#!/usr/bin/env python3 +"""\ +@file post_artifacts.py +@author Nat Goodspeed +@date 2023-08-18 +@brief Unpack and post artifacts from a GitHub Actions build + +$LicenseInfo:firstyear=2023&license=viewerlgpl$ +Copyright (c) 2023, Linden Research, Inc. +$/LicenseInfo$ +""" + +import github +import json +import os +import sys + +class Error(Exception): + pass + +def main(*raw_args): + buildstr = os.getenv('BUILD') + build = json.loads(buildstr) + from pprint import pprint + pprint(build) + +if __name__ == "__main__": + try: + sys.exit(main(*sys.argv[1:])) + except Error as err: + sys.exit(str(err)) -- cgit v1.2.3 From 929aa15c80c89555f1f5c5fc57c4d4c27650a1c8 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Mon, 28 Aug 2023 13:21:16 -0400 Subject: SL-18837: Experiment with download-artifact downloading all files. --- .github/workflows/build.yaml | 37 +++++++++++++++++++++---------------- 1 file changed, 21 insertions(+), 16 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 1cdef55f5f..440681edb1 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -242,25 +242,30 @@ jobs: release: needs: build runs-on: ubuntu-latest - if: github.ref_type == 'tag' && startsWith(github.ref_name, 'Second_Life_') + ##if: github.ref_type == 'tag' && startsWith(github.ref_name, 'Second_Life_') steps: - - name: Checkout code - uses: actions/checkout@v3 - with: - ref: ${{ github.sha }} - - - name: Setup python - uses: actions/setup-python@v4 - with: - python-version: "3.11" +## - name: Checkout code +## uses: actions/checkout@v3 +## with: +## ref: ${{ github.sha }} +## +## - name: Setup python +## uses: actions/setup-python@v4 +## with: +## python-version: "3.11" +## +## - name: Install PyGithub +## run: pip3 install PyGithub +## +## - name: Unpack artifacts +## env: +## BUILD: ${{ toJSON(needs.build) }} +## run: .github/workflows/post_artifacts.py - - name: Install PyGithub - run: pip3 install PyGithub + - uses: actions/download-artifact@v3 - - name: Unpack artifacts - env: - BUILD: ${{ toJSON(needs.build) }} - run: .github/workflows/post_artifacts.py + - name: Show what we downloaded + run: ls -R ## # forked from softprops/action-gh-release ## - uses: secondlife-3p/action-gh-release@v1 -- cgit v1.2.3 From 7779cebdcd1aecbce92c660072c00064185a95f1 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 29 Aug 2023 17:55:53 -0400 Subject: SL-18837: Introduce flatten_files.py and use to post release assets --- .github/workflows/build.yaml | 46 +++++---- .github/workflows/flatten_files.py | 180 ++++++++++++++++++++++++++++++++++++ .github/workflows/post_artifacts.py | 31 ------- 3 files changed, 206 insertions(+), 51 deletions(-) create mode 100755 .github/workflows/flatten_files.py delete mode 100755 .github/workflows/post_artifacts.py (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 440681edb1..61a1215d07 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -244,16 +244,16 @@ jobs: runs-on: ubuntu-latest ##if: github.ref_type == 'tag' && startsWith(github.ref_name, 'Second_Life_') steps: -## - name: Checkout code -## uses: actions/checkout@v3 -## with: -## ref: ${{ github.sha }} -## -## - name: Setup python -## uses: actions/setup-python@v4 -## with: -## python-version: "3.11" -## + - name: Checkout code + uses: actions/checkout@v3 + with: + ref: ${{ github.sha }} + + - name: Setup python + uses: actions/setup-python@v4 + with: + python-version: "3.11" + ## - name: Install PyGithub ## run: pip3 install PyGithub ## @@ -263,17 +263,23 @@ jobs: ## run: .github/workflows/post_artifacts.py - uses: actions/download-artifact@v3 + with: + path: artifacts - name: Show what we downloaded run: ls -R -## # forked from softprops/action-gh-release -## - uses: secondlife-3p/action-gh-release@v1 -## with: -## prerelease: true -## generate_release_notes: true -## # the only reason we generate a GH release is to post build products -## fail_on_unmatched_files: true -## files: | -## ${{ needs.build.outputs.installer }} -## ${{ needs.build.outputs.metadata }} + - name: Make output dir + run: mkdir assets + + - name: Reshuffle artifact files + run: .github/workflows/flatten_files.py assets artifacts + + # forked from softprops/action-gh-release + - uses: secondlife-3p/action-gh-release@v1 + with: + prerelease: true + generate_release_notes: true + # the only reason we generate a GH release is to post build products + fail_on_unmatched_files: true + files: "assets/*" diff --git a/.github/workflows/flatten_files.py b/.github/workflows/flatten_files.py new file mode 100755 index 0000000000..542fa0206b --- /dev/null +++ b/.github/workflows/flatten_files.py @@ -0,0 +1,180 @@ +#!/usr/bin/env python3 +"""\ +@file flatten_files.py +@author Nat Goodspeed +@date 2023-08-18 +@brief From an input directory tree, populate a single flat output directory. + +$LicenseInfo:firstyear=2023&license=viewerlgpl$ +Copyright (c) 2023, Linden Research, Inc. +$/LicenseInfo$ +""" + +DESCRIPTION = """\ +From an input directory tree, populate a single flat output directory. + +For files with colliding names, rename them to unambiguous names derived from +their relative pathname within the input tree. + +This is useful when downloading GitHub build artifacts from multiple platforms +to post them all as release assets without collisions. +""" + +from collections import defaultdict +from contextlib import suppress +import filecmp +import os +from pathlib import Path +import sys + +class Error(Exception): + pass + +def flatten(output, input='.', dry_run=False): + try: + in_stat = os.stat(input) + except FileNotFoundError as err: + raise Error(f'{input} does not exist') from err + + try: + out_stat = os.stat(output) + except FileNotFoundError: + # output doesn't yet exist - at this point that's okay + out_stat = None + + # use samestat() to avoid being fooled by different ways of expressing the + # same path + if out_stat and os.path.samestat(out_stat, in_stat): + # output directory same as input: in this case, don't prune output + # directory from input tree walk because we'd prune everything + out_stat = None + elif out_stat: + # distinct existing output directory (potentially containing, or + # contained by, the input directory) + outfiles = [f for f in Path(output).rglob('*') if f.is_file()] + if outfiles: + print(f'Warning: {output} already contains {len(outfiles)} files:', file=sys.stderr) + for f in sorted(outfiles): + print(' ', f.relative_to(output), file=sys.stderr) + + # Use os.walk() instead of Path.rglob() so we can prune unwanted + # directories. + infiles = [] + for parent, dirs, files in os.walk(input): + infiles.extend(Path(parent, f) for f in files) + # Prune directories: because we must modify the dirs list in-place, + # and because we're using indexes, traverse backwards so deletion + # won't affect subsequent iterations. Yes we really must subtract 1 + # that many times. + for idx in range(len(dirs)-1, -1, -1): + if dirs[idx].startswith('.'): + # skip dot-named directories + print(f'ignoring {dirs[idx]}', file=sys.stderr) + del dirs[idx] + elif out_stat and os.path.samestat(os.stat(os.path.join(parent, dirs[idx])), out_stat): + # output directory lives under input directory: ignore any + # previous contents + print(f'ignoring nested output directory {os.path.join(parent, dirs[idx])}', + file=sys.stderr) + del dirs[idx] + + # Now that we've traversed the input tree, create the output directory if + # needed. + output = Path(output) + output.mkdir(parents=True, exist_ok=True) + + # group files by basename to identify collisions + basenames = defaultdict(list) + for f in infiles: + basenames[f.name].append(f) + + # output names: populate it right away with unique basenames + outnames = { name: files[0] for name, files in basenames.items() + if len(files) == 1 } + + # now focus on the collisions + for name, files in basenames.items(): + if len(files) <= 1: + continue + + # Special case: are these colliding files equal? e.g. viewer_version.txt + # Pass shallow=False so we actually read the files in question. Even + # if they're identical, they've been downloaded from different + # artifacts and have different timestamps (which would fool the default + # shallow=True). This could be time-consuming if we were comparing two + # of our very large files, but (a) our very large files already have + # distinct names and so don't reach this call and (b) if we somehow do + # wind up in that situation, it would be even more important to post + # only a single copy. + if all(filecmp.cmp(files[0], f, shallow=False) for f in files[1:]): + # pick only one of them and use its simple basename + outnames[name] = files[0] + continue + + # Because of our intended use for GitHub Actions build artifacts, we + # assume the top-level artifact names are descriptive. We'd still like + # to eliminate mid-level directory names that don't help disambiguate, + # so for instance, given: + # Windows metadata/newview/viewer_version.txt + # macOS metadata/newview/viewer_version.txt + # we see no reason to retain the 'newview' pathname component. Try + # longer and longer prefixes of the pathname parents. (But don't + # forget to trim off the original input directory pathname.) + filepairs = [(f, f.relative_to(input)) for f in files] + partslen = max(len(rel.parts) for f, rel in filepairs) + # skip the basename itself, we'll append that explicitly + for prefixlen in range(partslen - 1): + # Consider these relative names (shouldn't occur, but...): + # parent/autobuild-package.xml + # parent/newview/autobuild-package.xml + # Unless these are in fact identical, they'll collide, meaning + # we'll see them here. But beware their unequal numbers of parts. + # partslen will be 3, so prefixlen will be 0, 1 -- but unless we + # constrain it with min(), for prefixlen == 1 we'd construct: + # ('parent', 'autobuild-package.xml', 'autobuild-package.xml') + # ('parent', 'newview', 'autobuild-package.xml') + # whereas of course the correct answer would be: + # ('parent', 'autobuild-package.xml') + # ('parent', 'newview', 'autobuild-package.xml') + # Since we already know the basename is identical for every f in + # files, though, we can omit it from our uniqueness testing. + trynames = { rel.parts[:min(prefixlen+1, len(rel.parts)-1)]: f + for f, rel in filepairs } + if len(trynames) == len(files): + # Found a prefix without collisions -- note that we're + # guaranteed to get here eventually since the full paths are + # distinct in the filesystem, we just want to try to shorten. + # Path.parts is specifically documented to be a tuple. Join + # the key tuple with some delimiter acceptable to the + # filesystem. + outnames.update(('-'.join(nametuple + (name,)), f) + for nametuple, f in trynames.items()) + # stop considering longer prefixlens + break + + # at this point outnames should have distinct keys -- move to the output + # directory + for name, f in outnames.items(): + newname = output / name + if (not dry_run) and newname != f: + newname = f.rename(newname) + print(f'{f} => {newname}') + +def main(*raw_args): + from argparse import ArgumentParser + parser = ArgumentParser(description=DESCRIPTION) + parser.add_argument('-n', '--dry-run', action='store_true', default=False, + help="""show what would happen without moving files""") + parser.add_argument('output', metavar='OUTDIR', + help="""populate OUTDIR with (possibly renamed) files""") + parser.add_argument('input', metavar='INDIR', nargs='?', default='.', + help="""recursively read files under INDIR tree""") + + args = parser.parse_args(raw_args) + flatten(args.output, args.input, dry_run=args.dry_run) + +if __name__ == "__main__": + try: + sys.exit(main(*sys.argv[1:])) + except Error as err: + sys.exit(str(err)) diff --git a/.github/workflows/post_artifacts.py b/.github/workflows/post_artifacts.py deleted file mode 100755 index bb51feb0a9..0000000000 --- a/.github/workflows/post_artifacts.py +++ /dev/null @@ -1,31 +0,0 @@ -#!/usr/bin/env python3 -"""\ -@file post_artifacts.py -@author Nat Goodspeed -@date 2023-08-18 -@brief Unpack and post artifacts from a GitHub Actions build - -$LicenseInfo:firstyear=2023&license=viewerlgpl$ -Copyright (c) 2023, Linden Research, Inc. -$/LicenseInfo$ -""" - -import github -import json -import os -import sys - -class Error(Exception): - pass - -def main(*raw_args): - buildstr = os.getenv('BUILD') - build = json.loads(buildstr) - from pprint import pprint - pprint(build) - -if __name__ == "__main__": - try: - sys.exit(main(*sys.argv[1:])) - except Error as err: - sys.exit(str(err)) -- cgit v1.2.3 From b06aa53f59dcd2efa4c73bbaa84b17c0d080117e Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 29 Aug 2023 20:03:21 -0400 Subject: SL-18837: Only list the downloaded artifacts. --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 61a1215d07..d62b640369 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -267,7 +267,7 @@ jobs: path: artifacts - name: Show what we downloaded - run: ls -R + run: ls -R artifacts - name: Make output dir run: mkdir assets -- cgit v1.2.3 From e8cd5205e89993df357410c245f99ebb7703958d Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 31 Aug 2023 15:53:56 -0400 Subject: SL-19243: Try to run Windows BugSplat uploads as a separate GH job. Upload a new Windows-exe artifact containing just the executable (needed by BugSplat) separately from the artifact containing the whole NSIS installer. This requires a new viewer_exe step output set by viewer_manifest.py. Define viewer_channel and viewer_version as build job outputs. Set viewer_channel in build.yaml when tag is interpreted. Set viewer_version in build.sh at the point when it would have posted viewer_version.txt to codeticket. Add a post-windows-symbols job dependent on the build job that engages secondlife/viewer-post-bugsplat-windows, which in turn engages secondlife/post-bugsplat-windows. We keep the actual upload code in a separate repo in case we need to modify that code before rerunning to resolve upload errors. If we kept the upload code in the viewer repo itself, rerunning the upload with modifications would necessarily require rerunning the viewer build, which would defeat the purpose of SL-19243. Because of that new upload job in build.yaml, skip Windows symbol uploads in build.sh. Use a simple (platform name) artifact name for metadata because of flatten_files.py's filename collision resolution. Use hyphens, not spaces, in remaining artifact names: apparently download-artifact doesn't much like artifacts with spaces in their names. Only run the release job when in fact there's a tag. Without that, we get errors. We need not create flatten_files.py's output directory beforehand because it will do that implicitly. --- .github/workflows/build.yaml | 45 +++++++++++++++++++++++++++++++++----------- 1 file changed, 34 insertions(+), 11 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index d62b640369..ad5925d266 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -19,9 +19,8 @@ jobs: developer_dir: "/Applications/Xcode_14.0.1.app/Contents/Developer" runs-on: ${{ matrix.runner }} outputs: - # pass these from build job to release job - installer: ${{ steps.build.outputs.installer }} - metadata: ${{ steps.build.outputs.metadata }} + viewer_channel: ${{ steps.build.outputs.viewer_channel }} + viewer_version: ${{ steps.build.outputs.viewer_version }} env: AUTOBUILD_ADDRSIZE: 64 AUTOBUILD_BUILD_ID: ${{ github.run_id }} @@ -175,6 +174,7 @@ jobs: export viewer_channel="${viewer_channel//_/ }" else export viewer_channel="Second Life Test" fi + echo "viewer_channel=$viewer_channel" >> "$GITHUB_OUTPUT" # On windows we need to point the build to the correct python # as neither CMake's FindPython nor our custom Python.cmake module @@ -207,24 +207,37 @@ jobs: - name: Upload installer uses: actions/upload-artifact@v3 with: - name: "${{ steps.build.outputs.artifact }} installer" + name: "${{ steps.build.outputs.artifact }}-installer" # emitted by build.sh, possibly multiple lines path: | ${{ steps.build.outputs.installer }} + - name: Upload executable + uses: actions/upload-artifact@v3 + with: + name: "${{ steps.build.outputs.artifact }}-exe + if: steps.build.outputs.viewer_exe + path: ${{ steps.build.outputs.viewer_exe }} + # The other upload of nontrivial size is the symbol file. Use a distinct # artifact for that too. - name: Upload symbol file uses: actions/upload-artifact@v3 with: - name: "${{ steps.build.outputs.artifact }} symbols" + name: "${{ steps.build.outputs.artifact }}-symbols" path: | ${{ steps.build.outputs.symbolfile }} - name: Upload metadata uses: actions/upload-artifact@v3 with: - name: "${{ steps.build.outputs.artifact }} metadata" + # Call this artifact just "Windows" or "macOS" because it's the only + # artifact in which we expect files from both platforms with + # colliding names (e.g. autobuild-package.xml). Our flatten_files.py + # (see release step) resolves collisions by prepending the artifact + # name, so when we anticipate collisions, it's good to keep the + # artifact name short and sweet. + name: "${{ steps.build.outputs.artifact }}" # emitted by build.sh, possibly multiple lines path: | ${{ steps.build.outputs.metadata }} @@ -234,15 +247,28 @@ jobs: # should only be set for viewer-private if: steps.build.outputs.physicstpv with: - name: "${{ steps.build.outputs.artifact }} physics" + name: "${{ steps.build.outputs.artifact }}-physics" # emitted by build.sh, zero or one lines path: | ${{ steps.build.outputs.physicstpv }} + post-windows-symbols: + needs: build + runs-on: ubuntu-latest + steps: + - name: Post windows symbols + uses: secondlife/viewer-post-bugsplat-windows + with: + username: ${{ secrets.BUGSPLAT_USER }} + password: ${{ secrets.BUGSPLAT_PASS }} + database: "SecondLife_Viewer_2018" + channel: ${{ needs.build.outputs.viewer_channel }} + version: ${{ needs.build.outputs.viewer_version }} + release: needs: build runs-on: ubuntu-latest - ##if: github.ref_type == 'tag' && startsWith(github.ref_name, 'Second_Life_') + if: github.ref_type == 'tag' && startsWith(github.ref_name, 'Second_Life_') steps: - name: Checkout code uses: actions/checkout@v3 @@ -269,9 +295,6 @@ jobs: - name: Show what we downloaded run: ls -R artifacts - - name: Make output dir - run: mkdir assets - - name: Reshuffle artifact files run: .github/workflows/flatten_files.py assets artifacts -- cgit v1.2.3 From 58e8c3567f219703623f3a4755d3ba796ba4ef85 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 31 Aug 2023 16:06:13 -0400 Subject: SL-19243: Fix build.yaml syntax error. --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index ad5925d266..e0caee849a 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -215,7 +215,7 @@ jobs: - name: Upload executable uses: actions/upload-artifact@v3 with: - name: "${{ steps.build.outputs.artifact }}-exe + name: "${{ steps.build.outputs.artifact }}-exe" if: steps.build.outputs.viewer_exe path: ${{ steps.build.outputs.viewer_exe }} -- cgit v1.2.3 From 348d7107070defa996b870691df23570694f1713 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 31 Aug 2023 16:09:12 -0400 Subject: SL-19243: Fix 'uses:' reference to viewer-post-bugsplat-windows --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index e0caee849a..a6a8b49d26 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -257,7 +257,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Post windows symbols - uses: secondlife/viewer-post-bugsplat-windows + uses: secondlife/viewer-post-bugsplat-windows@main with: username: ${{ secrets.BUGSPLAT_USER }} password: ${{ secrets.BUGSPLAT_PASS }} -- cgit v1.2.3 From 3147b55cecb5fc8a0de71cee09b0e12b66b75a40 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 31 Aug 2023 17:28:25 -0400 Subject: SL-19243: Fix wonky 'if:' in build.yaml --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index a6a8b49d26..526ac6999f 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -213,10 +213,10 @@ jobs: ${{ steps.build.outputs.installer }} - name: Upload executable + if: steps.build.outputs.viewer_exe uses: actions/upload-artifact@v3 with: name: "${{ steps.build.outputs.artifact }}-exe" - if: steps.build.outputs.viewer_exe path: ${{ steps.build.outputs.viewer_exe }} # The other upload of nontrivial size is the symbol file. Use a distinct -- cgit v1.2.3 From 2ee8cb0e1601465737fad1fdc02dc237c4294330 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Fri, 1 Sep 2023 07:46:32 -0400 Subject: SL-19243: Job to post windows symbols must run on Windows. --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 526ac6999f..901cd092af 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -254,7 +254,7 @@ jobs: post-windows-symbols: needs: build - runs-on: ubuntu-latest + runs-on: windows steps: - name: Post windows symbols uses: secondlife/viewer-post-bugsplat-windows@main -- cgit v1.2.3 From 7cedb1eb20c1263ad1b26af6a3d297e532d641e1 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Fri, 1 Sep 2023 10:53:02 -0400 Subject: SL-19243: Add post-mac-symbols job using viewer-post-bugsplat-mac. The initial viewer-post-bugsplat-mac is just a placeholder so far, but we can flesh it out while the viewer builds necessitated by this change are running, and then we can iterate on viewer-post-bugsplat-mac without having to rebuild the viewer. --- .github/workflows/build.yaml | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 901cd092af..a901e33ec1 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -256,7 +256,7 @@ jobs: needs: build runs-on: windows steps: - - name: Post windows symbols + - name: Post Windows symbols uses: secondlife/viewer-post-bugsplat-windows@main with: username: ${{ secrets.BUGSPLAT_USER }} @@ -265,6 +265,19 @@ jobs: channel: ${{ needs.build.outputs.viewer_channel }} version: ${{ needs.build.outputs.viewer_version }} + post-mac-symbols: + needs: build + runs-on: macos + steps: + - name: Post Mac symbols + uses: secondlife/viewer-post-bugsplat-mac@main + with: + username: ${{ secrets.BUGSPLAT_USER }} + password: ${{ secrets.BUGSPLAT_PASS }} + database: "SecondLife_Viewer_2018" + channel: ${{ needs.build.outputs.viewer_channel }} + version: ${{ needs.build.outputs.viewer_version }} + release: needs: build runs-on: ubuntu-latest -- cgit v1.2.3 From 755f9d9ac9548e27d68ec701676e20c4824833f8 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Wed, 6 Sep 2023 17:03:22 -0400 Subject: SL-19243: Specify macos-latest for post-mac-symbols. We want to run on a GitHub-hosted runner rather than one of our own. --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index a901e33ec1..025fc1560e 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -267,7 +267,7 @@ jobs: post-mac-symbols: needs: build - runs-on: macos + runs-on: macos-latest steps: - name: Post Mac symbols uses: secondlife/viewer-post-bugsplat-mac@main -- cgit v1.2.3 From 949909013e77e35fe59ed9507a2c40fdb31bc1fc Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 7 Sep 2023 11:38:00 -0400 Subject: SL-18837: Segregate ReleaseOS artifacts; don't even upload. Eliminate references to (no longer set) matrix.addrsize. --- .github/workflows/build.yaml | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 69a7e4b6a6..46ec8fdeb9 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -86,10 +86,10 @@ jobs: id: cache-installables with: path: .autobuild-installables - key: ${{ runner.os }}-${{ matrix.addrsize }}-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} + key: ${{ runner.os }}-64-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} restore-keys: | - ${{ runner.os }}-${{ matrix.addrsize }}-${{ matrix.configuration }}- - ${{ runner.os }}-${{ matrix.addrsize }}- + ${{ runner.os }}-64-${{ matrix.configuration }}- + ${{ runner.os }}-64- - name: Install windows dependencies if: runner.os == 'Windows' @@ -205,9 +205,14 @@ jobs: # 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. - echo "artifact=$RUNNER_OS" >> $GITHUB_OUTPUT + if [[ "$AUTOBUILD_CONFIGURATION" == "ReleaseOS" ]] + then cfg_suffix='OS' + else cfg_suffix='' + fi + echo "artifact=$RUNNER_OS$cfg_suffix" >> $GITHUB_OUTPUT - name: Upload installer + if: matrix.configuration != "ReleaseOS" uses: actions/upload-artifact@v3 with: name: "${{ steps.build.outputs.artifact }}-installer" @@ -216,7 +221,7 @@ jobs: ${{ steps.build.outputs.installer }} - name: Upload executable - if: steps.build.outputs.viewer_exe + if: matrix.configuration != "ReleaseOS" && steps.build.outputs.viewer_exe uses: actions/upload-artifact@v3 with: name: "${{ steps.build.outputs.artifact }}-exe" @@ -225,6 +230,7 @@ jobs: # The other upload of nontrivial size is the symbol file. Use a distinct # artifact for that too. - name: Upload symbol file + if: matrix.configuration != "ReleaseOS" uses: actions/upload-artifact@v3 with: name: "${{ steps.build.outputs.artifact }}-symbols" @@ -232,6 +238,7 @@ jobs: ${{ steps.build.outputs.symbolfile }} - name: Upload metadata + if: matrix.configuration != "ReleaseOS" uses: actions/upload-artifact@v3 with: # Call this artifact just "Windows" or "macOS" because it's the only @@ -248,7 +255,7 @@ jobs: - name: Upload physics package uses: actions/upload-artifact@v3 # should only be set for viewer-private - if: steps.build.outputs.physicstpv + if: matrix.configuration != "ReleaseOS" && steps.build.outputs.physicstpv with: name: "${{ steps.build.outputs.artifact }}-physics" # emitted by build.sh, zero or one lines -- cgit v1.2.3 From bac73831c0f92dcdff1d85dab60e18ce6f6dabda Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 7 Sep 2023 11:48:15 -0400 Subject: SL-18837: String literals are single-quoted in GitHub expressions. --- .github/workflows/build.yaml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 46ec8fdeb9..89241071e3 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -212,7 +212,7 @@ jobs: echo "artifact=$RUNNER_OS$cfg_suffix" >> $GITHUB_OUTPUT - name: Upload installer - if: matrix.configuration != "ReleaseOS" + if: matrix.configuration != 'ReleaseOS' uses: actions/upload-artifact@v3 with: name: "${{ steps.build.outputs.artifact }}-installer" @@ -221,7 +221,7 @@ jobs: ${{ steps.build.outputs.installer }} - name: Upload executable - if: matrix.configuration != "ReleaseOS" && steps.build.outputs.viewer_exe + if: matrix.configuration != 'ReleaseOS' && steps.build.outputs.viewer_exe uses: actions/upload-artifact@v3 with: name: "${{ steps.build.outputs.artifact }}-exe" @@ -230,7 +230,7 @@ jobs: # The other upload of nontrivial size is the symbol file. Use a distinct # artifact for that too. - name: Upload symbol file - if: matrix.configuration != "ReleaseOS" + if: matrix.configuration != 'ReleaseOS' uses: actions/upload-artifact@v3 with: name: "${{ steps.build.outputs.artifact }}-symbols" @@ -238,7 +238,7 @@ jobs: ${{ steps.build.outputs.symbolfile }} - name: Upload metadata - if: matrix.configuration != "ReleaseOS" + if: matrix.configuration != 'ReleaseOS' uses: actions/upload-artifact@v3 with: # Call this artifact just "Windows" or "macOS" because it's the only @@ -255,7 +255,7 @@ jobs: - name: Upload physics package uses: actions/upload-artifact@v3 # should only be set for viewer-private - if: matrix.configuration != "ReleaseOS" && steps.build.outputs.physicstpv + if: matrix.configuration != 'ReleaseOS' && steps.build.outputs.physicstpv with: name: "${{ steps.build.outputs.artifact }}-physics" # emitted by build.sh, zero or one lines -- cgit v1.2.3 From 77227cf5c427b1be0481989f6cd9fd53a36dc487 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 7 Sep 2023 14:09:54 -0400 Subject: SL-18837: Suppress BUGSPLAT_DB for ReleaseOS builds. --- .github/workflows/build.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 89241071e3..77cb91cd85 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -34,8 +34,8 @@ jobs: AUTOBUILD_VARIABLES_FILE: ${{ github.workspace }}/.build-variables/variables AUTOBUILD_VSVER: "170" DEVELOPER_DIR: ${{ matrix.developer_dir }} - # Ensure that viewer builds engage Bugsplat. - BUGSPLAT_DB: "SecondLife_Viewer_2018" + # Ensure that Linden viewer builds engage Bugsplat. + BUGSPLAT_DB: ${{ matrix.configuration != 'ReleaseOS' && 'SecondLife_Viewer_2018' || '' }} BUGSPLAT_PASS: ${{ secrets.BUGSPLAT_PASS }} BUGSPLAT_USER: ${{ secrets.BUGSPLAT_USER }} build_coverity: false -- cgit v1.2.3 From c87d9c635b71d761e0ef84c1a9442759db721487 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Fri, 8 Sep 2023 14:30:05 -0400 Subject: SL-18837: Suppress ReleaseOS for now. --- .github/workflows/build.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 77cb91cd85..7e3d2b68de 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -12,7 +12,9 @@ jobs: strategy: matrix: runner: [windows-large, macos-12-xl] - configuration: [Release, ReleaseOS] + ## Skip ReleaseOS until we resolve + ## === FAILURE No installer found from /c/a/viewer/viewer + configuration: [Release] ##, ReleaseOS] python-version: ["3.11"] include: - runner: macos-12-xl -- cgit v1.2.3 From 2d04cc14d3805df982d51d96d2e3d180f5ef0b34 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Fri, 8 Sep 2023 17:01:46 -0400 Subject: SL-19242: Post -app artifact, not -exe, with entire install image. Previously we posted Windows-exe, macOS-exe artifacts that were a little inconsistent: Windows-exe contained just the Windows executable, whereas macOS-exe contained the whole .app tree (but without the .app directory). Change to post Windows-app, macOS-app artifacts that each contain the whole viewer install image, including the top-level application name directory. This is what we'll need to codesign and notarize. --- .github/workflows/build.yaml | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 7e3d2b68de..8146db36ee 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -223,11 +223,16 @@ jobs: ${{ steps.build.outputs.installer }} - name: Upload executable - if: matrix.configuration != 'ReleaseOS' && steps.build.outputs.viewer_exe + if: matrix.configuration != 'ReleaseOS' && steps.build.outputs.viewer_app uses: actions/upload-artifact@v3 with: - name: "${{ steps.build.outputs.artifact }}-exe" - path: ${{ steps.build.outputs.viewer_exe }} + name: "${{ steps.build.outputs.artifact }}-app" + # The directory specified as viewer_app contains the directory + # containing the application image. Strip out any other build + # detritus from the artifact. + path: | + ${{ steps.build.outputs.viewer_app }} + "!${{ steps.build.outputs.viewer_app }}/*.bat" # The other upload of nontrivial size is the symbol file. Use a distinct # artifact for that too. -- cgit v1.2.3 From 63d5d38e36061291343eddcec24a7243f896b980 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Fri, 8 Sep 2023 17:24:04 -0400 Subject: SL-18837: Stop failing build.sh if there's no installer. This unblocks ReleaseOS builds, and also preps for SL-19242. Streamline build.sh's Uploads section. --- .github/workflows/build.yaml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 8146db36ee..acd30106c3 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -12,9 +12,7 @@ jobs: strategy: matrix: runner: [windows-large, macos-12-xl] - ## Skip ReleaseOS until we resolve - ## === FAILURE No installer found from /c/a/viewer/viewer - configuration: [Release] ##, ReleaseOS] + configuration: [Release, ReleaseOS] python-version: ["3.11"] include: - runner: macos-12-xl -- cgit v1.2.3 From 29300a1fd356b7355ecfb56951e7d7ad0553ef15 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Mon, 11 Sep 2023 10:07:51 -0400 Subject: SL-19242: Try harder to post artifacts containing exactly app image. In a Windows build tree, we don't actually have an app-named top directory, so don't package its containing directory -- just the app dir itself, e.g. "newview/Release". In a Mac build tree, though we do have "Second Life Mumble.app", its parent directory also contains other large stuff. Try posting a temp directory containing a symlink to the .app. Ditch the "!*.bat" exclusion: the presence of a second path (even an exclusion) changes how upload-artifact nests its contents. --- .github/workflows/build.yaml | 4 ---- 1 file changed, 4 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index acd30106c3..9f10275d7c 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -225,12 +225,8 @@ jobs: uses: actions/upload-artifact@v3 with: name: "${{ steps.build.outputs.artifact }}-app" - # The directory specified as viewer_app contains the directory - # containing the application image. Strip out any other build - # detritus from the artifact. path: | ${{ steps.build.outputs.viewer_app }} - "!${{ steps.build.outputs.viewer_app }}/*.bat" # The other upload of nontrivial size is the symbol file. Use a distinct # artifact for that too. -- cgit v1.2.3 From 0992a0af3bc1d9c78d611c3778eca86b575dbe4c Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 12 Sep 2023 12:46:28 -0400 Subject: SL-19243: Use consolidated viewer-build-util instead of distinct viewer-post-bugsplat-{windows,mac} repos. --- .github/workflows/build.yaml | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 9f10275d7c..7c1489e7fd 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -265,10 +265,17 @@ jobs: post-windows-symbols: needs: build - runs-on: windows + runs-on: ubuntu-latest steps: + - name: Checkout viewer-build-util + uses: actions/checkout@v3 + with: + repository: secondlife/viewer-build-util + ref: main + path: .util + - name: Post Windows symbols - uses: secondlife/viewer-post-bugsplat-windows@main + uses: .util/post-bugsplat-windows with: username: ${{ secrets.BUGSPLAT_USER }} password: ${{ secrets.BUGSPLAT_PASS }} @@ -278,10 +285,17 @@ jobs: post-mac-symbols: needs: build - runs-on: macos-latest + runs-on: ubuntu-latest steps: + - name: Checkout viewer-build-util + uses: actions/checkout@v3 + with: + repository: secondlife/viewer-build-util + ref: main + path: .util + - name: Post Mac symbols - uses: secondlife/viewer-post-bugsplat-mac@main + uses: .util/post-bugsplat-mac with: username: ${{ secrets.BUGSPLAT_USER }} password: ${{ secrets.BUGSPLAT_PASS }} -- cgit v1.2.3 From d795b49f16ef77bf7453af228d121a1f7de5f1f9 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 12 Sep 2023 12:50:13 -0400 Subject: SL-19243: Job step 'uses' must specify action.yaml file instead of having it implied by specifying the containing directory. --- .github/workflows/build.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 7c1489e7fd..8157b9559f 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -275,7 +275,7 @@ jobs: path: .util - name: Post Windows symbols - uses: .util/post-bugsplat-windows + uses: .util/post-bugsplat-windows/action.yaml with: username: ${{ secrets.BUGSPLAT_USER }} password: ${{ secrets.BUGSPLAT_PASS }} @@ -295,7 +295,7 @@ jobs: path: .util - name: Post Mac symbols - uses: .util/post-bugsplat-mac + uses: .util/post-bugsplat-mac/action.yaml with: username: ${{ secrets.BUGSPLAT_USER }} password: ${{ secrets.BUGSPLAT_PASS }} -- cgit v1.2.3 From 3e86f26b408a33578482d20cd82ae9b5b5a5dc7c Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 12 Sep 2023 13:55:08 -0400 Subject: SL-19243: Try to convince GitHub that ./.util is really a path. --- .github/workflows/build.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 8157b9559f..4286de7cd3 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -275,7 +275,7 @@ jobs: path: .util - name: Post Windows symbols - uses: .util/post-bugsplat-windows/action.yaml + uses: ./.util/post-bugsplat-windows with: username: ${{ secrets.BUGSPLAT_USER }} password: ${{ secrets.BUGSPLAT_PASS }} @@ -295,7 +295,7 @@ jobs: path: .util - name: Post Mac symbols - uses: .util/post-bugsplat-mac/action.yaml + uses: ./.util/post-bugsplat-mac with: username: ${{ secrets.BUGSPLAT_USER }} password: ${{ secrets.BUGSPLAT_PASS }} -- cgit v1.2.3 From b02249546edeab57bef45cc72400973aa673d866 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 12 Sep 2023 16:28:09 -0400 Subject: SL-19243: Directly reference action subdirs in viewer-build-util instead of trying to checkout viewer-build-util (which doesn't work) and then reference action subdirs from the filesystem. Also engage (initial placeholder) actions to sign and package the platform-specific application artifacts. --- .github/workflows/build.yaml | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 4286de7cd3..b1dbc08011 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -263,19 +263,26 @@ jobs: path: | ${{ steps.build.outputs.physicstpv }} + sign-and-package-windows: + needs: build + runs-on: windows + steps: + - name: Sign and package Windows viewer + uses: secondlife/viewer-build-util/sign-pkg-windows@main + + sign-and-package-mac: + needs: build + runs-on: macos-latest + steps: + - name: Sign and package Mac viewer + uses: secondlife/viewer-build-util/sign-pkg-mac@main + post-windows-symbols: needs: build runs-on: ubuntu-latest steps: - - name: Checkout viewer-build-util - uses: actions/checkout@v3 - with: - repository: secondlife/viewer-build-util - ref: main - path: .util - - name: Post Windows symbols - uses: ./.util/post-bugsplat-windows + uses: secondlife/viewer-build-util/post-bugsplat-windows@main with: username: ${{ secrets.BUGSPLAT_USER }} password: ${{ secrets.BUGSPLAT_PASS }} @@ -287,15 +294,8 @@ jobs: needs: build runs-on: ubuntu-latest steps: - - name: Checkout viewer-build-util - uses: actions/checkout@v3 - with: - repository: secondlife/viewer-build-util - ref: main - path: .util - - name: Post Mac symbols - uses: ./.util/post-bugsplat-mac + uses: secondlife/viewer-build-util/post-bugsplat-mac@main with: username: ${{ secrets.BUGSPLAT_USER }} password: ${{ secrets.BUGSPLAT_PASS }} -- cgit v1.2.3 From 7c351379fc534fb2a17cac3fe5f574786f82eef6 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Fri, 15 Sep 2023 15:17:40 -0400 Subject: SL-19242: Retrieve and decode Windows signing cert, pass to action. --- .github/workflows/build.yaml | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index b1dbc08011..d04e105443 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -267,8 +267,18 @@ jobs: needs: build runs-on: windows steps: + - name: Decode certificate file + shell: bash + env: + SIGNING_CERT_WINDOWS: ${{ secrets.SIGNING_CERT_WINDOWS }} + run: | + mkdir -p .cert + echo "$SIGNING_CERT_WINDOWS" | base64 --decode > .cert/authenticode-cert.pfx + - name: Sign and package Windows viewer uses: secondlife/viewer-build-util/sign-pkg-windows@main + with: + certificate: .cert/authenticode-cert.pfx sign-and-package-mac: needs: build -- cgit v1.2.3 From 1184c383e20797c2c7df7a996663f9236b201cd4 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Mon, 18 Sep 2023 22:39:43 -0400 Subject: SL-19242: release job now depends on package jobs and uses new viewer-build-util/release-artifacts action. --- .github/workflows/build.yaml | 52 +++++------ .github/workflows/flatten_files.py | 180 ------------------------------------- 2 files changed, 22 insertions(+), 210 deletions(-) delete mode 100755 .github/workflows/flatten_files.py (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index d04e105443..8a477e1a29 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -242,13 +242,7 @@ jobs: if: matrix.configuration != 'ReleaseOS' uses: actions/upload-artifact@v3 with: - # Call this artifact just "Windows" or "macOS" because it's the only - # artifact in which we expect files from both platforms with - # colliding names (e.g. autobuild-package.xml). Our flatten_files.py - # (see release step) resolves collisions by prepending the artifact - # name, so when we anticipate collisions, it's good to keep the - # artifact name short and sweet. - name: "${{ steps.build.outputs.artifact }}" + name: "${{ steps.build.outputs.artifact }}-metadata" # emitted by build.sh, possibly multiple lines path: | ${{ steps.build.outputs.metadata }} @@ -314,37 +308,35 @@ jobs: version: ${{ needs.build.outputs.viewer_version }} release: - needs: build + needs: [sign-and-package-windows, sign-and-package-mac] runs-on: ubuntu-latest if: github.ref_type == 'tag' && startsWith(github.ref_name, 'Second_Life_') steps: - - name: Checkout code - uses: actions/checkout@v3 - with: - ref: ${{ github.sha }} - - - name: Setup python - uses: actions/setup-python@v4 - with: - python-version: "3.11" - -## - name: Install PyGithub -## run: pip3 install PyGithub -## -## - name: Unpack artifacts -## env: -## BUILD: ${{ toJSON(needs.build) }} -## run: .github/workflows/post_artifacts.py - - uses: actions/download-artifact@v3 with: path: artifacts - - name: Show what we downloaded - run: ls -R artifacts - - name: Reshuffle artifact files - run: .github/workflows/flatten_files.py assets artifacts + run: secondlife/viewer-build-util/release-artifacts@main + with: + input-path: artifacts + output-path: assets + exclude: | + # The *-app artifacts are for use only by the signing and + # packaging steps. Once we've generated signed installers, we no + # longer need them, and we CERTAINLY don't want to publish + # thousands of individual files as separate URLs. + Windows-app + macOS-app + prefix: | + # Use just "Windows" or "macOS" prefix because these are the only + # artifacts in which we expect files from both platforms with + # colliding names (e.g. autobuild-package.xml). release-artifacts + # normally resolves collisions by prepending the artifact name, so + # when we anticipate collisions, it's good to keep the prefix + # short and sweet. + Windows-metadata=Windows + macOS-metadata=macOS # forked from softprops/action-gh-release - uses: secondlife-3p/action-gh-release@v1 diff --git a/.github/workflows/flatten_files.py b/.github/workflows/flatten_files.py deleted file mode 100755 index 542fa0206b..0000000000 --- a/.github/workflows/flatten_files.py +++ /dev/null @@ -1,180 +0,0 @@ -#!/usr/bin/env python3 -"""\ -@file flatten_files.py -@author Nat Goodspeed -@date 2023-08-18 -@brief From an input directory tree, populate a single flat output directory. - -$LicenseInfo:firstyear=2023&license=viewerlgpl$ -Copyright (c) 2023, Linden Research, Inc. -$/LicenseInfo$ -""" - -DESCRIPTION = """\ -From an input directory tree, populate a single flat output directory. - -For files with colliding names, rename them to unambiguous names derived from -their relative pathname within the input tree. - -This is useful when downloading GitHub build artifacts from multiple platforms -to post them all as release assets without collisions. -""" - -from collections import defaultdict -from contextlib import suppress -import filecmp -import os -from pathlib import Path -import sys - -class Error(Exception): - pass - -def flatten(output, input='.', dry_run=False): - try: - in_stat = os.stat(input) - except FileNotFoundError as err: - raise Error(f'{input} does not exist') from err - - try: - out_stat = os.stat(output) - except FileNotFoundError: - # output doesn't yet exist - at this point that's okay - out_stat = None - - # use samestat() to avoid being fooled by different ways of expressing the - # same path - if out_stat and os.path.samestat(out_stat, in_stat): - # output directory same as input: in this case, don't prune output - # directory from input tree walk because we'd prune everything - out_stat = None - elif out_stat: - # distinct existing output directory (potentially containing, or - # contained by, the input directory) - outfiles = [f for f in Path(output).rglob('*') if f.is_file()] - if outfiles: - print(f'Warning: {output} already contains {len(outfiles)} files:', file=sys.stderr) - for f in sorted(outfiles): - print(' ', f.relative_to(output), file=sys.stderr) - - # Use os.walk() instead of Path.rglob() so we can prune unwanted - # directories. - infiles = [] - for parent, dirs, files in os.walk(input): - infiles.extend(Path(parent, f) for f in files) - # Prune directories: because we must modify the dirs list in-place, - # and because we're using indexes, traverse backwards so deletion - # won't affect subsequent iterations. Yes we really must subtract 1 - # that many times. - for idx in range(len(dirs)-1, -1, -1): - if dirs[idx].startswith('.'): - # skip dot-named directories - print(f'ignoring {dirs[idx]}', file=sys.stderr) - del dirs[idx] - elif out_stat and os.path.samestat(os.stat(os.path.join(parent, dirs[idx])), out_stat): - # output directory lives under input directory: ignore any - # previous contents - print(f'ignoring nested output directory {os.path.join(parent, dirs[idx])}', - file=sys.stderr) - del dirs[idx] - - # Now that we've traversed the input tree, create the output directory if - # needed. - output = Path(output) - output.mkdir(parents=True, exist_ok=True) - - # group files by basename to identify collisions - basenames = defaultdict(list) - for f in infiles: - basenames[f.name].append(f) - - # output names: populate it right away with unique basenames - outnames = { name: files[0] for name, files in basenames.items() - if len(files) == 1 } - - # now focus on the collisions - for name, files in basenames.items(): - if len(files) <= 1: - continue - - # Special case: are these colliding files equal? e.g. viewer_version.txt - # Pass shallow=False so we actually read the files in question. Even - # if they're identical, they've been downloaded from different - # artifacts and have different timestamps (which would fool the default - # shallow=True). This could be time-consuming if we were comparing two - # of our very large files, but (a) our very large files already have - # distinct names and so don't reach this call and (b) if we somehow do - # wind up in that situation, it would be even more important to post - # only a single copy. - if all(filecmp.cmp(files[0], f, shallow=False) for f in files[1:]): - # pick only one of them and use its simple basename - outnames[name] = files[0] - continue - - # Because of our intended use for GitHub Actions build artifacts, we - # assume the top-level artifact names are descriptive. We'd still like - # to eliminate mid-level directory names that don't help disambiguate, - # so for instance, given: - # Windows metadata/newview/viewer_version.txt - # macOS metadata/newview/viewer_version.txt - # we see no reason to retain the 'newview' pathname component. Try - # longer and longer prefixes of the pathname parents. (But don't - # forget to trim off the original input directory pathname.) - filepairs = [(f, f.relative_to(input)) for f in files] - partslen = max(len(rel.parts) for f, rel in filepairs) - # skip the basename itself, we'll append that explicitly - for prefixlen in range(partslen - 1): - # Consider these relative names (shouldn't occur, but...): - # parent/autobuild-package.xml - # parent/newview/autobuild-package.xml - # Unless these are in fact identical, they'll collide, meaning - # we'll see them here. But beware their unequal numbers of parts. - # partslen will be 3, so prefixlen will be 0, 1 -- but unless we - # constrain it with min(), for prefixlen == 1 we'd construct: - # ('parent', 'autobuild-package.xml', 'autobuild-package.xml') - # ('parent', 'newview', 'autobuild-package.xml') - # whereas of course the correct answer would be: - # ('parent', 'autobuild-package.xml') - # ('parent', 'newview', 'autobuild-package.xml') - # Since we already know the basename is identical for every f in - # files, though, we can omit it from our uniqueness testing. - trynames = { rel.parts[:min(prefixlen+1, len(rel.parts)-1)]: f - for f, rel in filepairs } - if len(trynames) == len(files): - # Found a prefix without collisions -- note that we're - # guaranteed to get here eventually since the full paths are - # distinct in the filesystem, we just want to try to shorten. - # Path.parts is specifically documented to be a tuple. Join - # the key tuple with some delimiter acceptable to the - # filesystem. - outnames.update(('-'.join(nametuple + (name,)), f) - for nametuple, f in trynames.items()) - # stop considering longer prefixlens - break - - # at this point outnames should have distinct keys -- move to the output - # directory - for name, f in outnames.items(): - newname = output / name - if (not dry_run) and newname != f: - newname = f.rename(newname) - print(f'{f} => {newname}') - -def main(*raw_args): - from argparse import ArgumentParser - parser = ArgumentParser(description=DESCRIPTION) - parser.add_argument('-n', '--dry-run', action='store_true', default=False, - help="""show what would happen without moving files""") - parser.add_argument('output', metavar='OUTDIR', - help="""populate OUTDIR with (possibly renamed) files""") - parser.add_argument('input', metavar='INDIR', nargs='?', default='.', - help="""recursively read files under INDIR tree""") - - args = parser.parse_args(raw_args) - flatten(args.output, args.input, dry_run=args.dry_run) - -if __name__ == "__main__": - try: - sys.exit(main(*sys.argv[1:])) - except Error as err: - sys.exit(str(err)) -- cgit v1.2.3 From bd8ecbb389efa977908f80b1d04bd827745bc892 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Mon, 18 Sep 2023 22:43:16 -0400 Subject: SL-19242: Typo in changing from inline to reusable action. --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 8a477e1a29..cbdbac65cd 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -317,7 +317,7 @@ jobs: path: artifacts - name: Reshuffle artifact files - run: secondlife/viewer-build-util/release-artifacts@main + uses: secondlife/viewer-build-util/release-artifacts@main with: input-path: artifacts output-path: assets -- cgit v1.2.3 From 763fcb02b89ae8e2149127f420bb5d9ca1594ccc Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 19 Sep 2023 09:15:30 -0400 Subject: SL-19242: Move comments out of YAML parameter text. --- .github/workflows/build.yaml | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index cbdbac65cd..bb1b8bb08b 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -321,20 +321,20 @@ jobs: with: input-path: artifacts output-path: assets - exclude: | - # The *-app artifacts are for use only by the signing and - # packaging steps. Once we've generated signed installers, we no - # longer need them, and we CERTAINLY don't want to publish - # thousands of individual files as separate URLs. + # The *-app artifacts are for use only by the signing and + # packaging steps. Once we've generated signed installers, we no + # longer need them, and we CERTAINLY don't want to publish + # thousands of individual files as separate URLs. + exclude: |- Windows-app macOS-app - prefix: | - # Use just "Windows" or "macOS" prefix because these are the only - # artifacts in which we expect files from both platforms with - # colliding names (e.g. autobuild-package.xml). release-artifacts - # normally resolves collisions by prepending the artifact name, so - # when we anticipate collisions, it's good to keep the prefix - # short and sweet. + # Use just "Windows" or "macOS" prefix because these are the only + # artifacts in which we expect files from both platforms with + # colliding names (e.g. autobuild-package.xml). release-artifacts + # normally resolves collisions by prepending the artifact name, so + # when we anticipate collisions, it's good to keep the prefix + # short and sweet. + prefix: |- Windows-metadata=Windows macOS-metadata=macOS -- cgit v1.2.3 From e8dfbbaf880314359c0c2d18c944199e3f26db07 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Wed, 20 Sep 2023 11:34:56 -0400 Subject: SL-19242: Pass channel and imagename to sign-pkg-mac/action.yaml. The viewer_manifest.py logic to determine the name of the viewer installer .dmg is a little convoluted. Make it tell viewer-build-util/sign-pkg-mac that name, rather than passing it all the relevant inputs and composing it redundantly. sign-pkg-mac also wants the viewer channel to determine the application name. --- .github/workflows/build.yaml | 4 ++++ 1 file changed, 4 insertions(+) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index bb1b8bb08b..b010115e9c 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -24,6 +24,7 @@ jobs: outputs: viewer_channel: ${{ steps.build.outputs.viewer_channel }} viewer_version: ${{ steps.build.outputs.viewer_version }} + imagename: ${{ steps.build.outputs.imagename }} env: AUTOBUILD_ADDRSIZE: 64 AUTOBUILD_BUILD_ID: ${{ github.run_id }} @@ -280,6 +281,9 @@ jobs: steps: - name: Sign and package Mac viewer uses: secondlife/viewer-build-util/sign-pkg-mac@main + with: + channel: ${{ needs.build.outputs.viewer_channel }} + imagename: ${{ needs.build.outputs.imagename }} post-windows-symbols: needs: build -- cgit v1.2.3 From 50e3d4020d2431d01ae3b8c6cc28c49a2762d267 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Mon, 25 Sep 2023 11:19:38 -0400 Subject: SL-19242: Reference the actual stored GitHub repo secrets. Add a Mac signing step to unpack the credentials bundled into NOTARIZE_CREDS_MACOS so viewer-build-util/sign-pkg-mac need not know about that peculiarity of our secrets formatting. --- .github/workflows/build.yaml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index b010115e9c..d7bc4a84af 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -279,11 +279,36 @@ jobs: needs: build runs-on: macos-latest steps: + - name: Unpack Mac notarization credentials + id: note-creds + shell: bash + run: | + # In NOTARIZE_CREDS_MACOS we expect to find: + # USERNAME="..." + # PASSWORD="..." + # ASC_PROVIDER="..." + eval "${{ secrets.NOTARIZE_CREDS_MACOS }} + echo "::add-mask::$USERNAME" + echo "::add-mask::$PASSWORD" + echo "::add-mask::$ASC_PROVIDER" + echo "note_user=$USERNAME" >> "$GITHUB_OUTPUT" + echo "note_pass=$PASSWORD" >> "$GITHUB_OUTPUT" + echo "note_asc=$ASC_PROVIDER" >> "$GITHUB_OUTPUT" + # If we didn't manage to retrieve all of these credentials, better + # find out sooner than later. + [[ -n "$USERNAME" && -n "$PASSWORD && -n "$ASC_PROVIDER" ]] + - name: Sign and package Mac viewer uses: secondlife/viewer-build-util/sign-pkg-mac@main with: channel: ${{ needs.build.outputs.viewer_channel }} imagename: ${{ needs.build.outputs.imagename }} + cert_base64: ${{ secrets.SIGNING_CERT_MACOS }} + cert_name: ${{ secrets.SIGNING_CERT_MACOS_IDENTITY }} + cert_pass: ${{ secrets.SIGNING_CERT_MACOS_PASSWORD }} + note_user: ${{ steps.note-creds.outputs.note_user }} + note_pass: ${{ steps.note-creds.outputs.note_pass }} + note_asc: ${{ steps.note-creds.outputs.note_asc }} post-windows-symbols: needs: build -- cgit v1.2.3 From d2d3599080d7011aa45fc72922d4d46378d95bc8 Mon Sep 17 00:00:00 2001 From: Brad Linden Date: Mon, 25 Sep 2023 12:47:03 -0700 Subject: Attempt to fix SL-19242 notarize creds secrets loading --- .github/workflows/build.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index d7bc4a84af..18f17a2084 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -287,7 +287,7 @@ jobs: # USERNAME="..." # PASSWORD="..." # ASC_PROVIDER="..." - eval "${{ secrets.NOTARIZE_CREDS_MACOS }} + eval "${{ secrets.NOTARIZE_CREDS_MACOS }}" echo "::add-mask::$USERNAME" echo "::add-mask::$PASSWORD" echo "::add-mask::$ASC_PROVIDER" @@ -296,7 +296,7 @@ jobs: echo "note_asc=$ASC_PROVIDER" >> "$GITHUB_OUTPUT" # If we didn't manage to retrieve all of these credentials, better # find out sooner than later. - [[ -n "$USERNAME" && -n "$PASSWORD && -n "$ASC_PROVIDER" ]] + [[ -n "$USERNAME" && -n "$PASSWORD" && -n "$ASC_PROVIDER" ]] - name: Sign and package Mac viewer uses: secondlife/viewer-build-util/sign-pkg-mac@main -- cgit v1.2.3 From e2ea42cb6a078d250a5d1c7ee81be355bde669bc Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Mon, 2 Oct 2023 16:52:11 -0400 Subject: SL-19242: Expect and pass Apple "Team ID" rather than "ASC Provider". "ASC Provider" was a credential accepted by altool, but switching from altool to notarytool requires a Team ID instead. Expect to find TEAM_ID in our repository secret NOTARIZE_CREDS_MACOS. Extract it and pass it to sign-pkg-mac. --- .github/workflows/build.yaml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 18f17a2084..d1f617f301 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -286,17 +286,17 @@ jobs: # In NOTARIZE_CREDS_MACOS we expect to find: # USERNAME="..." # PASSWORD="..." - # ASC_PROVIDER="..." + # TEAM_ID="..." eval "${{ secrets.NOTARIZE_CREDS_MACOS }}" echo "::add-mask::$USERNAME" echo "::add-mask::$PASSWORD" - echo "::add-mask::$ASC_PROVIDER" + echo "::add-mask::$TEAM_ID" echo "note_user=$USERNAME" >> "$GITHUB_OUTPUT" echo "note_pass=$PASSWORD" >> "$GITHUB_OUTPUT" - echo "note_asc=$ASC_PROVIDER" >> "$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 "$ASC_PROVIDER" ]] + [[ -n "$USERNAME" && -n "$PASSWORD" && -n "$TEAM_ID" ]] - name: Sign and package Mac viewer uses: secondlife/viewer-build-util/sign-pkg-mac@main @@ -308,7 +308,7 @@ jobs: cert_pass: ${{ secrets.SIGNING_CERT_MACOS_PASSWORD }} note_user: ${{ steps.note-creds.outputs.note_user }} note_pass: ${{ steps.note-creds.outputs.note_pass }} - note_asc: ${{ steps.note-creds.outputs.note_asc }} + note_team: ${{ steps.note-creds.outputs.note_team }} post-windows-symbols: needs: build -- cgit v1.2.3 From 1684d6249984e0ad8e13263da05f84cb5e6b84fb Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 3 Oct 2023 19:02:40 -0400 Subject: SL-19242: Remove signing and packaging from viewer_manifest.py for Mac and Windows. That's now done by subsequent jobs in the GitHub build. Remove workflow step to upload installers before signing and packaging jobs. Remove from viewer_manifest.py conditionals for 32-bit Windows or Mac. Also bump to actions/checkout@v4, per dependabot. --- .github/workflows/build.yaml | 15 +++------------ .github/workflows/pre-commit.yaml | 2 +- 2 files changed, 4 insertions(+), 13 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index d1f617f301..cb3212d56a 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -57,7 +57,7 @@ jobs: variants: ${{ matrix.configuration }} steps: - name: Checkout code - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: ref: ${{ github.event.pull_request.head.sha || github.sha }} @@ -67,14 +67,14 @@ jobs: python-version: ${{ matrix.python-version }} - name: Checkout build variables - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: repository: secondlife/build-variables ref: viewer path: .build-variables - name: Checkout master-message-template - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: repository: secondlife/master-message-template path: .master-message-template @@ -212,15 +212,6 @@ jobs: fi echo "artifact=$RUNNER_OS$cfg_suffix" >> $GITHUB_OUTPUT - - name: Upload installer - if: matrix.configuration != 'ReleaseOS' - uses: actions/upload-artifact@v3 - with: - name: "${{ steps.build.outputs.artifact }}-installer" - # emitted by build.sh, possibly multiple lines - path: | - ${{ steps.build.outputs.installer }} - - name: Upload executable if: matrix.configuration != 'ReleaseOS' && steps.build.outputs.viewer_app uses: actions/upload-artifact@v3 diff --git a/.github/workflows/pre-commit.yaml b/.github/workflows/pre-commit.yaml index 17c0ace02f..d626eef38d 100644 --- a/.github/workflows/pre-commit.yaml +++ b/.github/workflows/pre-commit.yaml @@ -11,7 +11,7 @@ jobs: pre-commit: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: actions/setup-python@v4 with: python-version: 3.x -- cgit v1.2.3 From 764897839788d3bc19d564cf074675f498b5a77c Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 5 Oct 2023 15:25:54 -0400 Subject: SL-18837: Name the release for the build number to readily find it. --- .github/workflows/build.yaml | 3 +++ 1 file changed, 3 insertions(+) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index cb3212d56a..2def307b94 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -361,6 +361,9 @@ jobs: # forked from softprops/action-gh-release - uses: secondlife-3p/action-gh-release@v1 with: + # name the release page for the build number so we can find it + # easily (analogous to looking up a codeticket build page) + name: "v${{ github.run_id }}" prerelease: true generate_release_notes: true # the only reason we generate a GH release is to post build products -- cgit v1.2.3 From 549e56572b821e8cfc15e591ce13861c2913d7c0 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 12 Oct 2023 17:25:30 -0400 Subject: PIE-1057: Engage viewer-build-util azure branch. --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 2def307b94..6c88c2ca5c 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -262,7 +262,7 @@ jobs: echo "$SIGNING_CERT_WINDOWS" | base64 --decode > .cert/authenticode-cert.pfx - name: Sign and package Windows viewer - uses: secondlife/viewer-build-util/sign-pkg-windows@main + uses: secondlife/viewer-build-util/sign-pkg-windows@azure with: certificate: .cert/authenticode-cert.pfx -- cgit v1.2.3 From f6d872a027834bc83ee51d488336de933b703f74 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Fri, 13 Oct 2023 15:11:30 -0400 Subject: PIE-1057: Pass sign-pkg-windows@azure the Azure-related secrets. --- .github/workflows/build.yaml | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 6c88c2ca5c..daa647f257 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -253,18 +253,14 @@ jobs: needs: build runs-on: windows steps: - - name: Decode certificate file - shell: bash - env: - SIGNING_CERT_WINDOWS: ${{ secrets.SIGNING_CERT_WINDOWS }} - run: | - mkdir -p .cert - echo "$SIGNING_CERT_WINDOWS" | base64 --decode > .cert/authenticode-cert.pfx - - name: Sign and package Windows viewer uses: secondlife/viewer-build-util/sign-pkg-windows@azure with: - certificate: .cert/authenticode-cert.pfx + vault_uri: "${{ secrets.AZURE_KEY_VAULT_URI }}" + cert_name: "${{ secrets.AZURE_CERT_NAME }}" + client_id: "${{ secrets.AZURE_CLIENT_ID }}" + client_secret: "${{ secrets.AZURE_CLIENT_SECRET }}" + tenant_id: "${{ secrets.AZURE_TENANT_ID }}" sign-and-package-mac: needs: build -- cgit v1.2.3 From 2e8e96cfbcb383a667d1b938f364f0bbafcad5b4 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Wed, 18 Oct 2023 17:44:07 -0400 Subject: PIE-1057: viewer-build-util's azure branch has been merged to main. --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index daa647f257..33a8cffa3f 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -254,7 +254,7 @@ jobs: runs-on: windows steps: - name: Sign and package Windows viewer - uses: secondlife/viewer-build-util/sign-pkg-windows@azure + uses: secondlife/viewer-build-util/sign-pkg-windows@main with: vault_uri: "${{ secrets.AZURE_KEY_VAULT_URI }}" cert_name: "${{ secrets.AZURE_CERT_NAME }}" -- cgit v1.2.3