nixpkgs/pkgs/servers/osmocom/osmo-mgw/default.nix
stuebinm ff1a94e523 treewide: add meta.mainProgram to packages with a single binary
The nixpkgs-unstable channel's programs.sqlite was used to identify
packages producing exactly one binary, and these automatically added
to their package definitions wherever possible.
2024-03-19 03:14:51 +01:00

53 lines
933 B
Nix

{ lib
, stdenv
, fetchFromGitHub
, autoreconfHook
, pkg-config
, libosmocore
, libosmo-netif
, libosmoabis
}:
let
inherit (stdenv) isLinux;
in
stdenv.mkDerivation rec {
pname = "osmo-mgw";
version = "1.12.2";
src = fetchFromGitHub {
owner = "osmocom";
repo = "osmo-mgw";
rev = version;
hash = "sha256-RE16qzL8CXjGzoDniB8gBF0fsIaWzDuIvpdQ/5vUdug=";
};
postPatch = ''
echo "${version}" > .tarball-version
'';
nativeBuildInputs = [
autoreconfHook
pkg-config
];
buildInputs = [
libosmocore
libosmo-netif
libosmoabis
];
enableParallelBuilding = true;
meta = {
description = "Osmocom Media Gateway (MGW). speaks RTP and E1 as well as MGCP";
mainProgram = "osmo-mgw";
homepage = "https://osmocom.org/projects/osmo-mgw";
license = lib.licenses.agpl3Plus;
maintainers = with lib.maintainers; [ janik ];
platforms = lib.platforms.linux;
};
}