-
Notifications
You must be signed in to change notification settings - Fork 3
97 lines (97 loc) · 3.28 KB
/
rust.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
# This workflow is based on tg-rust-g/.github/workflows/rust.yml
# It has very minor modifications to be compatible with this
name: rust-g
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
build-windows:
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: "Apply Paradise Patches"
run: |
git config --global user.email "[email protected]"
git config --global user.name "CI User"
./apply_patches.sh
shell: bash
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
target: i686-pc-windows-msvc
- name: Check (all features)
uses: actions-rs/cargo@v1
with:
toolchain: stable
command: check
args: --manifest-path paradise-rust-g/Cargo.toml --target i686-pc-windows-msvc --features all
- name: Build (release) (default features)
uses: actions-rs/cargo@v1
with:
toolchain: stable
command: build
args: --manifest-path paradise-rust-g/Cargo.toml --target i686-pc-windows-msvc --release --features all
- uses: actions/upload-artifact@v4
with:
name: rust_g.dll
path: paradise-rust-g/target/i686-pc-windows-msvc/release/rust_g.dll
build-linux:
runs-on: ubuntu-latest
env:
BYOND_MAJOR: 515
BYOND_MINOR: 1642
PKG_CONFIG_ALLOW_CROSS: 1
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: "Apply Paradise Patches"
run: |
git config --global user.email "[email protected]"
git config --global user.name "CI User"
./apply_patches.sh
- run: |
sudo dpkg --add-architecture i386
sudo apt-get update
sudo apt-get install g++-multilib zlib1g-dev:i386 libssl-dev:i386 libdbus-1-dev
./paradise-rust-g/scripts/install_byond.sh
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
target: i686-unknown-linux-gnu
- name: Check (all features)
uses: actions-rs/cargo@v1
with:
toolchain: stable
command: check
args: --manifest-path paradise-rust-g/Cargo.toml --target i686-unknown-linux-gnu --features all
- name: Build (Debug) (all features)
uses: actions-rs/cargo@v1
with:
toolchain: stable
command: build
args: --manifest-path paradise-rust-g/Cargo.toml --target i686-unknown-linux-gnu --features all
- name: Run tests (all features)
uses: actions-rs/cargo@v1
with:
toolchain: stable
command: test
args: --manifest-path paradise-rust-g/Cargo.toml --target i686-unknown-linux-gnu --features all
env:
BYOND_BIN: /home/runner/BYOND/byond/bin
- name: Build (release) (default features)
uses: actions-rs/cargo@v1
with:
toolchain: stable
command: build
args: --manifest-path paradise-rust-g/Cargo.toml --target i686-unknown-linux-gnu --release --features all
- uses: actions/upload-artifact@v4
with:
name: rust_g
path: paradise-rust-g/target/i686-unknown-linux-gnu/release/librust_g.so