Unverified Commit 0f3c4ca2 authored by Aleksana's avatar Aleksana Committed by GitHub
Browse files

blackbox-terminal: 0.14.0 -> 0.14.0-unstable-2025-08-29 (#464357)

parents b9bb6136 aeec8acb
Loading
Loading
Loading
Loading
+0 −46
Original line number Diff line number Diff line
{
  lib,
  stdenv,
  fetchFromGitLab,
  meson,
  ninja,
  pkg-config,
  vala,
  gobject-introspection,
  gtk4,
  gtk3,
  desktop-file-utils,
}:

stdenv.mkDerivation {
  pname = "marble";
  version = "unstable-2023-05-11";

  src = fetchFromGitLab {
    domain = "gitlab.gnome.org";
    owner = "raggesilver";
    repo = "marble";
    # the same used on flatpak
    rev = "f240b2ec7d5cdacb8fdcc553703420dc5101ffdb";
    sha256 = "sha256-obtz7zOyEZPgi/NNjtLr6aFm/1UVTzjTdJpN3JQfpUs=";
  };

  nativeBuildInputs = [
    meson
    ninja
    pkg-config
    vala
    gtk3 # For gtk-update-icon-cache
    desktop-file-utils # For update-desktop-database
    gobject-introspection # For g-ir-compiler
  ];
  buildInputs = [ gtk4 ];

  meta = with lib; {
    description = "Raggesilver's GTK library";
    homepage = "https://gitlab.gnome.org/raggesilver/marble";
    license = licenses.gpl3Plus;
    maintainers = with maintainers; [ chuangzhu ];
    platforms = platforms.linux;
  };
}
+11 −54
Original line number Diff line number Diff line
@@ -2,7 +2,6 @@
  lib,
  stdenv,
  fetchFromGitLab,
  fetchpatch,
  meson,
  ninja,
  pkg-config,
@@ -13,48 +12,26 @@
  sassc,
  libadwaita,
  pcre2,
  libsixel,
  libxml2,
  librsvg,
  libgee,
  callPackage,
  python3,
  desktop-file-utils,
  wrapGAppsHook4,
  sixelSupport ? false,
}:

let
  marble = callPackage ./marble.nix { };
in
stdenv.mkDerivation rec {
  pname = "blackbox";
  version = "0.14.0";
stdenv.mkDerivation {
  pname = "blackbox-terminal";
  version = "0.14.0-unstable-2025-08-29";

  src = fetchFromGitLab {
    domain = "gitlab.gnome.org";
    owner = "raggesilver";
    repo = "blackbox";
    rev = "v${version}";
    hash = "sha256-ebwh9WTooJuvYFIygDBn9lYC7+lx9P1HskvKU8EX9jw=";
    rev = "9290c2feddc4415752afd1b03c82a1d82a6b3392";
    hash = "sha256-s1e9zS4ijsa3+zxlsdxlqTzR1Rnb4hxjwlqYEhtvy5g=";
  };

  patches = [
    # Fix closing confirmation dialogs not showing
    (fetchpatch {
      url = "https://gitlab.gnome.org/raggesilver/blackbox/-/commit/3978c9b666d27adba835dd47cf55e21515b6d6d9.patch";
      hash = "sha256-L/Ci4YqYNzb3F49bUwEWSjzr03MIPK9A5FEJCCct+7A=";
    })

    # Fix build with GCC 14
    # https://gitlab.gnome.org/GNOME/vala/-/merge_requests/369#note_1986032
    # https://gitlab.gnome.org/raggesilver/blackbox/-/merge_requests/143
    (fetchpatch {
      url = "https://gitlab.gnome.org/raggesilver/blackbox/-/commit/2f45717f1c18f710d9b9fbf21830027c8f0794e7.patch";
      hash = "sha256-VlXttqOTbhD6Rp7ZODgsafOjeY+Lb5sZP277bC9ENXU=";
    })
  ];

  postPatch = ''
    substituteInPlace build-aux/meson/postinstall.py \
      --replace-fail 'gtk-update-icon-cache' 'gtk4-update-icon-cache'
@@ -73,28 +50,8 @@ stdenv.mkDerivation rec {
  ];
  buildInputs = [
    gtk4
    (vte-gtk4.overrideAttrs (
      old:
      {
        src = fetchFromGitLab {
          domain = "gitlab.gnome.org";
          owner = "GNOME";
          repo = "vte";
          rev = "3c8f66be867aca6656e4109ce880b6ea7431b895";
          hash = "sha256-vz9ircmPy2Q4fxNnjurkgJtuTSS49rBq/m61p1B43eU=";
        };
        patches = lib.optional (old ? patches) (lib.head old.patches);
        postPatch = (old.postPatch or "") + ''
          patchShebangs src/box_drawing_generate.sh
        '';
      }
      // lib.optionalAttrs sixelSupport {
        buildInputs = old.buildInputs ++ [ libsixel ];
        mesonFlags = old.mesonFlags ++ [ "-Dsixel=true" ];
      }
    ))
    vte-gtk4
    json-glib
    marble
    libadwaita
    pcre2
    libxml2
@@ -102,18 +59,18 @@ stdenv.mkDerivation rec {
    libgee
  ];

  mesonFlags = [ "-Dblackbox_is_flatpak=false" ];
  mesonFlags = [
    (lib.mesonBool "blackbox_is_flatpak" false)
  ];

  meta = {
    description = "Beautiful GTK 4 terminal";
    mainProgram = "blackbox";
    description = "Elegant and customizable terminal for GNOME";
    homepage = "https://gitlab.gnome.org/raggesilver/blackbox";
    changelog = "https://gitlab.gnome.org/raggesilver/blackbox/-/raw/v${version}/CHANGELOG.md";
    license = lib.licenses.gpl3Plus;
    maintainers = with lib.maintainers; [
      chuangzhu
      linsui
    ];
    mainProgram = "blackbox";
    platforms = lib.platforms.linux;
  };
}