1 { stdenv, lib, fetchurl, skawarePackages }:
5 # When you update, check whether we can drop the skalibs pin.
6 version = "2020.05.04";
7 sha256 = "0lnafcp4yipi0dl8gh33zjs8wlpz0mim8mwmiz9s49id0b0fmlla";
8 skalibs = skawarePackages.skalibs_2_10;
10 in stdenv.mkDerivation {
11 inherit pname version;
14 url = "https://code.dogmap.org/fdtools/releases/fdtools-${version}.tar.bz2";
18 patches = [ ./new-skalibs.patch ];
19 outputs = [ "bin" "lib" "dev" "doc" "out" ];
22 # temporary, until fdtools catches up to skalibs
29 conf-compile/defaults/host_link.sh \
30 > conf-compile/host_link.sh
32 conf-compile/defaults/host_compile.sh \
33 > conf-compile/host_compile.sh
35 echo "${skalibs.lib}/lib/skalibs/sysdeps" \
36 > conf-compile/depend_skalibs_sysdeps
45 tools=( grabconsole multitee pipecycle recvfd seek0 sendfd setblock setstate statfile vc-get vc-lock vc-switch )
47 for t in "''${tools[@]}"; do
48 mv "command/$t" "$bin/bin/$t"
53 docdir=$doc/share/doc/fdtools
56 mv library/fdtools.a $lib/lib/fdtools.a
57 mv include/fdtools.h $dev/include/fdtools.h
59 ${skawarePackages.cleanPackaging.commonFileActions {
65 "package/{build,check,compile,elsewhere,install,install_commands,own,run,sharing,upgrade,upgrade_version,url_src,url_src_latest,versions}"
74 ${skawarePackages.cleanPackaging.checkForRemainingFiles}
76 # we don’t use this, but nixpkgs requires it
81 homepage = "https://code.dogmap.org/fdtools/";
82 description = "Set of utilities for working with file descriptors";
83 license = lib.licenses.gpl2Only;
84 platforms = lib.platforms.linux;
85 maintainers = [ lib.maintainers.Profpatsch ];