git: 48ed3ad2283f - main - security/clamav-lts: Update to 1.0.1

From: Yasuhiro Kimura <yasu_at_FreeBSD.org>
Date: Mon, 08 May 2023 06:34:07 UTC
The branch main has been updated by yasu:

URL: https://cgit.FreeBSD.org/ports/commit/?id=48ed3ad2283fbd880e5eaf9d5ca5af2c98ba4c8d

commit 48ed3ad2283fbd880e5eaf9d5ca5af2c98ba4c8d
Author:     Yasuhiro Kimura <yasu@FreeBSD.org>
AuthorDate: 2023-05-08 05:43:00 +0000
Commit:     Yasuhiro Kimura <yasu@FreeBSD.org>
CommitDate: 2023-05-08 06:29:51 +0000

    security/clamav-lts: Update to 1.0.1
    
    First version of new regular feature release 1.1 is released and
    security/clamav is updated to it. So update security/clamav-lts to the
    latest patch version of 1.0 LTS feature release now.
---
 security/clamav-lts/Makefile                       | 199 +++++++++------------
 security/clamav-lts/distinfo                       |   6 +-
 security/clamav-lts/files/clamav-clamd.in          |   7 +-
 security/clamav-lts/files/clamav-freshclam.in      |  11 --
 ...shared_output.c => extra-patch-common_output.c} |   4 +-
 ...h-libclamav_c++_llvm_include_llvm_Support_CFG.h |  62 -------
 security/clamav-lts/files/pkg-deinstall.in         |  25 ---
 security/clamav-lts/files/pkg-message.in           |  13 ++
 security/clamav-lts/pkg-descr                      |   2 +-
 security/clamav-lts/pkg-plist                      |  64 +++----
 10 files changed, 133 insertions(+), 260 deletions(-)

diff --git a/security/clamav-lts/Makefile b/security/clamav-lts/Makefile
index 66a3cc7e3e4c..82ad5a2e94ed 100644
--- a/security/clamav-lts/Makefile
+++ b/security/clamav-lts/Makefile
@@ -1,5 +1,5 @@
 PORTNAME=	clamav
-DISTVERSION=	0.103.8
+DISTVERSION=	1.0.1
 PORTEPOCH=	1
 CATEGORIES=	security
 MASTER_SITES=	https://www.clamav.net/downloads/production/
@@ -10,164 +10,127 @@ COMMENT=	Open-source (GPL) anti-virus engine (LTS Feature Release)
 WWW=		https://www.clamav.net/
 
 LICENSE=	GPLv2
-LICENSE_FILE=	${WRKSRC}/COPYING
+LICENSE_FILE=	${WRKSRC}/COPYING.txt
 
+BUILD_DEPENDS=	${RUST_DEFAULT}>=1.56.0:lang/${RUST_DEFAULT}
 LIB_DEPENDS=	libcurl.so:ftp/curl \
-		libltdl.so:devel/libltdl \
-		libmspack.so:archivers/libmspack
+		libjson-c.so:devel/json-c \
+		libmspack.so:archivers/libmspack \
+		libpcre2-8.so:devel/pcre2
 
-USES=		cpe gmake gnome libtool ncurses pathfix pkgconfig ssl
+USES=		cmake cpe gnome iconv ncurses pkgconfig ssl
+USE_GNOME=	libxml2
 USE_LDCONFIG=	yes
 USE_RC_SUBR=	clamav-clamd clamav-freshclam
 
