Merge pull request #217930 from SuperSandro2000/betterbird
betterbird: init at 102.8.0-bb30
This commit is contained in:
commit
c972d6df96
6 changed files with 169 additions and 2 deletions
|
@ -541,6 +541,7 @@ buildStdenv.mkDerivation ({
|
|||
'';
|
||||
|
||||
passthru = {
|
||||
inherit application extraPatches;
|
||||
inherit updateScript;
|
||||
inherit version;
|
||||
inherit alsaSupport;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{ stdenv, lib, callPackage, fetchurl, fetchpatch, nixosTests, buildMozillaMach }:
|
||||
|
||||
rec {
|
||||
{
|
||||
firefox = buildMozillaMach rec {
|
||||
pname = "firefox";
|
||||
version = "112.0.2";
|
||||
|
|
|
@ -0,0 +1,44 @@
|
|||
--- a/12-feature-linux-systray-example.patch
|
||||
+++ b/12-feature-linux-systray-example.patch
|
||||
@@ -8,18 +8,15 @@ diff --git a/third_party/appindicator/Makefile b/third_party/appindicator/Makefi
|
||||
new file mode 100644
|
||||
--- /dev/null
|
||||
+++ b/third_party/appindicator/Makefile
|
||||
-@@ -0,0 +1,34 @@
|
||||
+@@ -0,0 +1,31 @@
|
||||
+# Code from https://github.com/AyatanaIndicators/libayatana-appindicator
|
||||
+# and related repositories.
|
||||
+# See https://github.com/AyatanaIndicators/libayatana-appindicator/issues/46 for build instructions.
|
||||
+# You need: sudo aptitude install libdbusmenu-gtk3-dev
|
||||
+
|
||||
-+CFLAGS=`pkg-config --cflags gtk+-3.0 glib-2.0` \
|
||||
-+ -I/usr/include/libdbusmenu-glib-0.4/ \
|
||||
-+ -I/usr/include/libdbusmenu-gtk3-0.4/ \
|
||||
-+ -I/usr/include/glib-2.0
|
||||
++CFLAGS=`pkg-config --cflags gtk+-3.0 glib-2.0 dbusmenu-gtk3-0.4` \
|
||||
+
|
||||
-+LDFLAGS=`pkg-config --libs gtk+-3.0 glib-2.0` -ldbusmenu-glib -ldbusmenu-gtk3
|
||||
++LDFLAGS=`pkg-config --libs dbusmenu-gtk3-0.4`
|
||||
+
|
||||
+OBJECTS=betterbird-systray-icon.o \
|
||||
+ app-indicator.o \
|
||||
--- a/1790619-send-progress-width.patch
|
||||
+++ b/1790619-send-progress-width.patch
|
||||
@@ -31,6 +21,7 @@
|
||||
scrolling="false">
|
||||
<head>
|
||||
<title>&sendDialog.title;</title>
|
||||
+ <link rel="localization" href="branding/brand.ftl" />
|
||||
+ <script defer="defer" src="chrome://messenger/content/dialogShadowDom.js"></script>
|
||||
<script defer="defer" src="chrome://messenger/content/messengercompose/sendProgress.js"></script>
|
||||
- <script defer="defer" src="chrome://messenger/content/dialogShadowDom.js"></script>
|
||||
--- a/1777788-fix-dialog-size.patch
|
||||
+++ b/1777788-fix-dialog-size.patch
|
||||
@@ -22,6 +22,7 @@ diff --git a/mailnews/compose/content/sendProgress.xhtml b/mailnews/compose/cont
|
||||
scrolling="false">
|
||||
<head>
|
||||
<title>&sendDialog.title;</title>
|
||||
+ <link rel="localization" href="branding/brand.ftl" />
|
||||
<script defer="defer" src="chrome://messenger/content/dialogShadowDom.js"></script>
|
||||
<script defer="defer" src="chrome://messenger/content/messengercompose/sendProgress.js"></script>
|
||||
</head>
|
116
pkgs/applications/networking/mailreaders/betterbird/default.nix
Normal file
116
pkgs/applications/networking/mailreaders/betterbird/default.nix
Normal file
|
@ -0,0 +1,116 @@
|
|||
{ lib
|
||||
, buildMozillaMach
|
||||
, cacert
|
||||
, fetchFromGitHub
|
||||
, fetchurl
|
||||
, git
|
||||
, libdbusmenu-gtk3
|
||||
, runtimeShell
|
||||
, thunderbird-unwrapped
|
||||
}:
|
||||
|
||||
((buildMozillaMach rec {
|
||||
pname = "betterbird";
|
||||
version = "102.8.0";
|
||||
|
||||
applicationName = "Betterbird";
|
||||
binaryName = "betterbird";
|
||||
inherit (thunderbird-unwrapped) application extraPatches;
|
||||
|
||||
src = fetchurl {
|
||||
# https://download.cdn.mozilla.net/pub/mozilla.org/thunderbird/releases/
|
||||
url = "mirror://mozilla/thunderbird/releases/${version}/source/thunderbird-${version}.source.tar.xz";
|
||||
sha512 = "2431eb8799184b261609c96bed3c9368bec9035a831aa5f744fa89e48aedb130385b268dd90f03bbddfec449dc3e5fad1b5f8727fe9e11e1d1f123a81b97ddf8";
|
||||
};
|
||||
|
||||
extraPostPatch = let
|
||||
majVer = lib.versions.major version;
|
||||
betterbird = fetchFromGitHub {
|
||||
owner = "Betterbird";
|
||||
repo = "thunderbird-patches";
|
||||
rev = "${version}-bb30";
|
||||
postFetch = ''
|
||||
echo "Retrieving external patches"
|
||||
|
||||
echo "#!${runtimeShell}" > external.sh
|
||||
grep " # " $out/${majVer}/series-M-C >> external.sh
|
||||
grep " # " $out/${majVer}/series >> external.sh
|
||||
sed -i -e 's/\/rev\//\/raw-rev\//' external.sh
|
||||
sed -i -e 's|\(.*\) # \(.*\)|curl \2 -o $out/${majVer}/external/\1|' external.sh
|
||||
chmod 700 external.sh
|
||||
|
||||
mkdir $out/${majVer}/external
|
||||
SSL_CERT_FILE=${cacert}/etc/ssl/certs/ca-bundle.crt
|
||||
. ./external.sh
|
||||
rm external.sh
|
||||
'';
|
||||
sha256 = "sha256-ouJSFz/5shNR9puVjrZRJq90DHTeSx7hAnDpuhkBsDo=";
|
||||
};
|
||||
in thunderbird-unwrapped.extraPostPatch or "" + /* bash */ ''
|
||||
PATH=$PATH:${lib.makeBinPath [ git ]}
|
||||
patches=$(mktemp -d)
|
||||
for dir in branding bugs external features misc; do
|
||||
cp -r ${betterbird}/${majVer}/$dir/*.patch $patches/
|
||||
done
|
||||
cp ${betterbird}/${majVer}/series* $patches/
|
||||
chmod -R +w $patches
|
||||
|
||||
cd $patches
|
||||
patch -p1 < ${./betterbird.diff}
|
||||
substituteInPlace 12-feature-linux-systray.patch \
|
||||
--replace "/usr/include/libdbusmenu-glib-0.4/" "${lib.getDev libdbusmenu-gtk3}/include/libdbusmenu-glib-0.4/" \
|
||||
--replace "/usr/include/libdbusmenu-gtk3-0.4/" "${lib.getDev libdbusmenu-gtk3}/include/libdbusmenu-gtk3-0.4/"
|
||||
cd -
|
||||
|
||||
chmod -R +w dom/base/test/gtest/
|
||||
|
||||
while read patch; do
|
||||
patch="''${patch%%#*}"
|
||||
patch="''${patch% }"
|
||||
if [[ $patch == "" ]]; then
|
||||
continue
|
||||
fi
|
||||
|
||||
echo Applying patch $patch.
|
||||
if [[ $patch == *-m-c.patch ]]; then
|
||||
git apply -p1 -v < $patches/$patch
|
||||
else
|
||||
cd comm
|
||||
git apply -p1 -v < $patches/$patch
|
||||
cd ..
|
||||
fi
|
||||
done < <(cat $patches/series $patches/series-M-C)
|
||||
'';
|
||||
|
||||
extraBuildInputs = [
|
||||
libdbusmenu-gtk3
|
||||
];
|
||||
|
||||
extraConfigureFlags = [
|
||||
"--enable-application=comm/mail"
|
||||
"--with-branding=comm/mail/branding/betterbird"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Betterbird is a fine-tuned version of Mozilla Thunderbird, Thunderbird on steroids, if you will";
|
||||
homepage = "https://www.betterbird.eu/";
|
||||
maintainers = with maintainers; [ SuperSandro2000 ];
|
||||
inherit (thunderbird-unwrapped.meta) platforms badPlatforms broken license;
|
||||
};
|
||||
}).override {
|
||||
crashreporterSupport = false; # not supported
|
||||
geolocationSupport = false;
|
||||
webrtcSupport = false;
|
||||
|
||||
pgoSupport = false; # console.warn: feeds: "downloadFeed: network connection unavailable"
|
||||
}).overrideAttrs(oldAttrs: {
|
||||
postInstall = oldAttrs.postInstall or "" + ''
|
||||
mv $out/lib/thunderbird/* $out/lib/betterbird
|
||||
rmdir $out/lib/thunderbird/
|
||||
rm $out/bin/thunderbird
|
||||
ln -srf $out/lib/betterbird/betterbird $out/bin/betterbird
|
||||
'';
|
||||
|
||||
doInstallCheck = false;
|
||||
requiredSystemFeatures = [];
|
||||
})
|
|
@ -16,7 +16,7 @@ args:
|
|||
# For that to work out of the box, it requires `gnupg` on PATH and
|
||||
# `gpgme` in `LD_LIBRARY_PATH`; we do this below.
|
||||
buildCommand = old.buildCommand + ''
|
||||
wrapProgram $out/bin/thunderbird \
|
||||
wrapProgram $out/bin/${browser.binaryName} \
|
||||
--prefix LD_LIBRARY_PATH ':' "${lib.makeLibraryPath [ gpgme ]}" \
|
||||
--prefix PATH ':' "${lib.makeBinPath [ gnupg ]}"
|
||||
'';
|
||||
|
|
|
@ -34228,6 +34228,12 @@ with pkgs;
|
|||
|
||||
thonny = callPackage ../applications/editors/thonny { };
|
||||
|
||||
betterbird-unwrapped = callPackage ../applications/networking/mailreaders/betterbird { };
|
||||
betterbird = wrapThunderbird betterbird-unwrapped {
|
||||
desktopName = "Betterbird";
|
||||
pname = "betterbird";
|
||||
};
|
||||
|
||||
thunderbirdPackages = recurseIntoAttrs (callPackage ../applications/networking/mailreaders/thunderbird/packages.nix {
|
||||
callPackage = newScope {
|
||||
inherit (rustPackages) cargo rustc;
|
||||
|
|
Loading…
Reference in a new issue