{ stdenv, lib, fetchzip }:

stdenv.mkDerivation {
  pname = "love";
  version = "11.4";

  src = fetchzip {
    url = "https://github.com/love2d/love/releases/download/11.4/love-11.4-macos.zip";
    sha256 = "sha256-1YZVh0fl1sSpdEk+NR+J2IJ6G0rYXwdEuhBPJjhxx5o=";
  };

  dontBuild = true;

  installPhase = ''
    mkdir -p $out/bin
    cp -r . $out/love.app
    ln -s $out/love.app/Contents/MacOS/love $out/bin/love
  '';

  meta.platforms = lib.platforms.darwin;
}
