Remove irc/bitlbee-otr port.

This commit is contained in:
Ashish SHUKLA 2011-06-13 01:26:44 +00:00
parent f2199d52e3
commit 044d9d1bac
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=275478
12 changed files with 1 additions and 502 deletions

1
MOVED
View File

@ -2217,3 +2217,4 @@ www/ruby-asp||2011-06-09|Removed, depends on expired port, seems abandonware its
lang/njs||2011-06-09|Has expired: Upstream disapear and distfile is no more available
editors/wily||2011-06-09|Removed, depends on an expired port
x11-fonts/Xg||2011-06-09|Has expired: Upstream disapear and distfile is no more available
irc/bitlbee-otr||2011-06-13|Removed, overridden by irc/bitlbee

View File

@ -7,7 +7,6 @@
SUBDIR += bip
SUBDIR += bitchx
SUBDIR += bitlbee
SUBDIR += bitlbee-otr
SUBDIR += bnc
SUBDIR += bobot++
SUBDIR += bopm

View File

@ -1,147 +0,0 @@
# New ports collection makefile for: bitlbee
# Date created: 8 August 2008
# Whom: Ashish Shukla <wahjava@gmail.com>
#
# $FreeBSD$
#
PORTNAME= bitlbee-otr
PORTVERSION= 1.2.8
PORTREVISION= 3
CATEGORIES= irc
MASTER_SITES= http://fbsd.zlonet.ru/distfiles/ \
http://wahjava.users.sourceforge.net/
MAINTAINER= ashish@FreeBSD.org
COMMENT= An IRC to other chat networks gateway with support for OTR
SUB_FILES= pkg-message
MAN5= bitlbee.conf.5
MAN8= bitlbee.8
PORTDOCS= AUTHORS CHANGES CREDITS FAQ README
PORTEXAMPLES= bitlbee.conf motd.txt
CONFLICTS= bitlbee-[0-9]*
GNU_CONFIGURE= yes
USE_BZIP2= yes
USE_GMAKE= yes
USE_GNOME= glib20
USE_RC_SUBR= bitlbee
PKGMESSAGE= ${WRKDIR}/pkg-message
LICENSE= GPLv2
LICENSE_FILE= ${WRKSRC}/COPYING
OPTIONS= MSN "Enable MSN protocol support" On \
DEBUG "Create debuggable binary" Off \
OPENSSL "Use openssl rather than gnutls" Off \
IPV6 "Compile IPV6 support" On \
XMPP "Enable XMPP protocol support" On \
OSCAR "Enable OSCAR (ICQ,AIM) protocol support" On \
YAHOO "Enable Yahoo protocol support" On \
TWITTER "Enable Twitter protocol support" On
CONFIGURE_ARGS= --config=/var/db/bitlbee --strip=0
BITLBEEUSER?= bitlbee
BITLBEEGROUP?= bitlbee
BITLBEEDIR?= /nonexistent
BITLBEEUID= 914
BITLBEEGID= ${BITLBEEUID}
PLIST_SUB= BITLBEEUSER=${BITLBEEUSER} \
BITLBEEGROUP=${BITLBEEGROUP}
SUB_LIST+= BITLBEEUSER=${BITLBEEUSER} \
BITLBEEGROUP=${BITLBEEGROUP} \
BITLBEEDIR=${BITLBEEDIR} \
BITLBEEUID=${BITLBEEUID} \
BITLBEEGID=${BITLBEEGID}
SUB_FILES+= pkg-install pkg-deinstall
.include <bsd.port.options.mk>
.if !defined(WITHOUT_MSN)
CONFIGURE_ARGS+=--msn=1
.else
CONFIGURE_ARGS+=--msn=0 --ssl=bogus
.endif
.if !defined(WITHOUT_XMPP)
CONFIGURE_ARGS+=--jabber=1
.else
CONFIGURE_ARGS+=--jabber=0
.endif
.if !defined(WITHOUT_OSCAR)
CONFIGURE_ARGS+=--oscar=1
.else
CONFIGURE_ARGS+=--oscar=0
.endif
.if !defined(WITHOUT_YAHOO)
CONFIGURE_ARGS+=--yahoo=1
.else
CONFIGURE_ARGS+=--yahoo=0
.endif
.if defined(WITH_OPENSSL)
CONFIGURE_ARGS+=--ssl=openssl
.else
CONFIGURE_ARGS+=--ssl=gnutls
LIB_DEPENDS+= gnutls.47:${PORTSDIR}/security/gnutls
.endif
.if defined(WITH_DEBUG)
CONFIGURE_ARGS+=--debug=1
.endif
.if defined(WITHOUT_IPV6)
CONFIGURE_ARGS+=--ipv6=0
.endif
.if !defined(WITHOUT_TWITTER)
CONFIGURE_ARGS+=--twitter=1
.else
CONFIGURE_ARGS+=--twitter=0
.endif
LIB_DEPENDS+= otr.4:${PORTSDIR}/security/libotr
CONFIGURE_ARGS+=--otr=1
post-patch:
@${REINPLACE_CMD} \
-e "s|^EFLAGS=|EFLAGS=${LDFLAGS}|" \
${WRKSRC}/configure
@${REINPLACE_CMD} \
-e "s:/etc/bitlbee/motd.txt:${PREFIX}/etc/bitlbee/motd.txt:" \
-e "s:/var/lib/bitlbee:/var/db/bitlbee:" \
${WRKSRC}/bitlbee.conf
@${REINPLACE_CMD} \
-e "s:/var/lib/bitlbee:/var/db/bitlbee:" \
${WRKSRC}/doc/bitlbee.8
.if ${OSVERSION} < 700042
@${REINPLACE_CMD} -e "s:-iquote:-I:g" ${WRKSRC}/configure
.endif
pre-install:
@PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
post-install:
${MKDIR} ${PREFIX}/etc/bitlbee
${MKDIR} -m 0700 /var/db/bitlbee
${CHOWN} -R ${BITLBEEUSER}:${BITLBEEGROUP} /var/db/bitlbee
.if !defined(NOPORTDOCS)
${MKDIR} ${DOCSDIR}
${INSTALL_DATA} ${PORTDOCS:S@^@${WRKSRC}/doc/@} ${DOCSDIR}
.endif
.if !defined(NOPORTEXAMPLES)
${MKDIR} ${EXAMPLESDIR}
${INSTALL_DATA} ${PORTEXAMPLES:S@^@${WRKSRC}/@} ${EXAMPLESDIR}
.endif
@${CAT} ${PKGMESSAGE}
.include <bsd.port.mk>

