diff options
-rw-r--r-- | pkgs/applications/gis/tunnelx/default.nix | 27 |
1 files changed, 15 insertions, 12 deletions
diff --git a/pkgs/applications/gis/tunnelx/default.nix b/pkgs/applications/gis/tunnelx/default.nix index 821900a9d465e..fd8c893a91b38 100644 --- a/pkgs/applications/gis/tunnelx/default.nix +++ b/pkgs/applications/gis/tunnelx/default.nix @@ -19,34 +19,37 @@ stdenv.mkDerivation (finalAttrs: { }; nativeBuildInputs = [ - makeWrapper - ]; - - buildInputs = [ jdk - ]; - - runtimeInputs = [ - survex + makeWrapper ]; buildPhase = '' + runHook preBuild + javac -d . src/*.java + + runHook postBuild ''; installPhase = '' + runHook preInstall + mkdir -p $out/bin $out/java cp -r symbols Tunnel tutorials $out/java + # `SURVEX_EXECUTABLE_DIR` must include trailing slash makeWrapper ${jre}/bin/java $out/bin/tunnelx \ --add-flags "-cp $out/java Tunnel.MainBox" \ - --set SURVEX_EXECUTABLE_DIR ${survex}/bin/ \ + --set SURVEX_EXECUTABLE_DIR ${lib.getBin survex}/bin/ \ --set TUNNEL_USER_DIR $out/java/ + + runHook postInstall ''; - meta = with lib; { + meta = { description = "A program for drawing cave surveys in 2D"; homepage = "https://github.com/CaveSurveying/tunnelx/"; - license = licenses.gpl3; - maintainers = with maintainers; [ goatchurchprime ]; + license = lib.licenses.gpl3; + maintainers = with lib.maintainers; [ goatchurchprime ]; + platforms = lib.platforms.linux; }; }) |