From 1033ce03b4c2ca08fa0ea66c255d8ef7d6737e24 Mon Sep 17 00:00:00 2001 From: Sergei Zimmerman Date: Tue, 3 Jun 2025 20:31:52 +0000 Subject: [PATCH 1/3] lowdown: 1.3.2 -> 2.0.2 https://github.com/kristapsdz/lowdown/releases/tag/VERSION_1_4_0 https://github.com/kristapsdz/lowdown/releases/tag/VERSION_2_0_0 https://github.com/kristapsdz/lowdown/releases/tag/VERSION_2_0_2 --- pkgs/by-name/lo/lowdown/package.nix | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/pkgs/by-name/lo/lowdown/package.nix b/pkgs/by-name/lo/lowdown/package.nix index 8c393af15ac2..0ed05f596982 100644 --- a/pkgs/by-name/lo/lowdown/package.nix +++ b/pkgs/by-name/lo/lowdown/package.nix @@ -5,6 +5,7 @@ fixDarwinDylibNames, which, dieHook, + bmake, enableShared ? !stdenv.hostPlatform.isStatic, enableStatic ? stdenv.hostPlatform.isStatic, enableDarwinSandbox ? true, @@ -16,7 +17,7 @@ stdenv.mkDerivation rec { pname = "lowdown${ lib.optionalString (stdenv.hostPlatform.isDarwin && !enableDarwinSandbox) "-unsandboxed" }"; - version = "1.3.2"; + version = "2.0.2"; outputs = [ "out" @@ -27,12 +28,13 @@ stdenv.mkDerivation rec { src = fetchurl { url = "https://kristaps.bsd.lv/lowdown/snapshots/lowdown-${version}.tar.gz"; - hash = "sha512-IQmgPm2zE+B82Zdg+ldjtU/XI+qab9YRAzwzRMYv32KKjql0YLDEgc/m6DbgyCiNBkulD0dVExCtrTM+nBFHzw=="; + hash = "sha512-cfzhuF4EnGmLJf5EGSIbWqJItY3npbRSALm+GarZ7SMU7Hr1xw0gtBFMpOdi5PBar4TgtvbnG4oRPh+COINGlA=="; }; nativeBuildInputs = [ which dieHook + bmake # Uses FreeBSD's dialect ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ fixDarwinDylibNames ]; @@ -74,7 +76,7 @@ stdenv.mkDerivation rec { postInstall = let - soVersion = "1"; + soVersion = "2"; in # Check that soVersion is up to date even if we are not on darwin From db90b27976387040e64eec33146f661f5416fb10 Mon Sep 17 00:00:00 2001 From: Sergei Zimmerman Date: Tue, 3 Jun 2025 20:32:30 +0000 Subject: [PATCH 2/3] nixVersions.nix_2_24: fix build against lowdown 2.0.2 --- pkgs/tools/package-management/nix/common-autoconf.nix | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/pkgs/tools/package-management/nix/common-autoconf.nix b/pkgs/tools/package-management/nix/common-autoconf.nix index 6f9b4fef5747..894380f71cf0 100644 --- a/pkgs/tools/package-management/nix/common-autoconf.nix +++ b/pkgs/tools/package-management/nix/common-autoconf.nix @@ -254,6 +254,14 @@ let "--enable-lto" ]; + env.CXXFLAGS = toString ( + lib.optionals (lib.versionAtLeast lowdown.version "1.4.0") [ + # Autotools based build system wasn't updated with the backport of + # https://github.com/NixOS/nix/pull/12115, so set the define explicitly. + "-DHAVE_LOWDOWN_1_4" + ] + ); + makeFlags = [ # gcc runs multi-threaded LTO using make and does not yet detect the new fifo:/path style # of make jobserver. until gcc adds support for this we have to instruct make to use this From 413d3444bfa5aa0d8ed373541ab854b8beb8e2fd Mon Sep 17 00:00:00 2001 From: sternenseemann Date: Wed, 23 Jul 2025 23:34:30 +0200 Subject: [PATCH 3/3] lixPackageSets.*.lix: apply patches for lowdown >= 1.4 compat --- pkgs/tools/package-management/lix/default.nix | 28 +++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/pkgs/tools/package-management/lix/default.nix b/pkgs/tools/package-management/lix/default.nix index 52e9ceb4d457..e3a9d8581673 100644 --- a/pkgs/tools/package-management/lix/default.nix +++ b/pkgs/tools/package-management/lix/default.nix @@ -9,6 +9,7 @@ fetchgit, fetchFromGitHub, fetchFromGitea, + fetchpatch2, rustPlatform, editline, ncurses, @@ -168,6 +169,15 @@ lib.makeExtensible (self: { hash = "sha256-b5d+HnPcyHz0ZJW1+LZl4qm4LGTB/TiaDFQVlVL2xpE="; }; + patches = [ + # Support for lowdown >= 1.4, https://gerrit.lix.systems/c/lix/+/3731 + (fetchpatch2 { + name = "lix-2.91-lowdown-1.4.0.patch"; + url = "https://git.lix.systems/lix-project/lix/commit/ecff59d77371b21fef229c33ebb629bc49a8fad5.patch"; + sha256 = "sha256-2M5oId5kObwzpw67rddAPI2RbWPEVlGBrMUXZWqqmEo="; + }) + ]; + docCargoDeps = rustPlatform.fetchCargoVendor { name = "lix-doc-${version}"; inherit src; @@ -200,6 +210,15 @@ lib.makeExtensible (self: { hash = "sha256-iP2iUDxA99RcgQyZROs7bQw8pqxa1vFudRqjAIHg9Iw="; }; + patches = [ + # Support for lowdown >= 1.4, https://gerrit.lix.systems/c/lix/+/3731 + (fetchpatch2 { + name = "lix-lowdown-1.4.0.patch"; + url = "https://git.lix.systems/lix-project/lix/commit/858de5f47a1bfd33835ec97794ece339a88490f1.patch"; + hash = "sha256-FfLO2dFSWV1qwcupIg8dYEhCHir2XX6/Hs89eLwd+SY="; + }) + ]; + cargoDeps = rustPlatform.fetchCargoVendor { name = "lix-${version}"; inherit src; @@ -231,6 +250,15 @@ lib.makeExtensible (self: { hash = "sha256-J4ycLoXHPsoBoQtEXFCelL4xlq5pT8U9tNWNKm43+YI="; }; + patches = [ + # Support for lowdown >= 1.4, https://gerrit.lix.systems/c/lix/+/3731 + (fetchpatch2 { + name = "lix-lowdown-1.4.0.patch"; + url = "https://git.lix.systems/lix-project/lix/commit/858de5f47a1bfd33835ec97794ece339a88490f1.patch"; + hash = "sha256-FfLO2dFSWV1qwcupIg8dYEhCHir2XX6/Hs89eLwd+SY="; + }) + ]; + cargoDeps = rustPlatform.fetchCargoVendor { name = "lix-${version}"; inherit src;