Fix DaVinci Resolve installation (symbol lookup errors)

This post is mostly for my future self, but feel free to use the one-liner if you have just installed or upgraded BlackMagic DaVinci Resolve (Studio) onto your Linux machine and it’s not starting because of symbol lookup errors, e.g. /opt/resolve/bin/resolve: symbol lookup error: /usr/lib64/libpango-1.0.so.0: undefined symbol: g_string_free_and_steal.

One-liner

for lib in $(ldd /opt/resolve/bin/resolve | cut -d' ' -f1);
do
  [ -f "/usr/lib/${lib}" ] \
  && [ -f "/opt/resolve/libs/${lib}" ] \
  && { echo "Found ${lib} in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/${lib}" \
       && sudo rm "/opt/resolve/libs/${lib}"; } \
done

Example output

pn@vision ~ $ for lib in $(ldd /opt/resolve/bin/resolve | cut -d' ' -f1);
do
  [ -f "/usr/lib/${lib}" ] \
  && [ -f "/opt/resolve/libs/${lib}" ] \
  && { echo "Found ${lib} in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/${lib}" \
       && sudo rm "/opt/resolve/libs/${lib}"; } \
done
Found libavformat.so.60 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libavformat.so.60
Found libavcodec.so.60 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libavcodec.so.60
Found libavutil.so.58 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libavutil.so.58
Found libswscale.so.7 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libswscale.so.7
Found libmp3lame.so in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libmp3lame.so
Found libgstreamer-1.0.so.0 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libgstreamer-1.0.so.0
Found libgobject-2.0.so.0 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libgobject-2.0.so.0
Found libglib-2.0.so.0 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libglib-2.0.so.0
Found libgstbase-1.0.so.0 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libgstbase-1.0.so.0
Found libgstapp-1.0.so.0 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libgstapp-1.0.so.0
Found libgstrtp-1.0.so.0 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libgstrtp-1.0.so.0
Found libgstvideo-1.0.so.0 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libgstvideo-1.0.so.0
Found libgstsdp-1.0.so.0 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libgstsdp-1.0.so.0
Found libgstpbutils-1.0.so.0 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libgstpbutils-1.0.so.0
Found libgstaudio-1.0.so.0 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libgstaudio-1.0.so.0
Found libgsttag-1.0.so.0 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libgsttag-1.0.so.0
Found libgstwebrtc-1.0.so.0 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libgstwebrtc-1.0.so.0
Found libgio-2.0.so.0 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libgio-2.0.so.0
Found libgmodule-2.0.so.0 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/libgmodule-2.0.so.0
Found liborc-0.4.so.0 in both /usr/lib and /opt/resolve/libs - deleting /opt/resolve/libs/liborc-0.4.so.0

Explanation

  1. ldd is used to get a list of all shared libraries that the DaVinci Resolve executable (/opt/resolve/bin/resolve) links against
  2. The for loop iterates over these collected filenames and for each checks whether it’s both present in the standard library path (/usr/lib) and in DaVinci Resolve’s own libs directory (/opt/resolve/libs).
  3. If that is the case, they’re deleted from /opt/resolve/libs, so that only the ones coming with the distro remain.

Why does this work?

Some shared libraries (those that the one-liner deletes) that come with DaVinci Resolve are older versions that are not compatible with other libs that come with your distro.

At the time of writing there are 20 such libs, see in the Example Output section for a list.

By deleting them, the loader will find the ones in /usr/lib instead. These are compatible with the aforementioned other libs from your distro, because they are coming from your distro.

I’ve written the one-liner for DaVinci Resolve 19.1.2 and tested it with it on my Gentoo system. It should work on other distros as well.

Leave a Reply

Your email address will not be published. Required fields are marked *