From 8edc5f9999026fe206b34815004488f9b6eb75e0 Mon Sep 17 00:00:00 2001 From: Moritz Ulrich Date: Fri, 21 Mar 2014 13:26:03 +0100 Subject: [PATCH] weechat: Backport fix for freeze with gnutls 3.2. Fixes /exit when using gnutls 3.2. This is a temporary solution as 3.1 isn't building right now. The next release of weechat will include this fix. --- .../networking/irc/weechat/default.nix | 7 +++++++ .../networking/irc/weechat/fix-gnutls-32.diff | 16 ++++++++++++++++ pkgs/top-level/all-packages.nix | 5 +---- 3 files changed, 24 insertions(+), 4 deletions(-) create mode 100644 pkgs/applications/networking/irc/weechat/fix-gnutls-32.diff diff --git a/pkgs/applications/networking/irc/weechat/default.nix b/pkgs/applications/networking/irc/weechat/default.nix index 89b437acc905..b47018e0d970 100644 --- a/pkgs/applications/networking/irc/weechat/default.nix +++ b/pkgs/applications/networking/irc/weechat/default.nix @@ -17,6 +17,13 @@ stdenv.mkDerivation rec { cacert cmake ]; + # This patch is based on + # weechat/c324610226cef15ecfb1235113c8243b068084c8. It fixes + # freeze/crash on /exit when using nixpkgs' gnutls 3.2. The next + # weechat release (0.4.4) will include this, so it's safe to remove + # then. + patches = [ ./fix-gnutls-32.diff ]; + postInstall = '' wrapProgram "$out/bin/weechat" \ --prefix PYTHONPATH : "$PYTHONPATH" \ diff --git a/pkgs/applications/networking/irc/weechat/fix-gnutls-32.diff b/pkgs/applications/networking/irc/weechat/fix-gnutls-32.diff new file mode 100644 index 000000000000..56e357c8f7dc --- /dev/null +++ b/pkgs/applications/networking/irc/weechat/fix-gnutls-32.diff @@ -0,0 +1,16 @@ +diff --git a/src/gui/curses/CMakeLists.txt b/src/gui/curses/CMakeLists.txt +index 325c611..a8927bc 100644 +--- a/src/gui/curses/CMakeLists.txt ++++ b/src/gui/curses/CMakeLists.txt +@@ -53,9 +53,7 @@ IF(${CMAKE_SYSTEM_NAME} STREQUAL "FreeBSD") + ENDIF(HAVE_BACKTRACE) + ENDIF(${CMAKE_SYSTEM_NAME} STREQUAL "FreeBSD") + +-IF(${CMAKE_SYSTEM_NAME} STREQUAL "OpenBSD") +- LIST(APPEND EXTRA_LIBS "pthread") +-ENDIF(${CMAKE_SYSTEM_NAME} STREQUAL "OpenBSD") ++LIST(APPEND EXTRA_LIBS "pthread") + + IF(ICONV_LIBRARY) + LIST(APPEND EXTRA_LIBS ${ICONV_LIBRARY}) + diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 984188e2371b..968ef26d29ec 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -9215,10 +9215,7 @@ let graphicsSupport = false; }; - weechat = callPackage ../applications/networking/irc/weechat { - # weechat doesn't exit with gnutls32. Use 3.1 for now. - gnutls = gnutls31; - }; + weechat = callPackage ../applications/networking/irc/weechat { }; weston = callPackage ../applications/window-managers/weston { };