5 updateAutotoolsGnuConfigScriptsHook,
9 stdenv.mkDerivation rec {
14 url = "https://github.com/PhilipHazel/pcre2/releases/download/pcre2-${version}/pcre2-${version}.tar.bz2";
15 hash = "sha256-008C4RPPcZOh6/J3DTrFJwiNSF1OBH7RDl0hfG713pY=";
18 nativeBuildInputs = [ updateAutotoolsGnuConfigScriptsHook ];
24 # only enable jit on supported platforms which excludes Apple Silicon, see https://github.com/zherczeg/sljit/issues/51
25 "--enable-jit=${if stdenv.hostPlatform.isS390x then "no" else "auto"}"
27 # fix pcre jit in systemd units that set MemoryDenyWriteExecute=true like gitea
28 ++ lib.optional withJitSealloc "--enable-jit-sealloc";
40 moveToOutput bin/pcre2-config "$dev"
44 homepage = "https://www.pcre.org/";
45 description = "Perl Compatible Regular Expressions";
46 license = licenses.bsd3;
47 maintainers = with maintainers; [ ttuegel ];
48 platforms = platforms.all;