-GNU_CONFIGURE=	yes
-CONFIGURE_ARGS=	--disable-dependency-tracking \
-		--enable-bigstack \
-		--enable-clamdtop \
-		--libdir=${PREFIX}/lib \
-		--with-dbdir=${DBDIR} \
-		--with-libcurl=${LOCALBASE} \
-		--with-openssl=${OPENSSLBASE} \
-		--with-system-libmspack=${LOCALBASE}/lib/libmspack.so
-
-INSTALL_TARGET=	install-strip
-CFLAGS_i386=	-march=i486
-# This port has a problem with -pthread,
-# force to use -lthr until it's not fixed.
-LDFLAGS+=	-lthr
-
-CONFLICTS_INSTALL=	clamav
-
-SUB_FILES=	pkg-deinstall
-SUB_LIST+=	CHMOD=${CHMOD} \
-		CHOWN=${CHOWN} \
-		CLAMAV_CLAMD_PIDFILE=${CLAMAV_CLAMD_PIDFILE} \
-		CLAMAV_CLAMD_SOCKET=${CLAMAV_CLAMD_SOCKET} \
-		CLAMAV_MILTER_SOCKET=${CLAMAV_MILTER_SOCKET} \
-		CLAMAVGROUP=${CLAMAVGROUP} \
-		CLAMAVUSER=${CLAMAVUSER} \
-		DBDIR=${DBDIR} \
-		LOGDIR=${LOGDIR} \
-		RUNDIR=${RUNDIR}
-
-CLAMAVUSER?=	clamav
-CLAMAVGROUP?=	clamav
-
-.if ${CLAMAVUSER} == "clamav"
-USERS=		clamav
-.endif
+CMAKE_ARGS=	-DDATABASE_DIRECTORY:STRING=${_DBDIR}
+CMAKE_ON=	ENABLE_EXTERNAL_MSPACK
 
-.if ${CLAMAVGROUP} == "clamav"
-GROUPS=		clamav mail
-.endif
+TEST_TARGET=	check
 
-PLIST_SUB+=	CLAMAVGROUP=${CLAMAVGROUP} \
-		CLAMAVUSER=${CLAMAVUSER} \
-		DBDIR=${DBDIR} \
-		LOGDIR=${LOGDIR} \
-		RUNDIR=${RUNDIR}
+CONFLICTS_INSTALL=	clamav-lts
 
-OPTIONS_DEFINE=	ARC ARJ DMG_XAR DOCS EXPERIMENTAL ICONV IPV6 JSON LDAP LHA \
-		MILTER PCRE STDERR TESTS UNRAR UNZOO
-
-OPTIONS_DEFAULT=	ARC ARJ DMG_XAR JSON MILTER PCRE UNRAR UNZOO
+SUB_FILES=	pkg-message
+SUB_LIST+=	CHMOD=${CHMOD} \
+		CHOWN=${CHOWN} \
+		CLAMAV_CLAMD_PIDFILE=${_CLAMAV_CLAMD_PIDFILE} \
+		CLAMAV_CLAMD_SOCKET=${_CLAMAV_CLAMD_SOCKET} \
+		CLAMAV_MILTER_SOCKET=${_CLAMAV_MILTER_SOCKET} \
+		CLAMAVGROUP=${_CLAMAVGROUP} \
+		CLAMAVUSER=${_CLAMAVUSER} \
+		DBDIR=${_DBDIR} \
+		LOGDIR=${_LOGDIR} \
+		RUNDIR=${_RUNDIR}
+
+USERS=		${_CLAMAVUSER}
+GROUPS=		${_CLAMAVGROUP} mail
+
+PLIST_SUB+=	CLAMAVGROUP=${_CLAMAVGROUP} \
+		CLAMAVUSER=${_CLAMAVUSER} \
+		DBDIR=${_DBDIR} \
+		LOGDIR=${_LOGDIR} \
+		RUNDIR=${_RUNDIR}
+
+OPTIONS_DEFINE=	ARC ARJ DOCS EXPERIMENTAL LHA MILTER STDERR TESTS UNRAR UNZOO
+
+OPTIONS_DEFAULT=	ARC ARJ MILTER UNRAR UNZOO
 OPTIONS_SUB=		yes
 
 ARC_DESC=		Enable arch archives support
 ARJ_DESC=		Enable arj archives support
-DMG_XAR_DESC=		Enable DMG and XAR archives support
 EXPERIMENTAL_DESC=	Build experimental code
 LHA_DESC=		Enable lha archives support
 MILTER_DESC=		Compile the milter interface
 STDERR_DESC=		Print logs to stderr instead of stdout
