From 6535f0bca658d772efffbfe04ba5f9e625a9b31e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20=C4=8Cun=C3=A1t?= Date: Mon, 6 Nov 2017 19:20:21 +0100 Subject: [PATCH] flex: fix with glibc-2.26 It caused segfaults, e.g. when building doxygen. --- pkgs/development/tools/parsing/flex/default.nix | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/pkgs/development/tools/parsing/flex/default.nix b/pkgs/development/tools/parsing/flex/default.nix index 92fba47b756f..354126b5457f 100644 --- a/pkgs/development/tools/parsing/flex/default.nix +++ b/pkgs/development/tools/parsing/flex/default.nix @@ -1,4 +1,6 @@ -{ stdenv, fetchurl, bison, m4 }: +{ stdenv, fetchurl, bison, m4 +, fetchpatch, autoreconfHook, help2man +}: stdenv.mkDerivation rec { name = "flex-${version}"; @@ -9,6 +11,14 @@ stdenv.mkDerivation rec { sha256 = "15g9bv236nzi665p9ggqjlfn4dwck5835vf0bbw2cz7h5c1swyp8"; }; + patches = [(fetchpatch { + name = "glibc-2.26.patch"; + url = "https://raw.githubusercontent.com/lede-project/source/0fb14a2b1ab2f82c" + + "/tools/flex/patches/200-build-AC_USE_SYSTEM_EXTENSIONS-in-configure.ac.patch"; + sha256 = "1aarhcmz7mfrgh15pkj6f7ikxa2m0mllw1i1vscsf1kw5d05lw6f"; + })]; + nativeBuildInputs = [ autoreconfHook help2man ]; + buildInputs = [ bison ]; propagatedBuildInputs = [ m4 ];