From ec6c329dcfa0e4fb77a8db8463b7c88863cb9fd4 Mon Sep 17 00:00:00 2001 From: Daniel Mierswa Date: Sat, 3 Jan 2009 04:02:40 +0100 Subject: [PATCH] add new thunderbird w/ enigmail TODO: find a better solution to handle in-source builds --- metadata/layout.conf | 2 +- .../enigmail_visibility_workaround.patch | 16 ++ .../thunderbird-2.0.0.19.exheres-0 | 139 ++++++++++++++++++ 3 files changed, 156 insertions(+), 1 deletion(-) create mode 100644 packages/mail-client/thunderbird/files/enigmail_visibility_workaround.patch create mode 100644 packages/mail-client/thunderbird/thunderbird-2.0.0.19.exheres-0 diff --git a/metadata/layout.conf b/metadata/layout.conf index 283ea1d..3894c3a 100644 --- a/metadata/layout.conf +++ b/metadata/layout.conf @@ -2,4 +2,4 @@ layout = exheres eapi_when_unknown = exheres-0 eapi_when_unspecified = exheres-0 profile_eapi = exheres-0 -masters = arbor +masters = arbor mozilla diff --git a/packages/mail-client/thunderbird/files/enigmail_visibility_workaround.patch b/packages/mail-client/thunderbird/files/enigmail_visibility_workaround.patch new file mode 100644 index 0000000..a05b185 --- /dev/null +++ b/packages/mail-client/thunderbird/files/enigmail_visibility_workaround.patch @@ -0,0 +1,16 @@ +Upstream: Unknown +Source: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=442966 +Reason: linker errors at final stage + +--- ./build-dir/mozilla/mail/extensions/enigmail/build/nsEnigModule.cpp 2006-05-20 23:47:30.000000000 +0200 ++++ ./build-dir/mozilla/mail/extensions/enigmail/build/nsEnigModule.cpp~ 2007-09-30 12:35:16.000000000 +0200 +@@ -34,7 +34,9 @@ + * + * ***** END LICENSE BLOCK ***** */ + ++#pragma GCC visibility push(default) + #include "nsIGenericFactory.h" ++#pragma GCC visibility pop + #include "nsEnigModule.h" + + #include "nsEnigMsgCompose.h" diff --git a/packages/mail-client/thunderbird/thunderbird-2.0.0.19.exheres-0 b/packages/mail-client/thunderbird/thunderbird-2.0.0.19.exheres-0 new file mode 100644 index 0000000..8d3e55b --- /dev/null +++ b/packages/mail-client/thunderbird/thunderbird-2.0.0.19.exheres-0 @@ -0,0 +1,139 @@ +# Copyright 2008 Bernd Steinhauser +# Distributed under the terms of the GNU General Public License v2 + +# this is a copy of Bernd Steinhausers exheres in mozilla.git +# with added enigmail support + +require mozilla + +ENIGMAIL_VERSION="0.95.7" +ENIGMAIL_TARBALL="enigmail-${ENIGMAIL_VERSION}.tar.gz" + +SUMMARY="Mozilla's standalone mail client" +DESCRIPTION=" +" +HOMEPAGE="" +DOWNLOADS=" + ftp://ftp.mozilla.org/pub/${PN}/releases/${PV}/source/${PNV}-source.tar.bz2 + enigmail? ( + http://www.mozilla-enigmail.org/download/source/${ENIGMAIL_TARBALL} + ) +" + +LICENCES="MPL" +SLOT="0" +PLATFORMS="~amd64" +MYOPTIONS="bindist enigmail ldap svg xinerama" + +# libXIE? +# AC_CHECK_LIB(XIE, XieFloGeometry, [MOZ_XIE_LIBS="-lXIE"],, +# $XLIBS $XEXT_LIBS) +# AC_CHECK_HEADER(X11/extensions/XIElib.h) + +# media-libs/libpng +# dev-libs/nss + +DEPENDENCIES=" + build: + app-arch/unzip + dev-util/pkg-config + x11-proto/xextproto + xinerama? ( x11-proto/xineramaproto ) + build+run: + dev-libs/libIDL + dev-libs/nspr + media-libs/freetype + media-libs/jpeg + x11-libs/pango + x11-libs/cairo[svg?] + x11-libs/gtk+:2 + x11-libs/libX11 + x11-libs/libXext + x11-libs/libXt + x11-libs/libICE + x11-libs/libSM + xinerama? ( x11-libs/libXinerama ) +" + +WORK="${WORKBASE}"/mozilla +ECONF_SOURCE="${WORKBASE}"/mozilla +export MOZILLA_OFFICIAL=1 +export BUILD_OFFICIAL=1 + +src_prepare() { + mozilla_src_prepare + + sed \ + -e "/^mozappdir/ c mozappdir = /usr/$(get_libdir)/${PN}" \ + -i "${WORKBASE}"/mozilla/config/autoconf.mk.in \ + || die "mozappdir sed failed." + + if option enigmail ; then + mv "${WORKBASE}/enigmail" mailnews/extensions \ + || die "mv enigmail failed" + cd mailnews/extensions/enigmail \ + || die "cd enigmail failed" + expatch -p6 "${FILES}/enigmail_visibility_workaround.patch" + fi +} + +src_configure() { + mkdir -p "${WORK}" + cd "${WORK}" + + export MOZ_OBJDIR=@TOPSRCDIR@/../build + export MOZ_CO_PROJECT=browser + export MOZ_BUILD_PROJECTS=browser + + econf \ + --enable-application=mail \ + --enable-crypto \ + --enable-freetype \ + --enable-optimize \ + --enable-system-cairo \ + --disable-mochitest \ + --disable-gnomeui \ + --disable-gnomevfs \ + --disable-javaxpcom \ + --disable-strip \ + --disable-xprint \ + --with-system-nspr \ + --with-system-jpeg \ + --with-system-png \ + --with-system-zlib \ + --with-libIDL \ + --with-x \ + --without-system-nss \ + $(option_enable ldap) \ + $(option_enable ldap ldap-experimental) \ + $(option_enable !bindist official-branding) \ + $(option_enable svg) \ + --with-default-mozilla-five-home=/usr/$(get_libdir)/${PN} \ + --with-distribution-id=org.exherbo +} + +src_compile() { + default + if option enigmail ; then + cd mailnews/extensions/enigmail \ + || die "cd enigmail failed" + ./makemake -r \ + || die "./makemake -r failed" + emake \ + || die "emake in enigmail failed" + fi +} + +src_install() { + default + if option enigmail ; then + local enigmail_path="mailnews/extensions/enigmail" + local install_rdf="${enigmail_path}/package/install.rdf" + # taken from enigmail-0.95.7-r2.ebuild + local em_id=$(sed -n '//!d; s/.*\({.*}\).*/\1/; p; q' ${install_rdf}) + local extension_path="/usr/$(get_libdir)/${PN}/extensions/${em_id}" + + emake -C "${enigmail_path}" xpi + unzip -d "${IMAGE}/${extension_path}" "${WORK}/dist/bin"/*xpi + fi +}