Skip to content

Commit

Permalink
Update CI
Browse files Browse the repository at this point in the history
  • Loading branch information
larseggert committed Mar 13, 2024
1 parent 0b34b7f commit 012e715
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 109 deletions.
68 changes: 0 additions & 68 deletions .github/actions/nss/action.yml

This file was deleted.

3 changes: 0 additions & 3 deletions .github/workflows/bench.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,6 @@ jobs:
version: $TOOLCHAIN
components: rustfmt

- name: Fetch and build NSS and NSPR
uses: ./.github/actions/nss

- name: Build
run: |
cargo "+$TOOLCHAIN" bench --features bench --no-run
Expand Down
41 changes: 3 additions & 38 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,65 +46,30 @@ jobs:
env:
DEBIAN_FRONTEND: noninteractive
run: |
sudo apt-get install -y --no-install-recommends gyp mercurial ninja-build lld
sudo apt-get install -y --no-install-recommends lld libnss3-dev
echo "RUSTFLAGS=-C link-arg=-fuse-ld=lld" >> "$GITHUB_ENV"
# In addition to installing dependencies, first make sure System Integrity Protection (SIP)
# is disabled on this MacOS runner. This is needed to allow the NSS libraries to be loaded
# from the build directory and avoid various other test failures. This seems to always be
# the case on any macos-13 runner, but not consistently on macos-latest (which is currently
# macos-12, FWIW).
- name: Install dependencies (MacOS)
if: runner.os == 'MacOS'
run: |
csrutil status | grep disabled
brew install ninja mercurial llvm
brew install llvm nss
echo "/opt/homebrew/opt/llvm/bin" >> "$GITHUB_PATH"
ln -s /opt/homebrew/bin/python3 /opt/homebrew/bin/python
# python3 -m pip install gyp-next
# Above does not work, since pypi only has gyp 0.15.0, which is too old
# for the homebrew python3. Install from source instead.
python3 -m pip install git+https://github.com/nodejs/gyp-next
python3 -m pip install packaging
echo "$(python3 -m site --user-base)/bin" >> "$GITHUB_PATH"
echo "RUSTFLAGS=-C link-arg=-fuse-ld=lld" >> "$GITHUB_ENV"
- name: Use MSYS2 environment and install more dependencies (Windows)
if: runner.os == 'Windows'
run: |
# shellcheck disable=SC2028
{
echo "C:\\msys64\\usr\\bin"
echo "C:\\msys64\\mingw64\\bin"
} >> "$GITHUB_PATH"
/c/msys64/usr/bin/pacman -S --noconfirm nsinstall
python3 -m pip install git+https://github.com/nodejs/gyp-next
echo "$(python3 -m site --user-base)/bin" >> "$GITHUB_PATH"
run: /c/msys64/usr/bin/pacman -S --noconfirm nss

- name: Set up MSVC build environment (Windows)
if: runner.os == 'Windows'
uses: ilammy/msvc-dev-cmd@v1

- name: Set up NSS/NSPR build environment (Windows)
if: runner.os == 'Windows'
run: |
{
echo "GYP_MSVS_OVERRIDE_PATH=$VSINSTALLDIR"
echo "GYP_MSVS_VERSION=2022"
echo "BASH=$SHELL"
} >> "$GITHUB_ENV"
# See https://github.com/ilammy/msvc-dev-cmd#name-conflicts-with-shell-bash
rm /usr/bin/link.exe
- name: Install Rust
uses: ./.github/actions/rust
with:
version: ${{ matrix.rust-toolchain }}
components: rustfmt, clippy, llvm-tools-preview

- name: Fetch and build NSS and NSPR
uses: ./.github/actions/nss

- name: Build
run: |
# shellcheck disable=SC2086
Expand Down

0 comments on commit 012e715

Please sign in to comment.