1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-15 03:14:23 +00:00
freebsd-ports/security/clamav-devel/pkg-install
Yen-Ming Lee 07db5231ff Enable pthread support using devel/pth.
Turn on building clamd and clamdscan.

PR:		53056
Pointed out by:	Olivier Tharan <olive@oban.frmug.org>
Submitted by:	TERAMOTO Masahiro <markun@onohara.to>
2003-06-08 16:16:49 +00:00

31 lines
671 B
Bash

#!/bin/sh
if [ "$2" != "PRE-INSTALL" ]; then
exit 0
fi
USER?=clamav
GROUP?=clamav
if ! pw groupshow "$GROUP" 2>/dev/null 1>&2; then
if pw groupadd $GROUP; then
echo "=> Added group \"$GROUP\"."
else
echo "=> Adding group \"$GROUP\" failed..."
exit 1
fi
fi
if ! pw usershow "$USER" 2>/dev/null 1>&2; then
if pw useradd $USER -g $GROUP -h - \
-s "/sbin/nologin" -d "/nonexistent" \
-c "Clam Antivirus"; \
then
echo "=> Added user \"$USER\"."
else
echo "=> Adding user \"$USER\" failed..."
exit 1
fi
fi
exit 0