-TESTS_DESC=		Run compile-time tests (req. python)
+TESTS_DESC=		Build with test enabled (`make test` requires it)
 UNZOO_DESC=		Enable zoo archives support
 
 ARC_RUN_DEPENDS=		arc:archivers/arc
 ARJ_RUN_DEPENDS=		arj:archivers/arj
-DMG_XAR_USE=			GNOME=libxml2
-DMG_XAR_CONFIGURE_WITH=		xml=${LOCALBASE}
-EXPERIMENTAL_CONFIGURE_ENABLE=	experimental
-ICONV_USES=			iconv
-ICONV_CONFIGURE_WITH=		iconv
-IPV6_CONFIGURE_ENABLE=		ipv6
-JSON_LIB_DEPENDS=		libjson-c.so:devel/json-c
-JSON_CONFIGURE_WITH=		libjson=${LOCALBASE}
-LDAP_USES=			ldap
-LDAP_LDFLAGS=			-lldap -L${LOCALBASE}/lib
+EXPERIMENTAL_CMAKE_BOOL=	ENABLE_EXPERIMENTAL
 LHA_RUN_DEPENDS=		lha:archivers/lha
 .if !exists(/usr/lib/libmilter.so)
-MILTER_LIB_DEPENDS+=		libmilter.so:mail/libmilter
+MILTER_LIB_DEPENDS=		libmilter.so:mail/libmilter
 .endif
 MILTER_USE=			RC_SUBR=clamav-milter
-MILTER_CONFIGURE_ENABLE=	milter
-MILTER_CONFIGURE_WITH=		sendmail=/usr/sbin/sendmail
 .if !exists(/usr/lib/libmilter.so)
-MILTER_CFLAGS=			-I${LOCALBASE}/include
-MILTER_LDFLAGS=			-L${LOCALBASE}/lib
+MILTER_USE+=			localbase
 .endif
-PCRE_LIB_DEPENDS=		libpcre2-8.so:devel/pcre2
-PCRE_CONFIGURE_WITH=		pcre
-STDERR_EXTRA_PATCHES=		${FILESDIR}/extra-patch-shared_output.c
+MILTER_CMAKE_BOOL=		ENABLE_MILTER
+STDERR_EXTRA_PATCHES=		${FILESDIR}/extra-patch-common_output.c
 TESTS_BUILD_DEPENDS=		${LOCALBASE}/include/check.h:devel/check
 TESTS_USES=			python:build
-TESTS_CONFIGURE_ENABLE=		check
-UNRAR_CONFIGURE_ENABLE=		unrar
+TESTS_CMAKE_BOOL=		ENABLE_TESTS
+UNRAR_CMAKE_BOOL=		ENABLE_UNRAR
 UNZOO_RUN_DEPENDS=		unzoo:archivers/unzoo
 
-CLAMAV_CLAMD_SOCKET?=	${RUNDIR}/clamd.sock
-CLAMAV_CLAMD_PIDFILE?=	${RUNDIR}/clamd.pid
-CLAMAV_MILTER_SOCKET?=	${RUNDIR}/clmilter.sock
+_CLAMAVUSER?=	clamav
+_CLAMAVGROUP?=	clamav
 
-DBDIR=		/var/db/clamav
-LOGDIR=		/var/log/clamav
-RUNDIR=		/var/run/clamav
-PY_NO_THREAD=	${WRKDIR}/.python-has-no-threads
+_CLAMAV_CLAMD_SOCKET?=	${_RUNDIR}/clamd.sock
+_CLAMAV_CLAMD_PIDFILE?=	${_RUNDIR}/clamd.pid
+_CLAMAV_MILTER_SOCKET?=	${_RUNDIR}/clmilter.sock
 
