Merge pull request #101234 from danielfullmer/cross-rpcsvc-proto

rpcsvc-proto: fix cross-compilation
This commit is contained in:
Maximilian Bosch 2020-10-21 21:38:42 +02:00 committed by GitHub
commit a3b1b42d32
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,4 +1,4 @@
{ stdenv, fetchFromGitHub, autoreconfHook }:
{ stdenv, lib, fetchFromGitHub, autoreconfHook, buildPackages }:
stdenv.mkDerivation rec {
pname = "rpcsvc-proto";
@ -13,8 +13,14 @@ stdenv.mkDerivation rec {
outputs = [ "out" "man" ];
depsBuildBuild = [ buildPackages.stdenv.cc ];
nativeBuildInputs = [ autoreconfHook ];
postPatch = lib.optionalString (stdenv.hostPlatform != stdenv.buildPlatform) ''
substituteInPlace rpcsvc/Makefile.am \
--replace '$(top_builddir)/rpcgen/rpcgen' '${buildPackages.rpcsvc-proto}/bin/rpcgen'
'';
meta = with stdenv.lib; {
homepage = "https://github.com/thkukuk/rpcsvc-proto";
description = "This package contains rpcsvc proto.x files from glibc, which are missing in libtirpc";