about summary refs log tree commit diff
path: root/pkgs/applications/graphics
diff options
context:
space:
mode:
authorJan Tojnar <jtojnar@gmail.com>2021-02-11 01:45:15 +0100
committerJan Tojnar <jtojnar@gmail.com>2021-02-11 02:05:37 +0100
commit7ec9410c6a76d52dd841a4dfd4cf64ce16b1799e (patch)
tree7f83a071c9a1569ffa530ec6126d9858506a5e27 /pkgs/applications/graphics
parented6ccd4b27cdc05e12909843b3d46d6c3bfe02e0 (diff)
downloadnixlib-7ec9410c6a76d52dd841a4dfd4cf64ce16b1799e.tar
nixlib-7ec9410c6a76d52dd841a4dfd4cf64ce16b1799e.tar.gz
nixlib-7ec9410c6a76d52dd841a4dfd4cf64ce16b1799e.tar.bz2
nixlib-7ec9410c6a76d52dd841a4dfd4cf64ce16b1799e.tar.lz
nixlib-7ec9410c6a76d52dd841a4dfd4cf64ce16b1799e.tar.xz
nixlib-7ec9410c6a76d52dd841a4dfd4cf64ce16b1799e.tar.zst
nixlib-7ec9410c6a76d52dd841a4dfd4cf64ce16b1799e.zip
gimpPlugins.fourier: fix loading
Turns out there was a pre-compiled binary in the tarball,
which was installed instead of building our own binary.
That means RPATH was not set properly,
and the plug-in could not find libgimp.
Diffstat (limited to 'pkgs/applications/graphics')
-rw-r--r--pkgs/applications/graphics/gimp/plugins/default.nix21
1 files changed, 17 insertions, 4 deletions
diff --git a/pkgs/applications/graphics/gimp/plugins/default.nix b/pkgs/applications/graphics/gimp/plugins/default.nix
index 555bfbe17e7f..57ab023359b4 100644
--- a/pkgs/applications/graphics/gimp/plugins/default.nix
+++ b/pkgs/applications/graphics/gimp/plugins/default.nix
@@ -83,15 +83,28 @@ in
        Filters/Generic/FFT Forward
        Filters/Generic/FFT Inverse
     */
-    name = "fourier-0.4.3";
-    buildInputs = with pkgs; [ fftw ];
+    pname = "fourier";
+    version = "0.4.3";
 
     src = fetchurl {
-      url = "https://www.lprp.fr/files/old-web/soft/gimp/${name}.tar.gz";
+      url = "https://www.lprp.fr/files/old-web/soft/gimp/${pname}-${version}.tar.gz";
       sha256 = "0mf7f8vaqs2madx832x3kcxw3hv3w3wampvzvaps1mkf2kvrjbsn";
     };
 
-    installPhase = "installPlugins fourier";
+    buildInputs = with pkgs; [ fftw ];
+
+    postPatch = ''
+      # The tarball contains a prebuilt binary.
+      make clean
+    '';
+
+    installPhase = ''
+      runHook preInstall
+
+      installPlugins fourier
+
+      runHook postInstall
+    '';
 
     meta = with lib; {
       description = "GIMP plug-in to do the fourier transform";