commit:     77a56afe8fd8e19d6bf7564318c851af76b42df7
Author:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Mon Jul 24 14:05:24 2017 +0000
Commit:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Mon Jul 24 14:18:02 2017 +0000
URL:        https://gitweb.gentoo.org/proj/mozilla.git/commit/?id=77a56afe

seamonkey: Added latest revision.

 ...ust-contain-fPIC-when-checking-the-linker.patch | 35 +++++++++++
 www-client/seamonkey/metadata.xml                  | 72 +++++++++++-----------
 ...monkey-2.48.ebuild => seamonkey-2.48-r1.ebuild} | 67 ++++++++++----------
 3 files changed, 106 insertions(+), 68 deletions(-)

diff --git 
a/www-client/seamonkey/files/0001-CFLAGS-must-contain-fPIC-when-checking-the-linker.patch
 
b/www-client/seamonkey/files/0001-CFLAGS-must-contain-fPIC-when-checking-the-linker.patch
new file mode 100644
index 0000000..fe3130e
--- /dev/null
+++ 
b/www-client/seamonkey/files/0001-CFLAGS-must-contain-fPIC-when-checking-the-linker.patch
@@ -0,0 +1,35 @@
+From 4604a80b052456f20187d89e5c3e115ef0bb7251 Mon Sep 17 00:00:00 2001
+From: "Jory A. Pratt" <[email protected]>
+Date: Mon, 24 Jul 2017 06:10:11 -0500
+Subject: [PATCH] CFLAGS must contain -fPIC when checking the linker
+ https://bugs.gentoo.org/show_bug.cgi?id=607350
+
+Signed-off-by: Jory A. Pratt <[email protected]>
+---
+ mozilla/build/autoconf/compiler-opts.m4 | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/mozilla/build/autoconf/compiler-opts.m4 
b/mozilla/build/autoconf/compiler-opts.m4
+index c12d400..639e99e 100644
+--- a/mozilla/build/autoconf/compiler-opts.m4
++++ b/mozilla/build/autoconf/compiler-opts.m4
+@@ -268,6 +268,8 @@ MOZ_ARG_ENABLE_BOOL(pie,
+ 
+ if test "$GNU_CC" -a -n "$MOZ_PIE"; then
+     AC_MSG_CHECKING([for PIE support])
++    _SAVE_CFLAGS=$CFLAGS
++    CFLAGS="$CFLAGS -fPIC"
+     _SAVE_LDFLAGS=$LDFLAGS
+     LDFLAGS="$LDFLAGS -pie"
+     AC_TRY_LINK(,,AC_MSG_RESULT([yes])
+@@ -275,6 +277,8 @@ if test "$GNU_CC" -a -n "$MOZ_PIE"; then
+                   AC_MSG_RESULT([no])
+                   AC_MSG_ERROR([--enable-pie requires PIE support from the 
linker.]))
+     LDFLAGS=$_SAVE_LDFLAGS
++    CFLAGS=$_SAVE_CFLAGS
++
+ fi
+ 
+ AC_SUBST(MOZ_PROGRAM_LDFLAGS)
+-- 
+2.13.3

diff --git a/www-client/seamonkey/metadata.xml 
b/www-client/seamonkey/metadata.xml
index 154a2a5..484e981 100644
--- a/www-client/seamonkey/metadata.xml
+++ b/www-client/seamonkey/metadata.xml
@@ -1,40 +1,40 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd";>
 <pkgmetadata>
-<maintainer type="person">
-    <email>[email protected]</email>
-    <name>Lars Wendler</name>
-  </maintainer>
-<maintainer type="project">
-    <email>[email protected]</email>
-    <name>Gentoo Mozilla Team</name>
-  </maintainer>
-<use>
-       <flag name="calendar">Build Mozilla's calendar</flag>
-       <flag name="chatzilla">Build Mozilla's IRC client (default on)</flag>
-       <flag name="custom-optimization">Build with user-specified compiler 
optimizations
-               (-Os, -O0, -O1, -O2, -O3) from CFLAGS (unsupported)</flag>
-       <flag name="gmp-autoupdate">Allow Gecko Media Plugins (binary blobs) to 
be automatically
-               downloaded and kept up-to-date in user profiles</flag>
-       <flag name="gtk3">Use the cairo-gtk3 rendering engine</flag>
-       <flag name="ipc">Use inter-process communication between tabs and 
plugins.
-               Allows for greater stability in case of plugin crashes</flag>
-       <flag name="jemalloc">Enable or disable jemalloc</flag>
-       <flag name="roaming">Build roaming extension support (default on)</flag>
-       <flag name="skia">Enable the SKIA engine for 2D rendering as an 
alternative to cairo</flag>
-       <flag name="system-cairo">Use the system-wide <pkg>x11-libs/cairo</pkg>
-               instead of bundled.</flag>
-       <flag name="system-harfbuzz">Use the system-wide 
<pkg>media-libs/harfbuzz</pkg>
-               instead of bundled.</flag>
-       <flag name="system-icu">Use the sytem-wide <pkg>dev-libs/icu</pkg>
-               instead of bundled.</flag>
-       <flag name="system-jpeg">Use the system-wide 
<pkg>media-libs/libjpeg-turbo</pkg>
-               instead of bundled.</flag>
-       <flag name="system-libevent">Use the system-wide 
<pkg>dev-libs/libevent</pkg>
-               instead of bundled.</flag>
-       <flag name="system-libvpx">Use the system-wide 
<pkg>media-libs/libvpx</pkg>
-               instead of bundled.</flag>
-       <flag name="system-sqlite">Use the system-wide <pkg>dev-db/sqlite</pkg>
-               installation with secure-delete enabled</flag>
-</use>
+       <maintainer type="person">
+               <email>[email protected]</email>
+               <name>Lars Wendler</name>
+       </maintainer>
+       <maintainer type="project">
+               <email>[email protected]</email>
+               <name>Gentoo Mozilla Team</name>
+       </maintainer>
+       <use>
+               <flag name="calendar">Build Mozilla's calendar</flag>
+               <flag name="chatzilla">Build Mozilla's IRC client (default 
on)</flag>
+               <flag name="custom-optimization">Build with user-specified 
compiler optimizations
+                       (-Os, -O0, -O1, -O2, -O3) from CFLAGS 
(unsupported)</flag>
+               <flag name="gmp-autoupdate">Allow Gecko Media Plugins (binary 
blobs) to be automatically
+                       downloaded and kept up-to-date in user profiles</flag>
+               <flag name="gtk3">Use the cairo-gtk3 rendering engine</flag>
+               <flag name="ipc">Use inter-process communication between tabs 
and plugins.
+                       Allows for greater stability in case of plugin 
crashes</flag>
+               <flag name="jemalloc">Enable or disable jemalloc</flag>
+               <flag name="roaming">Build roaming extension support (default 
on)</flag>
+               <flag name="skia">Enable the SKIA engine for 2D rendering as an 
alternative to cairo</flag>
+               <flag name="system-cairo">Use the system-wide 
<pkg>x11-libs/cairo</pkg>
+                       instead of bundled.</flag>
+               <flag name="system-harfbuzz">Use the system-wide 
<pkg>media-libs/harfbuzz</pkg>
+                       instead of bundled.</flag>
+               <flag name="system-icu">Use the sytem-wide 
<pkg>dev-libs/icu</pkg>
+                       instead of bundled.</flag>
+               <flag name="system-jpeg">Use the system-wide 
<pkg>media-libs/libjpeg-turbo</pkg>
+                       instead of bundled.</flag>
+               <flag name="system-libevent">Use the system-wide 
<pkg>dev-libs/libevent</pkg>
+                       instead of bundled.</flag>
+               <flag name="system-libvpx">Use the system-wide 
<pkg>media-libs/libvpx</pkg>
+                       instead of bundled.</flag>
+               <flag name="system-sqlite">Use the system-wide 
<pkg>dev-db/sqlite</pkg>
+                       installation with secure-delete enabled</flag>
+       </use>
 </pkgmetadata>

