release: fix windows artifacts and stop building asan when releasing on linux (#1283)

* release: fix windows artifacts and stop building asan when releasing on linux

* release: use valid paths in the container's context
This commit is contained in:
Tyler Wilding 2022-04-04 20:50:08 -04:00 committed by GitHub
parent 8e71184daf
commit dba95660ea
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 47 additions and 13 deletions

View file

@ -0,0 +1,24 @@
#!/usr/bin/env bash
set -e
DEST=${1}
SOURCE=${2}
mkdir -p $DEST
cp $SOURCE/build/bin/gk.exe $DEST
cp $SOURCE/build/bin/goalc.exe $DEST
cp $SOURCE/build/bin/extractor.exe $DEST
mkdir -p $DEST/data
mkdir -p $DEST/data/decompiler/
mkdir -p $DEST/data/assets
mkdir -p $DEST/data/game
mkdir -p $DEST/data/log
mkdir -p $DEST/data/game/graphics/opengl_renderer/
cp -r $SOURCE/decompiler/config $DEST/data/decompiler/
cp -r $SOURCE/goal_src $DEST/data
cp -r $SOURCE/game/assets $DEST/data/game/
cp -r $SOURCE/game/graphics/opengl_renderer/shaders $DEST/data/game/graphics/opengl_renderer

View file

@ -111,9 +111,7 @@ const { data: releaseAssetsPost } = await octokit.rest.repos.listReleaseAssets({
// Expected Assets, if we have all of them, we will publish it // Expected Assets, if we have all of them, we will publish it
let expectedAssets = { let expectedAssets = {
"windows-decompiler": false, "windows": false,
"windows-gk": false,
"windows-goalc": false,
"linux" : false, "linux" : false,
} }

View file

@ -53,7 +53,7 @@ jobs:
cache_key: ${{ matrix.os }}-${{ matrix.compiler }} cache_key: ${{ matrix.os }}-${{ matrix.compiler }}
- name: CMake Generation - Clang - name: CMake Generation - Clang
if: matrix.compiler == 'clang' if: matrix.compiler == 'clang' && !startsWith(github.ref, 'refs/tags/')
run: | run: |
export CC=clang export CC=clang
export CXX=clang++ export CXX=clang++
@ -64,6 +64,18 @@ jobs:
-DCMAKE_CXX_COMPILER_LAUNCHER="${{ github.workspace }}"/buildcache/bin/buildcache \ -DCMAKE_CXX_COMPILER_LAUNCHER="${{ github.workspace }}"/buildcache/bin/buildcache \
-DCODE_COVERAGE=ON -DASAN_BUILD=ON -DCODE_COVERAGE=ON -DASAN_BUILD=ON
- name: CMake Generation - Clang - No ASAN
if: matrix.compiler == 'clang' && startsWith(github.ref, 'refs/tags/')
run: |
export CC=clang
export CXX=clang++
cmake -B build \
-DCMAKE_BUILD_TYPE=Release \
-DBUILD_FOR_RELEASE=ON \
-DCMAKE_C_COMPILER_LAUNCHER="${{ github.workspace }}"/buildcache/bin/buildcache \
-DCMAKE_CXX_COMPILER_LAUNCHER="${{ github.workspace }}"/buildcache/bin/buildcache \
-DCODE_COVERAGE=ON -DASAN_BUILD=OFF
- name: CMake Generation - GCC - name: CMake Generation - GCC
if: matrix.compiler == 'gcc' if: matrix.compiler == 'gcc'
run: | run: |
@ -88,7 +100,7 @@ jobs:
run: ./test_code_coverage.sh run: ./test_code_coverage.sh
- name: Submit Coverage Report to Codacy - name: Submit Coverage Report to Codacy
if: ${{ matrix.compiler }} == 'gcc' if: matrix.compiler == 'gcc'
uses: codacy/codacy-coverage-reporter-action@v1 uses: codacy/codacy-coverage-reporter-action@v1
continue-on-error: true continue-on-error: true
with: with:
@ -101,7 +113,7 @@ jobs:
if: github.repository == 'open-goal/jak-project' && startsWith(github.ref, 'refs/tags/') && matrix.compiler == 'clang' if: github.repository == 'open-goal/jak-project' && startsWith(github.ref, 'refs/tags/') && matrix.compiler == 'clang'
run: | run: |
mkdir -p ./ci-artifacts/out mkdir -p ./ci-artifacts/out
./scripts/shell/extract_build.sh ./ci-artifacts/out ./ ./.github/scripts/releases/extract_build_linux.sh ./ci-artifacts/out ./
tar czf ./ci-artifacts/linux.tar.gz ./ci-artifacts/out tar czf ./ci-artifacts/linux.tar.gz ./ci-artifacts/out
- name: Upload Assets and Potential Publish Release - name: Upload Assets and Potential Publish Release

View file

@ -81,19 +81,18 @@ jobs:
# ---- Release / Tagging related steps ---- # ---- Release / Tagging related steps ----
- name: Prepare Build Artifacts - name: Prepare Build Artifacts
if: github.repository == 'open-goal/jak-project' && startsWith(github.ref, 'refs/tags/') && matrix.compiler == 'clang' if: github.repository == 'open-goal/jak-project' && startsWith(github.ref, 'refs/tags/') && matrix.compiler == 'clang'
shell: bash
run: | run: |
mkdir -p ./ci-artifacts/ mkdir -p ./ci-artifacts/out
cp ./build/bin/decompiler.exe ./ci-artifacts/windows-decompiler.exe ./.github/scripts/releases/extract_build_windows.sh ./ci-artifacts/out ./
cp ./build/bin/gk.exe ./ci-artifacts/windows-gk.exe zip -r ./ci-artifacts/windows.zip ./ci-artfacts/out
cp ./build/bin/goalc.exe ./ci-artifacts/windows-goalc.exe
ls ./ci-artifacts/
- name: Upload Assets and Potential Publish Release - name: Upload Assets and Potential Publish Release
if: github.repository == 'open-goal/jak-project' && startsWith(github.ref, 'refs/tags/') && matrix.compiler == 'clang' if: github.repository == 'open-goal/jak-project' && startsWith(github.ref, 'refs/tags/') && matrix.compiler == 'clang'
env: env:
GITHUB_TOKEN: ${{ secrets.BOT_PAT }} GITHUB_TOKEN: ${{ secrets.BOT_PAT }}
ASSET_DIR: ${{ github.WORKSPACE }}/ci-artifacts ASSET_DIR: ${{ github.WORKSPACE }}/ci-artifacts
ASSET_EXTENSION: exe ASSET_EXTENSION: zip
TAG_TO_SEARCH_FOR: ${{ github.REF }} TAG_TO_SEARCH_FOR: ${{ github.REF }}
run: | run: |
cd ./.github/scripts/releases/upload-release-artifacts cd ./.github/scripts/releases/upload-release-artifacts

1
.gitignore vendored
View file

@ -43,3 +43,4 @@ texture_replacements/*
# generated cmake files # generated cmake files
svnrev.h svnrev.h
ci-artifacts/

View file

@ -70,7 +70,7 @@ elseif(MSVC)
endif() endif()
# c++ flags for all build types # c++ flags for all build types
set(CMAKE_CXX_FLAGS "/EHsc /utf-8 /arch:AVX") set(CMAKE_CXX_FLAGS "/EHsc /utf-8 /arch:AVX")
# linker flags # linker flags
set(CMAKE_EXE_LINKER_FLAGS "/STACK:16000000,16384") set(CMAKE_EXE_LINKER_FLAGS "/STACK:16000000,16384")
endif() endif()