Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
50 lines
942 B
Nix
50 lines
942 B
Nix
{
|
|
lib,
|
|
mkDerivation,
|
|
buildPackages,
|
|
rpcgen,
|
|
mtree,
|
|
}:
|
|
|
|
mkDerivation {
|
|
noLibc = true;
|
|
path = "include";
|
|
|
|
extraPaths = [
|
|
"contrib/libc-vis"
|
|
"etc/mtree/BSD.include.dist"
|
|
"sys"
|
|
# Used for aarch64-freebsd
|
|
"lib/msun/arm"
|
|
];
|
|
|
|
extraNativeBuildInputs = [
|
|
rpcgen
|
|
mtree
|
|
];
|
|
|
|
# The makefiles define INCSDIR per subdirectory, so we have to set
|
|
# something else on the command line so those definitions aren't
|
|
# overridden.
|
|
postPatch = ''
|
|
find "$BSDSRCDIR" -name Makefile -exec \
|
|
sed -i -E \
|
|
-e 's_/usr/include_''${INCSDIR0}_' \
|
|
{} \;
|
|
sed -E -i -e "/_PATH_LOGIN/d" $BSDSRCDIR/include/paths.h
|
|
'';
|
|
|
|
makeFlags = [ "RPCGEN_CPP=${buildPackages.stdenv.cc.cc}/bin/cpp" ];
|
|
|
|
# multiple header dirs, see above
|
|
postConfigure = ''
|
|
makeFlags=''${makeFlags/INCSDIR/INCSDIR0}
|
|
'';
|
|
|
|
headersOnly = true;
|
|
|
|
MK_HESIOD = "yes";
|
|
|
|
meta.platforms = lib.platforms.freebsd;
|
|
}
|