Skip to content

Commit

Permalink
WIP: new CI config.
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisCummins committed Sep 10, 2021
1 parent 103762f commit db3d161
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 18 deletions.
19 changes: 6 additions & 13 deletions .github/actions/install-build-dependencies/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,25 +4,18 @@ description: Install build dependencies
runs:
using: composite
steps:
- name: Install dependencies (linux)
- name: Install dependencies
run: |
if [ "$(uname)" != "Darwin" ]; then
if [ "$(uname)" = "Darwin" ]; then
brew install bazelisk zlib
else
curl -L "https://github.com/bazelbuild/bazelisk/releases/download/v1.6.1/bazelisk-linux-amd64" > bazel
chmod +x bazel
sudo mv bazel /usr/local/bin/bazel
sudo apt-get install clang-9 patchelf
python -m pip install -U pip wheel
python -m pip install -r compiler_gym/requirements.txt
fi
shell: bash

- name: Install dependencies (macos)
run: |
if [ "$(uname)" = "Darwin" ]; then
brew install bazelisk zlib
python -m pip install -U pip wheel
python -m pip install -r compiler_gym/requirements.txt
fi
python -m pip install -U pip wheel
python -m pip install -r compiler_gym/requirements.txt
shell: bash
env:
LDFLAGS: -L/usr/local/opt/zlib/lib
Expand Down
14 changes: 14 additions & 0 deletions .github/actions/install-runtime-dependencies/action.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
name: Install runtime dependencies
description: Install the runtime dependencies for CompilerGym.
runs:
using: composite
steps:
- name: Install runtime dependencies
run: |
python -m pip install -U pip wheel
python -m pip install -r compiler_gym/requirements.txt
if [ "$(uname)" = "Darwin" ]; then
brew install zlib
fi
shell: bash
4 changes: 2 additions & 2 deletions .github/actions/install-test-dependencies/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@ description: Install the dependencies for running the test suite.
runs:
using: composite
steps:
- name: Install python dependencies
run: python -m pip install -r compiler_gym/requirements.txt -r examples/requirements.txt -r tests/requirements.txt
- name: Install test dependencies
run: python -m pip install -r examples/requirements.txt -r tests/requirements.txt
shell: bash
12 changes: 9 additions & 3 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,9 @@ jobs:
name: manylinux-wheel

- name: Install wheel
run: python -m pip install dist/*.whl
run: python -m pip install *.whl

- uses: ./.github/actions/install-runtime-dependencies

- uses: ./.github/actions/install-test-dependencies

Expand All @@ -110,7 +112,9 @@ jobs:
name: macos-wheel

- name: Install wheel
run: python -m pip install dist/*.whl
run: python -m pip install *.whl

- uses: ./.github/actions/install-runtime-dependencies

- uses: ./.github/actions/install-test-dependencies

Expand All @@ -129,7 +133,9 @@ jobs:
name: manylinux-wheel

- name: Install wheel
run: python -m pip install dist/*.whl
run: python -m pip install *.whl

- uses: ./.github/actions/install-runtime-dependencies

- uses: ./.github/actions/install-test-dependencies

Expand Down

0 comments on commit db3d161

Please sign in to comment.