Skip to content

Commit 3d478d7

Browse files
committed
Build FFmpeg with v4l2 support for Linux
So that --v4l2-sink works with Linux static builds.
1 parent 54e1f8e commit 3d478d7

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

.github/workflows/release.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,8 @@ jobs:
7777
sudo apt update
7878
sudo apt install -y meson ninja-build nasm ffmpeg libsdl2-2.0-0 \
7979
libsdl2-dev libavcodec-dev libavdevice-dev libavformat-dev \
80-
libavutil-dev libswresample-dev libusb-1.0-0 libusb-1.0-0-dev
80+
libavutil-dev libswresample-dev libusb-1.0-0 libusb-1.0-0-dev \
81+
libv4l-dev
8182
8283
- name: Test
8384
run: release/test_client.sh
@@ -93,7 +94,8 @@ jobs:
9394
sudo apt update
9495
sudo apt install -y meson ninja-build nasm ffmpeg libsdl2-2.0-0 \
9596
libsdl2-dev libavcodec-dev libavdevice-dev libavformat-dev \
96-
libavutil-dev libswresample-dev libusb-1.0-0 libusb-1.0-0-dev
97+
libavutil-dev libswresample-dev libusb-1.0-0 libusb-1.0-0-dev \
98+
libv4l-dev
9799
98100
- name: Build linux
99101
run: release/build_linux.sh

app/deps/ffmpeg.sh

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,14 @@ else
8181
--enable-muxer=wav
8282
)
8383

84-
if [[ "$HOST" != linux ]]
84+
if [[ "$HOST" == linux ]]
8585
then
86+
conf+=(
87+
--enable-libv4l2
88+
--enable-outdev=v4l2
89+
--enable-encoder=rawvideo
90+
)
91+
else
8692
# libavdevice is only used for V4L2 on Linux
8793
conf+=(
8894
--disable-avdevice

0 commit comments

Comments
 (0)