Skip to content

Commit

Permalink
Windows debugging.
Browse files Browse the repository at this point in the history
  • Loading branch information
sunfishcode committed Sep 21, 2024
1 parent 04c48da commit 204352d
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 373 deletions.
41 changes: 0 additions & 41 deletions .cirrus.yml

This file was deleted.

333 changes: 1 addition & 332 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,231 +7,16 @@ on:
pull_request:

jobs:
rustfmt:
name: Rustfmt
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: true
- uses: ./.github/actions/install-rust
with:
toolchain: stable
- run: cargo fmt --all -- --check

check_cross:
name: Check Cross-Compilation
runs-on: ${{ matrix.os }}
strategy:
matrix:
build: [stable, beta]
include:
- build: stable
os: ubuntu-latest
rust: stable
- build: beta
os: ubuntu-latest
rust: beta

steps:
- uses: actions/checkout@v3
with:
submodules: true
- uses: ./.github/actions/install-rust
with:
toolchain: ${{ matrix.rust }}

- name: Install musl-tools
run: |
set -ex
sudo apt-get update
sudo apt-get install -y musl-tools
# Disable x86_64-pc-windows-msvc, x86_64-pc-windows-gnu,
# i686-pc-windows-msvc, and i686-pc-windows-gnu for now, since async-std
# doesn't currently support cross-compiling to Windows.
#
# Also disable x86_64-fuchsia and wasm32-unknown-emscripten, since
# async-std doesn't currently cross-compile on them.
- run: >
rustup target add
x86_64-unknown-linux-musl
x86_64-unknown-linux-gnux32
x86_64-linux-android
x86_64-apple-darwin
x86_64-unknown-freebsd
x86_64-unknown-netbsd
i686-unknown-linux-gnu
i686-unknown-linux-musl
- run: cargo check --workspace --bins --examples --tests --features=fs_utf8 --release -vv
- run: cargo check --workspace --bins --examples --tests --features=fs_utf8 --release -vv --target=x86_64-unknown-linux-musl
- run: cargo check --workspace --bins --examples --tests --features=fs_utf8 --release -vv --target=x86_64-unknown-linux-gnux32
- run: cargo check --workspace --bins --examples --tests --features=fs_utf8 --release -vv --target=x86_64-linux-android
- run: cargo check --workspace --bins --examples --tests --features=fs_utf8 --release -vv --target=x86_64-apple-darwin
- run: cargo check --workspace --bins --examples --tests --features=fs_utf8 --release -vv --target=x86_64-unknown-freebsd
- run: cargo check --workspace --bins --examples --tests --features=fs_utf8 --release -vv --target=x86_64-unknown-netbsd
- run: cargo check --workspace --bins --examples --tests --features=fs_utf8 --release -vv --target=i686-unknown-linux-gnu
- run: cargo check --workspace --bins --examples --tests --features=fs_utf8 --release -vv --target=i686-unknown-linux-musl

check_cross_windows:
name: Check Cross-Compilation on Windows
runs-on: ${{ matrix.os }}
strategy:
matrix:
build: [stable, beta]
include:
- build: stable
os: windows-latest
rust: stable
- build: beta
os: windows-latest
rust: beta

steps:
- uses: actions/checkout@v3
with:
submodules: true
- uses: ./.github/actions/install-rust
with:
toolchain: ${{ matrix.rust }}
- run: >
rustup target add
x86_64-pc-windows-gnu
i686-pc-windows-msvc
i686-pc-windows-gnu
- run: cargo check --workspace --bins --examples --tests --features=fs_utf8 --release -vv
- run: cargo check --workspace --bins --examples --tests --features=fs_utf8 --release -vv --target=x86_64-pc-windows-gnu
- run: cargo check --workspace --bins --examples --tests --features=fs_utf8 --release -vv --target=i686-pc-windows-msvc
- run: cargo check --workspace --bins --examples --tests --features=fs_utf8 --release -vv --target=i686-pc-windows-gnu

