Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bump to "latest" rustg #2

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .cargo/config
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
[target.i686-pc-windows-msvc]
rustflags = ["-C", "target-feature=+crt-static"]

[target.i686-win7-windows-msvc]
rustflags = ["-C", "target-feature=+crt-static"]

[target.x86_64-pc-windows-msvc]
rustflags = ["-C", "target-feature=+crt-static"]
3 changes: 3 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,6 @@ insert_final_newline = true

[*.dm]
indent_style = tab

[*.yml]
indent_size = 2
24 changes: 12 additions & 12 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,35 +12,35 @@ jobs:
steps:
- uses: actions/checkout@v4

- uses: dtolnay/rust-toolchain@stable
- uses: dtolnay/rust-toolchain@nightly
with:
targets: i686-pc-windows-msvc
components: rustfmt, clippy
targets: x86_64-pc-windows-msvc
components: clippy, rustfmt, rust-src

- uses: Swatinem/rust-cache@v2

- name: Clippy (all features)
run: cargo clippy --target i686-pc-windows-msvc --features all --locked -- -D warnings
run: cargo clippy -Z build-std --target i686-win7-windows-msvc --features all --locked -- -D warnings

- name: Rustfmt
run: cargo fmt -- --check

- name: Build (release) (default features)
run: cargo build --target i686-pc-windows-msvc --locked --release
run: cargo build -Z build-std --target i686-win7-windows-msvc --locked --release

- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
with:
name: Windows Build
path: |
target/i686-pc-windows-msvc/release/rust_g.dll
target/i686-pc-windows-msvc/release/rust_g.pdb
target/i686-win7-windows-msvc/release/rust_g.dll
target/i686-win7-windows-msvc/release/rust_g.pdb
target/rust_g.dm

build-linux:
runs-on: ubuntu-latest
env:
BYOND_MAJOR: 514
BYOND_MINOR: 1585
BYOND_MAJOR: 515
BYOND_MINOR: 1642
PKG_CONFIG_ALLOW_CROSS: 1

steps:
Expand All @@ -52,7 +52,7 @@ jobs:
sudo apt-get install libgcc-s1:i386 g++-multilib zlib1g-dev:i386
./scripts/install_byond.sh

- uses: dtolnay/rust-toolchain@stable
- uses: dtolnay/rust-toolchain@nightly
with:
targets: i686-unknown-linux-gnu

Expand All @@ -72,7 +72,7 @@ jobs:
- name: Build (release) (default features)
run: cargo build --target i686-unknown-linux-gnu --locked --release

- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
with:
name: Linux Build
path: |
Expand Down
2 changes: 1 addition & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"rust-analyzer.cargo.target": "i686-pc-windows-msvc",
"rust-analyzer.linkedProjects": [
".\\Cargo.toml"
"Cargo.toml"
]
}
33 changes: 33 additions & 0 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "rust: cargo build (win32)",
"args": [
"build",
"--target",
"i686-pc-windows-msvc",
],
"command": "cargo",
"problemMatcher": [
"$rustc"
],
"group": "build"
},
{
"label": "rust: cargo build (win32, all features)",
"args": [
"build",
"--target",
"i686-pc-windows-msvc",
"--features",
"all",
],
"command": "cargo",
"problemMatcher": [
"$rustc"
],
"group": "build"
},
]
}
Loading