View File

@ -1,2 +0,0 @@
SHA256 (bitlbee-otr-1.2.8.tar.bz2) = f09a88be7d995a0cc489ee9bea4ac49dc326c1b2e9396a8e7cc886b3894883a3
SIZE (bitlbee-otr-1.2.8.tar.bz2) = 394761

View File

@ -1,34 +0,0 @@
#!/bin/sh
#
# $FreeBSD$
#
# PROVIDE: bitlbee
# REQUIRE: DAEMON
# KEYWORD: shutdown
# Add the following lines to /etc/rc.conf to enable bitlbee:
# bitlbee_enable="YES"
# bitlbee_flags="<set as needed>"
. /etc/rc.subr
name="bitlbee"
rcvar=`set_rcvar`
load_rc_config $name
: ${bitlbee_enable="NO"}
: ${bitlbee_user="%%BITLBEEUSER%%"}
: ${bitlbee_config="%%PREFIX%%/etc/bitlbee/bitlbee.conf"}
required_files="${bitlbee_config}"
command="%%PREFIX%%/sbin/bitlbee"
start_cmd="bitlbee_start"
bitlbee_start()
{
echo "Starting ${name}."
su -m ${bitlbee_user} -c "${command} -D -c ${bitlbee_config} ${bitlbee_flags}"
}
run_rc_command "$1"

