From 33614fda223ffee95787f9babeae1d6904d93a08 Mon Sep 17 00:00:00 2001 From: networkException Date: Wed, 16 Aug 2023 17:35:06 +0200 Subject: [PATCH 1/3] re2: 2023-03-01 -> 2023-08-01 now requires abseil-cpp. --- pkgs/development/libraries/re2/default.nix | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/re2/default.nix b/pkgs/development/libraries/re2/default.nix index 202035232399..93960c7b3108 100644 --- a/pkgs/development/libraries/re2/default.nix +++ b/pkgs/development/libraries/re2/default.nix @@ -8,23 +8,26 @@ , haskellPackages , mercurial , python3Packages +, abseil-cpp }: stdenv.mkDerivation rec { pname = "re2"; - version = "2023-03-01"; + version = "2023-08-01"; src = fetchFromGitHub { owner = "google"; repo = "re2"; rev = version; - hash = "sha256-T+P7qT8x5dXkLZAL8VjvqPD345sa6ALX1f5rflE0dwc="; + hash = "sha256-RexwqNR/Izf2Rzu1cvMw+le6C4EmL4CeWCOc+vXUBZQ="; }; outputs = [ "out" "dev" ]; nativeBuildInputs = [ cmake ninja ]; + propagatedBuildInputs = [ abseil-cpp ]; + postPatch = '' substituteInPlace re2Config.cmake.in \ --replace "\''${PACKAGE_PREFIX_DIR}/" "" From f5e30de2ff3a41fe966be628a58fcac900ee9183 Mon Sep 17 00:00:00 2001 From: networkException Date: Wed, 16 Aug 2023 17:39:17 +0200 Subject: [PATCH 2/3] re2: add networkexception as maintainer --- pkgs/development/libraries/re2/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/libraries/re2/default.nix b/pkgs/development/libraries/re2/default.nix index 93960c7b3108..adaef49976a7 100644 --- a/pkgs/development/libraries/re2/default.nix +++ b/pkgs/development/libraries/re2/default.nix @@ -68,7 +68,7 @@ stdenv.mkDerivation rec { ''; license = licenses.bsd3; homepage = "https://github.com/google/re2"; - maintainers = with maintainers; [ azahi ]; + maintainers = with maintainers; [ azahi networkexception ]; platforms = platforms.all; }; } From a60e0da56302bc09573bc45fb3f86d7fb57a61a3 Mon Sep 17 00:00:00 2001 From: emilylange Date: Fri, 18 Aug 2023 14:59:33 +0200 Subject: [PATCH 3/3] pythonPackages.fb-re2: fix build with new re2 release --- pkgs/development/python-modules/fb-re2/default.nix | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/pkgs/development/python-modules/fb-re2/default.nix b/pkgs/development/python-modules/fb-re2/default.nix index 32a6a1d60ca1..df494068c444 100644 --- a/pkgs/development/python-modules/fb-re2/default.nix +++ b/pkgs/development/python-modules/fb-re2/default.nix @@ -1,5 +1,6 @@ { lib , buildPythonPackage +, fetchpatch , fetchPypi , re2 }: @@ -13,6 +14,16 @@ buildPythonPackage rec { sha256 = "83b2c2cd58d3874e6e3a784cf4cf2f1a57ce1969e50180f92b010eea24ef26cf"; }; + patches = [ + # Bump stdlib to c++17 to fix build with recent re2 + # https://github.com/facebook/pyre2/issues/24 + # https://github.com/facebook/pyre2/pull/25 + (fetchpatch { + url = "https://github.com/facebook/pyre2/pull/25/commits/08fb06ec3ccd412ca69483d27234684a04cb91a0.patch"; + hash = "sha256-kzxE2AxpE1tJJK0dJgoFfVka9zy2u0HEqiHoS7DQDQ0="; + }) + ]; + buildInputs = [ re2 ]; # no tests in PyPI tarball