-SED_CONF=	-E -e 's|^\#?(Example)$$|\#\1|' -e \
-		's|^\#?((Update)?LogFile) .*/([a-z]+\.log)$$|\1 ${LOGDIR}/\3|' \
-		-e 's|^\#?(PidFile) .*/([a-z\-]+\.pid)$$|\1 ${RUNDIR}/\2|' -e \
-		's|^\#?(LocalSocket) .*$$|\1 ${CLAMAV_CLAMD_SOCKET}|' -e \
-		's|^\#?(User) .*$$|\1 ${CLAMAVUSER}|' -e \
+_DBDIR=		/var/db/clamav
+_LOGDIR=	/var/log/clamav
+_RUNDIR=	/var/run/clamav
+
+_SED_CONF=	-E -e 's|^\#?(Example)$$|\#\1|' -e \
+		's|^\#?((Update)?LogFile) .*/([a-z]+\.log)$$|\1 ${_LOGDIR}/\3|' \
+		-e 's|^\#?(PidFile) .*/([a-z\-]+\.pid)$$|\1 ${_RUNDIR}/\2|' -e \
+		's|^\#?(LocalSocket) .*$$|\1 ${_CLAMAV_CLAMD_SOCKET}|' -e \
+		's|^\#?(User) .*$$|\1 ${_CLAMAVUSER}|' -e \
 		's|^\#?(AllowSupplementaryGroups).*$$|\1 yes|' -e \
 		's|^\#?(ScanMail).*$$|\1 yes|' -e \
-		's|^\#?(DatabaseDirectory) .*$$|\1 ${DBDIR}|' -e \
-		's|^\#?(DatabaseOwner) .*$$|\1 ${CLAMAVUSER}|' -e \
+		's|^\#?(DatabaseDirectory) .*$$|\1 ${_DBDIR}|' -e \
+		's|^\#?(DatabaseOwner) .*$$|\1 ${_CLAMAVUSER}|' -e \
 		's|^\#?(FixStaleSocket).*$$|\1 yes|' -e \
 		's|^\#?(NotifyClamd) .*$$|\1 ${PREFIX}/etc/clamd.conf|' -e \
-		's|^\#?(MilterSocket) */tmp.*$$|\1 ${CLAMAV_MILTER_SOCKET}|' -e \
-		's|^\#?(ClamdSocket).*$$|\1 unix:${CLAMAV_CLAMD_SOCKET}|'
-
-.include <bsd.port.pre.mk>
+		's|^\#?(MilterSocket) */tmp.*$$|\1 ${_CLAMAV_MILTER_SOCKET}|' \
+		-e 's|^\#?(ClamdSocket).*$$|\1 unix:${_CLAMAV_CLAMD_SOCKET}|'
 
 post-patch:
-	@${REINPLACE_CMD} ${SED_CONF} \
+	@${REINPLACE_CMD} ${_SED_CONF} \
 		${WRKSRC}/etc/clamd.conf.sample \
 		${WRKSRC}/etc/freshclam.conf.sample \
 		${WRKSRC}/etc/clamav-milter.conf.sample
 
-pre-configure-TESTS-on:
-	@if ! ${PYTHON_CMD} -c "import thread" >/dev/null 2>&1; then \
-		${ECHO_MSG} ""; \
-		${ECHO_MSG} "==========================================================================="; \
-		${ECHO_MSG} "= Unit tests REQUIRES python built with thread support, and yours is not. ="; \
-		${ECHO_MSG} "= It will not be called during this build                                 ="; \
-		${ECHO_MSG} "==========================================================================="; \
-		${ECHO_MSG} ""; \
-		${TOUCH} ${PY_NO_THREAD}; \
-	fi
-
-post-build-TESTS-on:
-	@if [ ! -f "${PY_NO_THREAD}" ]; then \
-		${MAKE_CMD} -C ${WRKSRC} check; \
-	fi
-
 post-install:
