clamav-1.0.0.

This commit is contained in:
4fury-c3440d8
2022-12-29 01:44:39 +03:00
parent 56eb91c18e
commit 57a40e0a8d
7 changed files with 99 additions and 44 deletions
+4 -4
View File
@@ -4,7 +4,7 @@
# Licensed under the GNU General Public License, version 3.
# See the file https://www.gnu.org/licenses/gpl-3.0.txt
from pisi.actionsapi import shelltools, cmaketools, pisitools, get
from pisi.actionsapi import shelltools, mesontools, cmaketools, pisitools, get
j = ''.join([
' -DENABLE_EXAMPLES=ON',
@@ -20,14 +20,14 @@ def setup():
cmaketools.configure(j)
def build():
shelltools.system("ninja -C _build")
mesontools.build("-C _build")
def check():
#pass
shelltools.system("ninja -C _build test")
mesontools.build("-C _build test")
def install():
shelltools.system("DESTDIR=%s ninja -C _build install" % get.installDIR())
mesontools.install("-C _build install")
#pisitools.dodir("/run/clamav")
pisitools.dodir("/var/lib/clamav")
+24
View File
@@ -0,0 +1,24 @@
# -*- coding: utf-8 -*-
#!/usr/bin/env python
import os
from comar.service import *
serviceType = "server"
serviceDesc = _({"en": "Clam Anti-Virus Daemon",
"tr": "Clam Antivirüs Servisi"})
@synchronized
def start():
startService(command="/usr/sbin/clamd",
pidfile="/run/clamd.pid",
donotify=False)
time.sleep(4)
@synchronized
def stop():
stopService(command="/usr/sbin/clamd",
donotify=True)
def status():
return isServiceRunning("/run/clamd.pid")
+23
View File
@@ -0,0 +1,23 @@
# -*- coding: utf-8 -*-
#!/usr/bin/env python
import os
from comar.service import *
serviceType = "server"
serviceDesc = _({"en": "ClamAV database updater service"})
@synchronized
def start():
startService(command="/usr/bin/freshclam",
args="-d -p /run/freshclam.pid",
pidfile="/run/freshclam.pid",
donotify=True)
@synchronized
def stop():
stopService(command="/usr/bin/freshclam",
donotify=True)
def status():
return isServiceRunning("/run/freshclam.pid")
+1 -1
View File
@@ -1,4 +1,4 @@
#!/usr/bin/python
#!/usr/bin/env python
import os
-32
View File
@@ -1,32 +0,0 @@
# -*- coding: utf-8 -*-
import os
from comar.service import *
serviceType = "server"
serviceDesc = _({"en": "Clam Anti-Virus Daemon",
"tr": "Clam Antivirüs Servisi"})
@synchronized
def start():
startService(command="/usr/sbin/clamd",
#chuid="clamav",
pidfile="/run/clamd.pid",
donotify=False)
time.sleep(3)
startService(command="/usr/bin/freshclam",
args="-d -p /run/freshclam.pid",
#chuid="clamav",
pidfile="/run/freshclam.pid",
donotify=True)
@synchronized
def stop():
stopService(command="/usr/sbin/clamd",
donotify=True)
time.sleep(4)
stopService(command="/usr/bin/freshclam",
donotify=True)
def status():
return isServiceRunning("/run/clamd.pid") and isServiceRunning("/run/freshclam.pid")
+17 -3
View File
@@ -12,7 +12,7 @@ index 7ca0e6e..98af596 100644
##
diff --git a/etc/clamd.conf.sample b/etc/clamd.conf.sample
index 2f18866..8a2580b 100644
index 37fb03b..997f573 100644
--- a/etc/clamd.conf.sample
+++ b/etc/clamd.conf.sample
@@ -5,13 +5,13 @@
@@ -76,11 +76,20 @@ index 2f18866..8a2580b 100644
# TCP address.
# By default we bind to INADDR_ANY, probably not wise.
@@ -218,7 +218,7 @@ Example
# Run as another user (clamd must be started by root for this option to work)
# Default: don't drop privileges
-#User clamav
+User clamav
# Stop daemon when libclamav reports out of memory condition.
#ExitOnOOM yes
diff --git a/etc/freshclam.conf.sample b/etc/freshclam.conf.sample
index 26c4e7a..5f791e8 100644
index 26c4e7a..1447490 100644
--- a/etc/freshclam.conf.sample
+++ b/etc/freshclam.conf.sample
@@ -5,12 +5,12 @@
@@ -5,16 +5,16 @@
# Comment or remove the line below.
@@ -95,6 +104,11 @@ index 26c4e7a..5f791e8 100644
# Path to the log file (make sure it has proper permissions)
# Default: disabled
-#UpdateLogFile /var/log/freshclam.log
+UpdateLogFile /var/log/freshclam.log
# Maximum size of the log file.
# Value of 0 disables the limit.
@@ -51,7 +51,7 @@ Example
# It is recommended that the directory where this file is stored is
# also owned by root to keep other users from tampering with it.
+30 -4
View File
@@ -12,8 +12,8 @@
<IsA>app:console</IsA>
<Summary>Clam Antivirus software.</Summary>
<Description>Clam AntiVirus is a GPL anti-virus toolkit for UNIX.</Description>
<Archive sha1sum="e5fa557de1713faeb23a8b1f6788c27c7b7a340f" type="targz">
https://www.clamav.net/downloads/production/clamav-0.105.1.tar.gz
<Archive sha1sum="eb29723bce6cb9bd267e0a5cd245f88594a8893e" type="targz">
https://www.clamav.net/downloads/production/clamav-1.0.0.tar.gz
</Archive>
<BuildDependencies>
<Dependency>rust</Dependency>
@@ -50,9 +50,9 @@
<!-- <Dependency>libmilter</Dependency> -->
</RuntimeDependencies>
<Files>
<Path fileType="cfgfiles">/etc/clamav</Path>
<Path fileType="executable">/usr/bin</Path>
<Path fileType="executable">/usr/sbin</Path>
<Path fileType="cfgfiles">/etc/clamav</Path>
<Path fileType="library">/usr/lib</Path>
<Path fileType="data">/run/clamav</Path>
<Path fileType="data">/var/lib/clamav</Path>
@@ -65,7 +65,26 @@
</AdditionalFiles>
<Provides>
<COMAR script="package.py">System.Package</COMAR>
<COMAR script="service.py">System.Service</COMAR>
<COMAR script="clamd.py">System.Service</COMAR>
</Provides>
</Package>
<Package>
<Name>freshclam</Name>
<RuntimeDependencies>
<Dependency release="current">clamav</Dependency>
</RuntimeDependencies>
<Files>
<Path fileType="cfgfiles">/etc/clamav/freshclam.conf</Path>
<Path fileType="executable">/usr/bin/freshclam</Path>
<Path fileType="data">/usr/lib/libfreshclam.so</Path>
<Path fileType="data">/usr/lib/libfreshclam.so.2</Path>
<Path fileType="data">/usr/lib/libfreshclam.so.2.0.2</Path>
<Path fileType="man">/usr/share/man/man1/freshclam.1</Path>
<Path fileType="man">/usr/share/man/man5/freshclam.conf.5</Path>
</Files>
<Provides>
<COMAR script="freshclam.py">System.Service</COMAR>
</Provides>
</Package>
@@ -81,6 +100,13 @@
</Package>
<History>
<Update release="5">
<Date>2022-12-25</Date>
<Version>1.0.0</Version>
<Comment>Version bump.</Comment>
<Name>fury</Name>
<Email>uglyside@yandex.ru</Email>
</Update>
<Update release="4">
<Date>2022-11-15</Date>
<Version>0.105.1</Version>