18 stdenv.mkDerivation rec {
22 src = fetchFromGitHub {
26 sha256 = "1r885zv1gsh88j43x6fvzbdgfkh712a227d369h4fdcbnnfd0kpm";
32 # Pull upstream fix for -fno-common toolchains:
33 # https://github.com/lcdproc/lcdproc/pull/148
35 name = "fno-common.patch";
36 url = "https://github.com/lcdproc/lcdproc/commit/fda5302878692da933dc03cd011f8ddffefa07a4.patch";
37 sha256 = "0ld6p1r4rjsnjr63afw3lp5lx25jxjs07lsp9yc3q96r91r835cy";
41 # we don't need to see the GPL every time we launch lcdd in the foreground
43 substituteInPlace server/main.c \
44 --replace 'output_GPL_notice();' '// output_GPL_notice();'
48 "--enable-lcdproc-menus"
49 "--enable-drivers=all"
50 "--with-pidfile-dir=/run"
53 buildInputs = [ freetype libX11 libftdi libusb-compat-0_1 libusb1 ncurses ];
55 nativeBuildInputs = [ autoreconfHook doxygen makeWrapper pkg-config ];
57 # In 0.5.9: gcc: error: libbignum.a: No such file or directory
58 enableParallelBuilding = false;
61 for f in $out/bin/*.pl ; do
62 substituteInPlace $f \
63 --replace /usr/bin/perl ${lib.getBin perl}/bin/perl
66 # NixOS will not use this file anyway but at least we can now execute LCDd
67 substituteInPlace $out/etc/LCDd.conf \
68 --replace server/drivers/ $out/lib/lcdproc/
72 description = "Client/server suite for controlling a wide variety of LCD devices";
73 homepage = "https://lcdproc.org/";
74 license = licenses.gpl2Plus;
75 maintainers = with maintainers; [ peterhoeg ];
76 platforms = platforms.unix;
77 # never built on aarch64-darwin since first introduction in nixpkgs
78 broken = stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isAarch64;