1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-25 23:20:55 +00:00

Merge pull request #93281 from danieldk/darktable-opencl

darktable: fix OpenCL support
This commit is contained in:
Daniël de Kok 2020-07-17 06:55:44 +02:00 committed by GitHub
commit b5e5800a0b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -45,6 +45,10 @@ stdenv.mkDerivation rec {
libPathEnvVar = if stdenv.isDarwin then "DYLD_LIBRARY_PATH" else "LD_LIBRARY_PATH";
libPathPrefix = "$out/lib/darktable" + stdenv.lib.optionalString stdenv.isLinux ":${ocl-icd}/lib";
in ''
for f in $out/share/darktable/kernels/*.cl; do
sed -r "s|#include \"(.*)\"|#include \"$out/share/darktable/kernels/\1\"|g" -i "$f"
done
gappsWrapperArgs+=(
--prefix ${libPathEnvVar} ":" "${libPathPrefix}"
)