mirror of
https://github.com/overte-org/overte.git
synced 2025-08-08 09:37:29 +02:00
Merge more of Austin's master_build.yml
This commit is contained in:
parent
0058f42ab8
commit
efc0c00d07
1 changed files with 151 additions and 118 deletions
269
.github/workflows/cmake.yml
vendored
269
.github/workflows/cmake.yml
vendored
|
@ -11,38 +11,30 @@ on:
|
||||||
# - stable
|
# - stable
|
||||||
|
|
||||||
env:
|
env:
|
||||||
CI_BUILD: Github
|
APP_NAME: interface
|
||||||
|
APP_SYMBOLS_PATH: interface\Release
|
||||||
BUILD_TYPE: Release
|
BUILD_TYPE: Release
|
||||||
RELEASE_TYPE: PR
|
BUCKET_NAME: hifi-gh-builds
|
||||||
|
CI_BUILD: Github
|
||||||
|
CMAKE_BACKTRACE_URL: https://highfidelity.sp.backtrace.io:6098
|
||||||
|
CMAKE_BACKTRACE_TOKEN: ${{ secrets.backtrace_token }}
|
||||||
|
CMAKE_BACKTRACE_SYMBOLS_TOKEN: ${{ secrets.backtrace_symbols_token }}
|
||||||
|
GIT_COMMIT: ${{ github.sha }}
|
||||||
|
RELEASE_TYPE: PRODUCTION
|
||||||
RELEASE_NUMBER: ${{ github.event.number }}
|
RELEASE_NUMBER: ${{ github.event.number }}
|
||||||
VERSION_CODE: ${{ github.event.number }}
|
VERSION_CODE: ${{ github.event.number }}
|
||||||
GIT_PR_COMMIT: ${{ github.sha }}
|
GIT_PR_COMMIT: ${{ github.sha }}
|
||||||
# FIXME should be a shortened version of the SHA
|
|
||||||
GIT_PR_COMMIT_SHORT: ${{ github.sha }}
|
|
||||||
HIFI_VCPKG_BOOTSTRAP: true
|
HIFI_VCPKG_BOOTSTRAP: true
|
||||||
|
OCULUS_APP_ID: '1255907384473836'
|
||||||
|
|
||||||
AWS_ACCESS_KEY_ID: ${{ secrets.aws_access_key_id }}
|
AWS_ACCESS_KEY_ID: ${{ secrets.aws_access_key_id }}
|
||||||
|
|
||||||
# Settings for uploading
|
|
||||||
APP_NAME: interface
|
|
||||||
#APP_NAME: gpu-frame-player
|
|
||||||
BUCKET_NAME: hifi-public
|
|
||||||
UPLOAD_PREFIX: austin/builds
|
|
||||||
|
|
||||||
# OSX specific variables
|
# OSX specific variables
|
||||||
DEVELOPER_DIR: /Applications/Xcode_11.2.app/Contents/Developer
|
DEVELOPER_DIR: /Applications/Xcode_11.2.app/Contents/Developer
|
||||||
MACOSX_DEPLOYMENT_TARGET: '10.11'
|
MACOSX_DEPLOYMENT_TARGET: '10.11'
|
||||||
# WIN32 specific variables
|
# WIN32 specific variables
|
||||||
PreferredToolArchitecture: X64
|
PreferredToolArchitecture: X64
|
||||||
|
|
||||||
BS_USERNAME: gustavo@highfidelity.io
|
|
||||||
BS_PASSWORD: ${MASKED_BUGSPLAT_PASSWORD}
|
|
||||||
CMAKE_BACKTRACE_URL: https://highfidelity.sp.backtrace.io:6098
|
|
||||||
GA_TRACKING_ID: UA-39558647-8
|
|
||||||
OCULUS_APP_ID: '1255907384473836'
|
|
||||||
# CMAKE_BACKTRACE_TOKEN: ${MASKED_CMAKE_BACKTRACE_TOKEN}
|
|
||||||
# CMAKE_BACKTRACE_SYMBOLS_TOKEN: ${MASKED_BACKTRACE_UPLOAD_TOKEN}
|
|
||||||
|
|
||||||
LINUX_DOCKER_IMAGE_NAME: "linux-hifi-gha:${{ github.event.number }}"
|
LINUX_DOCKER_IMAGE_NAME: "linux-hifi-gha:${{ github.event.number }}"
|
||||||
|
|
||||||
# Mac OS
|
# Mac OS
|
||||||
|
@ -74,109 +66,150 @@ env:
|
||||||
#STABLE_BUILD=0
|
#STABLE_BUILD=0
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
os: [windows-latest, macOS-latest, ubuntu-latest]
|
os: [windows-latest, macOS-latest, ubuntu-latest]
|
||||||
|
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
steps:
|
if: github.event.action != 'labeled' || github.event.label.name == 'rebuild'
|
||||||
- name: Checkout
|
steps:
|
||||||
uses: actions/checkout@v1
|
- name: Configure Build Environment 1
|
||||||
with:
|
shell: bash
|
||||||
submodules: true
|
run: |
|
||||||
fetch-depth: 1
|
echo ::set-env name=UPLOAD_PREFIX::master/$RELEASE_NUMBER
|
||||||
- name: Install python modules
|
echo ::set-env name=GIT_COMMIT_SHORT::`echo $GIT_COMMIT | cut -c1-7`
|
||||||
run: pip install awscli boto3 PyGithub
|
# Linux build variables
|
||||||
- name: Create Build Environment
|
if [ "${{ matrix.os }}" = "ubuntu-latest" ]; then
|
||||||
run: cmake -E make_directory ${{runner.workspace}}/build
|
echo ::set-env name=INSTALLER_EXT::tgz
|
||||||
|
fi
|
||||||
|
# Mac build variables
|
||||||
|
if [ "${{ matrix.os }}" = "macOS-latest" ]; then
|
||||||
|
echo ::set-env name=INSTALLER_EXT::dmg
|
||||||
|
fi
|
||||||
|
# Windows build variables
|
||||||
|
if [ "${{ matrix.os }}" = "windows-latest" ]; then
|
||||||
|
echo ::set-env name=INSTALLER_EXT::exe
|
||||||
|
fi
|
||||||
|
# Configuration is broken into two steps because you can't set an env var and also reference it in the same step
|
||||||
|
- name: Configure Build Environment 2
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
echo ::set-env name=ARTIFACT_PATTERN::HighFidelity-Beta-*.$INSTALLER_EXT
|
||||||
|
# Build type variables
|
||||||
|
if [ "${{ matrix.build_type }}" = "full" ]; then
|
||||||
|
echo ::set-env name=CLIENT_ONLY::FALSE
|
||||||
|
echo ::set-env name=INSTALLER::HighFidelity-Beta-$RELEASE_NUMBER-$GIT_COMMIT_SHORT.$INSTALLER_EXT
|
||||||
|
else
|
||||||
|
echo ::set-env name=CLIENT_ONLY::TRUE
|
||||||
|
echo ::set-env name=INSTALLER::HighFidelity-Beta-Interface-$RELEASE_NUMBER-$GIT_COMMIT_SHORT.$INSTALLER_EXT
|
||||||
|
fi
|
||||||
|
# Linux build variables
|
||||||
|
if [ "${{ matrix.os }}" = "ubuntu-latest" ]; then
|
||||||
|
echo ::set-env name=CLIENT_ONLY::FALSE
|
||||||
|
echo ::set-env name=PYTHON_EXEC::python3
|
||||||
|
echo ::set-env name=CMAKE_EXTRA::-DBUILD_TOOLS:BOOLEAN=FALSE
|
||||||
|
fi
|
||||||
|
# Mac build variables
|
||||||
|
if [ "${{ matrix.os }}" = "macOS-latest" ]; then
|
||||||
|
echo ::set-env name=PYTHON_EXEC::python3
|
||||||
|
echo ::set-env name=CMAKE_EXTRA::"-DCMAKE_XCODE_ATTRIBUTE_CODE_SIGNING_REQUIRED=OFF -DOPENSSL_ROOT_DIR=/usr/local/opt/openssl -G Xcode"
|
||||||
|
fi
|
||||||
|
# Windows build variables
|
||||||
|
if [ "${{ matrix.os }}" = "windows-latest" ]; then
|
||||||
|
echo ::set-env name=PYTHON_EXEC::python
|
||||||
|
echo ::set-env name=CMAKE_EXTRA::"-A x64"
|
||||||
|
echo ::set-env name=HF_PFX_PASSPHRASE::${{secrets.pfx_key}}
|
||||||
|
echo "::set-env name=HF_PFX_FILE::${{runner.workspace}}\build\codesign.pfx"
|
||||||
|
fi
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v1
|
||||||
|
with:
|
||||||
|
submodules: true
|
||||||
|
fetch-depth: 1
|
||||||
|
- name: Install python modules
|
||||||
|
run: $PYTHON_EXEC -m pip install boto3 PyGithub
|
||||||
|
- name: Create Build Environment
|
||||||
|
run: cmake -E make_directory ${{runner.workspace}}/build
|
||||||
|
|
||||||
#build_full_mac:
|
- name: Install apt packages (Linux)
|
||||||
- name: Configure CMake (macOS)
|
if: matrix.os == 'ubuntu-latest'
|
||||||
if: matrix.os == 'macOS-latest' && (github.event.action != 'labeled' || github.event.label.name == 'rebuild-mac' || github.event.label.name == 'rebuild')
|
run: sudo apt install -y mesa-common-dev libegl1 libglvnd-dev libdouble-conversion1 libpulse0
|
||||||
working-directory: ${{runner.workspace}}/build
|
- name: Configure CMake
|
||||||
run: cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DCMAKE_XCODE_ATTRIBUTE_CODE_SIGNING_REQUIRED=OFF -DOPENSSL_ROOT_DIR=/usr/local/opt/openssl -G Xcode -DVCPKG_APPLOCAL_DEPS=OFF
|
working-directory: ${{runner.workspace}}/build
|
||||||
- name: Build Console (macOS)
|
run: |
|
||||||
if: matrix.os == 'macOS-latest' && (github.event.action != 'labeled' || github.event.label.name == 'rebuild-mac' || github.event.label.name == 'rebuild')
|
echo '${{ toJson(env) }}'
|
||||||
working-directory: ${{runner.workspace}}/build
|
uname
|
||||||
run: cmake --build . --config $BUILD_TYPE --target packaged-server-console
|
cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DCLIENT_ONLY:BOOLEAN=$CLIENT_ONLY $CMAKE_EXTRA
|
||||||
- name: Build Application (macOS)
|
# macOS
|
||||||
if: matrix.os == 'macOS-latest' && (github.event.action != 'labeled' || github.event.label.name == 'rebuild-mac' || github.event.label.name == 'rebuild')
|
- name: Build Console (macOS)
|
||||||
working-directory: ${{runner.workspace}}/build
|
if: matrix.os == 'macOS-latest'
|
||||||
run: cmake --build . --config $BUILD_TYPE --target $APP_NAME
|
working-directory: ${{runner.workspace}}/build
|
||||||
- name: Build Domain Server (macOS)
|
run: cmake --build . --config $BUILD_TYPE --target packaged-server-console
|
||||||
if: matrix.os == 'macOS-latest' && (github.event.action != 'labeled' || github.event.label.name == 'rebuild-mac' || github.event.label.name == 'rebuild')
|
- name: Build Application (macOS)
|
||||||
shell: bash
|
if: matrix.os == 'macOS-latest'
|
||||||
working-directory: ${{runner.workspace}}/build
|
working-directory: ${{runner.workspace}}/build
|
||||||
run: cmake --build . --config $BUILD_TYPE --target domain-server
|
run: cmake --build . --config $BUILD_TYPE --target $APP_NAME
|
||||||
- name: Build Assignment Client (macOS)
|
- name: Build Domain Server (macOS)
|
||||||
if: matrix.os == 'macOS-latest' && (github.event.action != 'labeled' || github.event.label.name == 'rebuild-mac' || github.event.label.name == 'rebuild')
|
if: matrix.os == 'macOS-latest'
|
||||||
shell: bash
|
shell: bash
|
||||||
working-directory: ${{runner.workspace}}/build
|
working-directory: ${{runner.workspace}}/build
|
||||||
run: cmake --build . --config $BUILD_TYPE --target assignment-client
|
run: cmake --build . --config $BUILD_TYPE --target domain-server
|
||||||
- name: Build Installer (macOS)
|
- name: Build Assignment Client (macOS)
|
||||||
if: matrix.os == 'macOS-latest' && (github.event.action != 'labeled' || github.event.label.name == 'rebuild-mac' || github.event.label.name == 'rebuild')
|
if: matrix.os == 'macOS-latest'
|
||||||
working-directory: ${{runner.workspace}}/build
|
shell: bash
|
||||||
run: cmake --build . --config $BUILD_TYPE --target package
|
working-directory: ${{runner.workspace}}/build
|
||||||
|
run: cmake --build . --config $BUILD_TYPE --target assignment-client
|
||||||
|
- name: Build Installer (macOS)
|
||||||
|
if: matrix.os == 'macOS-latest'
|
||||||
|
working-directory: ${{runner.workspace}}/build
|
||||||
|
run: cmake --build . --config $BUILD_TYPE --target package
|
||||||
|
|
||||||
#build_full_win32:
|
#build_full_win32:
|
||||||
|
|
||||||
- name: Configure CMake (Windows)
|
- name: Build Console (Windows)
|
||||||
if: matrix.os == 'windows-latest' && (github.event.action != 'labeled' || github.event.label.name == 'rebuild-win' || github.event.label.name == 'rebuild')
|
if: matrix.os == 'windows-latest'
|
||||||
shell: bash
|
shell: bash
|
||||||
working-directory: ${{runner.workspace}}/build
|
working-directory: ${{runner.workspace}}/build
|
||||||
run: cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE -A x64
|
run: cmake --build . --config $BUILD_TYPE --target packaged-server-console
|
||||||
- name: Build Console (Windows)
|
- name: Build Application (Windows)
|
||||||
if: matrix.os == 'windows-latest' && (github.event.action != 'labeled' || github.event.label.name == 'rebuild-win' || github.event.label.name == 'rebuild')
|
if: matrix.os == 'windows-latest'
|
||||||
shell: bash
|
shell: bash
|
||||||
working-directory: ${{runner.workspace}}/build
|
working-directory: ${{runner.workspace}}/build
|
||||||
run: cmake --build . --config $BUILD_TYPE --target packaged-server-console
|
run: cmake --build . --config $BUILD_TYPE --target $APP_NAME
|
||||||
- name: Build Application (Windows)
|
- name: Build Domain Server (Windows)
|
||||||
if: matrix.os == 'windows-latest' && (github.event.action != 'labeled' || github.event.label.name == 'rebuild-win' || github.event.label.name == 'rebuild')
|
if: matrix.os == 'windows-latest'
|
||||||
shell: bash
|
shell: bash
|
||||||
working-directory: ${{runner.workspace}}/build
|
working-directory: ${{runner.workspace}}/build
|
||||||
run: cmake --build . --config $BUILD_TYPE --target $APP_NAME
|
run: cmake --build . --config $BUILD_TYPE --target domain-server
|
||||||
- name: Build Domain Server (Windows)
|
- name: Build Assignment Client (Windows)
|
||||||
if: matrix.os == 'windows-latest' && (github.event.action != 'labeled' || github.event.label.name == 'rebuild-win' || github.event.label.name == 'rebuild')
|
if: matrix.os == 'windows-latest'
|
||||||
shell: bash
|
shell: bash
|
||||||
working-directory: ${{runner.workspace}}/build
|
working-directory: ${{runner.workspace}}/build
|
||||||
run: cmake --build . --config $BUILD_TYPE --target domain-server
|
run: cmake --build . --config $BUILD_TYPE --target assignment-client
|
||||||
- name: Build Assignment Client (Windows)
|
- name: Build Installer (Windows)
|
||||||
if: matrix.os == 'windows-latest' && (github.event.action != 'labeled' || github.event.label.name == 'rebuild-win' || github.event.label.name == 'rebuild')
|
if: matrix.os == 'windows-latest'
|
||||||
shell: bash
|
shell: bash
|
||||||
working-directory: ${{runner.workspace}}/build
|
working-directory: ${{runner.workspace}}/build
|
||||||
run: cmake --build . --config $BUILD_TYPE --target assignment-client
|
run: cmake --build . --config $BUILD_TYPE --target package
|
||||||
- name: Build Installer (Windows)
|
#build_full_linux:
|
||||||
if: matrix.os == 'windows-latest' && (github.event.action != 'labeled' || github.event.label.name == 'rebuild-win' || github.event.label.name == 'rebuild')
|
|
||||||
shell: bash
|
|
||||||
working-directory: ${{runner.workspace}}/build
|
|
||||||
run: cmake --build . --config $BUILD_TYPE --target package
|
|
||||||
#build_full_linux:
|
|
||||||
|
|
||||||
- name: Install apt packages (Linux)
|
- name: Build (Linux)
|
||||||
if: matrix.os == 'ubuntu-latest' && (github.event.action != 'labeled' || github.event.label.name == 'rebuild-linux' || github.event.label.name == 'rebuild')
|
if: matrix.os == 'ubuntu-latest'
|
||||||
run: sudo apt install -y mesa-common-dev libegl1 libglvnd-dev libdouble-conversion1 libpulse0
|
shell: bash
|
||||||
- name: Configure CMake (Linux)
|
working-directory: ${{runner.workspace}}/build
|
||||||
if: matrix.os == 'ubuntu-latest' && (github.event.action != 'labeled' || github.event.label.name == 'rebuild-linux' || github.event.label.name == 'rebuild')
|
# Parallel make:
|
||||||
shell: bash
|
run: cmake --build . -- -j3
|
||||||
working-directory: ${{runner.workspace}}/build
|
- name: Build Ubuntu Docker (Linux)
|
||||||
run: cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DBUILD_TOOLS:BOOLEAN=false
|
if: matrix.os == 'ubuntu-latest'
|
||||||
- name: Build (Linux)
|
shell: bash
|
||||||
if: matrix.os == 'ubuntu-latest' && (github.event.action != 'labeled' || github.event.label.name == 'rebuild-linux' || github.event.label.name == 'rebuild')
|
working-directory: ${{runner.workspace}}/build
|
||||||
shell: bash
|
run: |
|
||||||
working-directory: ${{runner.workspace}}/build
|
cp $GITHUB_WORKSPACE/tools/ci-scripts/linux-gha/hifi.conf .
|
||||||
# Parallel make:
|
docker build -t $LINUX_DOCKER_IMAGE_NAME -f $GITHUB_WORKSPACE/tools/ci-scripts/linux-gha/Dockerfile ./
|
||||||
run: cmake --build . -- -j3
|
- name: Export Docker image (Linux)
|
||||||
- name: Build Ubuntu Docker (Linux)
|
if: matrix.os == 'ubuntu-latest'
|
||||||
if: matrix.os == 'ubuntu-latest' && (github.event.action != 'labeled' || github.event.label.name == 'rebuild-linux' || github.event.label.name == 'rebuild')
|
shell: bash
|
||||||
shell: bash
|
working-directory: ${{runner.workspace}}/build
|
||||||
working-directory: ${{runner.workspace}}/build
|
run: docker save -o ${{runner.workspace}}/build/hifi_docker_image.tar $LINUX_DOCKER_IMAGE_NAME
|
||||||
run: |
|
|
||||||
cp $GITHUB_WORKSPACE/tools/ci-scripts/linux-gha/hifi.conf .
|
|
||||||
docker build -t $LINUX_DOCKER_IMAGE_NAME -f $GITHUB_WORKSPACE/tools/ci-scripts/linux-gha/Dockerfile ./
|
|
||||||
- name: Export Docker image (Linux)
|
|
||||||
if: matrix.os == 'ubuntu-latest' && (github.event.action != 'labeled' || github.event.label.name == 'rebuild-linux' || github.event.label.name == 'rebuild')
|
|
||||||
shell: bash
|
|
||||||
working-directory: ${{runner.workspace}}/build
|
|
||||||
run: docker save -o ${{runner.workspace}}/build/hifi_docker_image.tar $LINUX_DOCKER_IMAGE_NAME
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue