From 05a82f0f468d0064c01911af2b43f2d57bd16984 Mon Sep 17 00:00:00 2001 From: Martin Weinelt Date: Tue, 1 Jun 2021 01:25:19 +0200 Subject: [PATCH 1/2] rust-cbindgen_latest: init at 0.19.0 --- .../tools/rust/cbindgen/latest.nix | 38 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 4 ++ 2 files changed, 42 insertions(+) create mode 100644 pkgs/development/tools/rust/cbindgen/latest.nix diff --git a/pkgs/development/tools/rust/cbindgen/latest.nix b/pkgs/development/tools/rust/cbindgen/latest.nix new file mode 100644 index 00000000000..c1bc2fb4c07 --- /dev/null +++ b/pkgs/development/tools/rust/cbindgen/latest.nix @@ -0,0 +1,38 @@ +{ lib, stdenv, fetchFromGitHub, rustPlatform, python3Packages, Security }: + +rustPlatform.buildRustPackage rec { + pname = "rust-cbindgen"; + version = "0.19.0"; + + src = fetchFromGitHub { + owner = "eqrion"; + repo = "cbindgen"; + rev = "v${version}"; + sha256 = "0753dklr5lm1dmk6hy5khh8k3xyr5srfsq11l07685h71j7z0r00"; + }; + + cargoSha256 = "0qyw0iqin7i31kk23ddsmywk7z0xxpd5n4q6dr6mf44y35a8krm8"; + + buildInputs = lib.optional stdenv.isDarwin Security; + + checkInputs = [ + python3Packages.cython + ]; + + checkFlags = [ + # Disable tests that require rust unstable features + # https://github.com/eqrion/cbindgen/issues/338 + "--skip test_expand" + "--skip test_bitfield" + "--skip lib_default_uses_debug_build" + "--skip lib_explicit_debug_build" + "--skip lib_explicit_release_build" + ]; + + meta = with lib; { + description = "A project for generating C bindings from Rust code"; + homepage = "https://github.com/eqrion/cbindgen"; + license = licenses.mpl20; + maintainers = with maintainers; [ jtojnar ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index e563a29cb2e..17f6ef9e8c0 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -11758,6 +11758,10 @@ in rust-cbindgen = callPackage ../development/tools/rust/cbindgen { inherit (darwin.apple_sdk.frameworks) Security; }; + rust-cbindgen_latest = callPackage ../development/tools/rust/cbindgen/latest.nix { + inherit (darwin.apple_sdk.frameworks) Security; + }; + rustup = callPackage ../development/tools/rust/rustup { inherit (darwin.apple_sdk.frameworks) CoreServices Security; }; From 66959b52fda9191ccde1327046528ed361f05d03 Mon Sep 17 00:00:00 2001 From: Martin Weinelt Date: Mon, 31 May 2021 13:31:09 +0200 Subject: [PATCH 2/2] firefox: 88.0.1 -> 89.0 https://www.mozilla.org/en-US/firefox/89.0/releasenotes/ (cherry picked from commit bcc35ef63fbabdd9e0b03213fb4af67dedf4c359) --- pkgs/applications/networking/browsers/firefox/common.nix | 8 +++++++- .../applications/networking/browsers/firefox/packages.nix | 4 ++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/pkgs/applications/networking/browsers/firefox/common.nix b/pkgs/applications/networking/browsers/firefox/common.nix index e35fd6ca701..62e641280b6 100644 --- a/pkgs/applications/networking/browsers/firefox/common.nix +++ b/pkgs/applications/networking/browsers/firefox/common.nix @@ -16,6 +16,10 @@ ### optionals +## backported libraries + +, rust-cbindgen_latest + ## optional libraries , alsaSupport ? stdenv.isLinux, alsaLib @@ -90,6 +94,8 @@ let then "/Applications/${binaryNameCapitalized}.app/Contents/MacOS" else "/bin"; + rust-cbindgen_pkg = if lib.versionAtLeast ffversion "89" then rust-cbindgen_latest else rust-cbindgen; + # 78 ESR won't build with rustc 1.47 inherit (if lib.versionAtLeast ffversion "82" then rustPackages else rustPackages_1_45) rustc cargo; @@ -226,7 +232,7 @@ buildStdenv.mkDerivation ({ perl pkg-config python3 - rust-cbindgen + rust-cbindgen_pkg rustc which unzip diff --git a/pkgs/applications/networking/browsers/firefox/packages.nix b/pkgs/applications/networking/browsers/firefox/packages.nix index 05f2524f949..b4d87b859ae 100644 --- a/pkgs/applications/networking/browsers/firefox/packages.nix +++ b/pkgs/applications/networking/browsers/firefox/packages.nix @@ -7,10 +7,10 @@ in rec { firefox = common rec { pname = "firefox"; - ffversion = "88.0.1"; + ffversion = "89.0"; src = fetchurl { url = "mirror://mozilla/firefox/releases/${ffversion}/source/firefox-${ffversion}.source.tar.xz"; - sha512 = "e2d7fc950ba49f225c83ee1d799d6318fcf16c33a3b7f40b85c49d5b7865f7e632c703e5fd227a303b56e2565d0796283ebb12d7fd1a02781dcaa45e84cea934"; + sha512 = "5089720feda15d054d0aa4c3bdeb84760314dadd6381d7360e688d8e396154868220c6315add650d8d2a42652cb8a9bfeb833885812ef0bd70a74ee58ad18aa3"; }; meta = {