man-db: Fix build on FreeBSD (#334985)

This commit is contained in:
Jörg Thalheim
2024-09-19 07:59:10 +02:00
committed by GitHub
+6 -2
View File
@@ -5,6 +5,7 @@
, gzip
, lib
, libiconv
, libiconvReal
, libpipeline
, makeWrapper
, nixosTests
@@ -28,8 +29,9 @@ stdenv.mkDerivation rec {
strictDeps = true;
nativeBuildInputs = [ autoreconfHook groff makeWrapper pkg-config zstd ];
buildInputs = [ libpipeline db groff ]; # (Yes, 'groff' is both native and build input)
nativeCheckInputs = [ libiconv /* for 'iconv' binary */ ];
buildInputs = [ libpipeline db groff ] # (Yes, 'groff' is both native and build input)
++ lib.optional stdenv.isFreeBSD libiconvReal;
nativeCheckInputs = [ (if stdenv.isFreeBSD then libiconvReal else libiconv) ]; # for 'iconv' binary; make very sure it matches buildinput libiconv
patches = [
./systemwide-man-db-conf.patch
@@ -59,6 +61,8 @@ stdenv.mkDerivation rec {
"ac_cv_func__set_invalid_parameter_handler=no"
"ac_cv_func_posix_fadvise=no"
"ac_cv_func_mempcpy=no"
] ++ lib.optionals stdenv.hostPlatform.isFreeBSD [
"--enable-mandirs="
];
preConfigure = ''