diff --git a/pkgs/development/libraries/science/networking/ns-3/default.nix b/pkgs/development/libraries/science/networking/ns-3/default.nix index 94bb5c3e3ab2..494c7f9f851b 100644 --- a/pkgs/development/libraries/science/networking/ns-3/default.nix +++ b/pkgs/development/libraries/science/networking/ns-3/default.nix @@ -1,5 +1,6 @@ { stdenv , fetchFromGitLab +, fetchpatch , python , wafHook @@ -44,7 +45,7 @@ stdenv.mkDerivation rec { owner = "nsnam"; repo = "ns-3-dev"; rev = "ns-3.${version}"; - sha256 = "158yjhsrmslj1q4zcq5p16hv9i82qnxx714l7idicncn0wzrfx7k"; + sha256 = "0ds8h0f2qcb0gc2a8bk38cbhdb122i4sbg589bjn59rblzw0hkq4"; }; nativeBuildInputs = [ wafHook python ]; @@ -97,6 +98,14 @@ stdenv.mkDerivation rec { ${pythonEnv.interpreter} ./test.py --nowaf ''; + patches = [ + (fetchpatch { + name = "upstream-issue-336.patch"; + url = "https://gitlab.com/nsnam/ns-3-dev/-/commit/673004edae1112e6cb249b698aad856d728530fb.patch"; + sha256 = "0q96ividinbh9xlws014b2ir6gaavygnln5ca9m1db06m4vfwhng"; + }) + ]; + # strictoverflow prevents clang from discovering pyembed when bindings hardeningDisable = [ "fortify" "strictoverflow"];