diff options
author | miwi <miwi@FreeBSD.org> | 2007-02-27 21:13:26 +0800 |
---|---|---|
committer | miwi <miwi@FreeBSD.org> | 2007-02-27 21:13:26 +0800 |
commit | bb0daee63748675600031e22819ba406b7140374 (patch) | |
tree | f857892c870ae570e18b63f717500deddfa35f1d /net-im | |
parent | 30706688d2d12389b4e3c44c46d9b7237cc8d581 (diff) | |
download | freebsd-ports-gnome-bb0daee63748675600031e22819ba406b7140374.tar.gz freebsd-ports-gnome-bb0daee63748675600031e22819ba406b7140374.tar.zst freebsd-ports-gnome-bb0daee63748675600031e22819ba406b7140374.zip |
- Unbreak
- Update to 1.6.0
- Add support for openssl, mysql, postgresql
- Pass maintainership to submitter
NOTES: Please read the UPDATING.
PR: 109259
Submitted by: Martin Matuska <martin@matuska.org>
Diffstat (limited to 'net-im')
-rw-r--r-- | net-im/jabber/Makefile | 100 | ||||
-rw-r--r-- | net-im/jabber/distinfo | 6 | ||||
-rw-r--r-- | net-im/jabber/files/jabber.in | 34 | ||||
-rw-r--r-- | net-im/jabber/files/jabberd.sh.in | 33 | ||||
-rw-r--r-- | net-im/jabber/files/patch-Makefile.in | 13 | ||||
-rw-r--r-- | net-im/jabber/files/patch-configure | 101 | ||||
-rw-r--r-- | net-im/jabber/files/patch-jabberd-Makefile.in | 22 | ||||
-rw-r--r-- | net-im/jabber/files/patch-jabberd_mio.c | 16 | ||||
-rw-r--r-- | net-im/jabber/files/patch-jsm-sessions.c | 34 | ||||
-rw-r--r-- | net-im/jabber/files/patch-man-Makefile.in | 22 | ||||
-rw-r--r-- | net-im/jabber/files/patch-man-jabberd.8.in | 13 | ||||
-rw-r--r-- | net-im/jabber/files/patch-xdb_file-xdbfiletool.cc | 14 | ||||
-rw-r--r-- | net-im/jabber/files/patch-xdb_sql-xdb_sql.cc | 11 | ||||
-rw-r--r-- | net-im/jabber/files/pkg-deinstall.in (renamed from net-im/jabber/pkg-deinstall) | 12 | ||||
-rw-r--r-- | net-im/jabber/files/pkg-install.in | 52 | ||||
-rw-r--r-- | net-im/jabber/files/pkg-message.in | 18 | ||||
-rw-r--r-- | net-im/jabber/pkg-descr | 17 | ||||
-rw-r--r-- | net-im/jabber/pkg-install | 68 | ||||
-rw-r--r-- | net-im/jabber/pkg-plist | 93 |
19 files changed, 492 insertions, 187 deletions
diff --git a/net-im/jabber/Makefile b/net-im/jabber/Makefile index 85d26388e366..625ddd701db8 100644 --- a/net-im/jabber/Makefile +++ b/net-im/jabber/Makefile @@ -6,48 +6,114 @@ # PORTNAME= jabber -PORTVERSION= 1.4.4 +PORTVERSION= 1.6.0 PORTEPOCH= 1 CATEGORIES= net-im ipv6 MASTER_SITES= http://download.jabberd.org/jabberd14/ -DISTNAME= ${PORTNAME}d-${PORTVERSION} +DISTNAME= jabberd14-${PORTVERSION} DIST_SUBDIR= jabber -MAINTAINER= ports@FreeBSD.org -COMMENT= Online presence and instant messaging server +MAINTAINER= martin@matuska.org +COMMENT= XMPP/Jabber server daemon -LIB_DEPENDS= pth.20:${PORTSDIR}/devel/pth \ +LIB_DEPENDS= pth.20:${PORTSDIR}/devel/pth-hard \ + popt.0:${PORTSDIR}/devel/popt \ idn.16:${PORTSDIR}/dns/libidn \ expat.6:${PORTSDIR}/textproc/expat2 -OPTIONS= IPV6 "Enable IPv6 support" off +OPTIONS= IPV6 "Enable IPv6 support" off \ + MYSQL "Build with MySQL support" off \ + PGSQL "Build with PostgreSQL support" off -USE_GNOME= gnometarget -USE_RC_SUBR= jabberd.sh +USE_RC_SUBR= jabber USE_OPENSSL= yes USE_ICONV= yes USE_GMAKE= yes +USE_GETTEXT= yes USE_AUTOTOOLS= libtool:15 -CONFIGURE_ENV= CPPFLAGS="${CPPFLAGS}" LDFLAGS="${LDFLAGS}" -CONFIGURE_ARGS= --localstatedir=/var \ - --with-ssl-legacy=/usr -USE_LDCONFIG= yes +USE_LDCONFIG= ${TARGETDIR}/lib/jabber +.if !defined(NO_INSTALL_MANPAGES) MAN5= jabber.xml.5 -MAN8= jabberd.8 +MAN8= jabberd14.8 +.endif + +JABBER_USER= jabber +JABBER_UID= 93 +JABBER_GROUP= ${JABBER_USER} +JABBER_GID= ${JABBER_UID} +JABBER_ETCDIR= "${TARGETDIR}/etc" +JABBER_RUNDIR= "/var/run/jabberd" +JABBER_SPOOLDIR="/var/spool/jabberd" +JABBER_LOGDIR= "/var/log/jabberd" + +CONFIGURE_ENV= CPPFLAGS="${CPPFLAGS}" LDFLAGS="${LDFLAGS}" +CONFIGURE_ARGS= --mandir=${MANPREFIX}/man --localstatedir=/var --enable-ssl \ + --with-ssl-legacy=${OPENSSLBASE} --sysconfdir=${JABBER_ETCDIR} \ + --includedir=${TARGETDIR}/include/jabber \ + --libdir=${TARGETDIR}/lib/jabber + +CPPFLAGS+= -I${LOCALBASE}/include/pth -I${LOCALBASE}/include +LDFLAGS+= -L${LOCALBASE}/lib/pth -L${LOCALBASE}/lib -BROKEN= breaks all jabber protocols +SUB_FILES+= pkg-install pkg-deinstall pkg-message +SUB_LIST+= JABBER_USER=${JABBER_USER} JABBER_UID=${JABBER_UID} \ + JABBER_GROUP=${JABBER_GROUP} JABBER_GID=${JABBER_GID} \ + JABBER_ETCDIR="${JABBER_ETCDIR}" \ + JABBER_LOGDIR="${JABBER_LOGDIR}" \ + JABBER_SPOOLDIR="${JABBER_SPOOLDIR}" \ + JABBER_RUNDIR="${JABBER_RUNDIR}" +PKGINSTALL= ${WRKDIR}/pkg-install +PKGDEINSTALL= ${WRKDIR}/pkg-deinstall +PKGMESSAGE= ${WRKDIR}/pkg-message -CPPFLAGS= -I${LOCALBASE}/include/pth -I${LOCALBASE}/include -LDFLAGS= -L${LOCALBASE}/lib/pth -L${LOCALBASE}/lib +DOCS= AUTHORS COPYING ChangeLog INSTALL NEWS README README.SQL README.config \ + README.filespool README.karma README.protocols TODO UPGRADE mysql.sql .include <bsd.port.pre.mk> +.if defined(WITH_MYSQL) +USE_MYSQL= yes +CONFIGURE_ARGS+= --with-mysql=${LOCALBASE} +.endif + +.if defined(WITH_PGSQL) +USE_PGSQL= yes +CONFIGURE_ARGS+= --with-postgresql=${LOCALBASE} +.endif + .if defined(WITH_IPV6) CONFIGURE_ARGS+= --enable-ipv6 .endif +.if exists(${LOCALBASE}/include/pth/pthread.h) +IGNORE= pth with soft syscalls is installed, please reinstall pth from devel/pth-hard +.endif + +post-patch: + @${REINPLACE_CMD} -e "s|\\\$$(localstatedir)/log/jabberd|${JABBER_LOGDIR}|g" \ + -e "s|\\\$$(localstatedir)/spool/jabberd|${JABBER_SPOOLDIR}|g" \ + -e "s|\\\$$(localstatedir)/run/jabberd|${JABBER_RUNDIR}|g" \ + ${WRKSRC}/Makefile.in + @${REINPLACE_CMD} -e "s|@localstatedir@/log/jabberd|${JABBER_LOGDIR}|g" \ + -e "s|@localstatedir@/spool/jabberd|${JABBER_SPOOLDIR}|g" \ + -e "s|@localstatedir@/run/jabberd|${JABBER_RUNDIR}|g" \ + ${WRKSRC}/jabber.xml.dist.in + @${LN} -s ${WRKSRC}/man/jabberd.8.in ${WRKSRC}/man/jabberd14.8.in + post-install: - PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL + @${TOUCH} ${TARGETDIR}/include/jabber/platform-settings + @${INSTALL_DATA} ${WRKSRC}/jabber.xml.dist ${TARGETDIR}/etc/jabber.xml.sample +.if !defined(NO_INSTALL_MANPAGES) + @cd ${WRKSRC}/man && make install-man +.endif +.if !defined(NOPORTDOCS) + @${MKDIR} ${DOCSDIR} +.for FILE in ${DOCS} + @${INSTALL_DATA} ${WRKSRC}/${FILE} ${DOCSDIR}/${FILE} +.endfor +.endif + @PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL + @${CAT} ${PKGMESSAGE} .include <bsd.port.post.mk> diff --git a/net-im/jabber/distinfo b/net-im/jabber/distinfo index 8b59abab87ae..d9a4d6bdd39d 100644 --- a/net-im/jabber/distinfo +++ b/net-im/jabber/distinfo @@ -1,3 +1,3 @@ -MD5 (jabber/jabberd-1.4.4.tar.gz) = 395f814a6627436ba7bd235509adcbc7 -SHA256 (jabber/jabberd-1.4.4.tar.gz) = 72e23766e737588ed8d77ca7565a8f4b2bba73967c02e9b7ee4d2122d198a0af -SIZE (jabber/jabberd-1.4.4.tar.gz) = 613479 +MD5 (jabber/jabberd14-1.6.0.tar.gz) = 058ae016c2afda43184f4eccb65de91d +SHA256 (jabber/jabberd14-1.6.0.tar.gz) = 8d0b0097bb68c4234a86030d73fa9b137f4e3ad8d02b015f70df91151c216930 +SIZE (jabber/jabberd14-1.6.0.tar.gz) = 820469 diff --git a/net-im/jabber/files/jabber.in b/net-im/jabber/files/jabber.in new file mode 100644 index 000000000000..a0c509b15952 --- /dev/null +++ b/net-im/jabber/files/jabber.in @@ -0,0 +1,34 @@ +#!/bin/sh +# +# $FreeBSD$ +# +# PROVIDE: jabber +# REQUIRE: LOGIN +# KEYWORD: shutdown +# +# Add the following lines to /etc/rc.conf to enable rsyncd: +# +# jabber_enable="YES" +# + +. %%RC_SUBR%% + +name="jabber" +rcvar=`set_rcvar` + +load_rc_config $name + +required_files=%%JABBER_ETCDIR%%/jabber.xml + +: ${jabber_enable="NO"} +: ${jabber_pidfile="%%JABBER_RUNDIR%%/jabber.pid"} +: ${jabber_flags="-B -c ${required_files}"} +: ${jabber_user="%%JABBER_USER%%"} +: ${jabber_group="%%JABBER_GROUP%%"} + +command=%%PREFIX%%/bin/jabberd14 +command_args="${jabberd_flags}" +pidfile=${jabberd_pidfile} +extra_commands="reload" + +run_rc_command "$1" diff --git a/net-im/jabber/files/jabberd.sh.in b/net-im/jabber/files/jabberd.sh.in deleted file mode 100644 index 82a112444cef..000000000000 --- a/net-im/jabber/files/jabberd.sh.in +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/sh -# -# $FreeBSD$ -# -# PROVIDE: jabber -# REQUIRE: LOGIN -# KEYWORD: shutdown -# -# Add the following lines to /etc/rc.conf to enable rsyncd: -# -# jabber_enable="YES" -# - -. %%RC_SUBR%% - -name="jabber" -rcvar=`set_rcvar` - -load_rc_config $name - -required_files=%%PREFIX%%/etc/${name}.xml - -: ${jabber_enable="NO"} -: ${jabber_pidfile="/var/run/jabber/${name}.pid"} -: ${jabber_flags="-B -h `/bin/hostname` -c ${required_files}"} -: ${jabber_user="jabber"} -: ${jabber_group="jabber"} - -command=%%PREFIX%%/bin/jabberd -command_args="${jabber_flags}" -pidfile=${jabber_pidfile} - -run_rc_command "$1" diff --git a/net-im/jabber/files/patch-Makefile.in b/net-im/jabber/files/patch-Makefile.in new file mode 100644 index 000000000000..ebbbf9bcb85b --- /dev/null +++ b/net-im/jabber/files/patch-Makefile.in @@ -0,0 +1,13 @@ +--- Makefile.in.orig Sun Dec 24 09:33:11 2006 ++++ Makefile.in Fri Feb 16 13:18:57 2007 +@@ -675,9 +675,8 @@ + + install-data-am: install-logDATA install-runDATA install-spoolDATA + @$(NORMAL_INSTALL) +- $(MAKE) $(AM_MAKEFLAGS) install-data-hook + +-install-exec-am: install-sysconfDATA ++install-exec-am: + + install-info: install-info-recursive + diff --git a/net-im/jabber/files/patch-configure b/net-im/jabber/files/patch-configure new file mode 100644 index 000000000000..a7ebde67a905 --- /dev/null +++ b/net-im/jabber/files/patch-configure @@ -0,0 +1,101 @@ +--- configure.orig Sat Feb 17 10:54:39 2007 ++++ configure Sat Feb 17 10:56:22 2007 +@@ -23750,8 +23750,8 @@ + CPPFLAGS="${CPPFLAGS} -I$postgresql/include" + fi + if test "${ac_cv_header_postgresql_libpq_fe_h+set}" = set; then +- { echo "$as_me:$LINENO: checking for postgresql/libpq-fe.h" >&5 +-echo $ECHO_N "checking for postgresql/libpq-fe.h... $ECHO_C" >&6; } ++ { echo "$as_me:$LINENO: checking for libpq-fe.h" >&5 ++echo $ECHO_N "checking for libpq-fe.h... $ECHO_C" >&6; } + if test "${ac_cv_header_postgresql_libpq_fe_h+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + fi +@@ -23759,8 +23759,8 @@ + echo "${ECHO_T}$ac_cv_header_postgresql_libpq_fe_h" >&6; } + else + # Is the header compilable? +-{ echo "$as_me:$LINENO: checking postgresql/libpq-fe.h usability" >&5 +-echo $ECHO_N "checking postgresql/libpq-fe.h usability... $ECHO_C" >&6; } ++{ echo "$as_me:$LINENO: checking libpq-fe.h usability" >&5 ++echo $ECHO_N "checking libpq-fe.h usability... $ECHO_C" >&6; } + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF +@@ -23768,7 +23768,7 @@ + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ + $ac_includes_default +-#include <postgresql/libpq-fe.h> ++#include <libpq-fe.h> + _ACEOF + rm -f conftest.$ac_objext + if { (ac_try="$ac_compile" +@@ -23817,15 +23817,15 @@ + echo "${ECHO_T}$ac_header_compiler" >&6; } + + # Is the header present? +-{ echo "$as_me:$LINENO: checking postgresql/libpq-fe.h presence" >&5 +-echo $ECHO_N "checking postgresql/libpq-fe.h presence... $ECHO_C" >&6; } ++{ echo "$as_me:$LINENO: checking libpq-fe.h presence" >&5 ++echo $ECHO_N "checking libpq-fe.h presence... $ECHO_C" >&6; } + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-#include <postgresql/libpq-fe.h> ++#include <libpq-fe.h> + _ACEOF + if { (ac_try="$ac_cpp conftest.$ac_ext" + case "(($ac_try" in +@@ -23865,30 +23865,30 @@ + # So? What about this header? + case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in + yes:no: ) +- { echo "$as_me:$LINENO: WARNING: postgresql/libpq-fe.h: accepted by the compiler, rejected by the preprocessor!" >&5 +-echo "$as_me: WARNING: postgresql/libpq-fe.h: accepted by the compiler, rejected by the preprocessor!" >&2;} +- { echo "$as_me:$LINENO: WARNING: postgresql/libpq-fe.h: proceeding with the compiler's result" >&5 +-echo "$as_me: WARNING: postgresql/libpq-fe.h: proceeding with the compiler's result" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libpq-fe.h: accepted by the compiler, rejected by the preprocessor!" >&5 ++echo "$as_me: WARNING: libpq-fe.h: accepted by the compiler, rejected by the preprocessor!" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libpq-fe.h: proceeding with the compiler's result" >&5 ++echo "$as_me: WARNING: libpq-fe.h: proceeding with the compiler's result" >&2;} + ac_header_preproc=yes + ;; + no:yes:* ) +- { echo "$as_me:$LINENO: WARNING: postgresql/libpq-fe.h: present but cannot be compiled" >&5 +-echo "$as_me: WARNING: postgresql/libpq-fe.h: present but cannot be compiled" >&2;} +- { echo "$as_me:$LINENO: WARNING: postgresql/libpq-fe.h: check for missing prerequisite headers?" >&5 +-echo "$as_me: WARNING: postgresql/libpq-fe.h: check for missing prerequisite headers?" >&2;} +- { echo "$as_me:$LINENO: WARNING: postgresql/libpq-fe.h: see the Autoconf documentation" >&5 +-echo "$as_me: WARNING: postgresql/libpq-fe.h: see the Autoconf documentation" >&2;} +- { echo "$as_me:$LINENO: WARNING: postgresql/libpq-fe.h: section \"Present But Cannot Be Compiled\"" >&5 +-echo "$as_me: WARNING: postgresql/libpq-fe.h: section \"Present But Cannot Be Compiled\"" >&2;} +- { echo "$as_me:$LINENO: WARNING: postgresql/libpq-fe.h: proceeding with the preprocessor's result" >&5 +-echo "$as_me: WARNING: postgresql/libpq-fe.h: proceeding with the preprocessor's result" >&2;} +- { echo "$as_me:$LINENO: WARNING: postgresql/libpq-fe.h: in the future, the compiler will take precedence" >&5 +-echo "$as_me: WARNING: postgresql/libpq-fe.h: in the future, the compiler will take precedence" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libpq-fe.h: present but cannot be compiled" >&5 ++echo "$as_me: WARNING: libpq-fe.h: present but cannot be compiled" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libpq-fe.h: check for missing prerequisite headers?" >&5 ++echo "$as_me: WARNING: libpq-fe.h: check for missing prerequisite headers?" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libpq-fe.h: see the Autoconf documentation" >&5 ++echo "$as_me: WARNING: libpq-fe.h: see the Autoconf documentation" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libpq-fe.h: section \"Present But Cannot Be Compiled\"" >&5 ++echo "$as_me: WARNING: libpq-fe.h: section \"Present But Cannot Be Compiled\"" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libpq-fe.h: proceeding with the preprocessor's result" >&5 ++echo "$as_me: WARNING: libpq-fe.h: proceeding with the preprocessor's result" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libpq-fe.h: in the future, the compiler will take precedence" >&5 ++echo "$as_me: WARNING: libpq-fe.h: in the future, the compiler will take precedence" >&2;} + + ;; + esac +-{ echo "$as_me:$LINENO: checking for postgresql/libpq-fe.h" >&5 +-echo $ECHO_N "checking for postgresql/libpq-fe.h... $ECHO_C" >&6; } ++{ echo "$as_me:$LINENO: checking for libpq-fe.h" >&5 ++echo $ECHO_N "checking for libpq-fe.h... $ECHO_C" >&6; } + if test "${ac_cv_header_postgresql_libpq_fe_h+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else diff --git a/net-im/jabber/files/patch-jabberd-Makefile.in b/net-im/jabber/files/patch-jabberd-Makefile.in new file mode 100644 index 000000000000..33ab6513e59e --- /dev/null +++ b/net-im/jabber/files/patch-jabberd-Makefile.in @@ -0,0 +1,22 @@ +--- jabberd/Makefile.in.orig Sun Feb 18 10:50:50 2007 ++++ jabberd/Makefile.in Sun Feb 18 10:52:00 2007 +@@ -38,7 +38,7 @@ + POST_UNINSTALL = : + build_triplet = @build@ + host_triplet = @host@ +-bin_PROGRAMS = jabberd$(EXEEXT) ++bin_PROGRAMS = jabberd14$(EXEEXT) + subdir = jabberd + DIST_COMMON = README $(include_HEADERS) $(srcdir)/Makefile.am \ + $(srcdir)/Makefile.in +@@ -322,8 +322,8 @@ + echo " rm -f $$p $$f"; \ + rm -f $$p $$f ; \ + done +-jabberd$(EXEEXT): $(jabberd_OBJECTS) $(jabberd_DEPENDENCIES) +- @rm -f jabberd$(EXEEXT) ++jabberd14$(EXEEXT): $(jabberd_OBJECTS) $(jabberd_DEPENDENCIES) ++ @rm -f jabberd14$(EXEEXT) + $(CXXLINK) $(jabberd_LDFLAGS) $(jabberd_OBJECTS) $(jabberd_LDADD) $(LIBS) + + mostlyclean-compile: diff --git a/net-im/jabber/files/patch-jabberd_mio.c b/net-im/jabber/files/patch-jabberd_mio.c deleted file mode 100644 index 24a2714d2a89..000000000000 --- a/net-im/jabber/files/patch-jabberd_mio.c +++ /dev/null @@ -1,16 +0,0 @@ ---- jabberd/mio.c.orig Wed Nov 12 22:19:08 2003 -+++ jabberd/mio.c Sun Sep 3 09:40:22 2006 -@@ -530,6 +530,13 @@ - return NULL; - } - -+ /* do not accept a higher fd than FD_SET, or FD_CLR can handle */ -+ if (fd >= FD_SETSIZE) { -+ log_warn(NULL, "could not accept incomming connection, maximum number of connections reached (%i)", FD_SETSIZE); -+ close(fd); -+ return NULL; -+ } -+ - #ifdef WITH_IPV6 - allow = _mio_allow_check(inet_ntop(AF_INET6, &serv_addr.sin6_addr, addr_str, sizeof(addr_str))); - deny = _mio_deny_check(addr_str); diff --git a/net-im/jabber/files/patch-jsm-sessions.c b/net-im/jabber/files/patch-jsm-sessions.c new file mode 100644 index 000000000000..6f77d05a8676 --- /dev/null +++ b/net-im/jabber/files/patch-jsm-sessions.c @@ -0,0 +1,34 @@ +--- jsm/sessions.c.orig Fri Feb 9 11:27:52 2007 ++++ jsm/sessions.c Fri Feb 9 11:45:32 2007 +@@ -105,7 +105,9 @@ + */ + static void _js_create_session_id(char resultbuffer[9], xht existing_sessions) { + static int seeded = 0; ++#ifdef _GLIBC_ + static struct drand48_data rand_state; ++#endif + long int rand_value; + int tries = 256; + +@@ -118,13 +120,21 @@ + seed_data[0] = now.tv_sec%0x10000; + seed_data[1] = now.tv_sec/0x10000; + seed_data[2] = now.tv_usec%0x10000; ++#ifdef _GLIBC_ + seed48_r(seed_data, &rand_state); ++#else ++ seed48(seed_data); ++#endif + seeded = 1; + } + + /* create an ID, that is not already used */ + while (tries--) { ++#ifdef _GLIBC_ + lrand48_r(&rand_state, &rand_value); ++#else ++ rand_value = lrand48(); ++#endif + snprintf(resultbuffer, 9, "%lx", rand_value); + + if (existing_sessions == NULL || xhash_get(existing_sessions, resultbuffer) == NULL) diff --git a/net-im/jabber/files/patch-man-Makefile.in b/net-im/jabber/files/patch-man-Makefile.in new file mode 100644 index 000000000000..6a433ef56bfd --- /dev/null +++ b/net-im/jabber/files/patch-man-Makefile.in @@ -0,0 +1,22 @@ +--- man/Makefile.in.orig Sun Feb 18 10:53:09 2007 ++++ man/Makefile.in Sun Feb 18 10:57:28 2007 +@@ -166,8 +166,8 @@ + sharedstatedir = @sharedstatedir@ + sysconfdir = @sysconfdir@ + target_alias = @target_alias@ +-man_MANS = jabberd.8 jabber.xml.5 +-EXTRA_DIST = jabberd.8.in jabber.xml.5.in ++man_MANS = jabberd14.8 jabber.xml.5 ++EXTRA_DIST = jabberd14.8.in jabber.xml.5.in + edit = sed \ + -e 's,\@sysconfdir\@,$(sysconfdir),g' \ + -e 's,\@VERSION\@,$(VERSION),g' +@@ -387,7 +387,7 @@ + + info-am: + +-install-data-am: install-man ++install-data-am: + + install-exec-am: + diff --git a/net-im/jabber/files/patch-man-jabberd.8.in b/net-im/jabber/files/patch-man-jabberd.8.in new file mode 100644 index 000000000000..d6e8f8ad9c40 --- /dev/null +++ b/net-im/jabber/files/patch-man-jabberd.8.in @@ -0,0 +1,13 @@ +--- man/jabberd.8.in.orig Sun Feb 18 10:53:40 2007 ++++ man/jabberd.8.in Sun Feb 18 10:53:58 2007 +@@ -1,8 +1,8 @@ + .TH jabberd 8 "12 Oct 2004" "@VERSION@" "jabberd14 project" + .SH NAME +-jabberd \- jabberd daemon ++jabberd14 \- jabberd daemon + .SH SYNOPSIS +-.B jabberd ++.B jabberd14 + .I [-B] [-c config] [-d mask | -D] [-H dir] [-v] [-V] [-Z zone(s)] [-I dir] + .SH DESCRIPTION + .BR jabberd diff --git a/net-im/jabber/files/patch-xdb_file-xdbfiletool.cc b/net-im/jabber/files/patch-xdb_file-xdbfiletool.cc new file mode 100644 index 000000000000..c350b65cfeab --- /dev/null +++ b/net-im/jabber/files/patch-xdb_file-xdbfiletool.cc @@ -0,0 +1,14 @@ +--- xdb_file/xdbfiletool.cc.orig Fri Feb 9 11:46:12 2007 ++++ xdb_file/xdbfiletool.cc Fri Feb 9 11:55:35 2007 +@@ -66,7 +66,11 @@ + + int main(int argc, const char **argv) { + char *host = NULL; ++#ifdef __FreeBSD__ ++ const char *error = NULL; ++#else + char *error = NULL; ++#endif + char *cfgfile = CONFIG_DIR "/jabber.xml"; + char *basedir = NULL; + char *do_get = NULL; diff --git a/net-im/jabber/files/patch-xdb_sql-xdb_sql.cc b/net-im/jabber/files/patch-xdb_sql-xdb_sql.cc new file mode 100644 index 000000000000..5c874214bc5d --- /dev/null +++ b/net-im/jabber/files/patch-xdb_sql-xdb_sql.cc @@ -0,0 +1,11 @@ +--- xdb_sql/xdb_sql.cc.orig Sat Feb 17 10:57:25 2007 ++++ xdb_sql/xdb_sql.cc Sat Feb 17 10:57:36 2007 +@@ -53,7 +53,7 @@ + #endif + + #ifdef HAVE_POSTGRESQL +-# include <postgresql/libpq-fe.h> ++# include <libpq-fe.h> + #endif + + /** diff --git a/net-im/jabber/pkg-deinstall b/net-im/jabber/files/pkg-deinstall.in index 7adc2901c773..274d53a37749 100644 --- a/net-im/jabber/pkg-deinstall +++ b/net-im/jabber/files/pkg-deinstall.in @@ -4,17 +4,21 @@ if [ "$2" != "POST-DEINSTALL" ]; then exit 0 fi -USER=jabber +USER=%%JABBER_USER%% +GROUP=%%JABBER_GROUP%% +RUNDIR="%%JABBER_RUNDIR%%" +SPOOLDIR="%%JABBER_SPOOLDIR%%" if pw usershow "${USER}" 2>/dev/null 1>&2; then echo "To delete Jabber user permanently, use 'pw userdel ${USER}'" fi -if pw groupshow "${USER}" 2>/dev/null 1>&2; then +if pw groupshow "${GROUP}" 2>/dev/null 1>&2; then echo "To delete Jabber group permanently, use 'pw groupdel ${USER}'" fi -echo "If you wish to delete jabber data files, remove '/var/spool/jabberd' directory." -echo "If you wish to delete jabber log files, remove '/var/log/jabberd' directory." +echo "You may want to delete the following directories:" +echo "${RUNDIR}" +echo "${SPOOLDIR}" exit 0 diff --git a/net-im/jabber/files/pkg-install.in b/net-im/jabber/files/pkg-install.in new file mode 100644 index 000000000000..2a7c130c1be1 --- /dev/null +++ b/net-im/jabber/files/pkg-install.in @@ -0,0 +1,52 @@ +#!/bin/sh + +if [ "$2" != "POST-INSTALL" ]; then + exit 0 +fi + +USER=%%JABBER_USER%% +GROUP=%%JABBER_GROUP%% +UID=%%JABBER_UID%% +GID=%%JABBER_GID%% +ETCDIR=%%JABBER_ETCDIR%% +RUNDIR=%%JABBER_RUNDIR%% +SPOOLDIR=%%JABBER_SPOOLDIR%% + +if ! pw groupshow "${GROUP}" 2>/dev/null 1>&2; then + if pw groupadd ${GROUP} -g ${GID}; then + echo "Added group \"${GROUP}\"." + else + echo "Adding group \"${GROUP}\" failed..." + exit 1 + fi +fi + +if ! pw usershow "${USER}" 2>/dev/null 1>&2; then + if pw useradd ${USER} -u ${UID} -g ${GROUP} -h - \ + -s "/sbin/nologin" -d "/nonexistent" \ + -c "Jabber Daemon"; \ + then + echo "Added user \"${USER}\"." + else + echo "Adding user \"${USER}\" failed..." + exit 1 + fi +fi + +if [ ! -d ${RUNDIR} ]; then + echo "Creating \"${RUNDIR}\"." + mkdir -p ${RUNDIR} +fi + +echo "Fixing ownerships and modes in \"${RUNDIR}\"." +chown -R ${USER}:${GROUP} ${RUNDIR} +chmod -R go= ${RUNDIR} + +if [ ! -d ${SPOOLDIR} ]; then + echo "Creating \"${SPOOLDIR}\"." + mkdir -p ${SPOOLDIR} +fi + +echo "Fixing ownerships and modes in \"${SPOOLDIR}\"." +chown -R ${USER}:${GROUP} ${SPOOLDIR} +chmod -R go= ${SPOOLDIR} diff --git a/net-im/jabber/files/pkg-message.in b/net-im/jabber/files/pkg-message.in new file mode 100644 index 000000000000..dd33daa33c2a --- /dev/null +++ b/net-im/jabber/files/pkg-message.in @@ -0,0 +1,18 @@ +------------------------------------------------------------------------ + +Congratulations, you have installed jabberd14. + +To configure jabberd14, please copy: +%%PREFIX%%/etc/jabber.xml.sample to %%PREFIX%%/etc/jabber.xml +and edit this file. + +For automatic startup define in your rc.conf: +jabberd14_enable="YES" + +If you want to use file logging instead of syslog, +confgiure this in jabber.xml and create the log directory defined there +(default log directory: %%JABBER_LOGDIR%%) +and change its owner/group to the user/group jabberd14 runs as +(default user: %%JABBER_USER%%, default group: %%JABBER_GROUP%%) + +------------------------------------------------------------------------ diff --git a/net-im/jabber/pkg-descr b/net-im/jabber/pkg-descr index 7767352059ef..48e449b7c5d8 100644 --- a/net-im/jabber/pkg-descr +++ b/net-im/jabber/pkg-descr @@ -1,11 +1,12 @@ -The Jabber server (jabberd) is a daemon for Jabber clients to connect -and communicate with. +jabberd14 is the original server implementation of the Jabber protocol, +now known as XMPP. It is open source, and it is free. This implementation +has been formerly known as just jabberd as well. -After editing $PREFIX/etc/jabber.xml, the server can be started by -rc.d script. +Please note: net-im/jabberd (also known as jabberd 2.x) is not a newer +version of jabberd14 but a completely different project. -Complete information about configuration can be found in the Jabber Server -mini-HOWTO at http://www.jabber.org/admin/. +You can learn more about jabberd14 at +WWW: http://jabberd.org/ -You can learn more about Jabber at -WWW: http://www.jabber.org/ +- Martin Matuska +martin@matuska.org diff --git a/net-im/jabber/pkg-install b/net-im/jabber/pkg-install deleted file mode 100644 index 1d8a161cc6b9..000000000000 --- a/net-im/jabber/pkg-install +++ /dev/null @@ -1,68 +0,0 @@ -#!/bin/sh - -if [ "$2" != "POST-INSTALL" ]; then - exit 0 -fi - -USER=jabber -GROUP=${USER} -UID=93 -GID=${UID} -ETCDIR=${PREFIX:-$PKG_PREFIX}/etc -LOGDIR="/var/log/jabberd" -PIDDIR="/var/run/jabberd" -SPOOLDIR="/var/spool/jabberd" - -if ! pw groupshow "${GROUP}" 2>/dev/null 1>&2; then - if pw groupadd ${GROUP} -g ${GID}; then - echo "Added group \"${GROUP}\"." - else - echo "Adding group \"${GROUP}\" failed..." - exit 1 - fi -fi - -if ! pw usershow "${USER}" 2>/dev/null 1>&2; then - if pw useradd ${USER} -u ${UID} -g ${GROUP} -h - \ - -s "/sbin/nologin" -d "/nonexistent" \ - -c "Jabber Daemon"; \ - then - echo "Added user \"${USER}\"." - else - echo "Adding user \"${USER}\" failed..." - exit 1 - fi -fi - -if [ ! -f ${ETCDIR}/jabber.xml ]; then - echo "Creating \"${ETCDIR}/jabber.xml\"." - cp -p ${ETCDIR}/jabber.xml.dist ${ETCDIR}/jabber.xml -fi - -echo "Fixing config files ownerships and modes." -chown root:${GROUP} ${ETCDIR}/jabber.xml ${ETCDIR}/jabber.xml.dist -chmod 640 ${ETCDIR}/jabber.xml ${ETCDIR}/jabber.xml.dist - -if [ ! -d ${LOGDIR} ]; then - echo "Creating \"${LOGDIR}\"." - mkdir -p ${LOGDIR} -fi - -echo "Fixing ownerships and modes in \"${LOGDIR}\"." -touch ${LOGDIR}/error.log ${LOGDIR}/record.log -chown ${USER}:${GROUP} ${LOGDIR}/error.log ${LOGDIR}/record.log -chmod 640 ${LOGDIR}/error.log ${LOGDIR}/record.log - -if [ ! -d ${PIDDIR} ]; then - echo "Creating \"${PIDDIR}\"." - mkdir -p ${PIDDIR} -fi - -if [ ! -d ${SPOOLDIR} ]; then - echo "Creating \"${SPOOLDIR}\"." - mkdir -p ${SPOOLDIR} -fi - -echo "Fixing ownerships and modes in \"${SPOOLDIR}\"." -chown -R ${USER}:${GROUP} ${SPOOLDIR} -chmod -R go= ${SPOOLDIR} diff --git a/net-im/jabber/pkg-plist b/net-im/jabber/pkg-plist index 0e4d1221c672..67e6e50d1958 100644 --- a/net-im/jabber/pkg-plist +++ b/net-im/jabber/pkg-plist @@ -1,39 +1,56 @@ -bin/jabberd +bin/jabberd14 bin/xdbfiletool -@unexec if cmp -s %D/etc/jabber.xml.dist %D/etc/jabber.xml; then rm -f %D/etc/jabber.xml; fi -etc/jabber.xml.dist -include/jabberd.h -include/jabberdlib.h -lib/libjabberd.a -lib/libjabberd.la -lib/libjabberd.so -lib/libjabberd.so.0 -lib/libjabberddialback.a -lib/libjabberddialback.la -lib/libjabberddialback.so -lib/libjabberddialback.so.0 -lib/libjabberddnsrv.a -lib/libjabberddnsrv.la -lib/libjabberddnsrv.so -lib/libjabberddnsrv.so.0 -lib/libjabberdpthsock.a -lib/libjabberdpthsock.la -lib/libjabberdpthsock.so -lib/libjabberdpthsock.so.0 -lib/libjabberdsm.a -lib/libjabberdsm.la -lib/libjabberdsm.so -lib/libjabberdsm.so.0 -lib/libjabberdxdbfile.a -lib/libjabberdxdbfile.la -lib/libjabberdxdbfile.so -lib/libjabberdxdbfile.so.0 -lib/libjabberdxdbsql.a -lib/libjabberdxdbsql.la -lib/libjabberdxdbsql.so -lib/libjabberdxdbsql.so.0 -@unexec if test ! -s /var/log/jabberd/error.log; then rm -f /var/log/jabberd/error.log; fi -@unexec if test ! -s /var/log/jabberd/record.log; then rm -f /var/log/jabberd/record.log; fi -@unexec rmdir /var/spool/jabberd 2>/dev/null || true -@unexec rmdir /var/run/jabberd 2>/dev/null || true -@unexec rmdir /var/log/jabberd 2>/dev/null || true +etc/jabber.xml.sample +include/jabber/jabberd.h +include/jabber/jabberdlib.h +include/jabber/platform-settings +lib/jabber/libjabberd.a +lib/jabber/libjabberd.la +lib/jabber/libjabberd.so +lib/jabber/libjabberd.so.1 +lib/jabber/libjabberddialback.a +lib/jabber/libjabberddialback.la +lib/jabber/libjabberddialback.so +lib/jabber/libjabberddialback.so.1 +lib/jabber/libjabberddnsrv.a +lib/jabber/libjabberddnsrv.la +lib/jabber/libjabberddnsrv.so +lib/jabber/libjabberddnsrv.so.1 +lib/jabber/libjabberdpthsock.a +lib/jabber/libjabberdpthsock.la +lib/jabber/libjabberdpthsock.so +lib/jabber/libjabberdpthsock.so.1 +lib/jabber/libjabberdsm.a +lib/jabber/libjabberdsm.la +lib/jabber/libjabberdsm.so +lib/jabber/libjabberdsm.so.1 +lib/jabber/libjabberdxdbfile.a +lib/jabber/libjabberdxdbfile.la +lib/jabber/libjabberdxdbfile.so +lib/jabber/libjabberdxdbfile.so.1 +lib/jabber/libjabberdxdbsql.a +lib/jabber/libjabberdxdbsql.la +lib/jabber/libjabberdxdbsql.so +lib/jabber/libjabberdxdbsql.so.1 +share/locale/de/LC_MESSAGES/jabberd14.mo +share/locale/fr/LC_MESSAGES/jabberd14.mo +share/locale/hu/LC_MESSAGES/jabberd14.mo +share/locale/it/LC_MESSAGES/jabberd14.mo +share/locale/nl/LC_MESSAGES/jabberd14.mo +%%PORTDOCS%%%%DOCSDIR%%/AUTHORS +%%PORTDOCS%%%%DOCSDIR%%/COPYING +%%PORTDOCS%%%%DOCSDIR%%/ChangeLog +%%PORTDOCS%%%%DOCSDIR%%/INSTALL +%%PORTDOCS%%%%DOCSDIR%%/NEWS +%%PORTDOCS%%%%DOCSDIR%%/README +%%PORTDOCS%%%%DOCSDIR%%/README.SQL +%%PORTDOCS%%%%DOCSDIR%%/README.config +%%PORTDOCS%%%%DOCSDIR%%/README.filespool +%%PORTDOCS%%%%DOCSDIR%%/README.karma +%%PORTDOCS%%%%DOCSDIR%%/README.protocols +%%PORTDOCS%%%%DOCSDIR%%/TODO +%%PORTDOCS%%%%DOCSDIR%%/UPGRADE +%%PORTDOCS%%%%DOCSDIR%%/mysql.sql +%%PORTDOCS%%@dirrm %%DOCSDIR%% +@dirrmtry lib/jabber +@dirrmtry include/jabber |