View File

@ -1,135 +0,0 @@
$FreeBSD$
--- lib/proxy.c.orig
+++ lib/proxy.c
@@ -57,27 +57,6 @@
gint inpa;
};
-
-
-static struct sockaddr_in *gaim_gethostbyname(const char *host, int port)
-{
- static struct sockaddr_in sin;
-
- if (!inet_aton(host, &sin.sin_addr)) {
- struct hostent *hp;
- if (!(hp = gethostbyname(host))) {
- return NULL;
- }
- memset(&sin, 0, sizeof(struct sockaddr_in));
- memcpy(&sin.sin_addr.s_addr, hp->h_addr, hp->h_length);
- sin.sin_family = hp->h_addrtype;
- } else
- sin.sin_family = AF_INET;
- sin.sin_port = htons(port);
-
- return &sin;
-}
-
static gboolean gaim_io_connected(gpointer data, gint source, b_input_condition cond)
{
struct PHB *phb = data;
@@ -110,47 +89,71 @@
return FALSE;
}
-static int proxy_connect_none(const char *host, unsigned short port, struct PHB *phb)
+static int proxy_connect_none(const char *host, unsigned short port_, struct PHB *phb)
{
- struct sockaddr_in *sin;
struct sockaddr_in me;
int fd = -1;
+ int ret;
+ char port[6];
+ struct addrinfo hints;
+ struct addrinfo* result;
- if (!(sin = gaim_gethostbyname(host, port))) {
- g_free(phb);
- return -1;
- }
+ g_snprintf(port, sizeof(port), "%d", port_);
- if ((fd = socket(sin->sin_family, SOCK_STREAM, 0)) < 0) {
- g_free(phb);
- return -1;
- }
+ memset(&hints, 0, sizeof(struct addrinfo));
+ hints.ai_family = AF_UNSPEC;
+ hints.ai_socktype = SOCK_STREAM;
+ hints.ai_flags = AI_ADDRCONFIG | AI_NUMERICSERV;
- sock_make_nonblocking(fd);
+ if (!(ret = getaddrinfo(host, port, &hints, &result)))
+ {
+ struct addrinfo* rp;
+
+ for (rp = result; rp; rp = rp->ai_next)
+ {
+ if ((fd = socket(rp->ai_family, rp->ai_socktype, rp->ai_protocol)) < 0) {
+ event_debug( "socket failed: %d\n", errno);
+ continue;
+ }
+
+ sock_make_nonblocking(fd);
+
+ if (global.conf->iface_out)
+ {
+ me.sin_family = AF_INET;
+ me.sin_port = 0;
+ me.sin_addr.s_addr = inet_addr( global.conf->iface_out );
+
+ if (bind(fd, (struct sockaddr *) &me, sizeof(me)) != 0)
+ event_debug("bind( %d, \"%s\" ) failure\n", fd, global.conf->iface_out);
+ }
+
+ event_debug("proxy_connect_none( \"%s\", %d ) = %d\n", host, port, fd);
- if( global.conf->iface_out )
+ if (connect(fd, rp->ai_addr, rp->ai_addrlen) < 0 && !sockerr_again()) {
+ event_debug( "connect failed: %s\n", strerror(errno));
+ closesocket(fd);
+ fd = -1;
+ continue;
+ } else {
+ phb->inpa = b_input_add(fd, GAIM_INPUT_WRITE, gaim_io_connected, phb);
+ phb->fd = fd;
+
+ break;
+ }
+ }
+
+ freeaddrinfo(result);
+ }
+ else
{
- me.sin_family = AF_INET;
- me.sin_port = 0;
- me.sin_addr.s_addr = inet_addr( global.conf->iface_out );
-
- if( bind( fd, (struct sockaddr *) &me, sizeof( me ) ) != 0 )
- event_debug( "bind( %d, \"%s\" ) failure\n", fd, global.conf->iface_out );
+ event_debug("gai(): %s\n", gai_strerror(ret));
}
- event_debug("proxy_connect_none( \"%s\", %d ) = %d\n", host, port, fd);
-
- if (connect(fd, (struct sockaddr *)sin, sizeof(*sin)) < 0 && !sockerr_again()) {
- closesocket(fd);
+ if(fd < 0)
g_free(phb);
-
- return -1;
- } else {
- phb->inpa = b_input_add(fd, GAIM_INPUT_WRITE, gaim_io_connected, phb);
- phb->fd = fd;
-
- return fd;
- }
+
+ return fd;
}

