Getting the following error
darktable: error while loading shared libraries: libx265.so.179: cannot open shared object file: No such file or directory
I have libx265.so.199 installed. I have no idea how this happened but DT was working last time I used before running software updater today.
my system - Ubuntu 22.04
As a quick and dirty fix Iād try to locate libx265.so.199 and make a symlink to it (or itās source as itās may be a symlink itself), in the same folder, named libx265.so.179
It may work but surely there is a better solution
As a general problem solving and less quickfix solution, check where you gat your darktable from and :
if itās from base ubuntu repository, you could warn the package maintainer.
if itās from a PPA check that this PPA is aimed at your version of Ubuntu and if it is warn the PPA maintainer.
The root of the problem probably being that Ubuntu 22.04 updated libx265 but the DT binary provided by the package you used to install it are compiled against the older version of libx265.
I did not know that DT needed that as itās more video oriented library !
It is a dependency of libheif which is used by dt to read āmodernā HEIC (HEVC aka H.265 encoded) images (it is indeed a codec designed for video primarily).
raj@:~ which darktable
/usr/bin/darktable
raj@:~ ldd which darktable | grep libx265
libx265.so.179 => not found
also many other things which were working like heif-enc from libheif, image viewer which was showing .heic files is not showing
But
ldd $(which ffmpeg) | grep libx265
libx265.so.199 => /lib/x86_64-linux-gnu/libx265.so.199 (0x00007fa2dd44a000)
The version libx265.so.179 is only available in ubuntu 20.04 while I am on 22.04 for many months and everything was working till yeasterday.
I donāt think that it is a bug as many other software which I mentioned earlier has stopped working and all are referring to libx265.so.179.
is there a way where by all packages/Apps using this earlier version now use the new version?
when I tried to reinstall the above packages all are giving error like
Package ālibvpx6ā has no installation candidate.
@Tamas_Papp I tried it and nothing is installed
Reading package lists⦠Done
Building dependency tree⦠Done
Reading state information⦠Done
0 to upgrade, 0 to newly install, 0 to remove and 4 not to upgrade.
I guess one could use something like lddtree to figure out what exactly tries to link to this old libx265, as ldd alone does not give you the hierarchy. Or try to understand the output of ldd -v.
Thanks for the correction, indeed it is not a direct dependency. lddtree (which I did not know about, thanks!) is in pax-utils, it suggests that this is a dependency of libheif.
Since darktable depends on the latter, it is a mystery to me why the relevant library is not installed.
Solution
I was searching for libx265 and I saw that libx265.so.179 was present in Firefox Snap package, I simply copied this file to /usr/lib/x86_64-linux-gnu/ and everything (except cannot view heic files in Image viewer or shotwell) started working.
Edit: Image viewer works after reinstalling
sudo apt-get --reinstall install heif-gdk-pixbuf
I know that this is not a solution as first of all, Ubuntu should not have removed this file in --autoremove and secondly why all these programs didnāt work because of this when a newer version file was present at this location. Is the reference hard coded?
@Tamas_Papp
dpkg -l libheif1
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Architecture Description
++±==============-==============-============-================================>
ii libheif1:amd64 1.12.0-2build1 amd64 ISO/IEC 23008-12:2017 HEIF file >
lines 1-6/6 (END)