diff --git a/print/cups-filters/Makefile b/print/cups-filters/Makefile index cb23340c8e43..47e84b25578a 100644 --- a/print/cups-filters/Makefile +++ b/print/cups-filters/Makefile @@ -2,6 +2,7 @@ PORTNAME= cups-filters PORTVERSION= 1.0.53 +PORTREVISION= 1 CATEGORIES= print MASTER_SITES= http://www.openprinting.org/download/cups-filters/ @@ -24,6 +25,7 @@ USES= compiler:c++11-lib pathfix pkgconfig shebangfix tar:xz SHEBANG_FILES= filter/textonly USE_GNOME= glib20 USE_GHOSTSCRIPT= yes +USE_RC_SUBR= cups_browsed GNU_CONFIGURE= yes CUPS_SOCKET= /var/run/cups.sock CONFIGURE_ARGS= --with-cups-domainsocket=${CUPS_SOCKET} diff --git a/print/cups-filters/files/cups_browsed.in b/print/cups-filters/files/cups_browsed.in new file mode 100644 index 000000000000..98513cf6901f --- /dev/null +++ b/print/cups-filters/files/cups_browsed.in @@ -0,0 +1,29 @@ +#!/bin/sh + +# $FreeBSD$ +# +# PROVIDE: cups_browsed +# REQUIRE: LOGIN +# KEYWORD: shutdown +# +# Add the following to /etc/rc.conf[.local] to enable this service +# +# cups_browsed_enable (bool): Set to NO by default. +# Set it to YES to enable cups_browsed. +# + +. /etc/rc.subr + +name=cups_browsed +rcvar=cups_browsed_enable + +load_rc_config ${name} + + : ${cups_browsed_enable:=NO} + +command=/usr/sbin/daemon +pidfile=/var/run/cups-browsed.pid +command_args="-p ${pidfile} %%PREFIX%%/sbin/cups-browsed" +procname="%%PREFIX%%/sbin/cups-browsed" + +run_rc_command "$1"