diff options
author | Alin Năstac <mrness@gentoo.org> | 2009-09-25 01:17:26 +0000 |
---|---|---|
committer | Alin Năstac <mrness@gentoo.org> | 2009-09-25 01:17:26 +0000 |
commit | a11a3a10651e986547da52e2cf06564ce1d6ed14 (patch) | |
tree | 7120d6ea47c7698253726bff392628c97a110a1d /app-mobilephone/kannel-sqlbox | |
parent | old (diff) | |
download | gentoo-2-a11a3a10651e986547da52e2cf06564ce1d6ed14.tar.gz gentoo-2-a11a3a10651e986547da52e2cf06564ce1d6ed14.tar.bz2 gentoo-2-a11a3a10651e986547da52e2cf06564ce1d6ed14.zip |
Initial import from bug 285246.
(Portage version: 2.1.6.13/cvs/Linux x86_64)
Diffstat (limited to 'app-mobilephone/kannel-sqlbox')
6 files changed, 239 insertions, 0 deletions
diff --git a/app-mobilephone/kannel-sqlbox/ChangeLog b/app-mobilephone/kannel-sqlbox/ChangeLog new file mode 100644 index 000000000000..2177706c49b2 --- /dev/null +++ b/app-mobilephone/kannel-sqlbox/ChangeLog @@ -0,0 +1,13 @@ +# ChangeLog for app-mobilephone/kannel-sqlbox +# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/app-mobilephone/kannel-sqlbox/ChangeLog,v 1.1 2009/09/25 01:17:26 mrness Exp $ + +*kannel-sqlbox-0.7.2 (25 Sep 2009) + + 25 Sep 2009; Alin Năstac <mrness@gentoo.org> +kannel-sqlbox-0.7.2.ebuild, + +files/kannel-sqlbox-0.7.2-configure.patch, + +files/kannel-sqlbox-0.7.2-sqlinit-hfiles.patch, + +files/kannel-sqlbox.initd, +metadata.xml: + Initial import from bug 285246, thanks to Travis Hansen <travisghansen at + yahoo dot com>. + diff --git a/app-mobilephone/kannel-sqlbox/files/kannel-sqlbox-0.7.2-configure.patch b/app-mobilephone/kannel-sqlbox/files/kannel-sqlbox-0.7.2-configure.patch new file mode 100644 index 000000000000..2b0b5f9e6218 --- /dev/null +++ b/app-mobilephone/kannel-sqlbox/files/kannel-sqlbox-0.7.2-configure.patch @@ -0,0 +1,30 @@ +diff -Nru sqlbox-0.7.2.orig/configure.in sqlbox-0.7.2/configure.in +--- sqlbox-0.7.2.orig/configure.in 2009-05-19 17:08:35.000000000 +0200 ++++ sqlbox-0.7.2/configure.in 2009-09-23 00:22:05.000000000 +0200 +@@ -207,7 +207,7 @@ + then + AC_CHECK_PROG(JADE, openjade, openjade, no) + else +- JADE = $OLDJADE ++ JADE=$OLDJADE + fi + AC_CHECK_PROG(JADETEX, jadetex, jadetex, no) + AC_CHECK_PROG(PDFJADETEX, pdfjadetex, pdfjadetex, no) +@@ -402,7 +402,7 @@ + AC_MSG_RESULT($loc) + AC_CHECK_FILE("$loc/include/kannel/gw-config.h", + [CFLAGS="$CFLAGS -I$loc/include/kannel -I$loc/include/kannel"; +- LDFLAGS="$LDFLAGS -L$loc/lib/kannel -lwap -lgwlib"; ++ LIBS="$LIBS -L$loc/lib/kannel -lwap -lgwlib"; + found=1 + ]) + fi +@@ -417,7 +417,7 @@ + AC_MSG_RESULT([$gw_version]) + AC_MSG_CHECKING([Kannel libs]) + if ! $GW_CONFIG --libs &>/dev/null ; then +- LDFLAGS="$LDFLAGS `$GW_CONFIG --libs`" ++ LIBS="$LIBS `$GW_CONFIG --libs`" + gw_libdir=`$GW_CONFIG --libs` + AC_MSG_RESULT([$gw_libdir]) + fi diff --git a/app-mobilephone/kannel-sqlbox/files/kannel-sqlbox-0.7.2-sqlinit-hfiles.patch b/app-mobilephone/kannel-sqlbox/files/kannel-sqlbox-0.7.2-sqlinit-hfiles.patch new file mode 100644 index 000000000000..0a3fb9136709 --- /dev/null +++ b/app-mobilephone/kannel-sqlbox/files/kannel-sqlbox-0.7.2-sqlinit-hfiles.patch @@ -0,0 +1,84 @@ +diff -Naur sqlbox-0.7.2/gw/sqlbox_mssql.h sqlbox-0.7.2.new/gw/sqlbox_mssql.h +--- sqlbox-0.7.2/gw/sqlbox_mssql.h 2009-05-19 11:08:35.000000000 -0400 ++++ sqlbox-0.7.2.new/gw/sqlbox_mssql.h 2009-09-16 11:23:03.000000000 -0400 +@@ -46,7 +46,7 @@ + void sql_save_msg(Msg *msg, Octstr *momt /*, Octstr smsbox_id */); + Msg *mssql_fetch_msg(); + void sql_shutdown(); +-struct server_type *sql_init_mssql(Cfg *cfg); ++struct server_type *sqlbox_init_mssql(Cfg *cfg); + #ifndef sqlbox_mssql_c + extern + #endif +diff -Naur sqlbox-0.7.2/gw/sqlbox_mysql.h sqlbox-0.7.2.new/gw/sqlbox_mysql.h +--- sqlbox-0.7.2/gw/sqlbox_mysql.h 2009-05-19 11:08:35.000000000 -0400 ++++ sqlbox-0.7.2.new/gw/sqlbox_mysql.h 2009-09-16 11:23:03.000000000 -0400 +@@ -48,7 +48,7 @@ + void sql_save_msg(Msg *msg, Octstr *momt); + Msg *mysql_fetch_msg(); + void sql_shutdown(); +-struct server_type *sql_init_mysql(Cfg *cfg); ++struct server_type *sqlbox_init_mysql(Cfg *cfg); + #ifndef sqlbox_mysql_c + extern + #endif +diff -Naur sqlbox-0.7.2/gw/sqlbox_oracle.h sqlbox-0.7.2.new/gw/sqlbox_oracle.h +--- sqlbox-0.7.2/gw/sqlbox_oracle.h 2009-05-19 11:08:35.000000000 -0400 ++++ sqlbox-0.7.2.new/gw/sqlbox_oracle.h 2009-09-16 11:23:03.000000000 -0400 +@@ -52,7 +52,7 @@ + void sql_save_msg(Msg *msg, Octstr *momt /*, Octstr smsbox_id */); + Msg *oracle_fetch_msg(); + void sql_shutdown(); +-struct server_type *sql_init_oracle(Cfg *cfg); ++struct server_type *sqlbox_init_oracle(Cfg *cfg); + #ifndef sqlbox_oracle_c + extern + #endif +diff -Naur sqlbox-0.7.2/gw/sqlbox_pgsql.h sqlbox-0.7.2.new/gw/sqlbox_pgsql.h +--- sqlbox-0.7.2/gw/sqlbox_pgsql.h 2009-05-19 11:08:35.000000000 -0400 ++++ sqlbox-0.7.2.new/gw/sqlbox_pgsql.h 2009-09-16 11:23:03.000000000 -0400 +@@ -44,7 +44,7 @@ + void sql_save_msg(Msg *msg, Octstr *momt /*, Octstr smsbox_id */); + Msg *pgsql_fetch_msg(); + void sql_shutdown(); +-struct server_type *sql_init_pgsql(Cfg *cfg); ++struct server_type *sqlbox_init_pgsql(Cfg *cfg); + void sqlbox_configure_pgsql(Cfg* cfg); + #ifndef sqlbox_pgsql_c + extern +diff -Naur sqlbox-0.7.2/gw/sqlbox_sdb.h sqlbox-0.7.2.new/gw/sqlbox_sdb.h +--- sqlbox-0.7.2/gw/sqlbox_sdb.h 2009-05-19 11:08:35.000000000 -0400 ++++ sqlbox-0.7.2.new/gw/sqlbox_sdb.h 2009-09-16 11:23:03.000000000 -0400 +@@ -21,7 +21,7 @@ + void sql_save_msg(Msg *msg, Octstr *momt ); + Msg *sdb_fetch_msg(); + void sql_shutdown(); +-struct server_type *sql_init_sdb(Cfg *cfg); ++struct server_type *sqlbox_init_sdb(Cfg *cfg); + #ifndef sqlbox_sdb_c + extern + #endif +diff -Naur sqlbox-0.7.2/gw/sqlbox_sqlite3.h sqlbox-0.7.2.new/gw/sqlbox_sqlite3.h +--- sqlbox-0.7.2/gw/sqlbox_sqlite3.h 2009-05-19 11:08:35.000000000 -0400 ++++ sqlbox-0.7.2.new/gw/sqlbox_sqlite3.h 2009-09-16 11:23:03.000000000 -0400 +@@ -41,7 +41,7 @@ + void sql_save_msg(Msg *msg, Octstr *momt ); + Msg *sqlite3_fetch_msg(); + void sql_shutdown(); +-struct server_type *sql_init_sqlite3(Cfg *cfg); ++struct server_type *sqlbox_init_sqlite3(Cfg *cfg); + #ifndef sqlbox_sqlite3_c + extern + #endif +diff -Naur sqlbox-0.7.2/gw/sqlbox_sqlite.h sqlbox-0.7.2.new/gw/sqlbox_sqlite.h +--- sqlbox-0.7.2/gw/sqlbox_sqlite.h 2009-05-19 11:08:35.000000000 -0400 ++++ sqlbox-0.7.2.new/gw/sqlbox_sqlite.h 2009-09-16 11:23:03.000000000 -0400 +@@ -41,7 +41,7 @@ + void sql_save_msg(Msg *msg, Octstr *momt ); + Msg *sqlite_fetch_msg(); + void sql_shutdown(); +-struct server_type *sql_init_sqlite(Cfg *cfg); ++struct server_type *sqlbox_init_sqlite(Cfg *cfg); + #ifndef sqlbox_sqlite_c + extern + #endif
\ No newline at end of file diff --git a/app-mobilephone/kannel-sqlbox/files/kannel-sqlbox.initd b/app-mobilephone/kannel-sqlbox/files/kannel-sqlbox.initd new file mode 100644 index 000000000000..0c24fc5c1716 --- /dev/null +++ b/app-mobilephone/kannel-sqlbox/files/kannel-sqlbox.initd @@ -0,0 +1,34 @@ +#!/sbin/runscript +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/app-mobilephone/kannel-sqlbox/files/kannel-sqlbox.initd,v 1.1 2009/09/25 01:17:26 mrness Exp $ + +KANNEL_SERVICE=${SVCNAME#*-} + +depend() { + need kannel-bearerbox + before kannel-smsbox +} + +checkconfig() { + if [ ! -f /etc/kannel/kannel.conf ] ; then + eerror "/etc/kannel/kannel.conf file doesn't exists!" + return 1 + fi +} + +start() { + checkconfig || return 1 + + ebegin "Starting kannel ${KANNEL_SERVICE}" + start-stop-daemon --start --quiet --exec /usr/sbin/${KANNEL_SERVICE} -- \ + --daemonize --user kannel --logfile /var/log/kannel/${KANNEL_SERVICE}.log \ + --pid-file /var/run/kannel/${KANNEL_SERVICE}.pid /etc/kannel/sqlbox.conf + eend $? +} + +stop() { + ebegin "Stopping kannel ${KANNEL_SERVICE}" + start-stop-daemon --stop --verbose --pidfile /var/run/kannel/${KANNEL_SERVICE}.pid + eend $? +} diff --git a/app-mobilephone/kannel-sqlbox/kannel-sqlbox-0.7.2.ebuild b/app-mobilephone/kannel-sqlbox/kannel-sqlbox-0.7.2.ebuild new file mode 100644 index 000000000000..313658db2151 --- /dev/null +++ b/app-mobilephone/kannel-sqlbox/kannel-sqlbox-0.7.2.ebuild @@ -0,0 +1,71 @@ +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/app-mobilephone/kannel-sqlbox/kannel-sqlbox-0.7.2.ebuild,v 1.1 2009/09/25 01:17:26 mrness Exp $ + +EAPI="2" + +inherit eutils autotools + +DESCRIPTION="DB-Based Kannel Box for message queueing" +HOMEPAGE="http://www.kannel.org/~aguerrieri/SqlBox/" +SRC_URI="http://www.kannel.org/~aguerrieri/SqlBox/Releases/sqlbox-${PV}.tar.gz" + +LICENSE="Kannel" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="ssl doc" + +RDEPEND=">=app-mobilephone/kannel-1.4.3-r1 + ssl? ( dev-libs/openssl )" +DEPEND="${RDEPEND} + doc? ( media-gfx/transfig + app-text/jadetex + app-text/docbook-dsssl-stylesheets + app-text/docbook-sgml-dtd:3.1 )" + +S="${WORKDIR}/sqlbox-${PV}" + +src_prepare() { + epatch "${FILESDIR}"/${P}-sqlinit-hfiles.patch + epatch "${FILESDIR}"/${P}-configure.patch + + # This package doesn't contain configure script, only configure.in + eautoreconf +} + +src_configure() { + econf --docdir=/usr/share/doc/${PF} \ + --without-ctlib \ + --without-mssql \ + $(use_enable ssl) \ + $(use_enable doc docs) \ + || die "econf failed" +} + +src_install() { + emake DESTDIR="${D}" install || die "failed emake install" + + if use doc; then + emake doc/userguide.html || die "emake docs failed" + dohtml doc/userguide.html || die "userguide.html not found" + fi + + newinitd "${FILESDIR}"/kannel-sqlbox.initd kannel-sqlbox + + dodoc AUTHORS ChangeLog NEWS README + insinto /etc/kannel + newins example/sqlbox.conf.example sqlbox.conf.sample +} + +pkg_postinst() { + elog "Please view the following page for config information:" + elog "http://www.kannel.org/pipermail/users/2006-October/000859.html" + elog "" + elog "In essence you need to do 3 things" + elog "1. Create the database (tables will be automatically created by kannel)" + elog "2. Point sqlbox to the smsbox-port in kannel [core] group" + elog "3. Point smsbox to smsbox-port in sqlbox [sqlbox] group" + elog "" + elog "This literally puts sqlbox in between the bearerbox and smsbox" + elog "for data storage into a database" +} diff --git a/app-mobilephone/kannel-sqlbox/metadata.xml b/app-mobilephone/kannel-sqlbox/metadata.xml new file mode 100644 index 000000000000..68a46ed35b66 --- /dev/null +++ b/app-mobilephone/kannel-sqlbox/metadata.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<herd>mobile-phone</herd> +<longdescription>Sqlbox is a special Kannel box that sits between bearerbox and +smsbox and uses a database queue to store and forward messages.</longdescription> +</pkgmetadata> |