From 00f75d8a4f6007c8e22cb93902eac30fe686a546 Mon Sep 17 00:00:00 2001 From: Jonas Heinrich Date: Mon, 10 Jan 2022 14:39:52 +0100 Subject: [PATCH] bluemail: init at 1.131.4-1795 --- .../mailreaders/bluemail/default.nix | 82 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 + 2 files changed, 84 insertions(+) create mode 100644 pkgs/applications/networking/mailreaders/bluemail/default.nix diff --git a/pkgs/applications/networking/mailreaders/bluemail/default.nix b/pkgs/applications/networking/mailreaders/bluemail/default.nix new file mode 100644 index 000000000000..50dec500870a --- /dev/null +++ b/pkgs/applications/networking/mailreaders/bluemail/default.nix @@ -0,0 +1,82 @@ +{ stdenv +, lib +, fetchurl +, dpkg +, autoPatchelfHook +, pango +, gtk3 +, alsa-lib +, nss +, libXdamage +, libdrm +, mesa +, libxshmfence +, makeWrapper +, wrapGAppsHook +, gcc-unwrapped +, udev +}: + +stdenv.mkDerivation rec { + pname = "bluemail"; + version = "1.131.4-1795"; + + # Taking a snapshot of the DEB release because there are no tagged version releases. + # For new versions, download the upstream release, extract it and check for the version string. + # In case there's a new version, create a snapshot of it on https://archive.org before updating it here. + src = fetchurl { + url = "https://web.archive.org/web/20220921124548/https://download.bluemail.me/BlueMail/deb/BlueMail.deb"; + sha256 = "sha256-deO+D9HSfj1YEDSO5Io0MA7H8ZK9iFSRwB/e+8GkgOU="; + }; + + nativeBuildInputs = [ + autoPatchelfHook + makeWrapper + dpkg + wrapGAppsHook + ]; + + buildInputs = [ + pango + gtk3 + alsa-lib + nss + libXdamage + libdrm + mesa + libxshmfence + udev + ]; + + unpackCmd = "${dpkg}/bin/dpkg-deb -x $src debcontents"; + + dontBuild = true; + dontStrip = true; + dontWrapGApps = true; + + installPhase = '' + mkdir -p $out/bin + mv opt/BlueMail/* $out + ln -s $out/bluemail $out/bin/bluemail + ''; + + makeWrapperArgs = [ + "--prefix LD_LIBRARY_PATH : ${lib.makeLibraryPath [ gcc-unwrapped.lib gtk3 udev ]}" + "--prefix PATH : ${lib.makeBinPath [ stdenv.cc ]}" + ]; + + preFixup = '' + wrapProgram $out/bin/bluemail \ + ''${makeWrapperArgs[@]} \ + ''${gappsWrapperArgs[@]} + ''; + + meta = with lib; { + description = "Free, secure, universal email app, capable of managing an unlimited number of mail accounts"; + homepage = "https://bluemail.me"; + license = licenses.unfree; + platforms = platforms.linux; + sourceProvenance = with sourceTypes; [ binaryNativeCode ]; + maintainers = with maintainers; [ onny ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 2f250222cc5e..3fa5de6054fa 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -26955,6 +26955,8 @@ with pkgs; bluejeans-gui = callPackage ../applications/networking/instant-messengers/bluejeans { }; + bluemail = callPackage ../applications/networking/mailreaders/bluemail { }; + blugon = callPackage ../applications/misc/blugon { }; bombadillo = callPackage ../applications/networking/browsers/bombadillo { };