about summary refs log tree commit diff
path: root/pkgs
diff options
context:
space:
mode:
authorNicolas Pierron <nicolas.b.pierron@gmail.com>2011-08-20 14:30:09 +0000
committerNicolas Pierron <nicolas.b.pierron@gmail.com>2011-08-20 14:30:09 +0000
commit1738fca3855be94cd957a293e19680d4cd31ce92 (patch)
treeb846a254157957edd6f58142a0ab4b8dfa8d950f /pkgs
parent9e53a20f501f629fcf50f78a5931be693c7f4977 (diff)
downloadnixlib-1738fca3855be94cd957a293e19680d4cd31ce92.tar
nixlib-1738fca3855be94cd957a293e19680d4cd31ce92.tar.gz
nixlib-1738fca3855be94cd957a293e19680d4cd31ce92.tar.bz2
nixlib-1738fca3855be94cd957a293e19680d4cd31ce92.tar.lz
nixlib-1738fca3855be94cd957a293e19680d4cd31ce92.tar.xz
nixlib-1738fca3855be94cd957a293e19680d4cd31ce92.tar.zst
nixlib-1738fca3855be94cd957a293e19680d4cd31ce92.zip
Add Thunderbird 5.0.
svn path=/nixpkgs/trunk/; revision=28710
Diffstat (limited to 'pkgs')
-rw-r--r--pkgs/applications/networking/mailreaders/thunderbird/5.x.nix83
-rw-r--r--pkgs/top-level/all-packages.nix4
2 files changed, 87 insertions, 0 deletions
diff --git a/pkgs/applications/networking/mailreaders/thunderbird/5.x.nix b/pkgs/applications/networking/mailreaders/thunderbird/5.x.nix
new file mode 100644
index 000000000000..473b83edb401
--- /dev/null
+++ b/pkgs/applications/networking/mailreaders/thunderbird/5.x.nix
@@ -0,0 +1,83 @@
+{ stdenv, fetchurl, pkgconfig, gtk, perl, python, zip, libIDL
+, dbus_glib, bzip2, alsaLib, nspr, yasm, mesa, nss
+, libnotify, cairo, pixman, fontconfig
+
+, # If you want the resulting program to call itself "Thunderbird"
+  # instead of "Shredder", enable this option.  However, those
+  # binaries may not be distributed without permission from the
+  # Mozilla Foundation, see
+  # http://www.mozilla.org/foundation/trademarks/.
+  enableOfficialBranding ? false
+
+}:
+
+let version = "5.0"; in
+
+# from wikipedia: This Release no longer supports versions of Mac OS X
+# before Mac OS X 10.5 Leopard or Mac computers with PowerPC processors.
+stdenv.mkDerivation {
+  name = "thunderbird-${version}";
+
+  src = fetchurl {
+    url = "http://releases.mozilla.org/pub/mozilla.org/thunderbird/releases/${version}/source/thunderbird-${version}.source.tar.bz2";
+    sha1 = "392c3e0ef70b62c29a543f88b2b8d5a51bfe69a7";
+  };
+
+  buildInputs =
+    [ pkgconfig perl python zip bzip2 gtk dbus_glib alsaLib libIDL nspr libnotify
+      libnotify cairo pixman fontconfig yasm mesa nss
+    ];
+
+  patches = [
+    # Fix weird dependencies such as a so file which depends on "-lpthread".
+    ./thunderbird-build-deps.patch
+  ];
+
+  NIX_LDFLAGS = "-lpixman-1";
+
+  configureFlags =
+    [ "--enable-application=mail"
+      "--enable-optimize"
+      "--disable-debug"
+      "--enable-strip"
+      "--with-system-jpeg"
+      "--with-system-zlib"
+      # "--with-system-bz2"
+      "--with-system-nspr"
+      "--enable-system-cairo"
+      "--disable-crashreporter"
+      "--disable-necko-wifi"
+      "--disable-tests"
+      "--enable-calendar"
+    ]
+    ++ stdenv.lib.optional enableOfficialBranding "--enable-official-branding";
+
+  # The Thunderbird Makefiles refer to the variables LIBXUL_DIST,
+  # prefix, and PREFIX in some places where they are not set.  In
+  # particular, there are some linker flags like
+  # `-rpath-link=$(LIBXUL_DIST)/bin'.  Since this expands to
+  # `-rpath-link=/bin', the build fails due to the purity checks in
+  # the ld wrapper.  So disable the purity check for now.
+  preBuild = "NIX_ENFORCE_PURITY=0";
+
+  # This doesn't work:
+  #makeFlags = "LIBXUL_DIST=$(out) prefix=$(out) PREFIX=$(out)";
+
+  postInstall =
+    ''
+      # Fix some references to /bin paths in the Xulrunner shell script.
+      substituteInPlace $out/lib/thunderbird-*/thunderbird \
+          --replace /bin/pwd "$(type -tP pwd)" \
+          --replace /bin/ls "$(type -tP ls)"
+    '';
+
+  meta = with stdenv.lib; {
+    description = "Mozilla Thunderbird, a full-featured email client";
+    homepage = http://www.mozilla.com/en-US/thunderbird/;
+    license =
+      # Official branding implies thunderbird name and logo cannot be reuse,
+      # see http://www.mozilla.org/foundation/licensing.html
+      if enableOfficialBranding then licenses.proprietary else licenses.mpl11;
+    maintainers = with maintainers; [ pierron ];
+  };
+}
diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix
index 085543c788f5..f5d669b9e1e9 100644
--- a/pkgs/top-level/all-packages.nix
+++ b/pkgs/top-level/all-packages.nix
@@ -7262,6 +7262,10 @@ let
     inherit (gnome) libIDL;
   };
 
+  thunderbird5 = callPackage ../applications/networking/mailreaders/thunderbird/5.x.nix {
+    inherit (gnome) libIDL;
+  };
+
   timidity = callPackage ../tools/misc/timidity { };
 
   tkcvs = callPackage ../applications/version-management/tkcvs { };