check_cross_nightly:
name: Check Cross-Compilation on Rust nightly
runs-on: ${{ matrix.os }}
strategy:
matrix:
build: [nightly]
include:
- build: nightly
os: ubuntu-latest
rust: nightly

steps:
- uses: actions/checkout@v3
with:
submodules: true
- uses: ./.github/actions/install-rust
with:
toolchain: ${{ matrix.rust }}

- name: Install musl-tools
run: |
set -ex
sudo apt-get update
sudo apt-get install -y musl-tools
# Disable x86_64-pc-windows-msvc, x86_64-pc-windows-gnu,
# i686-pc-windows-msvc, i686-pc-windows-gnu for now, and
# aarch64-pc-windows-msvc, since async-std doesn't currently support
# cross-compiling to Windows.
#
# Also disable x86_64-fuchsia and wasm32-unknown-emscripten, since
# async-std doesn't currently cross-compile on them.
- run: >
rustup target add
x86_64-unknown-linux-musl
x86_64-unknown-linux-gnux32
x86_64-linux-android
x86_64-apple-darwin
x86_64-unknown-freebsd
x86_64-unknown-netbsd
i686-unknown-linux-gnu
i686-unknown-linux-musl
aarch64-apple-darwin
riscv64gc-unknown-linux-gnu
arm-unknown-linux-gnueabihf
aarch64-linux-android
wasm32-wasi
- run: cargo check --workspace --all-targets --all-features --release -vv
- run: cargo check --workspace --all-targets --all-features --release -vv --target=x86_64-unknown-linux-musl
- run: cargo check --workspace --all-targets --all-features --release -vv --target=x86_64-unknown-linux-gnux32
- run: cargo check --workspace --all-targets --all-features --release -vv --target=x86_64-linux-android
- run: cargo check --workspace --all-targets --all-features --release -vv --target=x86_64-apple-darwin
- run: cargo check --workspace --all-targets --all-features --release -vv --target=x86_64-unknown-freebsd
- run: cargo check --workspace --all-targets --all-features --release -vv --target=x86_64-unknown-netbsd
- run: cargo check --workspace --all-targets --all-features --release -vv --target=i686-unknown-linux-gnu
- run: cargo check --workspace --all-targets --all-features --release -vv --target=i686-unknown-linux-musl
- run: cargo check --workspace --all-targets --all-features --release -vv --target=aarch64-apple-darwin
- run: cargo check --workspace --all-targets --all-features --release -vv --target=riscv64gc-unknown-linux-gnu
- run: cargo check --workspace --all-targets --all-features --release -vv --target=arm-unknown-linux-gnueabihf
- run: cargo check --workspace --all-targets --all-features --release -vv --target=aarch64-linux-android
- run: cd cap-std && cargo check --features=fs_utf8 --release -vv --target=wasm32-wasi

check_cross_nightly_windows:
name: Check Cross-Compilation on Rust nightly on Windows
runs-on: ${{ matrix.os }}
strategy:
matrix:
build: [nightly]
include:
- build: nightly
os: windows-latest
rust: nightly

steps:
- uses: actions/checkout@v3
with:
submodules: true
- uses: ./.github/actions/install-rust
with:
toolchain: ${{ matrix.rust }}
- run: >
rustup target add
x86_64-pc-windows-gnu
i686-pc-windows-msvc
i686-pc-windows-gnu
aarch64-pc-windows-msvc
- run: cargo check --workspace --all-targets --all-features --release -vv
- run: cargo check --workspace --all-targets --all-features --release -vv --target=x86_64-pc-windows-gnu
- run: cargo check --workspace --all-targets --all-features --release -vv --target=i686-pc-windows-msvc
- run: cargo check --workspace --all-targets --all-features --release -vv --target=i686-pc-windows-gnu
- run: cargo check --workspace --all-targets --all-features --release -vv --target=aarch64-pc-windows-msvc

