diff --git a/pkgs/applications/office/treesheets/default.nix b/pkgs/applications/office/treesheets/default.nix index e39d7b5954c2..7b1fd1ae73a8 100644 --- a/pkgs/applications/office/treesheets/default.nix +++ b/pkgs/applications/office/treesheets/default.nix @@ -1,10 +1,12 @@ { lib , stdenv , fetchFromGitHub -, wxGTK , cmake , ninja , wrapGAppsHook +, makeWrapper +, wxGTK +, Cocoa , unstableGitUpdater }: @@ -23,14 +25,25 @@ stdenv.mkDerivation rec { cmake ninja wrapGAppsHook + makeWrapper ]; buildInputs = [ wxGTK + ] ++ lib.optionals stdenv.isDarwin [ + Cocoa ]; NIX_CFLAGS_COMPILE = "-DPACKAGE_VERSION=\"${builtins.replaceStrings [ "unstable-" ] [ "" ] version}\""; + postInstall = lib.optionalString stdenv.isDarwin '' + shopt -s extglob + mkdir -p $out/{share/treesheets,bin} + mv $out/!(share) $out/share/treesheets + makeWrapper $out/{share/treesheets,bin}/treesheets \ + --chdir $out/share/treesheets + ''; + passthru = { updateScript = unstableGitUpdater { }; }; @@ -49,7 +62,7 @@ stdenv.mkDerivation rec { homepage = "https://strlen.com/treesheets/"; maintainers = with maintainers; [ obadz avery ]; - platforms = platforms.linux; + platforms = platforms.unix; license = licenses.zlib; }; } diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 9cfdc1f70e02..8caf01a6f2da 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -31892,7 +31892,8 @@ with pkgs; tree = callPackage ../tools/system/tree {}; treesheets = callPackage ../applications/office/treesheets { - wxGTK = wxGTK31-gtk3; + wxGTK = wxGTK32; + inherit (darwin.apple_sdk.frameworks) Cocoa; }; tremc = callPackage ../applications/networking/p2p/tremc { };