Merge pull request #116531 from SuperSandro2000/grpc

This commit is contained in:
Sandro 2021-03-26 17:45:58 +01:00 committed by GitHub
commit 362a2fb63f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 10 additions and 16 deletions

View File

@ -9,10 +9,8 @@
, doxygen
, protobuf
, crc32c
, c-ares
, fetchurl
, openssl
, zlib
, libnsl
}:
let
@ -33,7 +31,7 @@ let
};
nativeBuildInputs = [ cmake pkg-config ];
buildInputs = [ c-ares c-ares.cmake-config grpc openssl protobuf zlib ];
buildInputs = [ grpc openssl protobuf ];
postPatch = ''
sed -e 's,https://github.com/googleapis/googleapis/archive/9c9f778aedde02f9826d2ae5d0f9c96409ba0f25.tar.gz,file://${googleapis},' \
@ -55,7 +53,7 @@ in stdenv.mkDerivation rec {
sha256 = "15wci4m8h6py7fqfziq8mp5m6pxp2h1cbh5rp2k90mk5js4jb9pa";
};
buildInputs = [ curl crc32c c-ares c-ares.cmake-config googleapis-cpp-cmakefiles grpc protobuf libnsl ];
buildInputs = [ curl crc32c googleapis-cpp-cmakefiles grpc protobuf libnsl ];
nativeBuildInputs = [ clang-tools cmake pkg-config doxygen ];
outputs = [ "out" "dev" ];

View File

@ -1,12 +1,8 @@
{ stdenv, lib, fetchFromGitHub, pkg-config, cmake
, opentracing-cpp, protobuf, zlib
, enableGrpc ? false, grpc ? null, openssl ? null, c-ares ? null
, opentracing-cpp, protobuf
, enableGrpc ? false, grpc, openssl
}:
assert enableGrpc -> grpc != null;
assert enableGrpc -> openssl != null;
assert enableGrpc -> c-ares != null;
stdenv.mkDerivation rec {
pname = "lightstep-tracer-cpp";
version = "0.14.0";
@ -23,9 +19,9 @@ stdenv.mkDerivation rec {
];
buildInputs = [
opentracing-cpp protobuf zlib
opentracing-cpp protobuf
] ++ lib.optionals enableGrpc [
grpc openssl c-ares c-ares.cmake-config
grpc openssl
];
cmakeFlags = lib.optionals (!enableGrpc) [ "-DWITH_GRPC=OFF" ];

View File

@ -1,5 +1,5 @@
{ lib, stdenv, fetchFromGitHub, cmake, kernel, installShellFiles
, luajit, zlib, ncurses, perl, jsoncpp, libb64, openssl, curl, jq, gcc, elfutils, tbb, c-ares, protobuf, grpc
, luajit, ncurses, perl, jsoncpp, libb64, openssl, curl, jq, gcc, elfutils, tbb, protobuf, grpc
}:
with lib;
@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ cmake perl installShellFiles ];
buildInputs = [
zlib luajit ncurses jsoncpp libb64 openssl curl jq gcc elfutils tbb c-ares protobuf grpc
luajit ncurses jsoncpp libb64 openssl curl jq gcc elfutils tbb protobuf grpc
] ++ optionals (kernel != null) kernel.moduleBuildDependencies;
hardeningDisable = [ "pic" ];

View File

@ -1,5 +1,5 @@
{ lib, stdenv, fetchgit, fetchurl, git, cmake, pkg-config
, openssl, zlib, boost, grpc, c-ares, abseil-cpp, protobuf3_8, libnsl }:
, openssl, boost, grpc, abseil-cpp, protobuf3_8, libnsl }:
let
sqlite3 = fetchurl rec {
@ -130,7 +130,7 @@ in stdenv.mkDerivation rec {
cmakeFlags = ["-Dstatic=OFF" "-DBoost_NO_BOOST_CMAKE=ON"];
nativeBuildInputs = [ pkg-config cmake git ];
buildInputs = [ openssl openssl.dev boostSharedStatic zlib grpc c-ares c-ares.cmake-config abseil-cpp protobuf3_8 libnsl ];
buildInputs = [ openssl openssl.dev boostSharedStatic grpc abseil-cpp protobuf3_8 libnsl ];
preConfigure = ''
export HOME=$PWD