anchor.diff:      ++ optional (libmysql != null) "--with-mysql=${libmysql}"
       ++ optional (zlib != null) "--with-zlib=${zlib}"
       ++ optional (lzo != null) "--with-lzo=${lzo}"
  +    ++ optional (jansson != null) "--with-jansson=${jansson}"
       ++ optional (acl != null) "--enable-acl"
       ++ optional (glusterfs != null) "--with-glusterfs=${glusterfs}"
       ++ optional (libceph != null) "--with-cephfs=${libceph}";
   
     installFlags = [
       "sysconfdir=\${out}/etc"
  +    "confdir=\${out}/etc/bareos"
  +    "scriptdir=\${out}/etc/bareos"
       "working_dir=\${TMPDIR}"
       "log_dir=\${TMPDIR}"
       "sbindir=\${out}/bin"
  
positive.code: in
  stdenv.mkDerivation rec {
    name = "bareos-${version}";
    version = "14.2.4";
  
    src = fetchFromGitHub {
      owner = "bareos";
      repo = "bareos";
      rev = "Release/${version}";
      name = "${name}-src";
      sha256 = "0shb91pawdgrn6rb4np3zyyxv36899nvwf8jaihkg0wvb01viqzr";
    };
  
    buildInputs = [
      pkgconfig nettools gettext readline openssl python flex
      ncurses sqlite postgresql libmysql zlib lzo acl glusterfs libceph libcap
    ];
  
    postPatch = ''
  
negative.code: { stdenv, fetchFromGitHub, pkgconfig, nettools, gettext, libtool, flex
  , readline ? null, openssl ? null, python ? null, ncurses ? null
  , sqlite ? null, postgresql ? null, libmysql ? null, zlib ? null, lzo ? null
  , jansson ? null, acl ? null, glusterfs ? null, libceph ? null, libcap ? null
  }:
  
  assert sqlite != null || postgresql != null || libmysql != null;
  