Merge staging-next-22.11 into staging-22.11

This commit is contained in:
github-actions[bot]
2023-06-11 00:15:18 +00:00
committed by GitHub
6 changed files with 504 additions and 423 deletions

View File

@@ -3,10 +3,10 @@
rec {
firefox = buildMozillaMach rec {
pname = "firefox";
version = "114.0";
version = "114.0.1";
src = fetchurl {
url = "mirror://mozilla/firefox/releases/${version}/source/firefox-${version}.source.tar.xz";
sha512 = "c6929d34583f25119738d1c817a24fd358fcada1f0ba5c14bab07c2acd35f18a012f23d054bfe8c6b12c0dda7bd3abdc7a305a36c7a4d36542885abeea3aafec";
sha512 = "d422982e0271a68aa8064977b3a6b6f9412a30e7261ba06385c416e00e8ba0eb488d81a8929355fc92d35469d3308ec928f00e4de7248ed6390d5d900d7bce8f";
};
meta = {

View File

@@ -6,6 +6,7 @@
, makeWrapper
, writeText
, wrapGAppsHook
, callPackage
# Common run-time dependencies
, zlib
@@ -77,12 +78,12 @@ let
++ lib.optionals mediaSupport [ ffmpeg ]
);
version = "12.0.6";
version = "12.0.7";
srcs = {
sources = {
x86_64-linux = fetchurl {
url = "https://cdn.mullvad.net/browser/${version}/mullvad-browser-linux64-${version}_ALL.tar.xz";
hash = "sha256-XE6HFU38FhnikxGHRHxIGS3Z3Y2JNWH0yq2NejqbROI=";
hash = "sha256-8TcC39A9VFyhFb+pfefzvwJqXq1yF7C2YDcbCyEa0yo=";
};
};
@@ -103,7 +104,7 @@ stdenv.mkDerivation rec {
pname = "mullvad-browser";
inherit version;
src = srcs.${stdenv.hostPlatform.system} or (throw "unsupported system: ${stdenv.hostPlatform.system}");
src = sources.${stdenv.hostPlatform.system} or (throw "unsupported system: ${stdenv.hostPlatform.system}");
nativeBuildInputs = [ copyDesktopItems makeWrapper wrapGAppsHook ];
@@ -219,11 +220,20 @@ stdenv.mkDerivation rec {
runHook postInstall
'';
passthru = {
inherit sources;
updateScript = callPackage ../tor-browser-bundle-bin/update.nix {
inherit pname version meta;
baseUrl = "https://cdn.mullvad.net/browser/";
prefix = "mullvad-browser-";
};
};
meta = with lib; {
description = "Privacy-focused browser made in a collaboration between The Tor Project and Mullvad";
homepage = "https://mullvad.net/en/browser";
platforms = attrNames srcs;
maintainers = with maintainers; [ felschr ];
platforms = attrNames sources;
maintainers = with maintainers; [ felschr panicgh ];
# MPL2.0+, GPL+, &c. While it's not entirely clear whether
# the compound is "libre" in a strict sense (some components place certain
# restrictions on redistribution), it's free enough for our purposes.

View File

@@ -2,6 +2,7 @@
, fetchurl
, makeDesktopItem
, writeText
, callPackage
# Common run-time dependencies
, zlib
@@ -90,11 +91,11 @@ let
fteLibPath = makeLibraryPath [ stdenv.cc.cc gmp ];
# Upstream source
version = "12.0.6";
version = "12.0.7";
lang = "ALL";
srcs = {
sources = {
x86_64-linux = fetchurl {
urls = [
"https://dist.torproject.org/torbrowser/${version}/tor-browser-linux64-${version}_${lang}.tar.xz"
@@ -102,7 +103,7 @@ let
"https://tor.eff.org/dist/torbrowser/${version}/tor-browser-linux64-${version}_${lang}.tar.xz"
"https://tor.calyxinstitute.org/dist/torbrowser/${version}/tor-browser-linux64-${version}_${lang}.tar.xz"
];
hash = "sha256-MLy/T8A+udasITWYSzaqXSFhA3PJsG7DnKJG0b9UYvA=";
hash = "sha256-lo+Iy6I7S1NV1E9CBPqJjRFzuEXGC80NRUUlpZfG5wU=";
};
i686-linux = fetchurl {
@@ -112,7 +113,7 @@ let
"https://tor.eff.org/dist/torbrowser/${version}/tor-browser-linux32-${version}_${lang}.tar.xz"
"https://tor.calyxinstitute.org/dist/torbrowser/${version}/tor-browser-linux32-${version}_${lang}.tar.xz"
];
hash = "sha256-njJB5k7rQxRyL7foU8fLCQxy43dJvV26oKvQ+fw6U0o=";
hash = "sha256-aLHZUFDZZ4i7BXoM5YxPrznYw812/OGmhG97t9okOvs=";
};
};
@@ -133,7 +134,7 @@ stdenv.mkDerivation rec {
pname = "tor-browser-bundle-bin";
inherit version;
src = srcs.${stdenv.hostPlatform.system} or (throw "unsupported system: ${stdenv.hostPlatform.system}");
src = sources.${stdenv.hostPlatform.system} or (throw "unsupported system: ${stdenv.hostPlatform.system}");
preferLocalBuild = true;
allowSubstitutes = false;
@@ -445,6 +446,13 @@ stdenv.mkDerivation rec {
runHook postInstall
'';
passthru = {
inherit sources;
updateScript = callPackage ./update.nix {
inherit pname version meta;
};
};
meta = with lib; {
description = "Tor Browser Bundle built by torproject.org";
longDescription = ''
@@ -458,8 +466,8 @@ stdenv.mkDerivation rec {
'';
homepage = "https://www.torproject.org/";
changelog = "https://gitweb.torproject.org/builders/tor-browser-build.git/plain/projects/tor-browser/Bundle-Data/Docs/ChangeLog.txt?h=maint-${version}";
platforms = attrNames srcs;
maintainers = with maintainers; [ offline matejc thoughtpolice joachifm hax404 KarlJoad ];
platforms = attrNames sources;
maintainers = with maintainers; [ felschr panicgh joachifm hax404 ];
mainProgram = "tor-browser";
# MPL2.0+, GPL+, &c. While it's not entirely clear whether
# the compound is "libre" in a strict sense (some components place certain

View File

@@ -0,0 +1,62 @@
{ lib
, writeShellScript
, coreutils
, gnused
, gnugrep
, curl
, gnupg
, nix
, common-updater-scripts
# options
, pname
, version
, meta
, baseUrl ? "https://dist.torproject.org/torbrowser/"
# prefix used to match published archive
, prefix ? "tor-browser-"
# suffix used to match published archive
, suffix ? "_ALL.tar.xz"
}:
writeShellScript "update-${pname}" ''
PATH="${lib.makeBinPath [ coreutils curl gnugrep gnused gnupg nix common-updater-scripts ]}"
set -euo pipefail
trap
url=${baseUrl}
version=$(curl -s $url \
| sed -rne 's,^.*href="([0-9]+(\.[0-9]+)*)/".*,\1,p' \
| sort --version-sort | tail -1)
if [[ "${version}" = "$version" ]]; then
echo "The new version same as the old version."
exit 0
fi
HOME=$(mktemp -d)
export GNUPGHOME=$(mktemp -d)
trap 'rm -rf "$HOME" "$GNUPGHOME"' EXIT
gpg --auto-key-locate nodefault,wkd --locate-keys torbrowser@torproject.org
gpg --output $HOME/tor.keyring --export 0xEF6E286DDA85EA2A4BA7DE684E2C6E8793298290
curl --silent --show-error --fail -o $HOME/shasums "$url$version/sha256sums-signed-build.txt"
curl --silent --show-error --fail -o $HOME/shasums.asc "$url$version/sha256sums-signed-build.txt.asc"
gpgv --keyring=$HOME/tor.keyring $HOME/shasums.asc $HOME/shasums
declare -A platforms=(
['x86_64-linux']='linux64'
['i686-linux']='linux32'
)
for platform in ${lib.escapeShellArgs meta.platforms}; do
arch="''${platforms[$platform]}"
sha256=$(cat "$HOME/shasums" | grep "${prefix}""$arch-$version""${suffix}" | cut -d" " -f1)
hash=$(nix hash to-sri --type sha256 "$sha256")
update-source-version "${pname}" "0" "sha256-${lib.fakeSha256}" --source-key="sources.$platform"
update-source-version "${pname}" "$version" "$hash" --source-key="sources.$platform"
done
''

View File

@@ -15,13 +15,13 @@
stdenv.mkDerivation rec {
pname = "acme.sh";
version = "3.0.4";
version = "3.0.6";
src = fetchFromGitHub {
owner = "acmesh-official";
repo = "acme.sh";
rev = version;
sha256 = "sha256-PHxL48Gj6CJG4r3LXKQCU0KARmTu7DQrC29oLi7gvU8=";
rev = "refs/tags/${version}";
hash = "sha256-4Chqdr4a9+T+/o1vCPY5xMREoYl0HxY3OlGRD86ulGs=";
};
nativeBuildInputs = [
@@ -53,6 +53,7 @@ stdenv.mkDerivation rec {
meta = with lib; {
homepage = "https://acme.sh/";
changelog = "https://github.com/acmesh-official/acme.sh/releases/tag/${version}";
description = "A pure Unix shell script implementing ACME client protocol";
longDescription = ''
An ACME Shell script: acme.sh