-	${INSTALL_DATA} ${WRKSRC}/clamav-config.h ${STAGEDIR}${PREFIX}/include
-	@${MKDIR} ${STAGEDIR}${DOCSDIR}/html \
-		  ${STAGEDIR}${DBDIR} \
-		  ${STAGEDIR}${LOGDIR} \
-		  ${STAGEDIR}${RUNDIR}
-	(cd ${WRKSRC}/docs/html; ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR}/html)
-
-.include <bsd.port.post.mk>
+	${INSTALL_DATA} ${INSTALL_WRKSRC}/clamav-config.h ${STAGEDIR}${PREFIX}/include
+	@${MKDIR} ${STAGEDIR}${_DBDIR} \
+		  ${STAGEDIR}${_LOGDIR} \
+		  ${STAGEDIR}${_RUNDIR}
+
+post-install-DOCS-on:
+	${MV} ${STAGEDIR}${PREFIX}/share/doc/ClamAV ${STAGEDIR}${DOCSDIR}
+
+post-install-DOCS-off:
+	${RM} -r ${STAGEDIR}${PREFIX}/share/doc/ClamAV
+
+pre-test-TESTS-off:
+	@${ECHO_MSG} '******************************************************************' && \
+	${ECHO_MSG} '***** You need to enable TESTS option to execute `make test` *****' && \
+	${ECHO_MSG} '******************************************************************' && \
+	${FALSE}
+
+.include <bsd.port.mk>
diff --git a/security/clamav-lts/distinfo b/security/clamav-lts/distinfo
index 885f11841259..a0eddf5baa41 100644
--- a/security/clamav-lts/distinfo
+++ b/security/clamav-lts/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1676509752
-SHA256 (clamav-0.103.8.tar.gz) = 6f49da6ee927936de13d359e559d3944248e3a257d40b80b6c99ebe6fe8c8c3f
-SIZE (clamav-0.103.8.tar.gz) = 16524716
+TIMESTAMP = 1676505103
+SHA256 (clamav-1.0.1.tar.gz) = 0872dc1b82ff4cd7e8e4323faf5ee41a1f66ae80865d05429085b946355d86ee
+SIZE (clamav-1.0.1.tar.gz) = 31305590
diff --git a/security/clamav-lts/files/clamav-clamd.in b/security/clamav-lts/files/clamav-clamd.in
index b9c562f47987..c6de79538080 100644
--- a/security/clamav-lts/files/clamav-clamd.in
+++ b/security/clamav-lts/files/clamav-clamd.in
@@ -23,11 +23,10 @@ rcvar=clamav_clamd_enable
 load_rc_config "$name"
 
 : ${clamav_clamd_enable:=NO}
-: ${clamav_clamd_socket="%%CLAMAV_CLAMD_SOCKET%%"}
 : ${clamav_clamd_pidfile="%%CLAMAV_CLAMD_PIDFILE%%"}
-: ${clamav_clamd_user="%%CLAMAVUSER%%"}
 
 command=%%PREFIX%%/sbin/clamd
+pidfile=${clamav_clamd_pidfile}
 required_dirs=%%DBDIR%%
 required_files=%%PREFIX%%/etc/clamd.conf
 