View File

@ -1,56 +0,0 @@
$FreeBSD$
--- protocols/twitter/twitter_lib.c.orig
+++ protocols/twitter/twitter_lib.c
@@ -77,7 +77,8 @@
static void txs_free(struct twitter_xml_status *txs)
{
g_free(txs->text);
- txu_free(txs->user);
+ if(txs->user)
+ txu_free(txs->user);
g_free(txs);
}
@@ -472,19 +473,22 @@
for ( l = list; l ; l = g_slist_next(l) )
{
status = l->data;
- twitter_add_buddy(ic, status->user->screen_name, status->user->name);
-
- strip_html(status->text);
+ if(status->user)
+ {
+ twitter_add_buddy(ic, status->user->screen_name, status->user->name);
- // Say it!
- if (g_strcasecmp(td->user, status->user->screen_name) == 0)
- imcb_chat_log (gc, "Your Tweet: %s", status->text);
- else
- imcb_chat_msg (gc, status->user->screen_name, status->text, 0, status->created_at );
+ strip_html(status->text);
- // Update the home_timeline_id to hold the highest id, so that by the next request
- // we won't pick up the updates allready in the list.
- td->home_timeline_id = td->home_timeline_id < status->id ? status->id : td->home_timeline_id;
+ // Say it!
+ if (g_strcasecmp(td->user, status->user->screen_name) == 0)
+ imcb_chat_log (gc, "Your Tweet: %s", status->text);
+ else
+ imcb_chat_msg (gc, status->user->screen_name, status->text, 0, status->created_at );
+
+ // Update the home_timeline_id to hold the highest id, so that by the next request
+ // we won't pick up the updates allready in the list.
+ td->home_timeline_id = td->home_timeline_id < status->id ? status->id : td->home_timeline_id;
+ }
}
}
@@ -735,4 +739,4 @@
args[0] = "screen_name";
args[1] = who;
twitter_http(ic, create ? TWITTER_FRIENDSHIPS_CREATE_URL : TWITTER_FRIENDSHIPS_DESTROY_URL, twitter_http_post, ic, 1, args, 2);
-}
\ No newline at end of file
+}

View File

@ -1,17 +0,0 @@
#!/bin/sh -
#
# $FreeBSD$
#
BITLBEEUSER=%%BITLBEEUSER%%
BITLBEEGROUP=%%BITLBEEGROUP%%
if [ "$2" = "POST-DEINSTALL" ]; then
if /usr/sbin/pw group show "${BITLBEEGROUP}" 2>&1 >/dev/null; then
echo "You should manually remove the \"${BITLBEEGROUP}\" group."
fi
if /usr/sbin/pw user show "${BITLBEEUSER}" 2>&1 >/dev/null; then
echo "You should manually remove the \"${BITLBEEUSER}\" user."
fi
fi

View File