test:
name: Test
runs-on: ${{ matrix.os }}
strategy:
matrix:
build: [stable, windows-latest, windows-2019, macos-latest, macos-12, beta, ubuntu-20.04, aarch64-ubuntu]
build: [windows-latest]
include:
- build: stable
os: ubuntu-latest
rust: stable
- build: windows-latest
os: windows-latest
rust: stable
- build: windows-2019
os: windows-2019
rust: stable
- build: macos-latest
os: macos-latest
rust: stable
- build: macos-11
os: macos-11
rust: stable
- build: beta
os: ubuntu-latest
rust: beta
- build: ubuntu-20.04
os: ubuntu-20.04
rust: stable
- build: aarch64-ubuntu
os: ubuntu-latest
rust: stable
target: aarch64-unknown-linux-gnu
gcc_package: gcc-aarch64-linux-gnu
gcc: aarch64-linux-gnu-gcc
qemu: qemu-aarch64 -L /usr/aarch64-linux-gnu
qemu_target: aarch64-linux-user

steps:
- uses: actions/checkout@v3
Expand Down Expand Up @@ -275,119 +60,3 @@ jobs:
env:
RUST_BACKTRACE: 1
if: matrix.target != ''

test_nightly:
name: Test with Rust nightly
runs-on: ${{ matrix.os }}
strategy:
matrix:
build: [ubuntu, windows]
include:
- build: ubuntu
os: ubuntu-latest
rust: nightly
- build: windows
os: windows-latest
rust: nightly

steps:
- uses: actions/checkout@v3
with:
submodules: true
- uses: ./.github/actions/install-rust
with:
toolchain: ${{ matrix.rust }}
- run: cargo test --all-features --workspace

test_musl:
name: Test on Musl
runs-on: ${{ matrix.os }}
strategy:
matrix:
build: [ubuntu]
include:
- build: ubuntu
os: ubuntu-latest
rust: stable

steps:
- uses: actions/checkout@v3
with:
submodules: true
- uses: ./.github/actions/install-rust
with:
toolchain: ${{ matrix.rust }}

- name: Install musl-tools
run: |
set -ex
sudo apt-get update
sudo apt-get install -y musl-tools
- run: rustup target add x86_64-unknown-linux-musl
- run: cargo test --target x86_64-unknown-linux-musl --features fs_utf8 --workspace

test_linux_raw:
name: Test linux-raw support
runs-on: ${{ matrix.os }}
strategy:
matrix:
build: [ubuntu, ubuntu-20.04]
include:
- build: ubuntu
os: ubuntu-latest
rust: nightly
- build: ubuntu-20.04
os: ubuntu-20.04
rust: nightly

env:
RUSTFLAGS: --cfg linux_raw
RUSTDOCFLAGS: --cfg linux_raw
steps:
- uses: actions/checkout@v3
with:
submodules: true
- uses: ./.github/actions/install-rust
with:
toolchain: ${{ matrix.rust }}
- run: cargo test --all-features --workspace

test_msrv:
name: Test
runs-on: ${{ matrix.os }}
strategy:
matrix:
build: [msrv]
include:
- build: msrv
os: ubuntu-latest
rust: 1.63

steps:
- uses: actions/checkout@v3
with:
submodules: true
- uses: ./.github/actions/install-rust
with:
toolchain: ${{ matrix.rust }}
# Don't use --all-features because some of the features have dependencies
# that don't work on newer Rust versions.
- run: cargo test --workspace --features=fs_utf8,arf_strings
env:
RUST_BACKTRACE: 1

fuzz_targets:
name: Fuzz Targets
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: true
- uses: ./.github/actions/install-rust
with:
toolchain: nightly
- run: cargo install cargo-fuzz --vers "^0.11"
- run: cargo fetch
working-directory: ./fuzz
- run: cargo fuzz build --dev
Loading

0 comments on commit 204352d

Please sign in to comment.