diff options
author | Brandon Low <lostlogic@gentoo.org> | 2003-12-28 18:53:01 +0000 |
---|---|---|
committer | Brandon Low <lostlogic@gentoo.org> | 2003-12-28 18:53:01 +0000 |
commit | dbf62938758f3a1028a87891f92c9c4f537b5ced (patch) | |
tree | 7b6907b6126dcbf3652981195113f584ea40211b /dev-db | |
parent | Initial import of Firebird Super Server Binary, including init script and stuff (diff) | |
download | historical-dbf62938758f3a1028a87891f92c9c4f537b5ced.tar.gz historical-dbf62938758f3a1028a87891f92c9c4f537b5ced.tar.bz2 historical-dbf62938758f3a1028a87891f92c9c4f537b5ced.zip |
Initial import of Firebird Super Server Binary, including init script and stuff
Diffstat (limited to 'dev-db')
-rw-r--r-- | dev-db/firebird-ss-bin/Manifest | 6 | ||||
-rw-r--r-- | dev-db/firebird-ss-bin/files/conf | 4 | ||||
-rw-r--r-- | dev-db/firebird-ss-bin/files/digest-firebird-ss-bin-1.0.3 | 1 | ||||
-rw-r--r-- | dev-db/firebird-ss-bin/files/ibmgr | 4 | ||||
-rw-r--r-- | dev-db/firebird-ss-bin/files/init | 38 | ||||
-rw-r--r-- | dev-db/firebird-ss-bin/firebird-ss-bin-1.0.3.ebuild | 63 |
6 files changed, 115 insertions, 1 deletions
diff --git a/dev-db/firebird-ss-bin/Manifest b/dev-db/firebird-ss-bin/Manifest index 1e5bf5aaaa40..c8e542b24c15 100644 --- a/dev-db/firebird-ss-bin/Manifest +++ b/dev-db/firebird-ss-bin/Manifest @@ -1,2 +1,6 @@ -MD5 b1340b50e9359aee8f8a683f91f2a623 firebird-ss-bin-1.0.3.ebuild 273 +MD5 ec9752f4ebca07dec4db360e71019db4 firebird-ss-bin-1.0.3.ebuild 1752 +MD5 acdb1fcb058791633da7c64c9a4ce3bb ChangeLog 438 +MD5 5a6deb8ea2fdcf9b01fd158f3218e64d files/conf 65 +MD5 a0882fed63a80c35d1ea7041abe107b0 files/init 932 +MD5 7caa57f80334dc876fd2665bab570a99 files/ibmgr 85 MD5 0e82fc890ca01b96ea601979b67e7193 files/digest-firebird-ss-bin-1.0.3 75 diff --git a/dev-db/firebird-ss-bin/files/conf b/dev-db/firebird-ss-bin/files/conf new file mode 100644 index 000000000000..52b4b6b82ed8 --- /dev/null +++ b/dev-db/firebird-ss-bin/files/conf @@ -0,0 +1,4 @@ +INTERBASE=/opt/interbase +ISC_USER=SYSDBA +ISC_PASSWORD=masterkey + diff --git a/dev-db/firebird-ss-bin/files/digest-firebird-ss-bin-1.0.3 b/dev-db/firebird-ss-bin/files/digest-firebird-ss-bin-1.0.3 new file mode 100644 index 000000000000..437552f41250 --- /dev/null +++ b/dev-db/firebird-ss-bin/files/digest-firebird-ss-bin-1.0.3 @@ -0,0 +1 @@ +MD5 284e164daeb3b155e5f628c4eae7097c FirebirdSS-1.0.3.972-0.tar.gz 2659575 diff --git a/dev-db/firebird-ss-bin/files/ibmgr b/dev-db/firebird-ss-bin/files/ibmgr new file mode 100644 index 000000000000..5225ad531d00 --- /dev/null +++ b/dev-db/firebird-ss-bin/files/ibmgr @@ -0,0 +1,4 @@ +#!/bin/sh +INTERBASE=/opt/interbase +export INTERBASE +exec $INTERBASE/bin/ibmgr.bin $@ diff --git a/dev-db/firebird-ss-bin/files/init b/dev-db/firebird-ss-bin/files/init new file mode 100644 index 000000000000..8dc86ce342d3 --- /dev/null +++ b/dev-db/firebird-ss-bin/files/init @@ -0,0 +1,38 @@ +#!/sbin/runscript +#This was heavily copied from the generic-init.d script which comes with the +#binary version of firebird-ss + +depend() { + need net +} + +check_config() { + [ -z $INTERBASE ] && return 0 + [ -z $ISC_USER ] && return 0 + [ -z $ISC_PASSWORD ] && return 0 + [ -x $INTERBASE/bin/ibmgr ] || return 0 +} + +# See how we were called. +start() { + check_config || return 1 + ebegin "Starting Firebird server" + (sudo -u firebird ${INTERBASE}/bin/ibmgr -start -forever -user ${ISC_USER} -password ${ISC_PASSWORD};echo 1>&2) 2>${TEMP}/ibresult + result="$(cat ${TEMP}/ibresult)" + rm -f ${TEMP}/ibresult + if [ "${result/success}" != "${result}" ]; then + eend 0 + else + eend 1 + fi +} +stop() { + check_config || return 1 + ebegin "Stopping Firebird server" + result="$(sudo -u firebird ${INTERBASE}/bin/ibmgr -shut -user ${ISC_USER} -password ${ISC_PASSWORD} 2>&1)" + if [ "${result/completed}" != "${result}" ]; then + eend 0 + else + eend 1 + fi +} diff --git a/dev-db/firebird-ss-bin/firebird-ss-bin-1.0.3.ebuild b/dev-db/firebird-ss-bin/firebird-ss-bin-1.0.3.ebuild new file mode 100644 index 000000000000..9d21ade36d9a --- /dev/null +++ b/dev-db/firebird-ss-bin/firebird-ss-bin-1.0.3.ebuild @@ -0,0 +1,63 @@ +# Copyright 1999-2003 Gentoo Technologies, Inc. +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-db/firebird-ss-bin/firebird-ss-bin-1.0.3.ebuild,v 1.1 2003/12/28 18:52:53 lostlogic Exp $ +DEPEND="virtual/glibc" +RDEPEND="${DEPEND}" + +LICENSE="MPL-1.1" + +SLOT="0" + +KEYWORDS="~x86" + +HOMEPAGE="http://www.firebirdsql.com" + +MY_PN="FirebirdSS" +MY_PV="${PV}.972-0" +MY_P="${MY_PN}-${MY_PV}" + +SRC_URI="mirror://sourceforge/firebird/${MY_P}.tar.gz" +DESCRIPTION="Firebird SQL Super Server Binary" + +S=${WORKDIR}/${MY_P} + +src_install() { + cd ${D} + tar -zxvf ${S}/buildroot.tar.gz + chown -R firebird:firebird ${D}/opt/interbase + chmod ug+x ${D}/opt/interbase/bin/* + insinto /etc/conf.d + newins ${FILESDIR}/conf firebird + exeinto /etc/init.d + newexe ${FILESDIR}/init firebird + exeinto /opt/interbase/bin + newexe ${FILESDIR}/ibmgr ibmgr +} + +pkg_preinst() { + /etc/init.d/firebird stop 2> /dev/null + userdel firebird 2> /dev/null + if ! groupmod firebird; then + groupadd firebird 2> /dev/null || die "Failed to create group" + fi + useradd -g firebird -s /dev/null -d /var/empty -c "firebird" firebird || \ + die "Failed to create firebird user" +} + +pkg_postinst() { + if ! grep 'localhost[[:space:]]*$' /etc/hosts.equiv > /dev/null; then + echo localhost >> /etc/hosts.equiv + fi + if ! grep localhost.localdomain /etc/hosts.equiv > /dev/null; then + echo localhost.localdomain >> /etc/hosts.equiv + fi + if ! grep gds_db /etc/services > /dev/null; then + echo -e "#\n#Service added for gds_db (firebird)\n#" >> /etc/services + echo "gds_db 3050/tcp" >> /etc/services + + einfo "added gds_db to /etc/services" + fi + /etc/init.d/firebird start + chown firebird:firebird /opt/interbase + chmod ug+x /opt/interbase/bin/* +} |