Skip to content

Commit a56b995

Browse files
tre: 0.8.0 -> 0.9.0 (#365785)
2 parents 1a241fd + 26f9a86 commit a56b995

File tree

1 file changed

+38
-13
lines changed

1 file changed

+38
-13
lines changed

pkgs/by-name/tr/tre/package.nix

Lines changed: 38 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,55 @@
11
{
22
lib,
33
stdenv,
4-
fetchurl,
5-
fetchpatch,
4+
fetchFromGitHub,
5+
autoconf,
6+
automake,
7+
darwin,
8+
gettext,
9+
libiconv,
10+
libtool,
611
}:
712

8-
stdenv.mkDerivation rec {
13+
stdenv.mkDerivation (finalAttrs: {
914
pname = "tre";
10-
version = "0.8.0";
11-
src = fetchurl {
12-
url = "https://laurikari.net/tre/${pname}-${version}.tar.gz";
13-
sha256 = "1pd7qsa7vc3ybdc6h2gr4pm9inypjysf92kab945gg4qa6jp11my";
15+
version = "0.9.0";
16+
17+
src = fetchFromGitHub {
18+
owner = "laurikari";
19+
repo = "tre";
20+
tag = "v${finalAttrs.version}";
21+
hash = "sha256-5O8yqzv+SR8x0X7GtC2Pjo94gp0799M2Va8wJ4EKyf8=";
1422
};
1523

16-
patches = [
17-
(fetchpatch {
18-
url = "https://sources.debian.net/data/main/t/tre/0.8.0-6/debian/patches/03-cve-2016-8859";
19-
sha256 = "0navhizym6qxd4gngrsslbij8x9r3s67p1jzzhvsnq6ky49j7w3p";
20-
})
24+
outputs = [
25+
"out"
26+
"dev"
27+
];
28+
29+
nativeBuildInputs = [
30+
autoconf
31+
automake
32+
libtool
2133
];
2234

35+
buildInputs =
36+
[
37+
gettext
38+
]
39+
++ lib.optionals stdenv.hostPlatform.isDarwin [
40+
libiconv
41+
];
42+
43+
preConfigure = ''
44+
./utils/autogen.sh
45+
'';
46+
2347
meta = {
2448
description = "Lightweight and robust POSIX compliant regexp matching library";
2549
homepage = "https://laurikari.net/tre/";
50+
changelog = "https://github.com/laurikari/tre/releases/tag/v${finalAttrs.version}";
2651
license = lib.licenses.bsd2;
2752
mainProgram = "agrep";
2853
platforms = lib.platforms.unix;
2954
};
30-
}
55+
})

0 commit comments

Comments
 (0)