【jetpack 5.1.2】Error while loading shared libraries: libnvbuf_utils.so.1.0.0

I freshly installed jetpack 5.1.2 on my jetson xavier nx development kit through the sdk manager and I want to use hardware accelerated ffmpeg on it.
So I followed this tutorial to install ffmpeg and run it.

However, it report this error.

ffmpeg: error while loading shared libraries: libnvbuf_utils.so.1.0.0: cannot open shared object file: No such file or directory

Then I try to find this library under the directory /usr/lib/aarch64-linux-gnu/tegra

ls /usr/lib/aarch64-linux-gnu/tegra | grep libnvbuf_utils

As a result, it does not exist.

I used the sd card installation to write the os into tf card again but the error still exists.

OMG, after rolling back my system to jetpack 4.6, the ffmpeg apt source has already been broken.

The following packages have unmet dependencies:
 ffmpeg : Depends: libaom0 (>= 1.0.0) but it is not installable
          Depends: libc6 (>= 2.29) but 2.27-3ubuntu1.6 is to be installed
          Depends: libcdio-cdda2 (>= 10.2+2.0.0) but 10.2+0.94+2-2build1 is to be installed
          Depends: libcdio-paranoia2 (>= 10.2+2.0.0) but 10.2+0.94+2-2build1 is to be installed
          Depends: libcodec2-0.9 but it is not installable
          Depends: libgnutls30 (>= 3.6.12) but 3.5.18-1ubuntu1.6 is to be installed
          Depends: libgsm1 (>= 1.0.18) but 1.0.13-4build1 is to be installed
          Depends: libmysofa1 (>= 0.7~) but it is not installable
          Depends: librubberband2 (>= 1.8.2) but 1.8.1-7ubuntu2 is to be installed
          Depends: libsdl2-2.0-0 (>= 2.0.10) but 2.0.8+dfsg1-1ubuntu1.18.04.4 is to be installed
          Depends: libsnappy1v5 (>= 1.1.8) but 1.1.7-1 is to be installed
          Depends: libsndio7.0 (>= 1.1.0) but it is not installable
          Depends: libssh-gcrypt-4 (>= 0.8.0) but 0.8.0~20170825.94fa1e38-1ubuntu0.7 is to be installed
          Depends: libva2 (>= 2.2.0) but 2.1.0-3 is to be installed
          Depends: libvidstab1.1 but it is not installable
          Depends: libvpx6 (>= 1.6.0) but it is not installable
          Depends: libwebpmux3 (>= 0.6.1-2ubuntu0.20.04.1) but 0.6.1-2ubuntu0.18.04.2 is to be installed
          Depends: libx264-155 but it is not installable
          Depends: libx265-179 (>= 3.2) but it is not installable
E: Unable to correct problems, you have held broken packages.

Hi,
This issue is known. We are investigating it and will update.

As a quick solution, you may consider use jetson_multimedia_api. We have the samples demonstrating hardware decoding:

/usr/src/jetson_multimedia_api/samples/00_video_decode/
/usr/src/jetson_multimedia_api/samples/unittest_samples/decoder_unit_sample/

Saddly, all my work is on ffmpeg libav pack. OK, I will try your work around. But I still hope this problem could be solved as soon as possible.

In addition, does jetson_multimedia_api can be integrated into ffmpeg rtsp workflow? You know, ffmpeg libcodec cannot find libnvbuf_utils at present.
I must use the rtsp protocol in ffmpeg now.

I made the exact same mistake. Currently, my Jetson cannot use FFmpeg at all. Please provide a solution or an alternative method. Thank you.
@DaneLLL

Hi,
Currently there is no ffmpeg package enabling hardware encoding for Jetpack 5 releases. Please use the default ffmpeg package.

Hi,
The package is refreshed. Please download again and give it a try.

For building from source code, please try the steps:
download source code

$ echo "deb-src https://repo.download.nvidia.com/jetson/ffmpeg main main" |  sudo tee -a /etc/apt/sources.list
$ sudo apt update
$ apt source ffmpeg

build

ffmpeg-4.2.7$ ./configure --enable-nvv4l2dec --enable-libv4l2 --extra-libs="-L/usr/lib/aarch64-linux-gnu/tegra -lnvbufsurface -lnvbufsurftransform" --extra-cflags="-I /usr/src/jetson_multimedia_api/include/"
ffmpeg-4.2.7$ make

decode mp4 file

ffmpeg-4.2.7$ ./ffmpeg -c:v h264_nvv4l2dec -i /home/nvidia/test.mp4 a.yuv

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.