From 067eb832e4c0428973d09e15b04bd1aec6051583 Mon Sep 17 00:00:00 2001 From: Andreas Grapentin Date: Wed, 31 Jan 2018 20:11:25 +0100 Subject: nonprism/icedove: updated to 52.6.0 --- nonprism/icedove/PKGBUILD | 330 +++++++++++++++++++++++++++------------------- 1 file changed, 193 insertions(+), 137 deletions(-) (limited to 'nonprism/icedove/PKGBUILD') diff --git a/nonprism/icedove/PKGBUILD b/nonprism/icedove/PKGBUILD index d99655052..33b6b509a 100644 --- a/nonprism/icedove/PKGBUILD +++ b/nonprism/icedove/PKGBUILD @@ -1,123 +1,161 @@ +# $Id$ +# Contributor (Arch): Jan Alexander Steffens (heftig) +# Contributor (Arch): Ionut Biru +# Contributor (Arch): Alexander Baldeck +# Contributor (Arch): Dale Blount +# Contributor (Arch): Anders Bostrom # Maintainer: Andreas Grapentin # Contributor: André Silva # Contributor: Márcio Silva # Contributor: Luke R. # Contributor: Isaac David -_oldname=thunderbird -pkgname=icedove +# parabola changes and rationale: +# - rebranded to icedove +# - removed nonfree search engines +# - added makedepends: quilt mozilla-searchplugins python2-blessings +# - added replaces, conflicts, provides: thunderbird +# - disabled tests, they break in an environment without network access. +_pkgname=thunderbird +pkgname=icedove epoch=1 -pkgver=52.5.2 +pkgver=52.6.0 pkgrel=1.nonprism1 -_brandingver=52.1 -_brandingrel=1 -arch=(i686 x86_64 armv7h) - -pkgdesc="Icedove, the libre standalone mail and news reader based on Mozilla Thunderbird, without support for unsafe and dangerous for privacy protocols" -url="https://wiki.parabola.nu/$pkgname" +_bver=52.1 +_brel=1 +pkgdesc="Libre standalone mail and news reader based on Mozilla Thunderbird, without support for unsafe and dangerous for privacy protocols" +arch=(x86_64 i686 armv7h) license=(MPL GPL LGPL) - -depends=(alsa-lib dbus-glib gtk2 gtk3 hunspell libvpx libxt mime-types mozilla-common nss sqlite startup-notification ttf-font) +url="https://wiki.parabola.nu/$pkgname" +depends=(gtk3 gtk2 mozilla-common libxt startup-notification mime-types dbus-glib alsa-lib ffmpeg + nss hunspell sqlite ttf-font icu libvpx) depends_x86_64=("icu>=60" "icu<61") depends_i686=("icu>=60" "icu<61") depends_armv7h=("icu>=60" "icu<61") -makedepends=(autoconf2.13 diffutils gconf imake inetutils libpulse mesa mozilla-searchplugins pkg-config python2 quilt unzip yasm zip) -makedepends_i686=(cargo) -makedepends_x86_64=("${makedepends_i686[@]}") -optdepends=('libcanberra: for sound support') -replaces=("$pkgname-libre" "$_oldname") -conflicts=("$pkgname-libre" "$_oldname") +makedepends=(unzip zip diffutils python2 yasm mesa imake gconf libpulse inetutils xorg-server-xvfb + autoconf2.13 rust clang llvm quilt mozilla-searchplugins python2-blessings) +optdepends=('libcanberra: sound support') +replaces=("$_oldname") +conflicts=("$_oldname") provides=("$_oldname") options=(!emptydirs !makeflags) -install=$pkgname.install - -_parabolarepo=https://repo.parabola.nu/other/icedove -source=("https://ftp.mozilla.org/pub/$_oldname/releases/$pkgver/source/$_oldname-$pkgver.source.tar.xz" - "$_parabolarepo/${pkgname}_$_brandingver-$_brandingrel.branding.tar.xz" - "$_parabolarepo/${pkgname}_$_brandingver-$_brandingrel.branding.tar.xz.sig" - mozconfig - $pkgname.desktop - $pkgname-install-dir.patch - changing-the-default-search-engine.patch - vendor.js - rust-target-i586-to-i686.patch - mp4parse-bindings.patch - libre-searchengines.patch - no-neon.patch - no-crmf.patch) -sha256sums=('7772e1865cd4cbaac82ea05374d0ae51f754f47c6160c9b83919da483d620ee5' +source=(https://ftp.mozilla.org/pub/mozilla.org/thunderbird/releases/$pkgver/source/thunderbird-$pkgver.source.tar.xz + 0001-Bug-1338655-Don-t-try-to-build-mp4parse-bindings.-r-.patch + no-crmf.diff rust-i686.patch fix-wifi-scanner.diff + $pkgname.desktop $pkgname-install-dir.patch + https://repo.parabola.nu/other/icedove/${pkgname}_$_bver-$_brel.branding.tar.xz{,.sig} + libre.patch) +sha256sums=('16215fb5a3765c7e5a40eadc1f3aed6918294f6d8ef1552d2aa37656055045a8' + '413cd6d366d78f325d80ebebccfd0afa0d266b40b2e54b66ba2fa03c15f3ea67' + '9bb0ec0d1b267f8cc1f08fbd82666459a21e4c171d52b8314b80979c948d96ce' + 'f61ea706ce6905f568b9bdafd1b044b58f20737426f0aa5019ddb9b64031a269' + '9765bca5d63fb5525bbd0520b7ab1d27cabaed697e2fc7791400abc3fa4f13b8' + 'af8199a12ebe09189d143458bd1e2d0071aff3410ed121dc2329a448a56632f0' + 'a3f2431a6e9eb01d3e20dfa5110e769180b4a752ea834c1162088aa90d99e8f3' '246418976524fbead5b99e6227f97322f8d4c45e0edf9ce75561ae8eccdefc65' 'SKIP' - 'cafd1cf384791e8e3284f52370b2913a8b05935ecfd10d2a19c6dd5a8c219b62' - '0b0d25067c64c6b829c84e5259ffca978e3971f85acc8483f47bdbed5b0b5b6a' - '36e0a5ac0e994bfc939b4ac69a1a4aa365210e9dd5b49317d647c683817b2c5d' - 'ff3474b7d8f7ad245a324c14f01daf05834462b4f0144fbc50f055ebb573dac8' - '058b58074368b57acf8a6df9a9ffac848b7d7b39f5abd84cb2039bcee42b73e2' - '069fab4b99dd51d7d004124d0052ea7b864cf060ea943348d290ba6aae50b0ab' - '45a9e651278e39df39d17a679ac9ad81255cd51b530ba23b8e55e4d39c3b35d0' - '0db12bef46e0ad68dbdf6ce0c767956d6758b073531012a850e7975eda3fc7fe' - '59f40d8b2480aa67bf76f4f119826b6828a6a59cc040caf1ab5a6e19eef44c6e' - 'a7317caba56e89932bd9e3b9352d94701dd9a419685057f238b1ded8dc0adcd7') + '4a09569394f1b4e154fdcd53f2947b7be7f065baaa31c964629dff9117fdf49b') validpgpkeys=(BFA8008A8265677063B11BF47171986E4B745536) # Andreas Grapentin prepare() { - cd "$srcdir/$_oldname-$pkgver" + mkdir path + ln -s /usr/bin/python2 path/python - local brandingdir="$srcdir/$pkgname-$_brandingver" + cd $_pkgname-$pkgver + patch -Np1 -i ../$pkgname-install-dir.patch - # Prepare branding for the Icedove packages - mkdir -v mail/branding/$pkgname + # https://bugzilla.mozilla.org/show_bug.cgi?id=1314968 + patch -d mozilla -Np1 < ../fix-wifi-scanner.diff - # copy the branding files - cp -va $brandingdir/$pkgname-branding/* mail/branding/$pkgname + # https://bugzilla.mozilla.org/show_bug.cgi?id=1371991 + patch -Np1 -i ../no-crmf.diff + + # Build with the rust targets we actually ship + patch -d mozilla -Np1 < ../rust-i686.patch + + # https://bugs.archlinux.org/task/53890 + patch -d mozilla -Np1 < ../0001-Bug-1338655-Don-t-try-to-build-mp4parse-bindings.-r-.patch + + cat >.mozconfig <> .mozconfig << END +ac_add_options --disable-webrtc +ac_add_options --disable-elf-hack +ac_add_options --enable-optimize="-g -O2 -fno-schedule-insns" +END + fi + + # perform rebranding + local brandingdir="$srcdir/$pkgname-$_bver" + mkdir -v mail/branding/$pkgname + cp -va $srcdir/$pkgname-$_bver/$pkgname-branding/* mail/branding/$pkgname - # patch - export QUILT_PATCHES=$brandingdir/patches + export QUILT_PATCHES=$srcdir/$pkgname-$_bver/patches export QUILT_REFRESH_ARGS='-p ab --no-timestamps --no-index' export QUILT_DIFF_ARGS='--no-timestamps' - quilt push -av - # install the icons - for i in 16 22 24 32 48 64 128 256; do - install -Dm644 $brandingdir/app-icons/$pkgname$i.png \ - mail/branding/$pkgname/mailicon$i.png - done - for i in 48 64; do - install -Dm644 $brandingdir/app-icons/$pkgname$i.png \ - mail/branding/$pkgname/content/icon$i.png - done - cp -av $brandingdir/preview.png mail/themes/linux/mail/preview.png - - # install to /usr/lib/icedove - patch -Np1 -i "$srcdir/$pkgname-install-dir.patch" - - # https://bugzilla.mozilla.org/show_bug.cgi?id=1371991 - patch -Np1 -i "$srcdir/no-crmf.patch" - - # Fix rust build - patch -Np1 -i "$srcdir/rust-target-i586-to-i686.patch" - patch -Np1 -i "$srcdir/mp4parse-bindings.patch" - - # Fix freedom issues - patch -Np1 -i "$srcdir/libre-searchengines.patch" - - # Remove url-classifier from package-manifest.in to build and disable Phishing Protection + # Patch and remove anything that's left + patch -Np1 -i "$srcdir/libre.patch" sed -i '\|Phishing Protection|d \|UrlClassifier|d \|URLClassifier|d \|url-classifier|d ' mail/installer/package-manifest.in - - # Replace common URLs sed -i '\|extensions[.]getAddons[.]get[.]url| s|https://services[.]addons[.]mozilla[.]org.\+["][)][;]|https://directory.fsf.org/wiki/Icedove");|g; \|extensions[.]getAddons[.]search[.]browseURL| s|https://addons[.]mozilla[.]org.\+["][)][;]|https://directory.fsf.org/wiki/Icedove");|g; \|extensions[.]getAddons[.]search[.]url| s|https://services[.]addons[.]mozilla[.]org.\+["][)][;]|https://directory.fsf.org/wiki/Icedove");|g; \|extensions[.]webservice[.]discoverURL| s|https://services[.]addons[.]mozilla[.]org.\+["][)][;]|https://directory.fsf.org/wiki/Icedove");|g; ' mail/app/profile/all-thunderbird.js - - # Remove support for unsafe and dangerous for privacy protocols sed -i '\|facebook|d \|gtalk|d \|odnoklassniki|d @@ -135,88 +173,106 @@ prepare() { ' mail/installer/package-manifest.in rm -rv chat/protocols/{facebook,gtalk,twitter,yahoo} - cp -v "$srcdir/mozconfig" .mozconfig - - # make sure we use python2 - mkdir "$srcdir/path" - ln -s /usr/bin/python2 "$srcdir/path/python" - - # Change the default search engine using our system-provided searchplugins - patch -Np1 -i "$srcdir/changing-the-default-search-engine.patch" + for i in 16 22 24 32 48 64 128 256; do + install -Dm644 $srcdir/$pkgname-$_bver/app-icons/$pkgname$i.png \ + mail/branding/$pkgname/mailicon$i.png + done + for i in 48 64; do + install -Dm644 $srcdir/$pkgname-$_bver/app-icons/$pkgname$i.png \ + mail/branding/$pkgname/content/icon$i.png + done + cp -av $srcdir/$pkgname-$_bver/preview.png \ + mail/themes/linux/mail/preview.png # Load our searchplugins rm -rv mail/locales/en-US/searchplugins cp -av /usr/lib/mozilla/searchplugins mail/locales/en-US/ - - # ARM-specific changes: - if [[ "$CARCH" == arm* ]]; then - # https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=850984 - sed -i 's/\^\[:space:\]\*/^[[:space:]]*/' mozilla/{,js/src/}configure - - patch -Np0 -i ../no-neon.patch - sed -i '/ac_add_options --enable-gold/d' .mozconfig - cat >> .mozconfig <<- EOF - ac_add_options --disable-elf-hack - ac_add_options --disable-neon - ac_add_options --disable-ion - ac_add_options --disable-webrtc - ac_add_options --disable-debug - ac_add_options --disable-debug-symbols - EOF - fi } build() { - cd "$srcdir/$_oldname-$pkgver" + cd $_pkgname-$pkgver # _FORTIFY_SOURCE causes configure failures CPPFLAGS+=" -O2" - # Hardening - LDFLAGS+=" -Wl,-z,now" - - # GCC 6 - CFLAGS+=" -fno-delete-null-pointer-checks -fno-lifetime-dse -fno-schedule-insns2" - CXXFLAGS+=" -fno-delete-null-pointer-checks -fno-lifetime-dse -fno-schedule-insns2" - export PATH="$srcdir/path:$PATH" - export PYTHON="/usr/bin/python2" + # Do PGO + #xvfb-run -a -n 95 -s "-extension GLX -screen 0 1280x1024x24" \ + # make -f client.mk build MOZ_PGO=1 make -f client.mk build } package() { - cd "$srcdir/$_oldname-$pkgver" - + cd $_pkgname-$pkgver make -f client.mk DESTDIR="$pkgdir" INSTALL_SDK= install - install -Dm644 "$srcdir/vendor.js" "$pkgdir/usr/lib/$pkgname/defaults/preferences/vendor.js" + _vendorjs="$pkgdir/usr/lib/$pkgname/defaults/preferences/vendor.js" + install -Dm644 /dev/stdin "$_vendorjs" < What's new" menu entry to mozilla.debian.net +pref("mailnews.start_page.override_url", "http://wiki.debian.org/Icedove/WhatsNew45"); +END + + _distini="$pkgdir/usr/lib/$pkgname/distribution/distribution.ini" + install -Dm644 /dev/stdin "$_distini" <