2019-05-31 19:21:14 +00:00
|
|
|
{ stdenv, fetchFromGitHub }:
|
2013-08-15 13:07:04 +00:00
|
|
|
|
2019-08-13 21:52:01 +00:00
|
|
|
stdenv.mkDerivation {
|
2019-08-15 12:41:18 +00:00
|
|
|
pname = "re2";
|
2019-05-31 19:21:14 +00:00
|
|
|
version = "20190401";
|
2013-08-15 13:07:04 +00:00
|
|
|
|
2019-05-31 19:21:14 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "google";
|
|
|
|
repo = "re2";
|
|
|
|
rev = "2019-04-01";
|
|
|
|
sha256 = "018b8z3fgcr02rmhxdz80r363k40938cbgmk1c9b46k6xkc4q0hd";
|
2013-08-15 13:07:04 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
preConfigure = ''
|
|
|
|
substituteInPlace Makefile --replace "/usr/local" "$out"
|
2019-05-31 19:21:14 +00:00
|
|
|
# we're using gnu sed, even on darwin
|
|
|
|
substituteInPlace Makefile --replace "SED_INPLACE=sed -i '''" "SED_INPLACE=sed -i"
|
2013-08-15 13:07:04 +00:00
|
|
|
'';
|
|
|
|
|
2019-05-31 21:28:45 +00:00
|
|
|
preCheck = "patchShebangs runtests";
|
|
|
|
doCheck = true;
|
|
|
|
checkTarget = "test";
|
|
|
|
|
|
|
|
doInstallCheck = true;
|
|
|
|
installCheckTarget = "testinstall";
|
|
|
|
|
2013-08-15 13:07:04 +00:00
|
|
|
meta = {
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "https://github.com/google/re2";
|
2013-08-15 13:07:04 +00:00
|
|
|
description = "An efficient, principled regular expression library";
|
2015-05-28 17:20:29 +00:00
|
|
|
license = stdenv.lib.licenses.bsd3;
|
2013-08-15 13:07:04 +00:00
|
|
|
platforms = with stdenv.lib.platforms; all;
|
|
|
|
};
|
|
|
|
}
|