diff --git a/www-client/seamonkey/seamonkey-2.48.ebuild 
b/www-client/seamonkey/seamonkey-2.48-r1.ebuild
similarity index 89%
rename from www-client/seamonkey/seamonkey-2.48.ebuild
rename to www-client/seamonkey/seamonkey-2.48-r1.ebuild
index 452ce3d..01fae80 100644
--- a/www-client/seamonkey/seamonkey-2.48.ebuild
+++ b/www-client/seamonkey/seamonkey-2.48-r1.ebuild
@@ -63,11 +63,10 @@ inherit check-reqs flag-o-matic toolchain-funcs eutils 
mozconfig-v6.51 multilib
 
 PATCHFF="firefox-51.0-patches-06"
 PATCH="${PN}-2.46-patches-01"
-EMVER="1.9.8.1"
 
 DESCRIPTION="Seamonkey Web Browser"
 HOMEPAGE="http://www.seamonkey-project.org";
-KEYWORDS="~alpha amd64 ~arm ~ppc ~ppc64 ~x86"
+KEYWORDS="~alpha ~amd64 ~arm ~ppc ~ppc64 ~x86"
 
 SLOT="0"
 LICENSE="MPL-2.0 GPL-2 LGPL-2.1"
@@ -79,7 +78,6 @@ SRC_URI+="
        https://dev.gentoo.org/~polynomial-c/mozilla/patchsets/${PATCHFF}.tar.xz
        https://dev.gentoo.org/~axs/mozilla/patchsets/${PATCH}.tar.xz
        https://dev.gentoo.org/~polynomial-c/mozilla/patchsets/${PATCH}.tar.xz
-       crypt? ( 
https://www.enigmail.net/download/source/enigmail-${EMVER}.tar.gz )
 "
 
 ASM_DEPEND=">=dev-lang/yasm-1.1"
@@ -95,7 +93,9 @@ RDEPEND="
                                app-crypt/pinentry[qt4]
                        )
                )
