jabberd; from Gerardo Santana Gomez Garrido
This commit is contained in:
parent
043b234ca3
commit
1c04224216
54
net/jabberd/Makefile
Normal file
54
net/jabberd/Makefile
Normal file
@ -0,0 +1,54 @@
|
||||
# $OpenBSD: Makefile,v 1.1.1.1 2004/05/29 13:12:30 jakob Exp $
|
||||
|
||||
COMMENT= "jabber server"
|
||||
DISTNAME= jabberd-2.0s2
|
||||
CATEGORIES= net
|
||||
HOMEPAGE= http://jabberd.jabberstudio.org/2/
|
||||
MAINTAINER= Gerardo Santana Gomez Garrido <santana@openbsd.org.mx>
|
||||
|
||||
# GPL
|
||||
PERMIT_PACKAGE_CDROM= Yes
|
||||
PERMIT_PACKAGE_FTP= Yes
|
||||
PERMIT_DISTFILES_CDROM= Yes
|
||||
PERMIT_DISTFILES_FTP= Yes
|
||||
|
||||
MASTER_SITES= http://www.jabberstudio.org/files/jabberd2/
|
||||
|
||||
JABBERDUSER= _jabberd
|
||||
JABBERDGROUP= _jabberd
|
||||
JABBERDDIR= /var/jabberd
|
||||
|
||||
CONFIG_DIR= ${SYSCONFDIR}/jabberd
|
||||
EXAMPLES= ${PREFIX}/share/examples/jabberd
|
||||
|
||||
SUBST_VARS= CONFIG_DIR EXAMPLES \
|
||||
JABBERDUSER JABBERDGROUP JABBERDDIR
|
||||
|
||||
BUILD_DEPENDS= ::databases/mysql,-server
|
||||
LIB_DEPENDS= lib/mysql/mysqlclient.10::databases/mysql
|
||||
|
||||
MODULES=iconv
|
||||
|
||||
CONFIGURE_STYLE= gnu
|
||||
CONFIGURE_ARGS= --localstatedir=${JABBERDDIR:H}
|
||||
|
||||
do-install:
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/tools/jabberd ${PREFIX}/sbin
|
||||
${INSTALL_PROGRAM_DIR} ${PREFIX}/libexec/jabberd
|
||||
.for dir in c2s resolver router s2s sm
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/${dir}/${dir} ${PREFIX}/libexec/jabberd
|
||||
.endfor
|
||||
${INSTALL_MAN} ${WRKSRC}/man/*.8 ${PREFIX}/man/man8
|
||||
${INSTALL_DATA_DIR} ${EXAMPLES}
|
||||
${INSTALL_DATA_DIR} ${EXAMPLES}/templates
|
||||
${INSTALL_DATA} ${WRKSRC}/etc/jabberd.cfg.dist ${EXAMPLES}/jabberd.cfg
|
||||
${INSTALL_DATA} ${WRKSRC}/etc/c2s.xml.dist ${EXAMPLES}/c2s.xml
|
||||
${INSTALL_DATA} ${WRKSRC}/etc/resolver.xml.dist ${EXAMPLES}/resolver.xml
|
||||
${INSTALL_DATA} ${WRKSRC}/etc/router-users.xml.dist ${EXAMPLES}/router-users.xml
|
||||
${INSTALL_DATA} ${WRKSRC}/etc/router.xml.dist ${EXAMPLES}/router.xml
|
||||
${INSTALL_DATA} ${WRKSRC}/etc/s2s.xml.dist ${EXAMPLES}/s2s.xml
|
||||
${INSTALL_DATA} ${WRKSRC}/etc/sm.xml.dist ${EXAMPLES}/sm.xml
|
||||
${INSTALL_DATA} ${WRKSRC}/etc/templates/roster.xml.dist ${EXAMPLES}/templates/roster.xml
|
||||
${INSTALL_DATA} ${WRKSRC}/tools/db-setup.mysql ${EXAMPLES}
|
||||
|
||||
.include <bsd.port.mk>
|
3
net/jabberd/distinfo
Normal file
3
net/jabberd/distinfo
Normal file
@ -0,0 +1,3 @@
|
||||
MD5 (jabberd-2.0s2.tar.gz) = 0f794b00e480a7b4c36d858d4d0095bf
|
||||
RMD160 (jabberd-2.0s2.tar.gz) = 0b3722e5ef6ff8745a0c47da19d9896908a3d1aa
|
||||
SHA1 (jabberd-2.0s2.tar.gz) = bec5f3ab50e383d4d3282fe472e27b049b41badd
|
32
net/jabberd/patches/patch-tools_jabberd_in
Normal file
32
net/jabberd/patches/patch-tools_jabberd_in
Normal file
@ -0,0 +1,32 @@
|
||||
$OpenBSD: patch-tools_jabberd_in,v 1.1.1.1 2004/05/29 13:12:30 jakob Exp $
|
||||
--- tools/jabberd.in.orig Fri Sep 5 17:17:36 2003
|
||||
+++ tools/jabberd.in Fri Sep 5 17:19:16 2003
|
||||
@@ -64,23 +64,23 @@ $SIG{CHLD} = "IGNORE";
|
||||
#-----------------------------------------------------------------------------
|
||||
$jobs{jabberd}->{prefix} = "JBRD";
|
||||
|
||||
-$jobs{router}->{cmd} = "$Bin/router";
|
||||
+$jobs{router}->{cmd} = "$Bin/../libexec/jabberd/router";
|
||||
$jobs{router}->{config} = "$config_dir/router.xml";
|
||||
$jobs{router}->{prefix} = "ROUT";
|
||||
|
||||
-$jobs{resolver}->{cmd} = "$Bin/resolver";
|
||||
+$jobs{resolver}->{cmd} = "$Bin/../libexec/jabberd/resolver";
|
||||
$jobs{resolver}->{config} = "$config_dir/resolver.xml";
|
||||
$jobs{resolver}->{prefix} = "RSLV";
|
||||
|
||||
-$jobs{sm}->{cmd} = "$Bin/sm";
|
||||
+$jobs{sm}->{cmd} = "$Bin/../libexec/jabberd/sm";
|
||||
$jobs{sm}->{config} = "$config_dir/sm.xml";
|
||||
$jobs{sm}->{prefix} = "SM";
|
||||
|
||||
-$jobs{c2s}->{cmd} = "$Bin/c2s";
|
||||
+$jobs{c2s}->{cmd} = "$Bin/../libexec/jabberd/c2s";
|
||||
$jobs{c2s}->{config} = "$config_dir/c2s.xml";
|
||||
$jobs{c2s}->{prefix} = "C2S";
|
||||
|
||||
-$jobs{s2s}->{cmd} = "$Bin/s2s";
|
||||
+$jobs{s2s}->{cmd} = "$Bin/../libexec/jabberd/s2s";
|
||||
$jobs{s2s}->{config} = "$config_dir/s2s.xml";
|
||||
$jobs{s2s}->{prefix} = "S2S";
|
||||
|
26
net/jabberd/pkg/DEINSTALL
Normal file
26
net/jabberd/pkg/DEINSTALL
Normal file
@ -0,0 +1,26 @@
|
||||
#!/bin/sh
|
||||
# $OpenBSD: DEINSTALL,v 1.1.1.1 2004/05/29 13:12:30 jakob Exp $
|
||||
#
|
||||
# jabberd de-installation
|
||||
|
||||
PATH=/bin:/usr/bin:/sbin:/usr/sbin
|
||||
PREFIX=${PKG_PREFIX:-/usr/local}
|
||||
|
||||
if [ "$PKG_DELETE_EXTRA" != Yes ]; then
|
||||
echo
|
||||
echo "+---------------"
|
||||
echo "| To completely deinstall the $1 package you need to perform"
|
||||
echo "| these steps as root:"
|
||||
echo "|"
|
||||
echo "| userdel ${JABBERDUSER}"
|
||||
echo "| groupdel ${JABBERDGROUP}"
|
||||
echo "| rm -rf ${CONFIG_DIR}"
|
||||
echo "| rm -rf ${JABBERDDIR}"
|
||||
echo "|"
|
||||
echo "| Do not do this if you plan on re-installing $1"
|
||||
echo "| at some future time."
|
||||
echo "+---------------"
|
||||
echo
|
||||
fi
|
||||
|
||||
exit 0
|
3
net/jabberd/pkg/DESCR
Normal file
3
net/jabberd/pkg/DESCR
Normal file
@ -0,0 +1,3 @@
|
||||
jabberd 2 is the next generation of the jabberd server. It has been
|
||||
rewritten from the ground up to be scalable, architecturally sound, and to
|
||||
support the latest protocol extensions coming out of the JSF.
|
99
net/jabberd/pkg/INSTALL
Normal file
99
net/jabberd/pkg/INSTALL
Normal file
@ -0,0 +1,99 @@
|
||||
#!/bin/sh
|
||||
# $OpenBSD: INSTALL,v 1.1.1.1 2004/05/29 13:12:30 jakob Exp $
|
||||
#
|
||||
# Pre/post-installation setup of jabberd
|
||||
|
||||
PATH=/bin:/usr/bin:/sbin:/usr/sbin
|
||||
PREFIX=${PKG_PREFIX:-/usr/local}
|
||||
UID=533
|
||||
GID=533
|
||||
|
||||
do_usergroup_install()
|
||||
{
|
||||
# Create jabberd user and group
|
||||
groupinfo -e ${JABBERDGROUP}
|
||||
if [ $? -eq 0 ]; then
|
||||
echo "===> Using ${JABBERDGROUP} group for jabberd"
|
||||
else
|
||||
echo "===> Creating ${JABBERDGROUP} group for jabberd"
|
||||
groupadd -g $GID ${JABBERDGROUP}
|
||||
fi
|
||||
userinfo -e ${JABBERDUSER}
|
||||
if [ $? -eq 0 ]; then
|
||||
echo "===> Using ${JABBERDUSER} user for jabberd"
|
||||
else
|
||||
echo "===> Creating ${JABBERDUSER} user for jabberd"
|
||||
useradd -g ${JABBERDGROUP} -d /nonexistent -L daemon -c 'jabberd account' -s /bin/sh -u $UID ${JABBERDUSER}
|
||||
fi
|
||||
}
|
||||
|
||||
do_jabberddir_install()
|
||||
{
|
||||
install -d -o ${JABBERDUSER} -g ${JABBERDGROUP} -m 771 ${JABBERDDIR}
|
||||
install -d -o ${JABBERDUSER} -g ${JABBERDGROUP} -m 775 ${JABBERDDIR}/pid
|
||||
install -d -o ${JABBERDUSER} -g ${JABBERDGROUP} -m 775 ${JABBERDDIR}/log
|
||||
}
|
||||
|
||||
do_notice_conf()
|
||||
{
|
||||
echo
|
||||
echo "+---------------"
|
||||
echo "| The existing $1 configuration files in ${CONFIG_DIR} have NOT"
|
||||
echo "| been changed. You may want to compare them to the current samples in"
|
||||
echo "| ${EXAMPLES}, and update your configuration"
|
||||
echo "| files as needed."
|
||||
}
|
||||
|
||||
do_install_conf()
|
||||
{
|
||||
install -d -o root -g wheel -m 750 ${CONFIG_DIR}
|
||||
install -o ${JABBERDUSER} -g ${JABBERDGROUP} -m 640 ${EXAMPLES}/jabberd.cfg ${CONFIG_DIR}/jabberd.cfg
|
||||
install -o ${JABBERDUSER} -g ${JABBERDGROUP} -m 640 ${EXAMPLES}/c2s.xml ${CONFIG_DIR}/c2s.xml
|
||||
install -o ${JABBERDUSER} -g ${JABBERDGROUP} -m 640 ${EXAMPLES}/resolver.xml ${CONFIG_DIR}/resolver.xml
|
||||
install -o ${JABBERDUSER} -g ${JABBERDGROUP} -m 640 ${EXAMPLES}/router-users.xml ${CONFIG_DIR}/router-users.xml
|
||||
install -o ${JABBERDUSER} -g ${JABBERDGROUP} -m 640 ${EXAMPLES}/router.xml ${CONFIG_DIR}/router.xml
|
||||
install -o ${JABBERDUSER} -g ${JABBERDGROUP} -m 640 ${EXAMPLES}/s2s.xml ${CONFIG_DIR}/s2s.xml
|
||||
install -o ${JABBERDUSER} -g ${JABBERDGROUP} -m 640 ${EXAMPLES}/sm.xml ${CONFIG_DIR}/sm.xml
|
||||
install -d -o ${JABBERDUSER} -g ${JABBERDGROUP} -m 750 ${CONFIG_DIR}/templates
|
||||
install -o ${JABBERDUSER} -g ${JABBERDGROUP} -m 640 ${EXAMPLES}/templates/roster.xml ${CONFIG_DIR}/roster.xml
|
||||
|
||||
echo
|
||||
echo "+---------------"
|
||||
echo "| The $1 configuration files have been installed in ${CONFIG_DIR}."
|
||||
echo "| Please view this file and change the configuration to meet your needs."
|
||||
echo "+---------------"
|
||||
echo
|
||||
}
|
||||
|
||||
# verify proper execution
|
||||
#
|
||||
if [ $# -ne 2 ]; then
|
||||
echo "usage: $0 distname { PRE-INSTALL | POST-INSTALL }" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Verify/process the command
|
||||
#
|
||||
case $2 in
|
||||
PRE-INSTALL)
|
||||
do_usergroup_install
|
||||
;;
|
||||
POST-INSTALL)
|
||||
if [ ! -d ${JABBERDDIR} ]; then
|
||||
do_jabberddir_install
|
||||
fi
|
||||
if [ ! -d ${CONFIG_DIR} ]; then
|
||||
do_install_conf $1
|
||||
elif [ ! -f ${CONFIG_DIR}/jabberd.cfg ]; then
|
||||
do_install_conf $1
|
||||
else
|
||||
do_notice_conf $1
|
||||
fi
|
||||
;;
|
||||
*)
|
||||
echo "usage: $0 distname { PRE-INSTALL | POST-INSTALL }" >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
exit 0
|
34
net/jabberd/pkg/PLIST
Normal file
34
net/jabberd/pkg/PLIST
Normal file
@ -0,0 +1,34 @@
|
||||
@comment $OpenBSD: PLIST,v 1.1.1.1 2004/05/29 13:12:30 jakob Exp $
|
||||
libexec/jabberd/c2s
|
||||
libexec/jabberd/resolver
|
||||
libexec/jabberd/router
|
||||
libexec/jabberd/s2s
|
||||
libexec/jabberd/sm
|
||||
sbin/jabberd
|
||||
man/man8/c2s.8
|
||||
man/man8/jabberd.8
|
||||
man/man8/resolver.8
|
||||
man/man8/router.8
|
||||
man/man8/s2s.8
|
||||
man/man8/sm.8
|
||||
share/examples/jabberd/c2s.xml
|
||||
share/examples/jabberd/db-setup.mysql
|
||||
share/examples/jabberd/jabberd.cfg
|
||||
share/examples/jabberd/resolver.xml
|
||||
share/examples/jabberd/router-users.xml
|
||||
share/examples/jabberd/router.xml
|
||||
share/examples/jabberd/s2s.xml
|
||||
share/examples/jabberd/sm.xml
|
||||
share/examples/jabberd/templates/roster.xml
|
||||
@dirrm share/examples/jabberd/templates
|
||||
@dirrm share/examples/jabberd
|
||||
@cwd ${SYSCONFDIR}
|
||||
@extra jabberd/templates/roster.xml
|
||||
@extra jabberd/templates
|
||||
@extra jabberd/jabberd.cfg
|
||||
@extra jabberd/c2s.xml
|
||||
@extra jabberd/resolver.xml
|
||||
@extra jabberd/router-users.xml
|
||||
@extra jabberd/router.xml
|
||||
@extra jabberd/s2s.xml
|
||||
@extra jabberd/sm.xml
|
Loading…
Reference in New Issue
Block a user