Skip to content

Commit e56e35e

Browse files
committed
Update GitHub Actions
1 parent af51e48 commit e56e35e

File tree

2 files changed

+42
-9
lines changed

2 files changed

+42
-9
lines changed

.github/workflows/speexdsp.yml

+41-9
Original file line numberDiff line numberDiff line change
@@ -3,42 +3,74 @@ name: speexdsp
33
on: [push, pull_request]
44

55
jobs:
6-
rustfmt:
6+
7+
rustfmt-clippy:
78

89
runs-on: ubuntu-latest
910

11+
env:
12+
SPEEX_DIR: speex-dir
13+
1014
steps:
11-
- uses: actions/checkout@v1
15+
- uses: actions/checkout@v2
16+
1217
- name: Install stable
1318
uses: actions-rs/toolchain@v1
1419
with:
1520
profile: minimal
1621
toolchain: stable
1722
override: true
18-
components: rustfmt
23+
components: rustfmt, clippy
24+
1925
- name: Run rustfmt
2026
uses: actions-rs/cargo@v1
2127
with:
2228
command: fmt
2329
args: -- --check --verbose
2430

31+
- name: Install speexdsp
32+
run: |
33+
git clone https://github.com/xiph/speexdsp.git
34+
cd speexdsp
35+
./autogen.sh
36+
./configure --prefix=$HOME/$SPEEX_DIR
37+
make -j4 install
38+
39+
- name: Set environment variables
40+
run: |
41+
echo "::set-env name=PKG_CONFIG_PATH::$HOME/$SPEEX_DIR/lib/pkgconfig"
42+
echo "::set-env name=LD_LIBRARY_PATH::$HOME/$SPEEX_DIR/lib"
43+
44+
- name: Run clippy
45+
uses: actions-rs/clippy-check@v1
46+
with:
47+
token: ${{ secrets.GITHUB_TOKEN }}
48+
args: --all-features -- --verbose
49+
2550
build:
2651

52+
env:
53+
SPEEX_DIR: speex-dir
54+
2755
runs-on: ubuntu-latest
2856

2957
steps:
30-
- uses: actions/checkout@v1
58+
- uses: actions/checkout@v2
59+
3160
- name: Install speexdsp
3261
run: |
3362
git clone https://github.com/xiph/speexdsp.git
3463
cd speexdsp
3564
./autogen.sh
36-
./configure --prefix=$HOME/speex_dir
37-
make
38-
make install
65+
./configure --prefix=$HOME/$SPEEX_DIR
66+
make -j4 install
67+
68+
- name: Set environment variables
69+
run: |
70+
echo "::set-env name=PKG_CONFIG_PATH::$HOME/$SPEEX_DIR/lib/pkgconfig"
71+
echo "::set-env name=LD_LIBRARY_PATH::$HOME/$SPEEX_DIR/lib"
72+
3973
- name: Run tests
4074
run: |
41-
export PKG_CONFIG_PATH=$HOME/speex_dir/lib/pkgconfig:$PKG_CONFIG_PATH
42-
export LD_LIBRARY_PATH=$HOME/speex_dir/lib:$LD_LIBRARY_PATH
4375
cargo test --all-features
4476
cargo test --no-default-features

rustfmt.toml

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
max_width = 79

0 commit comments

Comments
 (0)