1{
2 lib,
3 stdenv,
4 fetchFromGitHub,
5 installShellFiles,
6}:
7
8stdenv.mkDerivation rec {
9 pname = "tncattach";
10 version = "0.1.9";
11
12 src = fetchFromGitHub {
13 owner = "markqvist";
14 repo = "tncattach";
15 rev = version;
16 sha256 = "0n7ad4gqvpgabw2i67s51lfz386wmv0cvnhxq9ygxpsqmx9aynxk";
17 };
18
19 nativeBuildInputs = [ installShellFiles ];
20
21 makeFlags = [ "compiler=$(CC)" ];
22
23 installPhase = ''
24 runHook preInstall
25 install -Dm755 tncattach -t $out/bin
26 installManPage tncattach.8
27 runHook postInstall
28 '';
29
30 meta = with lib; {
31 description = "Attach KISS TNC devices as network interfaces";
32 homepage = "https://github.com/markqvist/tncattach";
33 license = licenses.mit;
34 maintainers = with maintainers; [ sarcasticadmin ];
35 platforms = platforms.linux;
36 mainProgram = "tncattach";
37 };
38}