2021-01-21 17:00:13 +00:00
|
|
|
{ lib, stdenv
|
2020-03-19 07:46:14 +00:00
|
|
|
, fetchFromGitLab
|
|
|
|
, meson
|
|
|
|
, ninja
|
|
|
|
, pkg-config
|
|
|
|
, glib
|
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "libslirp";
|
2020-12-02 20:11:26 +00:00
|
|
|
version = "4.4.0";
|
2020-03-19 07:46:14 +00:00
|
|
|
|
|
|
|
src = fetchFromGitLab {
|
|
|
|
domain = "gitlab.freedesktop.org";
|
|
|
|
owner = "slirp";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2020-12-02 20:11:26 +00:00
|
|
|
sha256 = "0abh337jvij664w65zszjql42n720zzfap0ab0amr4qcvkzw7bjx";
|
2020-03-19 07:46:14 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ meson ninja pkg-config ];
|
|
|
|
|
|
|
|
buildInputs = [ glib ];
|
|
|
|
|
2020-04-24 00:13:31 +00:00
|
|
|
postPatch = ''
|
|
|
|
echo ${version} > .tarball-version
|
|
|
|
'';
|
|
|
|
|
2021-01-21 17:00:13 +00:00
|
|
|
meta = with lib; {
|
2020-03-19 07:46:14 +00:00
|
|
|
description = "General purpose TCP-IP emulator";
|
|
|
|
homepage = "https://gitlab.freedesktop.org/slirp/libslirp";
|
|
|
|
license = licenses.bsd3;
|
|
|
|
maintainers = with maintainers; [ orivej ];
|
2020-12-02 20:11:26 +00:00
|
|
|
platforms = platforms.unix;
|
2020-03-19 07:46:14 +00:00
|
|
|
};
|
|
|
|
}
|