From d6727abf63b361105454ccc5ef66f30ba3f73658 Mon Sep 17 00:00:00 2001 From: geos_one Date: Mon, 11 Oct 2010 20:17:05 +0000 Subject: [PATCH] add zarafa git-svn-id: https://svn.disconnected-by-peer.at/svn/linamh/trunk/mds@2511 6952d904-891a-0410-993b-d76249ca496b --- www-apps/zarafa/Manifest | 17 +++ .../files/50_zarafa-webaccess-mobile.conf | 12 ++ .../zarafa/files/50_zarafa-webaccess.conf | 12 ++ .../zarafa/files/patches/fix-pthread.patch | 44 +++++++ .../fix-zarafaserver-uuid-linkage.patch | 26 ++++ .../fix-zarafastats-uuid-linkage.patch | 24 ++++ .../files/patches/zarafa-6.40.0-package.patch | 61 ++++++++++ .../zarafa-6.40.2-libtcmalloc_shared-1.patch | 19 +++ www-apps/zarafa/files/zarafa-gateway.rc6 | 30 +++++ www-apps/zarafa/files/zarafa-ical.rc6 | 30 +++++ www-apps/zarafa/files/zarafa-indexer.rc6 | 31 +++++ www-apps/zarafa/files/zarafa-licensed.rc6 | 30 +++++ www-apps/zarafa/files/zarafa-monitor.rc6 | 30 +++++ www-apps/zarafa/files/zarafa-server.rc6 | 31 +++++ www-apps/zarafa/files/zarafa-spooler.rc6 | 30 +++++ www-apps/zarafa/files/zarafa.logrotate | 101 ++++++++++++++++ www-apps/zarafa/zarafa-6.40.2.ebuild | 111 ++++++++++++++++++ 17 files changed, 639 insertions(+) create mode 100644 www-apps/zarafa/Manifest create mode 100644 www-apps/zarafa/files/50_zarafa-webaccess-mobile.conf create mode 100644 www-apps/zarafa/files/50_zarafa-webaccess.conf create mode 100644 www-apps/zarafa/files/patches/fix-pthread.patch create mode 100644 www-apps/zarafa/files/patches/fix-zarafaserver-uuid-linkage.patch create mode 100644 www-apps/zarafa/files/patches/fix-zarafastats-uuid-linkage.patch create mode 100644 www-apps/zarafa/files/patches/zarafa-6.40.0-package.patch create mode 100644 www-apps/zarafa/files/patches/zarafa-6.40.2-libtcmalloc_shared-1.patch create mode 100644 www-apps/zarafa/files/zarafa-gateway.rc6 create mode 100644 www-apps/zarafa/files/zarafa-ical.rc6 create mode 100644 www-apps/zarafa/files/zarafa-indexer.rc6 create mode 100644 www-apps/zarafa/files/zarafa-licensed.rc6 create mode 100644 www-apps/zarafa/files/zarafa-monitor.rc6 create mode 100644 www-apps/zarafa/files/zarafa-server.rc6 create mode 100644 www-apps/zarafa/files/zarafa-spooler.rc6 create mode 100644 www-apps/zarafa/files/zarafa.logrotate create mode 100644 www-apps/zarafa/zarafa-6.40.2.ebuild diff --git a/www-apps/zarafa/Manifest b/www-apps/zarafa/Manifest new file mode 100644 index 0000000..1b20a38 --- /dev/null +++ b/www-apps/zarafa/Manifest @@ -0,0 +1,17 @@ +AUX 50_zarafa-webaccess-mobile.conf 298 RMD160 06cc5aed60486f78327aa20c0d03fd7ab10b52be SHA1 bef2feeb930d36403a48545045969b2556513dee SHA256 7019d90fae91e2efb54c2b002ff3ee40de5a684686a74753385514b6abbe8581 +AUX 50_zarafa-webaccess.conf 270 RMD160 226eb8c9661ff57347e2f917223a7823e666324a SHA1 fbd9efab7f9a1f85e55df142c0d553317eab1436 SHA256 ddf11e70107c2d6eaf40ba8253e2118822ee66eddaf471afebca248ba71e85a6 +AUX patches/fix-pthread.patch 1779 RMD160 48976038f579e5472395efdcec860b131e6be6da SHA1 ae10a342780d7699c30fb64d43f6c5c7795d89ab SHA256 8bfd5987ff8bf4d754b1ff69aa491ac56b3f12dafa3354566218c3f573f15160 +AUX patches/fix-zarafaserver-uuid-linkage.patch 1394 RMD160 f88c3d41e5af48713d5ba5a4f9a9add75724bb45 SHA1 59aadb0eb993c7a552018c37e715bee7caaa1a12 SHA256 c452efb1f6b4deec5f32471b3998d6b9a40a2eacba959b76b3abae7d82e80e22 +AUX patches/fix-zarafastats-uuid-linkage.patch 1051 RMD160 9713fa23bd16cb69111ecb39f840f8b7026d8f21 SHA1 ca04f80dce737ad10821c2e1bb84cd8f4ea5b9c5 SHA256 a1c0febb372dba9241cd87eded9d0e5940748cf01285a8eee0e43fa38a63fc03 +AUX patches/zarafa-6.40.0-package.patch 1938 RMD160 48ec724a787bd2b4db3b81b763fc1726a55eec3b SHA1 30aee89b4d186d2371568911ccfa245f1e39b4b7 SHA256 546ae930ee2f167987f336d873e68110394dad7573d9397c39f5c10166aa8eab +AUX patches/zarafa-6.40.2-libtcmalloc_shared-1.patch 857 RMD160 7112bfd1b5c1bf628f33521138d76ebdc9e8fa84 SHA1 638f39aa252c644362952becd5eb28fe06db8743 SHA256 c66f888d89a07c2c962f60aae81dee5b97cc2f0c0d4b5f725309f9f7509bea55 +AUX zarafa-gateway.rc6 747 RMD160 c6094f036814bb289eade6f309b9c48ed6b683d5 SHA1 6182824447f9373badf2b2536d41190451fbceb0 SHA256 d08eb9eb5e548dca24e644aee4196aa135ef79d74d244675eeb9ea47594311b0 +AUX zarafa-ical.rc6 663 RMD160 db306a10e7777889e9460488575cbdd1ddc9037e SHA1 8fa807d0da22ab4fc1f3156c3a7dc0fe3cdab1ad SHA256 1eec0c538a0264eb2757b5687c8285394f899740bc4cba913115f82ccab703e2 +AUX zarafa-indexer.rc6 720 RMD160 93d56a3be2c13e98a4aed6b6cc930a500d297d37 SHA1 7626c82c7f76163ba440c893ef84748d128e46c4 SHA256 39db611a8f3f0952dfb72b00b77bd3dbe760d99c21551e5a6769c7011722ae5a +AUX zarafa-licensed.rc6 719 RMD160 8c52c285698bdf307335fbd34b3cf745c4aa5f59 SHA1 ac6933fa631b57f81526a6da4242c5525f7d4882 SHA256 84d511f27ed2a024d670ce042359dc9489ce4041ca447fe98e006bd53345c25f +AUX zarafa-monitor.rc6 705 RMD160 d1e524b7ed48ec5b53594595a35d4fb3c02b1a5a SHA1 d9cbd4df039ae95048bc53edcd4c1968166fdde4 SHA256 6d7cc1b2f0c7049f28dccf0d65530f1075e932898ab9b7d68cd73ffc2e4dd6e9 +AUX zarafa-server.rc6 706 RMD160 d3734a455367d93d316fca873e79467f624b97a2 SHA1 e819806ba99c5b5d4c195cfbace7b4027b053976 SHA256 5a8553127bc529350cf56ea35b558e1d276ca0d4bde92a32583d62d0d790fa4f +AUX zarafa-spooler.rc6 705 RMD160 a2981b8e9b60df19d5adce5507ec51ac6d5b12e8 SHA1 09527095beb3891986656cb0e1c53414b7f038bf SHA256 4cf183daf6d86e2bb39073993af8f244bc28ee90feb4cf1ba34e5302894aa2fe +AUX zarafa.logrotate 1857 RMD160 d295f5307be6577d3f8fdc89edc7995adae2fd47 SHA1 7188133da91ad6d453811ff5e67d84fde49b4fb9 SHA256 44e26d9ad5eff2e159388698a068df72d9626d91e9be478be00b3e3eaa15913f +DIST zarafa-6.40.2.tar.gz 4605538 RMD160 9da243c0d7f5b9e86a5606482a1728b1056dde89 SHA1 3554a6f6cc2f32ee30f628598eb2d5de09fe5f1d SHA256 3ad4598cc6943e7e99d3d8340916dc425db1c54ed76c66a309183cb53b838350 +EBUILD zarafa-6.40.2.ebuild 3044 RMD160 adbd3ffb4adc061a2cf973a26ade748ce49ab52b SHA1 ff00058650f6495f4d1ed7f90178d21d7f93b007 SHA256 280d11ba32bfe3c238f0be40885ff737009b96a0e9df00ef2810f1d42ef57374 diff --git a/www-apps/zarafa/files/50_zarafa-webaccess-mobile.conf b/www-apps/zarafa/files/50_zarafa-webaccess-mobile.conf new file mode 100644 index 0000000..cf63fef --- /dev/null +++ b/www-apps/zarafa/files/50_zarafa-webaccess-mobile.conf @@ -0,0 +1,12 @@ + + Alias /webaccess-mobile /usr/share/zarafa-webaccess-mobile + + + DirectoryIndex index.php + Options -Indexes +FollowSymLinks + AllowOverride Options + + Order allow,deny + Allow from all + + diff --git a/www-apps/zarafa/files/50_zarafa-webaccess.conf b/www-apps/zarafa/files/50_zarafa-webaccess.conf new file mode 100644 index 0000000..b96147d --- /dev/null +++ b/www-apps/zarafa/files/50_zarafa-webaccess.conf @@ -0,0 +1,12 @@ + + Alias /webaccess /usr/share/zarafa-webaccess + + + DirectoryIndex index.php + Options -Indexes +FollowSymLinks + AllowOverride Options + + Order allow,deny + Allow from all + + diff --git a/www-apps/zarafa/files/patches/fix-pthread.patch b/www-apps/zarafa/files/patches/fix-pthread.patch new file mode 100644 index 0000000..515a366 --- /dev/null +++ b/www-apps/zarafa/files/patches/fix-pthread.patch @@ -0,0 +1,44 @@ +Index: zarafa-6.40.2/configure.ac +=================================================================== +--- zarafa-6.40.2.orig/configure.ac ++++ zarafa-6.40.2/configure.ac +@@ -405,7 +405,7 @@ if test "x$CLUCENE_INCLUDE_PREFIX" != "x + CPPFLAGS="$CPPFLAGS -I$CLUCENE_INCLUDE_PREFIX" + fi + # force add pthread in lucene test +-CXXFLAGS="$CXXFLAGS -pthread" ++CXXFLAGS="$CXXFLAGS -lpthread" + if test -e "${CLUCENE_LIB_PREFIX}/libclucene.a"; then + AC_CHECK_LIB(clucene, [open], + [ CLUCENE_LIBS="${CLUCENE_LIB_PREFIX}/libclucene.a" +@@ -555,7 +555,7 @@ libs_keep=$LIBS + AC_CHECK_LIB([pthread], [pthread_create],, AC_MSG_ERROR([required library libpthread missing or unusable])) + LIBS=$libs_keep + # because it seems this is better... (gnu c/c++ only?) +-CXXFLAGS="$CXXFLAGS -pthread" ++CXXFLAGS="$CXXFLAGS -lpthread" + + # Only specific links with uuid and dl, clients only with crypto and ssl for ssl connections + libs_keep=$LIBS +Index: zarafa-6.40.2/ltmain.sh +=================================================================== +--- zarafa-6.40.2.orig/ltmain.sh ++++ zarafa-6.40.2/ltmain.sh +@@ -1647,7 +1647,7 @@ EOF + continue + ;; + +- -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads) ++ -mt|-mthreads|-kthread|-Kthread|-lpthread|-pthreads|--thread-safe|-threads) + compiler_flags="$compiler_flags $arg" + compile_command="$compile_command $arg" + finalize_command="$finalize_command $arg" +@@ -2150,7 +2150,7 @@ EOF + lib= + found=no + case $deplib in +- -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads) ++ -mt|-mthreads|-kthread|-Kthread|-lpthread|-pthreads|--thread-safe|-threads) + if test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" diff --git a/www-apps/zarafa/files/patches/fix-zarafaserver-uuid-linkage.patch b/www-apps/zarafa/files/patches/fix-zarafaserver-uuid-linkage.patch new file mode 100644 index 0000000..610b74d --- /dev/null +++ b/www-apps/zarafa/files/patches/fix-zarafaserver-uuid-linkage.patch @@ -0,0 +1,26 @@ +Index: zarafa-6.40.0/provider/server/Makefile.in +=================================================================== +--- zarafa-6.40.0.orig/provider/server/Makefile.in ++++ zarafa-6.40.0/provider/server/Makefile.in +@@ -274,7 +274,7 @@ zarafa_server_LDADD = $(UUID_LIBS) $(INT + ${top_builddir}/common/libcommon_util.la \ + ${top_builddir}/common/libcommon_mapi.la \ + ${top_builddir}/common/libcommon_ssl.la \ +- $(MYSQL_LIBS) $(SSL_LIBS) $(PAM_LIBS) $(KRB5_LIBS) $(TCMALLOC_LIBS) -lrt ++ $(MYSQL_LIBS) $(UUID_LIBS) $(SSL_LIBS) $(PAM_LIBS) $(KRB5_LIBS) $(TCMALLOC_LIBS) -lrt + + zarafa_server_SOURCES = ECServer.cpp \ + ECSoapServerConnection.h ECSoapServerConnection.cpp \ +Index: zarafa-6.40.0/provider/server/Makefile.am +=================================================================== +--- zarafa-6.40.0.orig/provider/server/Makefile.am ++++ zarafa-6.40.0/provider/server/Makefile.am +@@ -18,7 +18,7 @@ zarafa_server_LDADD = $(UUID_LIBS) $(INT + ${top_builddir}/common/libcommon_util.la \ + ${top_builddir}/common/libcommon_mapi.la \ + ${top_builddir}/common/libcommon_ssl.la \ +- $(MYSQL_LIBS) $(SSL_LIBS) $(PAM_LIBS) $(KRB5_LIBS) $(TCMALLOC_LIBS) -lrt ++ $(MYSQL_LIBS) $(UUID_LIBS) $(SSL_LIBS) $(PAM_LIBS) $(KRB5_LIBS) $(TCMALLOC_LIBS) -lrt + + zarafa_server_SOURCES = ECServer.cpp \ + ECSoapServerConnection.h ECSoapServerConnection.cpp \ diff --git a/www-apps/zarafa/files/patches/fix-zarafastats-uuid-linkage.patch b/www-apps/zarafa/files/patches/fix-zarafastats-uuid-linkage.patch new file mode 100644 index 0000000..05e1406 --- /dev/null +++ b/www-apps/zarafa/files/patches/fix-zarafastats-uuid-linkage.patch @@ -0,0 +1,24 @@ +diff -Nuar zarafa-6.40.0.orig/ECtools/zarafa-stats/Makefile.am zarafa-6.40.0/ECtools/zarafa-stats/Makefile.am +--- zarafa-6.40.0.orig/ECtools/zarafa-stats/Makefile.am 2010-04-26 11:37:49.561680215 +0300 ++++ zarafa-6.40.0/ECtools/zarafa-stats/Makefile.am 2010-04-26 11:38:31.435806562 +0300 +@@ -13,7 +13,7 @@ + ${top_builddir}/mapi4linux/src/libmapi.la \ + ${top_builddir}/common/libcommon_mapi.la \ + ${top_builddir}/common/libcommon_util.la \ +- -lncurses ++ -lncurses -luuid + + zarafa_stats_SOURCES = zarafa-stats.cpp + +diff -Nuar zarafa-6.40.0.orig/ECtools/zarafa-stats/Makefile.in zarafa-6.40.0/ECtools/zarafa-stats/Makefile.in +--- zarafa-6.40.0.orig/ECtools/zarafa-stats/Makefile.in 2010-04-26 11:37:49.561680215 +0300 ++++ zarafa-6.40.0/ECtools/zarafa-stats/Makefile.in 2010-04-26 11:38:22.475687815 +0300 +@@ -250,7 +250,7 @@ + ${top_builddir}/mapi4linux/src/libmapi.la \ + ${top_builddir}/common/libcommon_mapi.la \ + ${top_builddir}/common/libcommon_util.la \ +- -lncurses ++ -lncurses -luuid + + zarafa_stats_SOURCES = zarafa-stats.cpp + all: all-am diff --git a/www-apps/zarafa/files/patches/zarafa-6.40.0-package.patch b/www-apps/zarafa/files/patches/zarafa-6.40.0-package.patch new file mode 100644 index 0000000..1a4877e --- /dev/null +++ b/www-apps/zarafa/files/patches/zarafa-6.40.0-package.patch @@ -0,0 +1,61 @@ +Patch by Robert Scheck for zarafa >= 6.40.0, which only +removes the paths from autoconf/automake related files, that don't exist in the OSS +version of Zarafa. Having these paths not removed causes autoreconf to fail, but a +re-run of autoreconf is needed in order to get the rpaths completely out of all the +libraries and binaries built during the make process. + +--- zarafa-6.40.0/configure.ac 2010-05-31 15:45:19.000000000 +0200 ++++ zarafa-6.40.0/configure.ac.package 2010-06-06 02:48:22.000000000 +0200 +@@ -772,19 +772,6 @@ + version + specialbuild + ]) +-dnl non-oss files +-if test -d `dirname $0`/licensed; then +-AC_CONFIG_FILES([ +- liblicense/Makefile +- licensed/Makefile +- ECtools/zarafa-backup/Makefile +- ECtools/zarafa-backup/helpers/Makefile +- ECtools/zarafa-report/Makefile +- ECtools/libarchiver/Makefile +- ECtools/zarafa-archiver/Makefile +- debian/zarafa.install +-]) +-fi + + AC_OUTPUT + +--- zarafa-6.40.0/Makefile.am 2010-05-31 15:45:19.000000000 +0200 ++++ zarafa-6.40.0/Makefile.am.package 2010-06-06 02:51:29.000000000 +0200 +@@ -1,9 +1,5 @@ + AUTOMAKE_OPTIONS = 1.9 foreign + +-if ! OSS_ONLY +-PROSUBS = liblicense licensed +-endif +- + SUBDIRS = common libfreebusy zarafa-libsync mapi4linux $(PROSUBS) provider libicalmapi inetmapi php-ext spooler gateway caldav ECtools installer po doc + + if WITH_PERL +@@ -17,10 +13,6 @@ + common/ecversion.h: versionheader.sh + sh ${top_srcdir}/versionheader.sh > common/ecversion.h + +-if ! OSS_ONLY +-CLEANFILES=common/ecversion.h +-endif +- + dist-hook: + find $(distdir) -type d -name .svn -exec rm -rf {} \; 2>/dev/null || true + if OSS_ONLY +--- zarafa-6.40.0/ECtools/Makefile.am 2010-05-31 15:45:18.000000000 +0200 ++++ zarafa-6.40.0/ECtools/Makefile.am.package 2010-06-06 02:48:37.000000000 +0200 +@@ -1,7 +1,3 @@ +-if ! OSS_ONLY +-PROSUBS = zarafa-backup zarafa-report libarchiver zarafa-archiver +-endif +- + if WITH_TESTTOOLS + TESTSUBS = ECTestTools + endif diff --git a/www-apps/zarafa/files/patches/zarafa-6.40.2-libtcmalloc_shared-1.patch b/www-apps/zarafa/files/patches/zarafa-6.40.2-libtcmalloc_shared-1.patch new file mode 100644 index 0000000..28dcc78 --- /dev/null +++ b/www-apps/zarafa/files/patches/zarafa-6.40.2-libtcmalloc_shared-1.patch @@ -0,0 +1,19 @@ +Submitted By: Your Name (your at email dot address) +Date: 2010-10-11 +Initial Package Version: 6.40.2 +Origin: me +Upstream Status: unknown +Description: on gentoo libtcmalloc_minimal is only provided as shared lib + +diff -Naur zarafa-6.40.2.orig/configure.ac zarafa-6.40.2/configure.ac +--- zarafa-6.40.2.orig/configure.ac 2010-10-11 18:39:35.000000000 +0000 ++++ zarafa-6.40.2/configure.ac 2010-10-11 18:40:03.000000000 +0000 +@@ -441,7 +441,7 @@ + AC_HELP_STRING([--with-tcmalloc-prefix=PATH],[path to tcmalloc lib, e.g. /usr/lib/]), + [TCMALLOC_PREFIX=${withval}],[TCMALLOC_PREFIX=/usr/lib]) + AC_CHECK_LIB(tcmalloc_minimal, [open], +- [ TCMALLOC_LIBS="${TCMALLOC_PREFIX}/libtcmalloc_minimal.a" ], ++ [ TCMALLOC_LIBS="${TCMALLOC_PREFIX}/libtcmalloc_minimal.so" ], + [ WITH_TCMALLOC=no ]) + AC_SUBST(TCMALLOC_LIBS) + AC_LANG_POP diff --git a/www-apps/zarafa/files/zarafa-gateway.rc6 b/www-apps/zarafa/files/zarafa-gateway.rc6 new file mode 100644 index 0000000..9399ae7 --- /dev/null +++ b/www-apps/zarafa/files/zarafa-gateway.rc6 @@ -0,0 +1,30 @@ +#!/sbin/runscript +# Copyright 1999-2008 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +GATEWAYCONFIG=/etc/zarafa/gateway.cfg +GATEWAYPROGRAM=/usr/bin/zarafa-gateway + +[ -x $GATEWAYPROGRAM ] || exit 0 + +GATEWAYCONFIG_OPT="" +[ ! -z $GATEWAYCONFIG -a -f $GATEWAYCONFIG ] && GATEWAYCONFIG_OPT="-c $GATEWAYCONFIG" + +PIDFILE=/var/run/"${SVCNAME}".pid + +start() { + ebegin "Starting ${SVCNAME}" + start-stop-daemon --start \ + --pidfile ${PIDFILE} \ + --exec ${GATEWAYPROGRAM} -- ${GATEWAYCONFIG_OPT} + eend $? +} + +stop() { + ebegin "Stopping ${SVCNAME}" + start-stop-daemon --stop \ + --pidfile ${PIDFILE} \ + --exec ${GATEWAYPROGRAM} -- ${GATEWAYCONFIG_OPT} + eend $? +} diff --git a/www-apps/zarafa/files/zarafa-ical.rc6 b/www-apps/zarafa/files/zarafa-ical.rc6 new file mode 100644 index 0000000..fec3b5c --- /dev/null +++ b/www-apps/zarafa/files/zarafa-ical.rc6 @@ -0,0 +1,30 @@ +#!/sbin/runscript +# Copyright 1999-2008 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +ICALCONFIG=/etc/zarafa/ical.cfg +ICALPROGRAM=/usr/bin/zarafa-ical + +[ -x $ICALPROGRAM ] || exit 0 + +ICALCONFIG_OPT="" +[ ! -z $ICALCONFIG -a -f $ICALCONFIG ] && ICALCONFIG_OPT="-c $ICALCONFIG" + +PIDFILE=/var/run/"${SVCNAME}".pid + +start() { + ebegin "Starting ${SVCNAME}" + start-stop-daemon --start \ + --pidfile ${PIDFILE} \ + --exec ${ICALPROGRAM} -- ${ICALCONFIG_OPT} + eend $? +} + +stop() { + ebegin "Stopping ${SVCNAME}" + start-stop-daemon --stop \ + --pidfile ${PIDFILE} \ + --exec ${ICALPROGRAM} -- ${ICALCONFIG_OPT} + eend $? +} diff --git a/www-apps/zarafa/files/zarafa-indexer.rc6 b/www-apps/zarafa/files/zarafa-indexer.rc6 new file mode 100644 index 0000000..ea89f4b --- /dev/null +++ b/www-apps/zarafa/files/zarafa-indexer.rc6 @@ -0,0 +1,31 @@ +#!/sbin/runscript +# Copyright 1999-2008 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +INDEXERCONFIG=/etc/zarafa/indexer.cfg +INDEXERPROGRAM=/usr/bin/zarafa-indexer + +[ -x $INDEXERPROGRAM ] || exit 0 + +INDEXERCONFIG_OPT="" +[ ! -z $INDEXERCONFIG -a -f $INDEXERCONFIG ] && INDEXERCONFIG_OPT="-c $INDEXERCONFIG" + +PIDFILE=/var/run/"${SVCNAME}".pid + +start() { + ebegin "Starting ${SVCNAME}" + start-stop-daemon --start \ + --pidfile ${PIDFILE} \ + --exec ${INDEXERPROGRAM} -- ${INDEXERCONFIG_OPT} + eend $? +} + +stop() { + ebegin "Stopping ${SVCNAME}" + start-stop-daemon --stop \ + --pidfile ${PIDFILE} \ + --retry 65 \ + --exec ${INDEXERPROGRAM} -- ${INDEXERCONFIG_OPT} + eend $? +} diff --git a/www-apps/zarafa/files/zarafa-licensed.rc6 b/www-apps/zarafa/files/zarafa-licensed.rc6 new file mode 100644 index 0000000..b15e8d5 --- /dev/null +++ b/www-apps/zarafa/files/zarafa-licensed.rc6 @@ -0,0 +1,30 @@ +#!/sbin/runscript +# Copyright 1999-2008 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +LICENSEDCONFIG=/etc/zarafa/licensed.cfg +LICENSEDPROGRAM=/usr/bin/zarafa-licensed + +[ -x $LICENSEDPROGRAM ] || exit 0 + +LICENSEDCONFIG_OPT="" +[ ! -z $LICENSEDCONFIG -a -f $LICENSEDCONFIG ] && LICENSEDCONFIG_OPT="-c $LICENSEDCONFIG" + +PIDFILE=/var/run/"${SVCNAME}".pid + +start() { + ebegin "Starting ${SVCNAME}" + start-stop-daemon --start \ + --pidfile ${PIDFILE} \ + --exec ${LICENSEDPROGRAM} -- ${LICENSEDCONFIG_OPT} + eend $? +} + +stop() { + ebegin "Stopping ${SVCNAME}" + start-stop-daemon --stop \ + --pidfile ${PIDFILE} \ + --exec ${LICENSEDPROGRAM} -- ${LICENSEDCONFIG_OPT} + eend $? +} diff --git a/www-apps/zarafa/files/zarafa-monitor.rc6 b/www-apps/zarafa/files/zarafa-monitor.rc6 new file mode 100644 index 0000000..0b9b790 --- /dev/null +++ b/www-apps/zarafa/files/zarafa-monitor.rc6 @@ -0,0 +1,30 @@ +#!/sbin/runscript +# Copyright 1999-2008 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +MONITORCONFIG=/etc/zarafa/monitor.cfg +MONITORPROGRAM=/usr/bin/zarafa-monitor + +[ -x $MONITORPROGRAM ] || exit 0 + +MONITORCONFIG_OPT="" +[ ! -z $MONITORCONFIG -a -f $MONITORCONFIG ] && MONITORCONFIG_OPT="-c $MONITORCONFIG" + +PIDFILE=/var/run/"${SVCNAME}".pid + +start() { + ebegin "Starting ${SVCNAME}" + start-stop-daemon --start \ + --pidfile ${PIDFILE} \ + --exec ${MONITORPROGRAM} -- ${MONITORCONFIG_OPT} + eend $? +} + +stop() { + ebegin "Stopping ${SVCNAME}" + start-stop-daemon --stop \ + --pidfile ${PIDFILE} \ + --exec ${MONITORPROGRAM} -- ${MONITORCONFIG_OPT} + eend $? +} diff --git a/www-apps/zarafa/files/zarafa-server.rc6 b/www-apps/zarafa/files/zarafa-server.rc6 new file mode 100644 index 0000000..2ae2da8 --- /dev/null +++ b/www-apps/zarafa/files/zarafa-server.rc6 @@ -0,0 +1,31 @@ +#!/sbin/runscript +# Copyright 1999-2008 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +SERVERCONFIG=/etc/zarafa/server.cfg +SERVERPROGRAM=/usr/bin/zarafa-server + +[ -x $SERVERPROGRAM ] || exit 0 + +SERVERCONFIG_OPT="" +[ ! -z $SERVERCONFIG -a -f $SERVERCONFIG ] && SERVERCONFIG_OPT="-c $SERVERCONFIG" + +PIDFILE=/var/run/"${SVCNAME}".pid + +start() { + ebegin "Starting ${SVCNAME}" + start-stop-daemon --start \ + --pidfile ${PIDFILE} \ + --exec ${SERVERPROGRAM} -- ${SERVERCONFIG_OPT} + eend $? +} + +stop() { + ebegin "Stopping ${SVCNAME}" + start-stop-daemon --stop \ + --pidfile ${PIDFILE} \ + --retry 65 \ + --exec ${SERVERPROGRAM} -- ${SERVERCONFIG_OPT} + eend $? +} diff --git a/www-apps/zarafa/files/zarafa-spooler.rc6 b/www-apps/zarafa/files/zarafa-spooler.rc6 new file mode 100644 index 0000000..0a24b9c --- /dev/null +++ b/www-apps/zarafa/files/zarafa-spooler.rc6 @@ -0,0 +1,30 @@ +#!/sbin/runscript +# Copyright 1999-2008 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +SPOOLERCONFIG=/etc/zarafa/spooler.cfg +SPOOLERPROGRAM=/usr/bin/zarafa-spooler + +[ -x $SPOOLERPROGRAM ] || exit 0 + +SPOOLERCONFIG_OPT="" +[ ! -z $SPOOLERCONFIG -a -f $SPOOLERCONFIG ] && SPOOLERCONFIG_OPT="-c $SPOOLERCONFIG" + +PIDFILE=/var/run/"${SVCNAME}".pid + +start() { + ebegin "Starting ${SVCNAME}" + start-stop-daemon --start \ + --pidfile ${PIDFILE} \ + --exec ${SPOOLERPROGRAM} -- ${SPOOLERCONFIG_OPT} + eend $? +} + +stop() { + ebegin "Stopping ${SVCNAME}" + start-stop-daemon --stop \ + --pidfile ${PIDFILE} \ + --exec ${SPOOLERPROGRAM} -- ${SPOOLERCONFIG_OPT} + eend $? +} diff --git a/www-apps/zarafa/files/zarafa.logrotate b/www-apps/zarafa/files/zarafa.logrotate new file mode 100644 index 0000000..3cf6a82 --- /dev/null +++ b/www-apps/zarafa/files/zarafa.logrotate @@ -0,0 +1,101 @@ +# +# This is an example for the common logrotate system. +# Copy this file to /etc/logrotate.d/zarafa to activate it. +# Also, check the location of the logfiles, and replace if needed. +# + +/var/log/zarafa/dagent.log { + weekly + missingok + rotate 52 + compress + delaycompress + notifempty + postrotate + killall -HUP zarafa-dagent + endscript +} + +/var/log/zarafa/indexer.log { + weekly + missingok + rotate 52 + compress + delaycompress + notifempty + postrotate + killall -HUP zarafa-indexer + endscript +} + +/var/log/zarafa/licensed.log { + weekly + missingok + rotate 52 + compress + delaycompress + notifempty + postrotate + killall -HUP zarafa-licensed + endscript +} + +/var/log/zarafa/server.log { + weekly + missingok + rotate 52 + compress + delaycompress + notifempty + postrotate + killall -HUP zarafa-server + endscript +} + +/var/log/zarafa/spooler.log { + weekly + missingok + rotate 52 + compress + delaycompress + notifempty + postrotate + killall -HUP zarafa-spooler + endscript +} + +/var/log/zarafa/monitor.log { + weekly + missingok + rotate 52 + compress + delaycompress + notifempty + postrotate + killall -HUP zarafa-monitor + endscript +} + +/var/log/zarafa/gateway.log { + weekly + missingok + rotate 52 + compress + delaycompress + notifempty + postrotate + killall -HUP zarafa-gateway + endscript +} + +/var/log/zarafa/ical.log { + weekly + missingok + rotate 52 + compress + delaycompress + notifempty + postrotate + killall -HUP zarafa-ical + endscript +} diff --git a/www-apps/zarafa/zarafa-6.40.2.ebuild b/www-apps/zarafa/zarafa-6.40.2.ebuild new file mode 100644 index 0000000..5b17a2f --- /dev/null +++ b/www-apps/zarafa/zarafa-6.40.2.ebuild @@ -0,0 +1,111 @@ +# Copyright 1999-2008 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +EAPI="2" + +PHP_EXT_NAME="mapi" +PHP_EXT_INI="yes" +PHP_EXT_ZENDEXT="no" + +ZARAFA_URL="http://www.zarafa.com/?q=en/download-community" +ZARAFA_PACKAGE="${P}.tar.gz" + +inherit eutils php-ext-base-r1 autotools +#inherit eutils php-ext-base-r1 + +DESCRIPTION="Open Source Groupware Solution" +HOMEPAGE="http://zarafa.com/" +SRC_URI="${ZARAFA_PACKAGE}" + +LICENSE="AGPL-3" +SLOT="0" +KEYWORDS="~amd64 ~x86" +RESTRICT="fetch" +IUSE="debug ldap logrotate licensed static tcmalloc kerberos" + +RDEPEND=">=dev-libs/libical-0.44 + dev-cpp/libvmime:0.7 + >=dev-lang/php-5.2.0 + app-text/catdoc + app-text/poppler + dev-cpp/clucene + dev-db/mysql + dev-libs/libxml2 + dev-libs/openssl + net-misc/curl + sys-libs/e2fsprogs-libs + sys-libs/zlib + virtual/httpd-php + kerberos? ( || ( app-crypt/mit-krb5 app-crypt/heimdal ) ) + ldap? ( net-nds/openldap ) + logrotate? ( app-admin/logrotate ) + tcmalloc? ( dev-util/google-perftools )" +DEPEND="${RDEPEND} + dev-util/pkgconfig + sys-devel/gettext" + +pkg_nofetch() { + einfo "Please download ${ZARAFA_PACKAGE} from:" + einfo ${ZARAFA_URL} + einfo "and move it to ${DISTDIR}" +} + +src_prepare() { + EPATCH_SOURCE="${FILESDIR}/patches" EPATCH_SUFFIX="patch" \ + EPATCH_FORCE="yes" epatch + edos2unix php-webclient-ajac/config.php.dist + eautoreconf +} + +src_configure() { + econf \ + --enable-oss \ + --disable-perl \ + --disable-testtools \ + --enable-release \ + --with-userscript-prefix=/etc/zarafa/userscripts \ + --with-quotatemplate-prefix=/etc/zarafa/quotamails \ + --with-indexerscripts-prefix=/etc/zarafa/indexerscripts \ + $(use_enable static) \ + $(use_enable tcmalloc) \ + $(use_enable debug) +} + +src_install() { + make DESTDIR="${D}" install || die "make install failed" + make DESTDIR="${D}" install-ajax-webaccess || die "make install-ajax-webaccess failed" + make DESTDIR="${D}" install-mobile-webaccess || die "make install-mobile-webaccess failed" + + insinto /etc/apache2/modules.d + newins "${FILESDIR}/50_mailman.conf-r1" 50_mailman.conf + newins "${FILESDIR}/50_zarafa-webaccess-mobile.conf" 50_zarafa-webaccess-mobile.conf + newins "${FILESDIR}/50_zarafa-webaccess.conf" 50_zarafa-webaccess.conf + + rm "${D}"/usr/share/zarafa-webaccess/*.conf + rm "${D}"/usr/share/zarafa-webaccess-mobile/*.conf + + php-ext-base-r1_src_install + + if use logrotate; then + insinto /etc/logrotate.d + newins "${FILESDIR}"/zarafa.logrotate zarafa || die "Failed to install logrotate" + fi + + insinto /etc/zarafa + doins "${S}"/installer/linux/*.cfg || die "Failed to install config files" + + dodir /var/log/zarafa + keepdir /var/log/zarafa + + if use licensed; then + newinitd ${FILESDIR}/zarafa-licensed.rc6 zarafa-licensed + fi + + newinitd ${FILESDIR}/zarafa-gateway.rc6 zarafa-gateway + newinitd ${FILESDIR}/zarafa-ical.rc6 zarafa-ical + newinitd ${FILESDIR}/zarafa-indexer.rc6 zarafa-indexer + newinitd ${FILESDIR}/zarafa-monitor.rc6 zarafa-monitor + newinitd ${FILESDIR}/zarafa-server.rc6 zarafa-server + newinitd ${FILESDIR}/zarafa-spooler.rc6 zarafa-spooler +}