Skip to content

Commit d4af228

Browse files
committed
3.1.0
Support librav1e for ffmpeg 4.4 installation script.
1 parent 3553c16 commit d4af228

File tree

1 file changed

+23
-3
lines changed

1 file changed

+23
-3
lines changed

install-ffmpeg-4_4.sh

Lines changed: 23 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,16 +25,25 @@ function mcd {
2525
}
2626

2727
msg "Install apt packages."
28-
sudo apt-get update -qq && sudo apt-get -y install \
28+
sudo apt-get update -qq || fail
29+
sudo apt-get -y install \
2930
autoconf automake build-essential cmake \
3031
git-core libass-dev libfreetype6-dev \
3132
libgnutls28-dev libsdl2-dev libtool \
3233
libva-dev libvdpau-dev libvorbis-dev \
3334
libxcb1-dev libxcb-shm0-dev libxcb-xfixes0-dev \
3435
meson ninja-build pkg-config texinfo wget yasm \
3536
zlib1g-dev libunistring-dev libssl-dev \
36-
libc6 libc6-dev unzip libnuma1 libnuma-dev || fail
37+
libc6 libc6-dev unzip libnuma1 libnuma-dev \
38+
perl clang || fail
3739

40+
msg "Install rustc and cargo 1.53.0."
41+
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh || fail
42+
source $HOME/.cargo/env || fail
43+
rustup toolchain install 1.53.0 || fail
44+
cargo install cargo-c || fail
45+
46+
msg "Install the newest meson."
3847
sudo pip3 install --user meson || fail
3948

4049
sudo apt-get -y upgrade || fail
@@ -169,10 +178,21 @@ ninja -j $(nproc) || fail
169178
sudo ninja install || fail
170179
sudo cp $BUILD_PATH/bin/vmaf $BIN_PATH || fail
171180

181+
# Install dependencies: librav1e
182+
msg "Install rav1e p20210713."
183+
cd $SOURCE_PATH || fail
184+
git -C rav1e pull 2> /dev/null || git clone --depth 1 -b p20210713 --single-branch https://github.com/xiph/rav1e.git
185+
cd rav1e || fail
186+
cargo cbuild --release || fail
187+
sudo cp target/x86_64-unknown-linux-gnu/release/rav1e.h $BUILD_PATH/include/
188+
sudo cp -r target/x86_64-unknown-linux-gnu/release/rav1e $BUILD_PATH/include/
189+
sudo cp target/x86_64-unknown-linux-gnu/release/rav1e.pc $BUILD_PATH/lib/pkgconfig/
190+
sudo cp target/x86_64-unknown-linux-gnu/release/librav1e.* $BUILD_PATH/lib/
191+
172192
# Install dependencies for GPU: ffnvcodec
173193
msg "Install the newest ffnvcodec."
174194
cd $SOURCE_PATH || fail
175-
git clone https://git.videolan.org/git/ffmpeg/nv-codec-headers.git || fail
195+
git -C nv-codec-headers pull 2> /dev/null || git clone --depth 1 https://git.videolan.org/git/ffmpeg/nv-codec-headers.git || fail
176196
cd nv-codec-headers || fail
177197
PATH="$BIN_PATH:$PATH" make -j$(nproc) || fail
178198
sudo make install

0 commit comments

Comments
 (0)