Darktable from Fedora flatpak missing OpenCL

was there something on licensing that prevents OpenCL use from Fedora Flatpaks? cant remember what was the main reason Darktable from Fedora flatpak dont have OpenCL enabled

Fedora flatpaks are built from the same source as the rpm. The spec file does not seem to have any flatpak specific switches, so the build should be the same. There are other possible reasons:

  • flatpak or system is missing drivers (e.g. intel-opencl for Intel Iris Xe)
  • flatpak’ed darktable is not permitted to use the opencl device

thank you for clearing this out tho Darktable from Flathub has OpenCL enable just checked that too so wanted to know is there something that blocks OpenCL fro fedora Flatpak. Also tested Darktable on Workstation using repo installation and it has OpenCL enabled too

Since you have all them installed already: Maybe try starting each from the command line with -d opencl, e.g.:

darktable -d opencl
flatpak run org.darktable.Darktable -d opencl

This shows you which features are compiled in and which opencl library is found for the working ones.

I still suspect that the flathub package “simply” includes a few opencl implementations. (It also provides a service and weighs in at 50MB vs 30MB compared to the Fedora flatpak.)

1 Like

full details Darktable Fedora flatpak

darktable 4.8.1
Copyright (C) 2012-2024 Johannes Hanika and other contributors.

Compile options:
  Bit depth              -> 64 bit
  Debug                  -> DISABLED
  SSE2 optimizations     -> ENABLED
  OpenMP                 -> ENABLED
  OpenCL                 -> ENABLED
  Lua                    -> ENABLED  - API version 9.3.0
  Colord                 -> ENABLED
  gPhoto2                -> ENABLED
  GMIC                   -> ENABLED  - Compressed LUTs are supported
  GraphicsMagick         -> ENABLED
  ImageMagick            -> DISABLED
  libavif                -> ENABLED
  libheif                -> ENABLED
  libjxl                 -> ENABLED
  OpenJPEG               -> ENABLED
  OpenEXR                -> ENABLED
  WebP                   -> ENABLED

See https://www.darktable.org/resources/ for detailed documentation.
See https://github.com/darktable-org/darktable/issues/new/choose to report bugs.

     0.1378 [dt_get_sysresource_level] switched to 1 as `default'
     0.1378   total mem:       31806MB
     0.1378   mipmap cache:    3975MB
     0.1379   available mem:   15903MB
     0.1379   singlebuff:      248MB
     0.1442 [dt_dlopencl_init] could not find default opencl runtime library 'libOpenCL'
     0.1443 [dt_dlopencl_init] could not find default opencl runtime library 'libOpenCL.so'
     0.1456 [opencl_init] opencl library 'libOpenCL.so.1' found on your system and loaded, preference 'default path'
     0.1456 [opencl_init] 0 platforms detected, error: Unknown OpenCL error
     0.1456 [opencl_init] FINALLY: opencl PREFERENCE=ON is NOT AVAILABLE and NOT ENABLED.

Yes, that’s what I get with that flatpak, too. It shows that opencl support is compiled into darktable, dt locates one opencl library but cannot use it. Same over here. In my case, that’s the library which the rpm can use, and over here the Fedora flatpak fails in the same way.

For me, the flathub darktable flatpak fails, too, albeit with a different message: it tries to use two different libraries (which apparantly come with their flatpak) but they don’t apply to my system. What’s the output from flathub’s version for you? That could indicate what’s missing in the Fedora flatpak (for your system).

basically identical

phatle@kinoite:/var/home/phatle$ flatpak run org.darktable.Darktable -d opencl
darktable 4.8.1
Copyright (C) 2012-2024 Johannes Hanika and other contributors.

Compile options:
  Bit depth              -> 64 bit
  Debug                  -> DISABLED
  SSE2 optimizations     -> ENABLED
  OpenMP                 -> ENABLED
  OpenCL                 -> ENABLED
  Lua                    -> ENABLED  - API version 9.3.0
  Colord                 -> ENABLED
  gPhoto2                -> ENABLED
  GMIC                   -> ENABLED  - Compressed LUTs are supported
  GraphicsMagick         -> ENABLED
  ImageMagick            -> DISABLED
  libavif                -> ENABLED
  libheif                -> ENABLED
  libjxl                 -> ENABLED
  OpenJPEG               -> ENABLED
  OpenEXR                -> ENABLED
  WebP                   -> ENABLED

See https://www.darktable.org/resources/ for detailed documentation.
See https://github.com/darktable-org/darktable/issues/new/choose to report bugs.

     0.0348 [dt_get_sysresource_level] switched to 1 as `default'
     0.0348   total mem:       31806MB
     0.0348   mipmap cache:    3975MB
     0.0348   available mem:   15903MB
     0.0348   singlebuff:      248MB
     0.0361 [opencl_init] opencl disabled via darktable preferences
     0.0362 [dt_dlopencl_init] could not find default opencl runtime library 'libOpenCL'
     0.0363 [dt_dlopencl_init] could not find default opencl runtime library 'libOpenCL.so'
     0.0364 [opencl_init] opencl library 'libOpenCL.so.1' found on your system and loaded, preference 'default path'
     0.0365 [opencl_init] 0 platforms detected, error: Unknown OpenCL error
     0.0365 [opencl_init] FINALLY: opencl PREFERENCE=OFF is NOT AVAILABLE and NOT ENABLED.

I may have misunderstood you - so neither of the flatpak versions (fedora/flathub) works for you? Then the diff between two non-working ones does not help.

Not working on F41… F40 flathub has only openCL working but for now I am not on F40 systems maybe tomorrow all these are done on F41 beta

OK, I guess it could help to be clear about what is working and what is not. Breakage when switching from F40 to a beta is something completely different than flathub vs fedora flatpak vs fedora rpm, of course. Can’t help with that.

1 Like

Yeah totally agree I should specify things better

Thi is not an issue with Fedora per say, this is a Flatpak issue as the OpenCL runtime is not in flatpak, and it is recommended to just use the .rpm if you want to use Darktable. I have some old post on this on the forum I believe . There’s supposed to be work on this in an upcoming freedesktop runtime, but I have not seen it come to fruition.

1 Like