Skip to content

Commit

Permalink
skipbits
Browse files Browse the repository at this point in the history
  • Loading branch information
johnhaddon committed Jan 3, 2024
1 parent 9a292bc commit fa9e2d0
Showing 1 changed file with 89 additions and 89 deletions.
178 changes: 89 additions & 89 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,95 +82,95 @@ jobs:

- uses: actions/checkout@v3

- uses: ilammy/msvc-dev-cmd@v1.12.1
with:
sdk: 10.0.17763.0

- name: Install toolchain (Windows)
run: |
python -m pip install scons
Invoke-WebRequest -Uri "https://inkscape.org/gallery/item/37363/inkscape-1.2.2_2022-12-09_732a01da63-x64.exe" -OutFile "inkscape.exe"
Start-Process .\inkscape.exe /S -NoNewWindow -Wait
shell: pwsh
if: runner.os == 'Windows'

- name: Install toolchain (Linux)
run: |
Xvfb :99 -screen 0 1280x1024x24 &
metacity --display :99.0 &
useradd -m testUser
echo LD_PRELOAD=libSegFault.so >> $GITHUB_ENV
# The Docker container configures bash shells such that they enable the
# software collections we want. If we could set GitHub's
# `defaults.run.shell` to `bash` then all our build steps would pick up
# this environment automatically. But we can't do that because it
# breaks the build on Windows, and we can't configure a different shell
# per platform because GitHub won't allow it. But we can run _this_
# Linux-only step in bash, and transfer the environment out to be used
# in later steps.
echo $PATH > $GITHUB_PATH
echo LD_LIBRARY_PATH=$LD_LIBRARY_PATH >> $GITHUB_ENV
echo DISPLAY=:99.0 >> $GITHUB_ENV
shell: bash
if: runner.os == 'Linux'

- name: 'Install Python Modules'
run: |
python --version
pip install PyJWT==1.7.1 PyGitHub==1.45
- name: Set Custom Variables
run: |
.github/workflows/main/setBuildVars.py
echo GAFFER_SPHINX=`which sphinx-build` >> $GITHUB_ENV
env:
GITHUB_ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GAFFER_BUILD_VARIANT: ${{ matrix.name }}
shell: bash

- name: Install dependencies
# The `$GITHUB_ENV` shenanigans creates an environment variable
# containing the hash of the archive, for use in the cache key
# below.
run: |
echo GAFFER_DEPENDENCIES_HASH=`python .github/workflows/main/installDependencies.py --archiveURL ${{ matrix.dependenciesURL }} --dependenciesDir ${{ env.GAFFER_BUILD_DIR }} --outputFormat "{archiveDigest}"` >> $GITHUB_ENV
./.github/workflows/main/installDelight.py
echo DELIGHT=$GITHUB_WORKSPACE/3delight >> $GITHUB_ENV
shell: bash

- name: Install Mesa (Windows)
# Installed after dependencies to avoid errors from python related to existing directory `bin`.
# Adapted from Mesa's `systemwidedeploy.cmd` `osmesa` branch.
run: |
curl.exe -L --output mesa.7z --url https://github.com/pal1000/mesa-dist-win/releases/download/22.3.1/mesa3d-22.3.1-release-msvc.7z
& "C:\Program Files\7-Zip\7z.exe" x mesa.7z -omesa
./mesa/systemwidedeploy.cmd 1
shell: pwsh
if: runner.os == 'Windows'

- name: Cache
uses: actions/cache@v3
with:
path: ${{ env.GAFFER_CACHE_DIR }}
key: ${{ runner.os }}-${{ matrix.containerImage }}-${{env.GAFFER_DEPENDENCIES_HASH}}-${{ matrix.buildType }}-${{ github.sha }}
restore-keys: |
${{ runner.os }}-${{ matrix.containerImage }}-${{env.GAFFER_DEPENDENCIES_HASH}}-${{ matrix.buildType }}-
- name: Build Gaffer
run: |
scons -j 2 build BUILD_TYPE=${{ matrix.buildType }} OPTIONS=.github/workflows/main/sconsOptions
env:
PYTHONUTF8: 1

- name: Test
# Tests should complete in well under an hour. If they don't it's most likely because
# of a hang, in which case we'd like to know more quickly than the default 6hr timeout
# allows.
timeout-minutes: 60
run: |
echo "::add-matcher::./.github/workflows/main/problemMatchers/unittest.json"
${{ matrix.testRunner }} "${{ env.GAFFER_BUILD_DIR }}/bin/gaffer test ${{ matrix.testArguments }}"
echo "::remove-matcher owner=unittest::"
# - uses: ilammy/msvc-dev-cmd@v1.12.1
# with:
# sdk: 10.0.17763.0

