Skip to content

Commit c91bf8b

Browse files
committed
Fix CI
1 parent e26f70c commit c91bf8b

File tree

2 files changed

+12
-3
lines changed

2 files changed

+12
-3
lines changed

.github/workflows/ci.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,15 @@ jobs:
227227
override: true
228228

229229
- name: Install System FFmpeg
230-
run: sudo apt-get install ffmpeg
230+
run: |
231+
sudo apt-get install libavcodec-dev
232+
sudo apt-get install libavdevice-dev
233+
sudo apt-get install libavfilter-dev
234+
sudo apt-get install libavformat-dev
235+
sudo apt-get install libavutil-dev
236+
sudo apt-get install libpostproc-dev
237+
sudo apt-get install libswresample-dev
238+
sudo apt-get install libswscale-dev
231239
232240
- name: Binding Build
233241
run: cargo build --verbose

build.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -119,15 +119,15 @@ fn probe_system_ffmpeg() -> Result<(), String> {
119119
match (&*LIBS)
120120
.iter()
121121
.map(|name| "lib".to_owned() + name)
122-
.filter_map(|libname| {
122+
.find(|libname| {
123123
pkgconfig::Config::new()
124124
.statik(true)
125125
// Remove side effect
126126
.cargo_metadata(false)
127127
.probe(&libname)
128128
.is_err()
129129
}) {
130-
Some(libname) => Err(format!("{} not found!", libname)),
130+
Some(libname) => Err(format!("{} not found", libname)),
131131
None => Ok(()),
132132
}
133133
}
@@ -150,6 +150,7 @@ fn main() {
150150
match probe_system_ffmpeg() {
151151
// No system FFmpeg found, download and build one
152152
Err(msg) => {
153+
eprintln!(msg + "! Try to git clone an FFmpeg and build");
153154
// All outputs are stored in ./ffmpeg/build/{bin, lib, share, include}
154155
// If no prebuilt FFmpeg libraries provided, we custom build a FFmpeg.
155156
env::set_var(

0 commit comments

Comments
 (0)