lol

Merge pull request #132310 from alyssais/grpc

grpc: fix cross

authored by

Ben Siraphob and committed by
GitHub
ae3a0556 038a9952

+6 -2
+6 -2
pkgs/development/libraries/grpc/default.nix
··· 1 - { lib, stdenv, fetchFromGitHub, fetchpatch, cmake, zlib, c-ares, pkg-config, re2, openssl, protobuf 1 + { lib, stdenv, fetchFromGitHub, fetchpatch, buildPackages 2 + , cmake, zlib, c-ares, pkg-config, re2, openssl, protobuf, grpc 2 3 , abseil-cpp, libnsl 3 4 }: 4 5 ··· 20 21 }) 21 22 ]; 22 23 23 - nativeBuildInputs = [ cmake pkg-config ]; 24 + nativeBuildInputs = [ cmake pkg-config ] 25 + ++ lib.optional (stdenv.hostPlatform != stdenv.buildPlatform) grpc; 24 26 propagatedBuildInputs = [ c-ares re2 zlib abseil-cpp ]; 25 27 buildInputs = [ c-ares.cmake-config openssl protobuf ] 26 28 ++ lib.optionals stdenv.isLinux [ libnsl ]; ··· 35 37 "-DBUILD_SHARED_LIBS=ON" 36 38 "-DCMAKE_SKIP_BUILD_RPATH=OFF" 37 39 "-DCMAKE_CXX_STANDARD=17" 40 + ] ++ lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform) [ 41 + "-D_gRPC_PROTOBUF_PROTOC_EXECUTABLE=${buildPackages.protobuf}/bin/protoc" 38 42 ]; 39 43 40 44 # CMake creates a build directory by default, this conflicts with the