@@ -38,10 +37,6 @@ reload_cmd="%%PREFIX%%/bin/clamdscan --reload"
 #clamav .93 won't start without a valid main.c[vl]d file
 clamav_clamd_precmd()
 {
-	local rundir=${clamav_clamd_pidfile%/*}
-	if [ ! -d $rundir ] ; then
-		install -d -m 0755 -o ${clamav_clamd_user} -g ${clamav_clamd_user} $rundir
-	fi
 	if [ ! -f %%DBDIR%%/main.cvd -a ! -f %%DBDIR%%/main.cld ];then
 		echo "Missing %%DBDIR%%/*.cvd or *.cld files.  You must run freshclam first"
 		exit 1
diff --git a/security/clamav-lts/files/clamav-freshclam.in b/security/clamav-lts/files/clamav-freshclam.in
index affd41e1c6a3..a32de395b2c8 100644
--- a/security/clamav-lts/files/clamav-freshclam.in
+++ b/security/clamav-lts/files/clamav-freshclam.in
@@ -24,7 +24,6 @@ load_rc_config ${name}
 
 : ${clamav_freshclam_enable:=NO}
 : ${clamav_freshclam_pidfile=%%RUNDIR%%/freshclam.pid}
-: ${clamav_freshclam_user=%%CLAMAVUSER%%}
 
 command=%%PREFIX%%/bin/freshclam
 pidfile=${clamav_freshclam_pidfile}
@@ -32,14 +31,4 @@ command_args="--daemon -p ${pidfile}"
 required_dirs=%%DBDIR%%
 required_files=%%PREFIX%%/etc/freshclam.conf
 
-start_precmd=clamav_freshclam_precmd
-
-clamav_freshclam_precmd()
-{
-	local rundir=${clamav_freshclam_pidfile%/*}
-	if [ ! -d $rundir ] ; then
-		install -d -m 0755 -o ${clamav_freshclam_user} -g ${clamav_freshclam_user} $rundir
-	fi
-}
-
 run_rc_command "$1"
diff --git a/security/clamav-lts/files/extra-patch-shared_output.c b/security/clamav-lts/files/extra-patch-common_output.c
similarity index 71%
rename from security/clamav-lts/files/extra-patch-shared_output.c
rename to security/clamav-lts/files/extra-patch-common_output.c
index ddb4ab029f38..c87b4daaff95 100644
--- a/security/clamav-lts/files/extra-patch-shared_output.c
+++ b/security/clamav-lts/files/extra-patch-common_output.c
@@ -1,5 +1,5 @@
---- shared/output.c.orig	Thu May 18 22:10:40 2006
-+++ shared/output.c	Thu May 18 22:12:43 2006
+--- common/output.c.orig	Thu May 18 22:10:40 2006
++++ common/output.c	Thu May 18 22:12:43 2006
 @@ -236,7 +236,13 @@
  	return;
      }
diff --git a/security/clamav-lts/files/patch-libclamav_c++_llvm_include_llvm_Support_CFG.h b/security/clamav-lts/files/patch-libclamav_c++_llvm_include_llvm_Support_CFG.h
deleted file mode 100644
index dd70c2ca4d20..000000000000
--- a/security/clamav-lts/files/patch-libclamav_c++_llvm_include_llvm_Support_CFG.h
+++ /dev/null
@@ -1,62 +0,0 @@
---- libclamav/c++/llvm/include/llvm/Support/CFG.h.orig	2016-04-22 15:02:19 UTC
-+++ libclamav/c++/llvm/include/llvm/Support/CFG.h
-@@ -27,8 +27,9 @@ namespace llvm {
- 
- template <class Ptr, class USE_iterator> // Predecessor Iterator
- class PredIterator : public std::iterator<std::forward_iterator_tag,
--                                          Ptr, ptrdiff_t> {
--  typedef std::iterator<std::forward_iterator_tag, Ptr, ptrdiff_t> super;
-+                                          Ptr, ptrdiff_t, Ptr*, Ptr*> {
-+  typedef std::iterator<std::forward_iterator_tag, Ptr, ptrdiff_t, Ptr*,
-+                                                                    Ptr*> super;
-   typedef PredIterator<Ptr, USE_iterator> Self;
-   USE_iterator It;
- 
-@@ -40,6 +41,7 @@ class PredIterator : public std::iterator<std::forward
- 
- public:
-   typedef typename super::pointer pointer;
-+  typedef typename super::reference reference;
- 
-   explicit inline PredIterator(Ptr *bb) : It(bb->use_begin()) {
-     advancePastNonTerminators();
-@@ -49,7 +51,7 @@ class PredIterator : public std::iterator<std::forward
-   inline bool operator==(const Self& x) const { return It == x.It; }
-   inline bool operator!=(const Self& x) const { return !operator==(x); }
- 
--  inline pointer operator*() const {
-+  inline reference operator*() const {
-     assert(!It.atEnd() && "pred_iterator out of range!");
-     return cast<TerminatorInst>(*It)->getParent();
-   }
-@@ -87,10 +89,11 @@ inline const_pred_iterator pred_end(const BasicBlock *
- 
- template <class Term_, class BB_>           // Successor Iterator
- class SuccIterator : public std::iterator<std::bidirectional_iterator_tag,
--                                          BB_, ptrdiff_t> {
-+                                          BB_, ptrdiff_t, BB_*, BB_*> {
-   const Term_ Term;
-   unsigned idx;
--  typedef std::iterator<std::bidirectional_iterator_tag, BB_, ptrdiff_t> super;
-+  typedef std::iterator<std::bidirectional_iterator_tag, BB_, ptrdiff_t, BB_*,
-+                                                                    BB_*> super;
-   typedef SuccIterator<Term_, BB_> Self;
- 
-   inline bool index_is_valid(int idx) {
-@@ -99,6 +102,7 @@ class SuccIterator : public std::iterator<std::bidirec
- 
- public:
-   typedef typename super::pointer pointer;
-+  typedef typename super::reference reference;
-   // TODO: This can be random access iterator, only operator[] missing.
- 
-   explicit inline SuccIterator(Term_ T) : Term(T), idx(0) {// begin iterator
-@@ -122,7 +126,7 @@ class SuccIterator : public std::iterator<std::bidirec
-   inline bool operator==(const Self& x) const { return idx == x.idx; }
-   inline bool operator!=(const Self& x) const { return !operator==(x); }
- 
--  inline pointer operator*() const { return Term->getSuccessor(idx); }
-+  inline reference operator*() const { return Term->getSuccessor(idx); }
-   inline pointer operator->() const { return operator*(); }
- 
-   inline Self& operator++() { ++idx; return *this; } // Preincrement
diff --git a/security/clamav-lts/files/pkg-deinstall.in b/security/clamav-lts/files/pkg-deinstall.in
deleted file mode 100644
index 47b5c7f8abf3..000000000000
--- a/security/clamav-lts/files/pkg-deinstall.in
+++ /dev/null
@@ -1,25 +0,0 @@
-#!/bin/sh
-
-if [ "$2" != "POST-DEINSTALL" ]; then
-	exit 0
-fi
-
-CLAMAVUSER=%%CLAMAVUSER%%
-
-echo
-echo "===================================================="
-echo
-echo "If you want remove clamav permanently from you system"
-echo "execute following commands:"
-echo
-echo " # rm -rf %%LOGDIR%%"
-echo " # rm -rf %%RUNDIR%%"
-echo " # rm -rf %%DBDIR%%"
-if pw usershow "${CLAMAVUSER}" 2>/dev/null 1>&2; then
-	echo " # pw userdel ${CLAMAVUSER}"
-fi
-echo
-echo "===================================================="
-echo
-
-exit 0
diff --git a/security/clamav-lts/files/pkg-message.in b/security/clamav-lts/files/pkg-message.in
new file mode 100644
index 000000000000..91cd8d4e1ada
--- /dev/null
+++ b/security/clamav-lts/files/pkg-message.in
@@ -0,0 +1,13 @@
+[
+{ type: remove
+  message: <<EOM
+If you want remove clamav permanently from you system
+execute following commands:
+
+ # rm -rf %%LOGDIR%%
+ # rm -rf %%RUNDIR%%
+ # rm -rf %%DBDIR%%
+ # pw userdel %%CLAMAVUSER%%
+EOM
+}
+]
diff --git a/security/clamav-lts/pkg-descr b/security/clamav-lts/pkg-descr
index cd67eb4713c9..2bf74d2ec371 100644
--- a/security/clamav-lts/pkg-descr
+++ b/security/clamav-lts/pkg-descr
@@ -4,4 +4,4 @@ security. It provides many utilities for users, including a flexible
 and scalable multi-threaded daemon, a command-line scanner and an
 advanced tool for automatic database updates.
 
-This is Long Term Support Feature Release of ClamAV.
+This is Regular (non-LTS) Feature Release of ClamAV.
diff --git a/security/clamav-lts/pkg-plist b/security/clamav-lts/pkg-plist
index be2e6006ee65..ca56d6a3f34d 100644
--- a/security/clamav-lts/pkg-plist
+++ b/security/clamav-lts/pkg-plist
@@ -4,9 +4,40 @@ bin/clamconf
 bin/clamdscan
 bin/clamdtop
 bin/clamscan
-%%JSON%%bin/clamsubmit
+bin/clamsubmit
 bin/freshclam
 bin/sigtool
+include/clamav-config.h
+include/clamav-types.h
+include/clamav-version.h
+include/clamav.h
+include/libfreshclam.h
+lib/libclamav.so
+lib/libclamav.so.11
+lib/libclamav.so.11.0.0
+%%UNRAR%%lib/libclamunrar.so
+%%UNRAR%%lib/libclamunrar.so.11
+%%UNRAR%%lib/libclamunrar.so.11.0.0
+%%UNRAR%%lib/libclamunrar_iface.so
+%%UNRAR%%lib/libclamunrar_iface.so.11
+%%UNRAR%%lib/libclamunrar_iface.so.11.0.0
+lib/libfreshclam.so
+lib/libfreshclam.so.2
+lib/libfreshclam.so.2.0.2
+libdata/pkgconfig/libclamav.pc
+share/man/man1/clambc.1.gz
+share/man/man1/clamconf.1.gz
+share/man/man1/clamdscan.1.gz
+share/man/man1/clamdtop.1.gz
+share/man/man1/clamscan.1.gz
+share/man/man1/clamsubmit.1.gz
+share/man/man1/freshclam.1.gz
+share/man/man1/sigtool.1.gz
+share/man/man5/clamav-milter.conf.5.gz
+share/man/man5/clamd.conf.5.gz
+share/man/man5/freshclam.conf.5.gz
+share/man/man8/clamav-milter.8.gz
+share/man/man8/clamd.8.gz
 %%PORTDOCS%%%%DOCSDIR%%/html/404.html
 %%PORTDOCS%%%%DOCSDIR%%/html/FontAwesome/css/font-awesome.css
 %%PORTDOCS%%%%DOCSDIR%%/html/FontAwesome/fonts/FontAwesome.ttf
@@ -131,37 +162,6 @@ bin/sigtool
 %%PORTDOCS%%%%DOCSDIR%%/html/theme-dawn.js
 %%PORTDOCS%%%%DOCSDIR%%/html/theme-tomorrow_night.js
 %%PORTDOCS%%%%DOCSDIR%%/html/tomorrow-night.css
-include/clamav-config.h
-include/clamav-types.h
-include/clamav-version.h
-include/clamav.h
-include/libfreshclam.h
-lib/libclamav.so
-lib/libclamav.so.9
-lib/libclamav.so.9.0.5
-%%UNRAR%%lib/libclamunrar.so
-%%UNRAR%%lib/libclamunrar.so.9
-%%UNRAR%%lib/libclamunrar.so.9.0.5
-%%UNRAR%%lib/libclamunrar_iface.so
-%%UNRAR%%lib/libclamunrar_iface.so.9
-%%UNRAR%%lib/libclamunrar_iface.so.9.0.5
-lib/libfreshclam.so
-lib/libfreshclam.so.2
-lib/libfreshclam.so.2.0.1
-libdata/pkgconfig/libclamav.pc
-man/man1/clambc.1.gz
-man/man1/clamconf.1.gz
-man/man1/clamdscan.1.gz
-man/man1/clamdtop.1.gz
-man/man1/clamscan.1.gz
-%%JSON%%man/man1/clamsubmit.1.gz
-man/man1/freshclam.1.gz
-man/man1/sigtool.1.gz
-man/man5/clamav-milter.conf.5.gz
-man/man5/clamd.conf.5.gz
-man/man5/freshclam.conf.5.gz
-man/man8/clamav-milter.8.gz
-man/man8/clamd.8.gz
 %%MILTER%%sbin/clamav-milter
 sbin/clamd
 @sample etc/clamd.conf.sample