# - name: Install toolchain (Windows)
# run: |
# python -m pip install scons
# Invoke-WebRequest -Uri "https://inkscape.org/gallery/item/37363/inkscape-1.2.2_2022-12-09_732a01da63-x64.exe" -OutFile "inkscape.exe"
# Start-Process .\inkscape.exe /S -NoNewWindow -Wait
# shell: pwsh
# if: runner.os == 'Windows'

# - name: Install toolchain (Linux)
# run: |
# Xvfb :99 -screen 0 1280x1024x24 &
# metacity --display :99.0 &
# useradd -m testUser
# echo LD_PRELOAD=libSegFault.so >> $GITHUB_ENV
# # The Docker container configures bash shells such that they enable the
# # software collections we want. If we could set GitHub's
# # `defaults.run.shell` to `bash` then all our build steps would pick up
# # this environment automatically. But we can't do that because it
# # breaks the build on Windows, and we can't configure a different shell
# # per platform because GitHub won't allow it. But we can run _this_
# # Linux-only step in bash, and transfer the environment out to be used
# # in later steps.
# echo $PATH > $GITHUB_PATH
# echo LD_LIBRARY_PATH=$LD_LIBRARY_PATH >> $GITHUB_ENV
# echo DISPLAY=:99.0 >> $GITHUB_ENV
# shell: bash
# if: runner.os == 'Linux'

# - name: 'Install Python Modules'
# run: |
# python --version
# pip install PyJWT==1.7.1 PyGitHub==1.45

# - name: Set Custom Variables
# run: |
# .github/workflows/main/setBuildVars.py
# echo GAFFER_SPHINX=`which sphinx-build` >> $GITHUB_ENV
# env:
# GITHUB_ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# GAFFER_BUILD_VARIANT: ${{ matrix.name }}
# shell: bash

# - name: Install dependencies
# # The `$GITHUB_ENV` shenanigans creates an environment variable
# # containing the hash of the archive, for use in the cache key
# # below.
# run: |
# echo GAFFER_DEPENDENCIES_HASH=`python .github/workflows/main/installDependencies.py --archiveURL ${{ matrix.dependenciesURL }} --dependenciesDir ${{ env.GAFFER_BUILD_DIR }} --outputFormat "{archiveDigest}"` >> $GITHUB_ENV
# ./.github/workflows/main/installDelight.py
# echo DELIGHT=$GITHUB_WORKSPACE/3delight >> $GITHUB_ENV
# shell: bash

# - name: Install Mesa (Windows)
# # Installed after dependencies to avoid errors from python related to existing directory `bin`.
# # Adapted from Mesa's `systemwidedeploy.cmd` `osmesa` branch.
# run: |
# curl.exe -L --output mesa.7z --url https://github.com/pal1000/mesa-dist-win/releases/download/22.3.1/mesa3d-22.3.1-release-msvc.7z
# & "C:\Program Files\7-Zip\7z.exe" x mesa.7z -omesa
# ./mesa/systemwidedeploy.cmd 1
# shell: pwsh
# if: runner.os == 'Windows'

# - name: Cache
# uses: actions/cache@v3
# with:
# path: ${{ env.GAFFER_CACHE_DIR }}
# key: ${{ runner.os }}-${{ matrix.containerImage }}-${{env.GAFFER_DEPENDENCIES_HASH}}-${{ matrix.buildType }}-${{ github.sha }}
# restore-keys: |
# ${{ runner.os }}-${{ matrix.containerImage }}-${{env.GAFFER_DEPENDENCIES_HASH}}-${{ matrix.buildType }}-

# - name: Build Gaffer
# run: |
# scons -j 2 build BUILD_TYPE=${{ matrix.buildType }} OPTIONS=.github/workflows/main/sconsOptions
# env:
# PYTHONUTF8: 1

# - name: Test
# # Tests should complete in well under an hour. If they don't it's most likely because
# # of a hang, in which case we'd like to know more quickly than the default 6hr timeout
# # allows.
# timeout-minutes: 60
# run: |
# echo "::add-matcher::./.github/workflows/main/problemMatchers/unittest.json"
# ${{ matrix.testRunner }} "${{ env.GAFFER_BUILD_DIR }}/bin/gaffer test ${{ matrix.testArguments }}"
# echo "::remove-matcher owner=unittest::"

- name: Build and test Arnold extension
run: |
Expand Down

0 comments on commit fa9e2d0

Please sign in to comment.