gperftools: Update to 2.0 and fix build

http://hydra.nixos.org/build/3875478
This commit is contained in:
Eelco Dolstra 2013-01-28 13:48:35 +01:00
parent 67de843bce
commit 35af62f998
5 changed files with 38 additions and 17 deletions

View file

@ -1,6 +1,6 @@
{ stdenv, fetchurl, fetchgit, cmake, boost, libunwind, mysql, libmemcached, pcre
, libevent, gd, curl, libxml2, icu, flex, bison, openssl, zlib, php, re2c
, expat, libcap, oniguruma, libdwarf, libmcrypt, inteltbb, google_perftools
, expat, libcap, oniguruma, libdwarf, libmcrypt, inteltbb, gperftools
, bzip2, openldap, readline, libelf, uwimap, binutils, cyrus_sasl, pam
}:
assert stdenv.system == "x86_64-linux";
@ -45,7 +45,7 @@ stdenv.mkDerivation {
buildInputs = [
cmake boost libunwind mysql libmemcached pcre libeventFB gd curlFB
libxml2_280 icu flex bison openssl zlib php expat libcap oniguruma
libdwarf libmcrypt inteltbb google_perftools bzip2 openldap readline
libdwarf libmcrypt inteltbb gperftools bzip2 openldap readline
libelf uwimap binutils cyrus_sasl pam
];
installPhase = ''

View file

@ -1,14 +0,0 @@
{stdenv, fetchurl, libunwind}:
stdenv.mkDerivation rec {
name = "google-perftools-1.8.3";
src = fetchurl {
url = "http://google-perftools.googlecode.com/files/${name}.tar.gz";
sha256 = "0ncx3a8jl6n38q9bjnaz5sq96yb6yh99j3bl64k3295v9arl9mva";
};
buildInputs = [libunwind];
meta = {
description = "Fast, multi-threaded malloc() and nifty performance analysis tools.";
platforms = stdenv.lib.platforms.linux;
};
}

View file

@ -0,0 +1,22 @@
{ stdenv, fetchurl, libunwind }:
stdenv.mkDerivation rec {
name = "gperftools-2.0";
src = fetchurl {
url = "https://gperftools.googlecode.com/files/${name}.tar.gz";
sha1 = "da7181a7ba9b5ee7302daf6c16e886c179fe8d1b";
};
patches = [ ./glibc-2.16.patch ];
buildInputs = [ libunwind ];
enableParallelBuilding = true;
meta = {
homepage = https://code.google.com/p/gperftools/;
description = "Fast, multi-threaded malloc() and nifty performance analysis tools";
platforms = stdenv.lib.platforms.linux;
};
}

View file

@ -0,0 +1,13 @@
Index: gperftools-2.0/src/base/linuxthreads.cc
===================================================================
--- gperftools-2.0.orig/src/base/linuxthreads.cc
+++ gperftools-2.0/src/base/linuxthreads.cc
@@ -193,7 +193,7 @@ static volatile int *sig_pids, sig_num_t
/* Signal handler to help us recover from dying while we are attached to
* other threads.
*/
-static void SignalHandler(int signum, siginfo_t *si, void *data) {
+static void SignalHandler(int signum, struct siginfo *si, void *data) {
if (sig_pids != NULL) {
if (signum == SIGABRT) {
while (sig_num_threads-- > 0) {

View file

@ -3807,7 +3807,7 @@ let
goocanvas = callPackage ../development/libraries/goocanvas { };
google_perftools = callPackage ../development/libraries/google-perftools { };
gperftools = callPackage ../development/libraries/gperftools { };
#GMP ex-satellite, so better keep it near gmp
mpfr = callPackage ../development/libraries/mpfr { };