updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / thunderbird-ldap / PKGBUILD
blob401711a7b65e379195b55a98d9264dddf8be600a
1 # Maintainer: Xavier Devlamynck <magicrhesus@ouranos.be>
2 # Contributor: Clement Demoulins <clement@archivel.fr>
3 # Contributor: Alexander Baldeck <alexander@archlinux.org>
4 # Contributor: Dale Blount <dale@archlinux.org>
5 # Contributor: Anders Bostrom <anders.bostrom@home.se>
6 pkgname=thunderbird-ldap
7 pkgver=3.1.10
8 pkgrel=2
9 pkgdesc="Standalone Mail/News reader"
10 arch=('i686' 'x86_64')
11 license=('MPL' 'GPL')
12 url="http://www.mozilla.org/projects/thunderbird"
13 depends=('gtk2' 'gcc-libs' 'mozilla-common' 'nss' 'libxt' 'shared-mime-info' 'alsa-lib' 'dbus-glib' 'hunspell' 'sqlite3>=3.7.4' 'desktop-file-utils' 'libnotify')
14 makedepends=('zip' 'pkg-config' 'python2' 'libidl2' 'wireless_tools' 'autoconf2.13')
15 optdepends=('libcanberra: for sound support')
16 install=thunderbird.install
17 source=(ftp://ftp.mozilla.org/pub/mozilla.org/thunderbird/releases/${pkgver}/source/thunderbird-${pkgver}.source.tar.bz2
18         mozconfig
19         thunderbird.desktop
20         thunderbird-3.0-lang.patch
21         thunderbird-appversion.patch
22         thunderbird-shared-error.patch
23         xulrunner-png14.patch
24         python2.7.patch
25         gcc46.patch
26         experimental_writeable_ldap.patch)
27 md5sums=('2a81f3ee7ea7acff0ee2eaee6574ea11'
28          '529d4caad3027116ab9e000438ca70fa'
29          '37457073c7f6feeb86c053701d23197f'
30          '25b6fe16ac24cd5c852213e5c1adb272'
31          '48ffcdb877a69d383b7d354e330f7658'
32          '3dca714ee8054634e6dfdb059464dc42'
33          '989b15f6bc9e2e9233fe4c6b23f412b1'
34          '78a4d0c920cbb8ec6a9a36974cd775ef'
35          'a2bced1791fb8eca978d31b129f92a28'
36          '7422528ec26a578203d6f3276c64c713')
38 build() {
39   cd "${srcdir}/comm-1.9.2"
40   patch -Np1 -i "${srcdir}/thunderbird-3.0-lang.patch"
41   patch -Np1 -i "${srcdir}/thunderbird-appversion.patch"
42   patch -Np1 -i "${srcdir}/thunderbird-shared-error.patch"
43   patch -Np1 -i "${srcdir}/gcc46.patch"
44   patch -Np0 -i "${srcdir}/xulrunner-png14.patch"
45   patch -Np0 -i "${srcdir}/python2.7.patch"
46   patch -Np0 -i "${srcdir}/experimental_writeable_ldap.patch" "${srcdir}/comm-1.9.2/mailnews/addrbook/src/nsAbLDAPDirectory.cpp"
48   cp "${srcdir}/mozconfig" .mozconfig
49   unset CXXFLAGS
50   unset CFLAGS
52   export CXXFLAGS="-fpermissive"
53   export LDFLAGS="-Wl,-rpath,/usr/lib/thunderbird-3.1"
55   make -j1 -f client.mk build MOZ_MAKE_FLAGS="${MAKEFLAGS}"
58 package() {
59   cd "${srcdir}/comm-1.9.2"
60   make -j1 DESTDIR="${pkgdir}" install
62   #Remove included dictionaries, add symlink to system myspell path.
63   #Note: this will cause file conflicts when users have installed dictionaries in the old location
64   rm -rf "${pkgdir}/usr/lib/thunderbird-3.1/dictionaries"
65   ln -sf /usr/share/myspell/dicts "${pkgdir}/usr/lib/thunderbird-3.1/dictionaries"
67   rm -rf "${pkgdir}/usr/bin/defaults"
69   install -m755 -d "${pkgdir}/usr/share/applications"
71   for i in 16x16 22x22 24x24 32x32 48x48 256x256; do
72       install -d "$pkgdir/usr/share/icons/hicolor/$i/apps"
73       cp other-licenses/branding/thunderbird/mailicon${i/x*/}.png "$pkgdir/usr/share/icons/hicolor/$i/apps/thunderbird.png"
74   done
76   install -m644 "${srcdir}/thunderbird.desktop" "${pkgdir}/usr/share/applications/"
78   rm -f ${pkgdir}/usr/lib/pkgconfig/thunderbird-ns{s,pr}.pc