summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick McLean <chutzpah@gentoo.org>2014-06-27 23:10:43 +0000
committerPatrick McLean <chutzpah@gentoo.org>2014-06-27 23:10:43 +0000
commit45fb0c887fc30b9b2f2da3d0b24ca67d1cd8cc62 (patch)
tree1cd7400228513f07078540813cbdac6bf2f2da33 /app-admin/conserver
parentVersion bump. (diff)
downloadgentoo-2-45fb0c887fc30b9b2f2da3d0b24ca67d1cd8cc62.tar.gz
gentoo-2-45fb0c887fc30b9b2f2da3d0b24ca67d1cd8cc62.tar.bz2
gentoo-2-45fb0c887fc30b9b2f2da3d0b24ca67d1cd8cc62.zip
Revision bump, in the init script, make start handle the pidfile as well as stop
(Portage version: 2.2.10/cvs/Linux x86_64, signed Manifest commit with key 0xE3F69979BB4B8928DA78E3D17CBF44EF)
Diffstat (limited to 'app-admin/conserver')
-rw-r--r--app-admin/conserver/ChangeLog9
-rw-r--r--app-admin/conserver/conserver-8.1.18-r1.ebuild87
-rw-r--r--app-admin/conserver/files/conserver.initd-r138
3 files changed, 133 insertions, 1 deletions
diff --git a/app-admin/conserver/ChangeLog b/app-admin/conserver/ChangeLog
index 96b569e539ee..d1ebb52060b3 100644
--- a/app-admin/conserver/ChangeLog
+++ b/app-admin/conserver/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for app-admin/conserver
# Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-admin/conserver/ChangeLog,v 1.82 2014/05/30 13:05:18 swift Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-admin/conserver/ChangeLog,v 1.83 2014/06/27 23:10:42 chutzpah Exp $
+
+*conserver-8.1.18-r1 (27 Jun 2014)
+
+ 27 Jun 2014; Patrick McLean <chutzpah@gentoo.org>
+ +conserver-8.1.18-r1.ebuild, +files/conserver.initd-r1:
+ Revision bump, in the init script, make start handle the pidfile as well as
+ stop
30 May 2014; Sven Vermeulen <swift@gentoo.org> conserver-8.1.16-r1.ebuild,
conserver-8.1.16.ebuild, conserver-8.1.18.ebuild:
diff --git a/app-admin/conserver/conserver-8.1.18-r1.ebuild b/app-admin/conserver/conserver-8.1.18-r1.ebuild
new file mode 100644
index 000000000000..3e3076ccddc6
--- /dev/null
+++ b/app-admin/conserver/conserver-8.1.18-r1.ebuild
@@ -0,0 +1,87 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-admin/conserver/conserver-8.1.18-r1.ebuild,v 1.1 2014/06/27 23:10:42 chutzpah Exp $
+
+EAPI="4"
+
+inherit ssl-cert eutils pam autotools
+
+DESCRIPTION="Serial Console Manager"
+HOMEPAGE="http://www.conserver.com/"
+SRC_URI="http://www.conserver.com/${P}.tar.gz"
+
+LICENSE="BSD GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~ia64 ~ppc ~ppc64 ~sparc ~x86"
+IUSE="kerberos pam ssl tcpd debug"
+
+DEPEND="ssl? ( >=dev-libs/openssl-0.9.6g )
+ pam? ( virtual/pam )
+ tcpd? ( sys-apps/tcp-wrappers )
+ debug? ( dev-libs/dmalloc )
+ kerberos? (
+ virtual/krb5
+ net-libs/libgssglue
+ )"
+RDEPEND="${DEPEND}
+ pam? ( >=sys-auth/pambase-20080219.1 )"
+
+src_prepare() {
+ # Apply patch to prevent package from stripping binaries
+ epatch "${FILESDIR}"/${PN}-prestrip.patch
+
+ # Apply patch to use custom dmalloc macro
+ epatch "${FILESDIR}"/${P}-dmalloc.patch
+
+ AT_M4DIR="m4" eautoreconf
+}
+
+src_configure() {
+ econf \
+ $(use_with ssl openssl) \
+ $(use_with pam) \
+ $(use_with tcpd libwrap) \
+ $(use_with debug dmalloc) \
+ $(use_with kerberos gssapi) \
+ --with-logfile=/var/log/conserver.log \
+ --with-pidfile=/var/run/conserver.pid \
+ --with-cffile=conserver/conserver.cf \
+ --with-pwdfile=conserver/conserver.passwd \
+ --with-master=localhost \
+ --with-port=7782
+}
+
+src_install() {
+ emake DESTDIR="${D}" exampledir="/usr/share/doc/${PF}/examples" install
+
+ ## create data directory
+ dodir /var/consoles
+ fowners daemon:daemon /var/consoles
+ fperms 700 /var/consoles
+
+ ## add startup and sample config
+ newinitd "${FILESDIR}"/conserver.initd-r1 conserver
+ newconfd "${FILESDIR}"/conserver.confd conserver
+
+ dodir /etc/conserver
+ fperms 700 /etc/conserver
+ insinto /etc/conserver
+ newins "${S}"/conserver.cf/conserver.cf conserver.cf.sample
+ newins "${S}"/conserver.cf/conserver.passwd conserver.passwd.sample
+
+ ## add docs
+ dohtml conserver.html
+ dodoc CHANGES FAQ PROTOCOL README TODO
+ dodoc conserver/Sun-serial contrib/maketestcerts
+ newdoc conserver.cf/conserver.cf conserver.cf.sample
+
+ # Add pam config
+ newpamd "${FILESDIR}"/conserver.pam-pambase conserver
+}
+
+pkg_postinst() {
+ # Add certs if SSL use flag is enabled
+ if use ssl && [ ! -f "${ROOT}"/etc/ssl/conserver/conserver.key ]; then
+ install_cert /etc/ssl/conserver/conserver
+ fi
+}
diff --git a/app-admin/conserver/files/conserver.initd-r1 b/app-admin/conserver/files/conserver.initd-r1
new file mode 100644
index 000000000000..b8ade4457e79
--- /dev/null
+++ b/app-admin/conserver/files/conserver.initd-r1
@@ -0,0 +1,38 @@
+#!/sbin/runscript
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-admin/conserver/files/conserver.initd-r1,v 1.1 2014/06/27 23:10:43 chutzpah Exp $
+
+depend() {
+ need clock
+}
+
+checkconfig() {
+ if [ ! -e /etc/conserver/conserver.cf ] ; then
+ eerror "You need to create /etc/conserver/conserver.cf first."
+ eerror "A sample is placed there to be renamed and ajusted."
+ eerror "Read the man page or see /usr/share/doc/conserver-<version>/."
+ return 1
+ fi
+
+ if [ ! -e /etc/conserver/conserver.passwd ] ; then
+ eerror "You need to create /etc/conserver/conserver.passwd first."
+ eerror "A sample is placed there to be renamed and ajusted."
+ eerror "Read the man page or see /usr/share/doc/conserver-<version>/."
+ return 1
+ fi
+}
+
+start() {
+ checkconfig || return 1
+ ebegin "Starting conserver"
+ start-stop-daemon --start --quiet --pidfile /var/run/conserver.pid --exec \
+ /usr/sbin/conserver -- ${CONSERVER_OPTS} 1>/dev/null
+ eend $? "Failed to start conserver"
+}
+
+stop() {
+ ebegin "Stopping conserver"
+ start-stop-daemon --stop --quiet --pidfile /var/run/conserver.pid
+ eend $? "Failed to stop conserver"
+}