1{ lib
2, stdenv
3, fetchFromGitHub
4}:
5
6stdenv.mkDerivation rec {
7 pname = "tinyssh";
8 version = "20240101";
9
10 src = fetchFromGitHub {
11 owner = "janmojzis";
12 repo = "tinyssh";
13 rev = "refs/tags/${version}";
14 hash = "sha256-wO0fGr+pU+Y5YCZMRGNOZ6pJeCUIc64TzmRAaQCnBxk=";
15 };
16
17 preConfigure = ''
18 echo /bin > conf-bin
19 echo /share/man > conf-man
20 '';
21
22 env.NIX_CFLAGS_COMPILE = lib.optionalString stdenv.cc.isClang "-Wno-error=implicit-function-declaration";
23
24 DESTDIR = placeholder "out";
25
26 meta = with lib; {
27 description = "Minimalistic SSH server";
28 homepage = "https://tinyssh.org";
29 changelog = "https://github.com/janmojzis/tinyssh/releases/tag/${version}";
30 license = licenses.cc0;
31 platforms = platforms.unix;
32 maintainers = with maintainers; [ kaction ];
33 };
34}