-               =app-crypt/gnupg-1.4* ) )
+               =app-crypt/gnupg-1.4* )
+               x11-plugins/enigmail
+       )
        jack? ( virtual/jack )
 "
 
@@ -147,6 +147,7 @@ src_unpack() {
 src_prepare() {
        # Apply our patches
        eapply "${WORKDIR}"/seamonkey
+       eapply 
"${FILESDIR}/0001-CFLAGS-must-contain-fPIC-when-checking-the-linker.patch" 
#625992
 
        # browser patches go here
        pushd "${S}"/mozilla &>/dev/null || die
@@ -262,12 +263,6 @@ src_configure() {
        # Finalize and report settings
        mozconfig_final
 
-       if use crypt ; then
-               pushd "${WORKDIR}"/enigmail &>/dev/null || die
-               econf
-               popd &>/dev/null || die
-       fi
-
        # Work around breakage in makeopts with --no-print-directory
        MAKEOPTS="${MAKEOPTS/--no-print-directory/}"
 
@@ -289,15 +284,6 @@ src_compile() {
        emake V=1 -f client.mk
 
        mozlinguas_src_compile
-
-       # Only build enigmail extension if conditions are met.
-       if use crypt ; then
-               einfo "Building enigmail"
-               pushd "${WORKDIR}"/enigmail &>/dev/null || die
-               emake -j1
-               emake xpi
-               popd &>/dev/null || die
-       fi
 }
 
 src_install() {
@@ -337,19 +323,6 @@ src_install() {
        emake DESTDIR="${D}" install
        cp "${FILESDIR}"/${PN}.desktop "${T}" || die
 
-       if use crypt ; then
-               local em_dir="${WORKDIR}/enigmail/build"
-               pushd "${T}" &>/dev/null || die
-               unzip "${em_dir}"/enigmail*.xpi install.rdf || die
-               emid=$(sed -n '/<em:id>/!d; s/.*\({.*}\).*/\1/; p; q' 
install.rdf)
-               #'
-               dodir ${MOZILLA_FIVE_HOME}/extensions/${emid}
-               cd "${D}"${MOZILLA_FIVE_HOME}/extensions/${emid} || die
-               unzip "${em_dir}"/enigmail*.xpi || die
-
-               popd &>/dev/null || die
-       fi
-
        sed 
's|^\(MimeType=.*\)$|\1text/x-vcard;text/directory;application/mbox;message/rfc822;x-scheme-handler/mailto;|'
 \
                -i "${T}"/${PN}.desktop || die
        sed 's|^\(Categories=.*\)$|\1Email;|' -i "${T}"/${PN}.desktop \
@@ -374,6 +347,16 @@ src_install() {
                rm -rf "${ED}"/usr/include 
"${ED}${MOZILLA_FIVE_HOME}"/{idl,include,lib,sdk}
        fi
 
+       if use crypt ; then
+               emid=$(sed -n '/<em:id>/!d; s/.*\({.*}\).*/\1/; p; q' 
"${EROOT%/}"/usr/share/enigmail/install.rdf)
+               if [[ -n ${emid} ]]; then
+                       dosym "${EPREFIX%/}"/usr/share/enigmail 
${MOZILLA_FIVE_HOME}/extensions/${emid}
+               else
+                       eerror "${EPREFIX%/}/usr/share/enigmail/install.rdf: No 
such file or directory"
+                       die "<EM:ID> tag for x11-plugins/enigmail could not be 
found!"
+               fi
+       fi
+
        if use chatzilla ; then
                local emid='{59c81df5-4b7a-477b-912d-4e0fdf64e5f2}'
 
@@ -407,6 +390,26 @@ pkg_preinst() {
        if [ -d ${MOZILLA_FIVE_HOME}/plugins ] ; then
                rm ${MOZILLA_FIVE_HOME}/plugins -rf
        fi
+
+       # Because PM's dont seem to properly merge a symlink replacing a 
directory
+       if use crypt ; then
+               local emid=$(sed -n '/<em:id>/!d; s/.*\({.*}\).*/\1/; p; q' 
"${EROOT%/}"/usr/share/enigmail/install.rdf)
+               local 
emidpath="${EROOT%/}"${MOZILLA_FIVE_HOME}/extensions/${emid}
+               if [[ -z ${emid} ]]; then
+                       eerror "${EROOT%/}/usr/share/enigmail/install.rdf: No 
such file or directory"
+                       die "Could not find enigmail on disk during 
pkg_preinst()"
+               fi
+               if [[ ! -h "${emidpath}" ]] && [[ -d "${emidpath}" ]]; then
+                       if ! rm -R --interactive=never "${emidpath}" ; then
+                               eerror "Could not remove enigmail directory 
from previous installation,"
+                               eerror "You must remove this by hand and rename 
the symbolic link yourself:"
+                               eerror
+                               eerror "\t cd 
${EPREFIX%/}${MOZILLA_FIVE_HOME}/extensions"
+                               eerror "\t rm -Rf ${emid}"
+                               eerror "\t mv ${emid}.backup* ${emid}"
+                       fi
+               fi
+       fi
 }
 
 pkg_postinst() {

Reply via email to