anchor.diff:      };
   
       postPatch = ''
  -      patchelf --set-rpath ${libXxf86vm}/lib lib/java3d-1.6/linux/amd64/libnativewindow_awt.so
  -      patchelf --set-rpath ${libXxf86vm}/lib lib/java3d-1.6/linux/amd64/libnativewindow_x11.so
  -      patchelf --set-rpath ${libXxf86vm}/lib lib/java3d-1.6/linux/i586/libnativewindow_awt.so
  -      patchelf --set-rpath ${libXxf86vm}/lib lib/java3d-1.6/linux/i586/libnativewindow_x11.so
  +      addAutoPatchelfSearchPath ${jre8}/lib/openjdk/jre/lib/
  +      autoPatchelf lib
  +
  +      # Nix cannot see the runtime references to the paths we just patched in
  +      # once they've been compressed into the .jar. Scan for and remember them
  +      # as plain text so they don't get overlooked.
  +      find . -name '*.so' | xargs strings | { grep '/nix/store' || :; } >> ./.jar-paths
       '';
   
  -    nativeBuildInputs = [ makeWrapper unzip ];
  -    buildInputs = [ ant jdk8 p7zip gtk3 gsettings-desktop-schemas ];
  +    nativeBuildInputs = [ makeWrapper unzip autoPatchelfHook ];
  +    buildInputs = [ ant jdk8 p7zip gtk3 gsettings-desktop-schemas libXxf86vm ];
   
       buildPhase = ''
         runHook preBuild
  
positive.code:         --set MESA_GL_VERSION_OVERRIDE 2.1 \
          --prefix XDG_DATA_DIRS : "$XDG_ICON_DIRS:${gtk3.out}/share:${gsettings-desktop-schemas}/share:$out/share:$GSETTINGS_SCHEMAS_PATH" \
          --add-flags "-Dsun.java2d.opengl=true -jar $out/share/java/${module}-${version}.jar -cp $out/share/java/Furniture.jar:$out/share/java/Textures.jar:$out/share/java/Help.jar -d${toString stdenv.hostPlatform.parsed.cpu.bits}"
  
        runHook postInstall
      '';
  
negative.code: , gtk3
  , gsettings-desktop-schemas
  , p7zip
  , autoPatchelfHook
  , libXxf86vm
  , unzip
  }:
  