Skip to content

Commit

Permalink
Updated clamav v1.2.3 → v1.4.1
Browse files Browse the repository at this point in the history
  • Loading branch information
Rishik-Y authored Dec 19, 2024
1 parent 205fd42 commit e548d18
Showing 1 changed file with 69 additions and 16 deletions.
85 changes: 69 additions & 16 deletions pkgs/tools/security/clamav/default.nix
Original file line number Diff line number Diff line change
@@ -1,43 +1,96 @@
{ lib, stdenv, fetchurl, pkg-config, cmake
, zlib, bzip2, libiconv, libxml2, openssl, ncurses, curl, libmilter, pcre2
, libmspack, systemd, Foundation, json_c, check
, rustc, rust-bindgen, rustfmt, cargo, python3
{
lib,
stdenv,
fetchurl,
pkg-config,
cmake,
zlib,
bzip2,
libiconv,
libxml2,
openssl,
ncurses,
curl,
libmilter,
pcre2,
libmspack,
systemd,
Foundation,
json_c,
check,
rustc,
rust-bindgen,
rustfmt,
cargo,
python3,
}:

stdenv.mkDerivation rec {
pname = "clamav";
version = "1.2.3";
version = "1.4.1";

src = fetchurl {
url = "https://www.clamav.net/downloads/production/${pname}-${version}.tar.gz";
hash = "sha256-nPcjBDn1JowskHe8hySVtv5SxlJ09VmkXQzZF9fNGWA=";
hash = "sha256-oxjngKw5prPWxGlxOC+W7d6Xzki442HrgOY0Fe1Batg=";
};

patches = [
# Flaky test, remove this when https://github.com/Cisco-Talos/clamav/issues/343 is fixed
./remove-freshclam-test.patch
./sample-cofiguration-file-install-location.patch
];

enableParallelBuilding = true;
nativeBuildInputs = [ cmake pkg-config rustc rust-bindgen rustfmt cargo python3 ];
buildInputs = [
zlib bzip2 libxml2 openssl ncurses curl libiconv libmilter pcre2 libmspack json_c check
] ++ lib.optional stdenv.isLinux systemd
++ lib.optional stdenv.isDarwin Foundation;
nativeBuildInputs = [
cmake
pkg-config
rustc
rust-bindgen
rustfmt
cargo
python3
];
buildInputs =
[
zlib
bzip2
libxml2







Expand Down



openssl
ncurses
curl
libiconv
libmilter
pcre2
libmspack
json_c
check
]
++ lib.optional stdenv.isLinux systemd
++ lib.optional stdenv.isDarwin Foundation;
cmakeFlags = [
"-DSYSTEMD_UNIT_DIR=${placeholder "out"}/lib/systemd"
"-DAPP_CONFIG_DIRECTORY=/etc/clamav"
];

doCheck = true;

meta = with lib; {
homepage = "https://www.clamav.net";
description = "Antivirus engine designed for detecting Trojans, viruses, malware and other malicious threats";
license = licenses.gpl2;
maintainers = with maintainers; [ robberer qknight globin ];
license = licenses.gpl2Only;
maintainers = with maintainers; [
robberer
qknight
globin
];
platforms = platforms.unix;
};
}

0 comments on commit e548d18

Please sign in to comment.