2015-02-06 21:21:57 +01:00
|
|
|
{ stdenv, version, src
|
|
|
|
, autoreconfHook, zlib, gtest
|
|
|
|
, ...
|
|
|
|
}:
|
2010-10-30 23:44:22 +02:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2015-02-20 19:42:14 +01:00
|
|
|
name = "protobuf-${version}";
|
2014-11-19 19:33:20 +01:00
|
|
|
|
2015-02-06 21:21:57 +01:00
|
|
|
inherit src;
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
rm -rf gtest
|
|
|
|
cp -r ${gtest.source} gtest
|
|
|
|
chmod -R a+w gtest
|
2015-10-20 03:40:55 +02:00
|
|
|
'' + stdenv.lib.optionalString stdenv.isDarwin ''
|
|
|
|
substituteInPlace src/google/protobuf/testing/googletest.cc \
|
|
|
|
--replace 'tmpnam(b)' '"'$TMPDIR'/foo"'
|
2015-02-06 21:21:57 +01:00
|
|
|
'';
|
2014-11-19 19:33:20 +01:00
|
|
|
|
2016-04-14 16:04:49 +02:00
|
|
|
outputs = [ "out" "lib" ];
|
|
|
|
|
2015-02-06 21:21:57 +01:00
|
|
|
buildInputs = [ autoreconfHook zlib ];
|
2010-10-30 23:44:22 +02:00
|
|
|
|
2014-09-18 13:12:01 +02:00
|
|
|
doCheck = true;
|
|
|
|
|
|
|
|
meta = {
|
2010-10-30 23:44:22 +02:00
|
|
|
description = "Protocol Buffers - Google's data interchange format";
|
2014-11-25 12:59:56 +01:00
|
|
|
longDescription =
|
|
|
|
'' Protocol Buffers are a way of encoding structured data in an
|
|
|
|
efficient yet extensible format. Google uses Protocol Buffers for
|
|
|
|
almost all of its internal RPC protocols and file formats.
|
|
|
|
'';
|
|
|
|
license = "mBSD";
|
2016-01-15 02:24:54 +01:00
|
|
|
homepage = https://developers.google.com/protocol-buffers/;
|
2016-08-02 19:50:55 +02:00
|
|
|
platforms = stdenv.lib.platforms.unix;
|
2010-10-30 23:44:22 +02:00
|
|
|
};
|
2015-02-20 19:36:16 +01:00
|
|
|
|
|
|
|
passthru.version = version;
|
2010-10-30 23:44:22 +02:00
|
|
|
}
|