Browse Source

print/cloudprint: Add port from official FreeBSD portstree

Bernhard Fröhlich 7 months ago
parent
commit
1fcef89742
Signed by: Bernhard Froehlich <decke@bluelife.at> GPG Key ID: 4DD88C3F9F3B8333

+ 34
- 0
print/cloudprint/Makefile View File

@@ -0,0 +1,34 @@
1
+# Created by: Bernhard Froehlich <decke@FreeBSD.org>
2
+# $FreeBSD: head/print/cloudprint/Makefile 472884 2018-06-20 17:05:41Z mat $
3
+
4
+PORTNAME=	cloudprint
5
+PORTVERSION=	0.14.0.20170128
6
+CATEGORIES=	print
7
+
8
+MAINTAINER=	decke@FreeBSD.org
9
+COMMENT=	Google Cloud Print proxy for local CUPS printers
10
+
11
+LICENSE=	GPLv3
12
+
13
+RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}pycups>=0:print/py-pycups@${PY_FLAVOR} \
14
+		${PYTHON_PKGNAMEPREFIX}configargparse>=0.9.3:devel/py-configargparse@${PY_FLAVOR} \
15
+		${PYTHON_PKGNAMEPREFIX}daemon>0:devel/py-daemon@${PY_FLAVOR} \
16
+		${PYTHON_PKGNAMEPREFIX}requests>=2.7.0:www/py-requests@${PY_FLAVOR}
17
+
18
+USE_GITHUB=	yes
19
+GH_ACCOUNT=	armooo
20
+GH_TAGNAME=	108b9f0
21
+
22
+NO_ARCH=	yes
23
+USES=		python
24
+USE_PYTHON=	autoplist concurrent distutils optsuffix
25
+USE_RC_SUBR=	${PORTNAME}
26
+
27
+USERS=		cups
28
+GROUPS=		cups
29
+
30
+SUB_LIST+=	PYTHON_CMD="${PYTHON_CMD}" \
31
+		CPUSER="${USERS}" \
32
+		CPGROUP="${GROUPS}"
33
+
34
+.include <bsd.port.mk>

+ 3
- 0
print/cloudprint/distinfo View File

@@ -0,0 +1,3 @@
1
+TIMESTAMP = 1497263520
2
+SHA256 (armooo-cloudprint-0.14.0.20170128-108b9f0_GH0.tar.gz) = a20351b9892ac950f014f07637033a1387971f82f3c81710949fedfa13e9b9d9
3
+SIZE (armooo-cloudprint-0.14.0.20170128-108b9f0_GH0.tar.gz) = 27507

+ 46
- 0
print/cloudprint/files/cloudprint.in View File

@@ -0,0 +1,46 @@
1
+#!/bin/sh
2
+
3
+# $FreeBSD: head/print/cloudprint/files/cloudprint.in 347727 2014-03-10 09:20:06Z decke $
4
+#
5
+# PROVIDE: cloudprint
6
+# REQUIRE: LOGIN cupsd
7
+# KEYWORD: shutdown
8
+#
9
+# Add the following line to /etc/rc.conf[.local] to enable cloudprint
10
+#
11
+# cloudprint_enable (bool):	Set to "NO" by default.
12
+#				Set it to "YES" to enable cloudprint.
13
+# cloudprint_user (str):	User account to run with.
14
+# cloudprint_group (str):	Group to run with.
15
+# cloudprint_flags (str):	Custom flags for cloudprint.
16
+
17
+. /etc/rc.subr
18
+
19
+: ${cloudprint_enable="NO"}
20
+: ${cloudprint_user="%%CPUSER%%"}
21
+: ${cloudprint_group="%%CPGROUP%%"}
22
+
23
+name=cloudprint
24
+rcvar=cloudprint_enable
25
+piddir="/var/run/${name}"
26
+pidfile="${piddir}/${name}.pid"
27
+confdir="%%PREFIX%%/etc/cloudprint"
28
+command="%%PREFIX%%/bin/cloudprint"
29
+command_args="-d -p ${pidfile} -a ${confdir}/cloudprintauth"
30
+command_interpreter="%%PYTHON_CMD%%"
31
+sig_stop="QUIT"
32
+start_precmd="${name}_prestart"
33
+
34
+cloudprint_prestart()
35
+{
36
+	if [ ! -d "${piddir}" ]; then
37
+		/usr/bin/install -d -o ${cloudprint_user} -g ${cloudprint_group} -m 0755 ${piddir}
38
+	fi
39
+	if [ ! -d "${confdir}" ]; then
40
+		/usr/bin/install -d -o ${cloudprint_user} -g ${cloudprint_group} -m 0755 ${confdir}
41
+	fi
42
+}
43
+
44
+load_rc_config $name
45
+
46
+run_rc_command "$1"

+ 4
- 0
print/cloudprint/pkg-descr View File

@@ -0,0 +1,4 @@
1
+Google cloud print proxy utility for sharing your local
2
+CUPS printers.
3
+
4
+WWW: https://github.com/armooo/cloudprint

Loading…
Cancel
Save