Skip to content

Commit

Permalink
rustc v1.78, nightly, and glibc fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
DougAnderson444 committed Nov 10, 2024
1 parent 5232315 commit 5372bb5
Showing 1 changed file with 16 additions and 4 deletions.
20 changes: 16 additions & 4 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ jobs:
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: 1.76.0
toolchain: 1.78.0
target: wasm32-unknown-unknown
override: true
- name: Download and install Trunk binary
Expand Down Expand Up @@ -131,24 +131,36 @@ jobs:
- uses: actions/checkout@master
- name: Install build dependencies - Rustup
run: |
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- --default-toolchain stable --profile default --target ${{ matrix.TARGET }} -y
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- --default-toolchain nightly --profile default --target ${{ matrix.TARGET }} -y
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
# For linux, it's necessary to use cross from the git repository to avoid glibc problems
# Ref: https://github.com/cross-rs/cross/issues/1510
- name: Install cross for linux
if: contains(matrix.TARGET, 'linux')
run: |
cargo install cross --git https://github.com/cross-rs/cross --rev 1b8cf50d20180c1a394099e608141480f934b7f7
cargo install cross --git https://github.com/cross-rs/cross --rev 4090beca3cfffa44371a5bba524de3a578aa46c3
- name: Install cross for mac and windows
- name: Install cross for mac and windows
if: ${{ !contains(matrix.TARGET, 'linux') }}
run: |
cargo install cross
- name: Install dependencies
if: contains(matrix.TARGET, 'linux')
run: |
sudo apt-get update
sudo apt-get install -y libglib2.0-dev pkg-config
- name: Set PKG_CONFIG_PATH
if: contains(matrix.TARGET, 'linux')
run: echo "PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/share/pkgconfig" >> $GITHUB_ENV

- name: Build
run: |
cross build --verbose --release --target=${{ matrix.TARGET }}
env:
PKG_CONFIG_ALLOW_CROSS: 1

- name: Rename
run: cp target/${{ matrix.TARGET }}/release/egui-multinode${{ matrix.EXTENSION }} egui-multinode-${{ matrix.TARGET }}${{ matrix.EXTENSION }}
Expand Down

0 comments on commit 5372bb5

Please sign in to comment.