diff --git a/pkgs/tools/misc/picocom/default.nix b/pkgs/tools/misc/picocom/default.nix index bb66b97039da..c49695fd9ad9 100644 --- a/pkgs/tools/misc/picocom/default.nix +++ b/pkgs/tools/misc/picocom/default.nix @@ -1,4 +1,8 @@ -{ stdenv, fetchFromGitHub, makeWrapper, lrzsz }: +{ stdenv, fetchFromGitHub, makeWrapper, lrzsz, IOKit }: + +assert stdenv.isDarwin -> IOKit != null; + +with stdenv.lib; stdenv.mkDerivation rec { name = "picocom-${version}"; @@ -11,7 +15,8 @@ stdenv.mkDerivation rec { sha256 = "1vvjydqf0ax47nvdyyl67jafw5b3sfsav00xid6qpgia1gs2r72n"; }; - buildInputs = [ makeWrapper ]; + buildInputs = [ makeWrapper ] + ++ optionals stdenv.isDarwin [ IOKit ]; installPhase = '' mkdir -p $out/bin $out/share/man/man1 @@ -26,6 +31,6 @@ stdenv.mkDerivation rec { description = "Minimal dumb-terminal emulation program"; homepage = https://github.com/npat-efault/picocom/; license = stdenv.lib.licenses.gpl2Plus; - platforms = stdenv.lib.platforms.gnu ++ stdenv.lib.platforms.linux; # arbitrary choice + platforms = platforms.unix; }; } diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 35d986a10d49..80e9680cb1b8 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -18821,7 +18821,9 @@ in picard = callPackage ../applications/audio/picard { }; - picocom = callPackage ../tools/misc/picocom { }; + picocom = callPackage ../tools/misc/picocom { + inherit (darwin.apple_sdk.frameworks) IOKit; + }; pidgin = callPackage ../applications/networking/instant-messengers/pidgin { openssl = if config.pidgin.openssl or true then openssl else null;