@ -1,74 +0,0 @@
#!/bin/sh -
#
# $FreeBSD$
#
BITLBEEDIR=%%BITLBEEDIR%%
BITLBEEUSER=%%BITLBEEUSER%%
BITLBEEGROUP=%%BITLBEEGROUP%%
BITLBEEUID=%%BITLBEEUID%%
BITLBEEGID=%%BITLBEEGID%%
ask() {
local question default answer
question=$1
default=$2
if [ -z "${PACKAGE_BUILDING}" ]; then
read -p "${question} [${default}]? " answer
fi
if [ "x${answer}" = "x" ]; then
answer=${default}
fi
echo ${answer}
}
yesno() {
local default question answer
question=$1
default=$2
while :; do
answer=$(ask "${question}" "${default}")
case "${answer}" in
[Yy][Ee][Ss]|[Yy])
return 0
;;
[Nn][Oo]|[Nn])
return 1
;;
esac
echo "Please answer yes or no."
done
}
if [ "$2" = "PRE-INSTALL" ]; then
if /usr/sbin/pw group show "${BITLBEEGROUP}" 2>&1 >/dev/null; then
echo "You already have a \"${BITLBEEGROUP}\" group, so I will use it."
else
echo "You need a \"${BITLBEEGROUP}\" group."
if yesno "Would you like me to create it" "YES"; then
/usr/sbin/pw groupadd "${BITLBEEGROUP}" -g "${BITLBEEGID}" -h - || \
/usr/sbin/pw groupadd "${BITLBEEGROUP}" -h - || exit
echo "Done."
else
echo "Please create the \"${BITLBEEGROUP}\" group manually and try again."
exit 1
fi
fi
if /usr/sbin/pw user show "${BITLBEEUSER}" 2>&1 >/dev/null; then
echo "You already have a \"${BITLBEEUSER}\" user, so I will use it."
else
echo "You need a \"${BITLBEEUSER}\" user."
if yesno "Would you like me to create it" "YES"; then
/usr/sbin/pw useradd "${BITLBEEUSER}" -u "${BITLBEEUID}" -g "${BITLBEEGROUP}" -h - -d "${BITLBEEDIR}" \
-s /sbin/nologin -c "Bitlbee pseudo-user" || \
/usr/sbin/pw useradd "${BITLBEEUSER}" -g "${BITLBEEGROUP}" -h - -d "${BITLBEEDIR}" \
-s /sbin/nologin -c "Bitlbee pseudo-user" || exit
else
echo "Please create the \"${BITLBEEUSER}\" user manually and try again."
exit 1
fi
fi
fi

View File

@ -1,23 +0,0 @@
/************************************************************************
To configure bitlbee, do the following:
Copy %%EXAMPLESDIR%%/bitlbee.conf
to %%PREFIX%%/etc/bitlbee/bitlbee.conf ,
Copy %%EXAMPLESDIR%%/motd.txt
to %%PREFIX%%/etc/bitlbee/motd.txt
and modify them to suit your needs.
You have two options for launching bitlbee: either launch it from
inetd(8) or run it as a stand-alone daemon (experimental).
To launch bitlbee from inetd(8), add the following line to
/etc/inetd.conf and reload inetd(8):
ircd stream tcp nowait %%BITLBEEUSER%% /usr/local/sbin/bitlbee bitlbee -I
To instead launch bitlbee as a daemon (experimental), add the
following line to /etc/rc.conf:
bitlbee_enable="YES"
*************************************************************************/

View File

@ -1,5 +0,0 @@
This is an otr-enabled branch of the mainline
BitlBee development version. This is not any
official bitlbee version.
WWW: http://www.khjk.org/bitlbee-otr/

View File

@ -1,8 +0,0 @@
sbin/bitlbee
share/bitlbee/help.txt
@dirrm share/bitlbee
@dirrmtry etc/bitlbee
@exec mkdir -p %D/etc/bitlbee
@exec mkdir -m 0700 -p /var/db/bitlbee
@exec chown -R %%BITLBEEUSER%%:%%BITLBEEGROUP%% /var/db/bitlbee
@unexec rmdir /var/db/bitlbee