libraw image decoder not working

  • If I install the Libraw plugin and try to load my photos (Canon and Sony raw) I always get the error message:

    Libraw image decoder could not be loaded

    I'm using LibreELEC build 9.2.3 and this installs libraw image decoder plugin version spiff-2.1.2.1.

    In the logfiles there's the following entry:

    2020-08-04 12:00:11.264 T:2876646256 DEBUG: ADDON: Dll Initializing - libraw image decoder

    2020-08-04 12:00:11.264 T:2876646256 DEBUG: SECTION:LoadDLL(/storage/.kodi/addons/http://imagedecoder.raw/imagedecoder.raw.so.2.1.2)

    2020-08-04 12:00:11.264 T:2876646256 DEBUG: Loading: /storage/.kodi/addons/http://imagedecoder.raw/imagedecoder.raw.so.2.1.2

    2020-08-04 12:00:11.278 T:2876646256 ERROR: Unable to load /storage/.kodi/addons/http://imagedecoder.raw/imagedecoder.raw.so.2.1.2, reason: liblcms2.so.2: cannot open shared object file: No such file or directory

    Edited once, last by MrksBr (August 4, 2020 at 1:09 PM).

  • Dear MrksBr,

    I was facing exactly the same issue you have reported and managed to fix it by manually copying the "liblcms2.so.2" library into the "/usr/lib/" folder.

    I could find the appropriate file in the Ubuntu "liblcms2-2_2.9-1ubuntu0.1_amd64.deb" package which can be retrieved from their official repositories here (I guess you can find this package for any other distribution, provided it is in the appropriate version and architecture you are using).

    After downloading (on another computer) you will have to extract the files contained in the package.

    From the two archive files you will obtain, the required file is located inside the "data.tar.xz" one, and you will have to extract it from the following path: "./data/usr/lib/x86_64-linux-gnu/liblcms2.so.2.0.8" (for the version I downloaded).

    You can then copy this file in the "/usr/lib/" folder of your LibreELEC installation. (You can do that with an "scp" command, just make sure you have enabled ssh on LibreELEC).

    After copying the file, check if it has the same attributes as the other libraries in the folder.

    -> In my case, the file was missing all execution rights for all users and groups, hence I had to run the following command (considering current folder is "/usr/lib"):

    Code
    chmod a+x liblcms2.so.2.0.8

    Following this you will have to create a symbolic link with the "liblcms2.so.2" alias pointing to the "liblcms2.so.x.y.z" file.

    In my case, this was achieved by (considering current folder is "/usr/lib"):

    Code
    ln -s ./liblcms2.so.2.0.8 ./liblcms2.so.2

    You may have to restart.

    Hoping this helps everyone facing this issue until the new version of the spiff add-on is released.

  • I'm facing the same problem on the latest LE 9.97.1 running on generic x64 hardware.

    Code
    2021-08-01 15:19:24.785 T:945     DEBUG <general>: ADDON: Dll Initializing - libraw image decoder
    2021-08-01 15:19:24.785 T:945     DEBUG <general>: SECTION:LoadDLL(/storage/.kodi/addons/imagedecoder.raw/imagedecoder.raw.so.3.0.1)
    2021-08-01 15:19:24.785 T:945     DEBUG <general>: Loading: /storage/.kodi/addons/imagedecoder.raw/imagedecoder.raw.so.3.0.1
    2021-08-01 15:19:24.787 T:945     ERROR <general>: Unable to load /storage/.kodi/addons/imagedecoder.raw/imagedecoder.raw.so.3.0.1, reason: liblcms2.so.2: cannot open shared object file: No such file or directory

    Sadly the fix from oduL doesn't work.

    I get:

    Code
    cp /var/media/80GB/usr/lib/x86_64-linux-gnu/liblcms2.so.2 /usr/lib/
    cp: can't create '/usr/lib/liblcms2.so.2': Read-only file system