Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib, stdenv, fetchFromGitHub, substituteAll, pkg-config, cmake, bluez, libusb1, curl 2, libiconv, gettext, sqlite, bash, dialog 3, dbiSupport ? false, libdbi ? null, libdbiDrivers ? null 4, postgresSupport ? false, postgresql ? null 5}: 6 7stdenv.mkDerivation rec { 8 pname = "gammu"; 9 version = "1.42.0"; 10 11 src = fetchFromGitHub { 12 owner = "gammu"; 13 repo = "gammu"; 14 rev = version; 15 sha256 = "sha256-aeaGHVxOMiXRU6RHws+oAnzdO9RY1jw/X/xuGfSt76I="; 16 }; 17 18 patches = [ 19 ./bashcomp-dir.patch 20 ./systemd.patch 21 (substituteAll { 22 src = ./gammu-config-dialog.patch; 23 dialog = "${dialog}/bin/dialog"; 24 }) 25 ]; 26 27 nativeBuildInputs = [ pkg-config cmake ]; 28 29 strictDeps = true; 30 31 buildInputs = [ bash bluez libusb1 curl gettext sqlite libiconv ] 32 ++ lib.optionals dbiSupport [ libdbi libdbiDrivers ] 33 ++ lib.optionals postgresSupport [ postgresql ]; 34 35 meta = with lib; { 36 homepage = "https://wammu.eu/gammu/"; 37 description = "Command line utility and library to control mobile phones"; 38 license = licenses.gpl2; 39 platforms = platforms.linux; 40 maintainers = [ maintainers.coroa ]; 41 }; 42}