lldpd: build on macOS (#350485)

This commit is contained in:
Franz Pletz 2024-10-25 07:59:28 +02:00 committed by GitHub
commit e176bec092
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 21 additions and 5 deletions

View File

@ -1,5 +1,13 @@
{ stdenv, lib, fetchurl, pkg-config, removeReferencesTo
, libevent, readline, net-snmp, openssl
{ stdenv
, Foundation
, fetchurl
, lib
, libevent
, net-snmp
, openssl
, pkg-config
, readline
, removeReferencesTo
}:
stdenv.mkDerivation rec {
@ -16,10 +24,16 @@ stdenv.mkDerivation rec {
"--enable-pie"
"--with-snmp"
"--with-systemdsystemunitdir=\${out}/lib/systemd/system"
] ++ lib.optionals stdenv.hostPlatform.isDarwin [
"--with-launchddaemonsdir=no"
"--with-privsep-chroot=/var/empty"
"--with-privsep-group=nogroup"
"--with-privsep-user=nobody"
];
nativeBuildInputs = [ pkg-config removeReferencesTo ];
buildInputs = [ libevent readline net-snmp openssl ];
buildInputs = [ libevent readline net-snmp openssl ]
++ lib.optionals stdenv.hostPlatform.isDarwin [ Foundation ];
enableParallelBuilding = true;
@ -34,6 +48,6 @@ stdenv.mkDerivation rec {
homepage = "https://lldpd.github.io/";
license = licenses.isc;
maintainers = with maintainers; [ fpletz ];
platforms = platforms.linux;
platforms = platforms.unix;
};
}

View File

@ -9163,7 +9163,9 @@ with pkgs;
lksctp-tools = callPackage ../os-specific/linux/lksctp-tools { };
lldpd = callPackage ../tools/networking/lldpd { };
lldpd = callPackage ../tools/networking/lldpd {
inherit (darwin.apple_sdk.frameworks) Foundation;
};
llm = with python3Packages; toPythonApplication llm;