summary refs log tree commit diff
diff options
context:
space:
mode:
authorArtturi <Artturin@artturin.com>2021-11-20 01:14:44 +0200
committerGitHub <noreply@github.com>2021-11-20 01:14:44 +0200
commitdd4ce550b3e0195e16b4b93e096e3d4b3a6af425 (patch)
tree25384d423b38f1c0f79b1f7cea072abc878b55ac
parentc03139da1d1cfddad0aa1b566cf5d5ddb8f03f5f (diff)
parenta96a6e751593609014b854ad40e2836c03c8a887 (diff)
downloadnixpkgs-dd4ce550b3e0195e16b4b93e096e3d4b3a6af425.tar
nixpkgs-dd4ce550b3e0195e16b4b93e096e3d4b3a6af425.tar.gz
nixpkgs-dd4ce550b3e0195e16b4b93e096e3d4b3a6af425.tar.bz2
nixpkgs-dd4ce550b3e0195e16b4b93e096e3d4b3a6af425.tar.lz
nixpkgs-dd4ce550b3e0195e16b4b93e096e3d4b3a6af425.tar.xz
nixpkgs-dd4ce550b3e0195e16b4b93e096e3d4b3a6af425.tar.zst
nixpkgs-dd4ce550b3e0195e16b4b93e096e3d4b3a6af425.zip
Merge pull request #146456 from Artturin/misc-updates1
-rw-r--r--nixos/modules/virtualisation/qemu-vm.nix2
-rw-r--r--pkgs/os-specific/linux/crda/default.nix36
-rw-r--r--pkgs/os-specific/linux/kmod-blacklist-ubuntu/default.nix6
-rw-r--r--pkgs/tools/admin/google-cloud-sdk/default.nix2
4 files changed, 24 insertions, 22 deletions
diff --git a/nixos/modules/virtualisation/qemu-vm.nix b/nixos/modules/virtualisation/qemu-vm.nix
index 67fde55faab..0c2782d3e02 100644
--- a/nixos/modules/virtualisation/qemu-vm.nix
+++ b/nixos/modules/virtualisation/qemu-vm.nix
@@ -845,7 +845,7 @@ in
         ''-append "$(cat ${config.system.build.toplevel}/kernel-params) init=${config.system.build.toplevel}/init regInfo=${regInfo}/registration ${consoles} $QEMU_KERNEL_PARAMS"''
       ])
       (mkIf cfg.useEFIBoot [
-        "-drive if=pflash,format=raw,unit=0,readonly,file=${efiFirmware}"
+        "-drive if=pflash,format=raw,unit=0,readonly=on,file=${efiFirmware}"
         "-drive if=pflash,format=raw,unit=1,file=$NIX_EFI_VARS"
       ])
       (mkIf (cfg.bios != null) [
diff --git a/pkgs/os-specific/linux/crda/default.nix b/pkgs/os-specific/linux/crda/default.nix
index c337da2fe72..d12bba4e164 100644
--- a/pkgs/os-specific/linux/crda/default.nix
+++ b/pkgs/os-specific/linux/crda/default.nix
@@ -2,35 +2,42 @@
 
 stdenv.mkDerivation rec {
   pname = "crda";
-  version = "3.18";
+  version = "4.14";
 
   src = fetchurl {
-    sha256 = "1gydiqgb08d9gbx4l6gv98zg3pljc984m50hmn3ysxcbkxkvkz23";
-    url = "http://kernel.org/pub/software/network/crda/crda-${version}.tar.xz";
+    url = "https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/crda.git/snapshot/crda-${version}.tar.gz";
+    sha256 = "sha256-Wo81u4snR09Gaw511FG6kXQz2KqxiJZ4pk2cTnKouMI=";
   };
 
   patches = [
-    # Switch to Python 3
-    # https://lore.kernel.org/linux-wireless/1437542484-23409-1-git-send-email-ahmed.taahir@gmail.com/
+    # Fix python 3 build: except ImportError, e: SyntaxError: invalid syntax
     (fetchpatch {
-      url = "https://lore.kernel.org/linux-wireless/1437542484-23409-2-git-send-email-ahmed.taahir@gmail.com/raw";
-      sha256 = "0s2n340cgaasvg1k8g9v8xjrbh4y2mcgrhdmv97ja2fs8xjcjbf1";
+      url = "https://raw.githubusercontent.com/archlinux/svntogit-packages/d234fddf451fab0f4fc412e2769f54e11f10d7d8/trunk/crda-4.14-python-3.patch";
+      sha256 = "sha256-KEezEKrfizq9k4ZiE2mf3Nl4JiBayhXeVnFl7wYh28Y=";
     })
+
     (fetchpatch {
-      url = "https://lore.kernel.org/linux-wireless/1437542484-23409-3-git-send-email-ahmed.taahir@gmail.com/raw";
-      sha256 = "01dlfw7kqhyx025jxq2l75950b181p9r7i9zkflcwvbzzdmx59md";
+      url = "https://raw.githubusercontent.com/archlinux/svntogit-packages/d48ec843222b0d74c85bce86fa6f087c7dfdf952/trunk/0001-Makefile-Link-libreg.so-against-the-crypto-library.patch";
+      sha256 = "sha256-j93oydi209f22OF8aXZ/NczuUOnlhkdSeYvy2WRRvm0=";
     })
   ];
 
-  buildInputs = [ libgcrypt libnl ];
+  strictDeps = true;
+
   nativeBuildInputs = [
     pkg-config
-    python3Packages.pycrypto
+    python3Packages.m2crypto # only used for a build time script
+  ];
+
+  buildInputs = [
+    libgcrypt
+    libnl
   ];
 
   postPatch = ''
     patchShebangs utils/
     substituteInPlace Makefile \
+      --replace 'gzip' 'gzip -n' \
       --replace ldconfig true \
       --replace pkg-config $PKG_CONFIG
     sed -i crda.c \
@@ -45,19 +52,12 @@ stdenv.mkDerivation rec {
     "REG_BIN=${wireless-regdb}/lib/crda/regulatory.bin"
   ];
 
-  NIX_CFLAGS_COMPILE = "-Wno-error=unused-const-variable";
-
   buildFlags = [ "all_noverify" ];
   enableParallelBuilding = true;
 
   doCheck = true;
   checkTarget = "verify";
 
-  postInstall = ''
-    # The patch installs build header
-    rm $out/include/reglib/keys-gcrypt.h
-  '';
-
   meta = with lib; {
     description = "Linux wireless Central Regulatory Domain Agent";
     longDescription = ''
diff --git a/pkgs/os-specific/linux/kmod-blacklist-ubuntu/default.nix b/pkgs/os-specific/linux/kmod-blacklist-ubuntu/default.nix
index 1c7ea22b758..4002657ad69 100644
--- a/pkgs/os-specific/linux/kmod-blacklist-ubuntu/default.nix
+++ b/pkgs/os-specific/linux/kmod-blacklist-ubuntu/default.nix
@@ -1,7 +1,7 @@
 { lib, stdenv, fetchurl, gnugrep, findutils }:
 
 let
-  version = "22-1.1ubuntu1"; # Zesty
+  version = "28-1ubuntu4"; # impish 2021-06-24
 
 in stdenv.mkDerivation {
   pname = "kmod-blacklist";
@@ -9,7 +9,7 @@ in stdenv.mkDerivation {
 
   src = fetchurl {
     url = "https://launchpad.net/ubuntu/+archive/primary/+files/kmod_${version}.debian.tar.xz";
-    sha256 = "1k749g707ccb82l4xmrkp53khl71f57cpj9fzd1qyzrz147fjyhi";
+    sha256 = "sha256-K8tWpaLmCm3Jcxw3OZ+D7Koiug7epooRn1YMfqjGAiw=";
   };
 
   installPhase = ''
@@ -31,7 +31,7 @@ in stdenv.mkDerivation {
   '';
 
   meta = with lib; {
-    homepage = "https://packages.ubuntu.com/source/zesty/kmod";
+    homepage = "https://launchpad.net/ubuntu/+source/kmod";
     description = "Linux kernel module blacklists from Ubuntu";
     platforms = platforms.linux;
     license = with licenses; [ gpl2Plus lgpl21Plus ];
diff --git a/pkgs/tools/admin/google-cloud-sdk/default.nix b/pkgs/tools/admin/google-cloud-sdk/default.nix
index fd02e7ea418..ac3f9d65c0f 100644
--- a/pkgs/tools/admin/google-cloud-sdk/default.nix
+++ b/pkgs/tools/admin/google-cloud-sdk/default.nix
@@ -103,6 +103,8 @@ in stdenv.mkDerivation rec {
     mkdir -p $out/share/zsh/site-functions
     mv $out/google-cloud-sdk/completion.zsh.inc $out/share/zsh/site-functions/_gcloud
     ln -s $out/share/zsh/site-functions/_gcloud $out/share/zsh/site-functions/_gsutil
+    # zsh doesn't load completions from $FPATH without #compdef as the first line
+    sed -i '1 i #compdef gcloud' $out/share/zsh/site-functions/_gcloud
 
     # This directory contains compiled mac binaries. We used crcmod from
     # nixpkgs instead.