aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--GIDs1
-rw-r--r--UIDs1
-rw-r--r--net/repeater/Makefile30
-rw-r--r--net/repeater/files/pkg-install.in24
-rw-r--r--net/repeater/files/pkg-message.in14
-rw-r--r--net/repeater/pkg-plist2
6 files changed, 25 insertions, 47 deletions
diff --git a/GIDs b/GIDs
index 9ad1fb41be79..4b752e4efe0b 100644
--- a/GIDs
+++ b/GIDs
@@ -286,5 +286,6 @@ unifi:*:975:
minetest:*:976:
ums:*:979:
hbase:*:980:
+uvncrep:*:981:
nogroup:*:65533:
nobody:*:65534:
diff --git a/UIDs b/UIDs
index 54673650b0d0..4abe71ccfd7e 100644
--- a/UIDs
+++ b/UIDs
@@ -292,4 +292,5 @@ tests:*:977:65534::0:0:Unprivileged user for tests:/nonexistent:/usr/sbin/nologi
_dnscrypt-proxy:*:978:65534::0:0:dnscrypt-proxy user:/var/empty:/usr/sbin/nologin
ums:*:979:979::0:0:Universal Media Server:/nonexistent:/usr/sbin/nologin
hbase:*:980:980::0:0:HBase user:/nonexistent:/usr/sbin/nologin
+uvncrep:*:981:981::0:0:UltraVNC Repeater daemon:/nonexistent:/usr/sbin/nologin
nobody:*:65534:65534::0:0:Unprivileged user:/nonexistent:/usr/sbin/nologin
diff --git a/net/repeater/Makefile b/net/repeater/Makefile
index 9c6c87b4ec35..d36696ca365d 100644
--- a/net/repeater/Makefile
+++ b/net/repeater/Makefile
@@ -11,30 +11,28 @@ MAINTAINER= ports@FreeBSD.org
COMMENT= UltraVNC repeater
USES= zip
-USE_RC_SUBR= repeater
+USE_RC_SUBR= ${PORTNAME}
WRKSRC= ${WRKDIR}/Ver${PORTVERSION:C/\.//}
-ALL_TARGET= repeater
+ALL_TARGET= ${PORTNAME}
REP_USER?= uvncrep
REP_GROUP?= uvncrep
+USERS= ${REP_USER}
+GROUPS= ${REP_GROUP}
-SUB_FILES= pkg-install pkg-message
-SUB_LIST= REP_USER=${REP_USER} REP_GROUP=${REP_GROUP}
+SUB_FILES= pkg-message
-PLIST_FILES= sbin/repeater etc/uvncrepeater.ini.sample
PORTDOCS= changelog.txt readme.txt ultravncrepeaterlinuxport.html
-NO_STAGE= yes
+OPTIONS_DEFINE= DOCS
+
+post-patch:
+ @${REINPLACE_CMD} -e 's|g++|${CXX}|' ${WRKSRC}/Makefile
+
do-install:
- ${INSTALL_PROGRAM} ${WRKSRC}/repeater ${PREFIX}/sbin/repeater
- ${INSTALL_DATA} ${WRKSRC}/uvncrepeater.ini ${PREFIX}/etc/uvncrepeater.ini.sample
-.if !defined(NOPORTDOCS)
- @${MKDIR} ${DOCSDIR}
- cd ${WRKSRC} && ${INSTALL_DATA} ${PORTDOCS} ${DOCSDIR}
-.endif
-
-post-install:
- @${SETENV} @PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
- @${CAT} ${PKGMESSAGE}
+ ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${STAGEDIR}${PREFIX}/sbin
+ ${INSTALL_DATA} ${WRKSRC}/uvncrepeater.ini ${STAGEDIR}${PREFIX}/etc/uvncrepeater.ini.sample
+ @${MKDIR} ${STAGEDIR}${DOCSDIR}
+ (cd ${WRKSRC} && ${INSTALL_DATA} ${PORTDOCS} ${STAGEDIR}${DOCSDIR})
.include <bsd.port.mk>
diff --git a/net/repeater/files/pkg-install.in b/net/repeater/files/pkg-install.in
deleted file mode 100644
index bc5252d00cdc..000000000000
--- a/net/repeater/files/pkg-install.in
+++ /dev/null
@@ -1,24 +0,0 @@
-#!/bin/sh
-# $FreeBSD$
-#
-
-PW="/usr/sbin/pw"
-CHOWN="/usr/sbin/chown"
-CHMOD="/bin/chmod"
-MKDIR="/bin/mkdir -p"
-NOLOGIN="/usr/sbin/nologin"
-
-REP_USER=%%REP_USER%%
-REP_GROUP=%%REP_GROUP%%
-
-case "$2" in
-
-POST-INSTALL)
- ${PW} groupshow -n ${REP_GROUP} >/dev/null 2>&1 \
- || ${PW} groupadd -n ${REP_GROUP}
- ${PW} usershow -n ${REP_USER} >/dev/null 2>&1 \
- || ${PW} useradd ${REP_USER} -g ${REP_GROUP} -s ${NOLOGIN}
- ;;
-
-esac
-exit 0
diff --git a/net/repeater/files/pkg-message.in b/net/repeater/files/pkg-message.in
index 8501c7945548..14932827c331 100644
--- a/net/repeater/files/pkg-message.in
+++ b/net/repeater/files/pkg-message.in
@@ -1,7 +1,7 @@
-############################################################################
-# Please create a config file in %%PREFIX%%/etc #
-# A sample configuration file is installed as uvncrepeater.ini.sample #
-# #
-# To enable UVNC Repeater, put the following to your /etc/rc.conf: #
-# repeater_enable="YES" #
-############################################################################
+
+Please edit %%PREFIX%%/etc/uvncrepeater.ini before using UltraVNC
+Repeater!
+
+To enable UVNC Repeater, put the following in your /etc/rc.conf:
+ repeater_enable="YES"
+
diff --git a/net/repeater/pkg-plist b/net/repeater/pkg-plist
new file mode 100644
index 000000000000..7aff543d906f
--- /dev/null
+++ b/net/repeater/pkg-plist
@@ -0,0 +1,2 @@
+@sample etc/uvncrepeater.ini.sample
+sbin/repeater