diff --git a/pkgs/applications/misc/navit/default.nix b/pkgs/applications/misc/navit/default.nix index 5d591243f50d..ede20d7935be 100644 --- a/pkgs/applications/misc/navit/default.nix +++ b/pkgs/applications/misc/navit/default.nix @@ -68,10 +68,10 @@ stdenv.mkDerivation rec { ''; # TODO: fix upstream? + libPath = stdenv.lib.makeLibraryPath ([ stdenv.cc.libc ] ++ buildInputs ); postFixup = '' - for lib in $(find "$out/lib/navit/" -iname "*.so" ); do - patchelf --set-rpath ${makeLibraryPath buildInputs} $lib - done + find "$out/lib" -type f -name "*.so" -exec patchelf --set-rpath $libPath {} \; + wrapProgram $out/bin/navit \ --prefix PATH : ${makeBinPath ( optional xkbdSupport xkbd