diff options
Diffstat (limited to 'pkgs/os-specific/linux')
137 files changed, 1205 insertions, 572 deletions
diff --git a/pkgs/os-specific/linux/915resolution/default.nix b/pkgs/os-specific/linux/915resolution/default.nix index 57f8ba0d33b..b67d737034e 100644 --- a/pkgs/os-specific/linux/915resolution/default.nix +++ b/pkgs/os-specific/linux/915resolution/default.nix @@ -1,10 +1,11 @@ {lib, stdenv, fetchurl}: stdenv.mkDerivation rec { - name = "915resolution-0.5.3"; + pname = "915resolution"; + version = "0.5.3"; src = fetchurl { - url = "http://915resolution.mango-lang.org/${name}.tar.gz"; + url = "http://915resolution.mango-lang.org/915resolution-${version}.tar.gz"; sha256 = "0hmmy4kkz3x6yigz6hk99416ybznd67dpjaxap50nhay9f1snk5n"; }; diff --git a/pkgs/os-specific/linux/acpid/default.nix b/pkgs/os-specific/linux/acpid/default.nix index d28ff447681..2b8dac0c8e4 100644 --- a/pkgs/os-specific/linux/acpid/default.nix +++ b/pkgs/os-specific/linux/acpid/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl, autoreconfHook }: stdenv.mkDerivation rec { - name = "acpid-2.0.32"; + pname = "acpid"; + version = "2.0.32"; src = fetchurl { - url = "mirror://sourceforge/acpid2/${name}.tar.xz"; + url = "mirror://sourceforge/acpid2/acpid-${version}.tar.xz"; sha256 = "0zhmxnhnhg4v1viw82yjr22kram6k5k1ixznhayk8cnw7q5x7lpj"; }; diff --git a/pkgs/os-specific/linux/acpitool/default.nix b/pkgs/os-specific/linux/acpitool/default.nix index 4a3d1a36bd7..d494e95e3db 100644 --- a/pkgs/os-specific/linux/acpitool/default.nix +++ b/pkgs/os-specific/linux/acpitool/default.nix @@ -7,10 +7,11 @@ let }; in stdenv.mkDerivation rec { - name = "acpitool-0.5.1"; + pname = "acpitool"; + version = "0.5.1"; src = fetchurl { - url = "mirror://sourceforge/acpitool/${name}.tar.bz2"; + url = "mirror://sourceforge/acpitool/acpitool-${version}.tar.bz2"; sha256 = "004fb6cd43102918b6302cf537a2db7ceadda04aef2e0906ddf230f820dad34f"; }; diff --git a/pkgs/os-specific/linux/afuse/default.nix b/pkgs/os-specific/linux/afuse/default.nix index 75c44e11172..5bf32fbe666 100644 --- a/pkgs/os-specific/linux/afuse/default.nix +++ b/pkgs/os-specific/linux/afuse/default.nix @@ -1,11 +1,14 @@ -{ lib, stdenv, fetchurl, pkg-config, autoreconfHook, fuse }: +{ lib, stdenv, fetchFromGitHub, pkg-config, autoreconfHook, fuse }: -stdenv.mkDerivation { - name = "afuse-0.4.1"; +stdenv.mkDerivation rec { + pname = "afuse"; + version = "0.4.1"; - src = fetchurl { - url = "https://github.com/pcarrier/afuse/archive/v0.4.1.tar.gz"; - sha256 = "1sfhicmxppkvdd4z9klfn63snb71gr9hff6xij1gzk94xg6m0ycc"; + src = fetchFromGitHub { + owner = "pcarrier"; + repo = "afuse"; + rev = "v${version}"; + sha256 = "06i855h8a1w2jfly2gfy7vwhb2fp74yxbf3r69s28lki2kzwjar6"; }; nativeBuildInputs = [ autoreconfHook pkg-config ]; diff --git a/pkgs/os-specific/linux/alsa-project/alsa-firmware/default.nix b/pkgs/os-specific/linux/alsa-project/alsa-firmware/default.nix index a627a7762a8..8ad48c41408 100644 --- a/pkgs/os-specific/linux/alsa-project/alsa-firmware/default.nix +++ b/pkgs/os-specific/linux/alsa-project/alsa-firmware/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, buildPackages, autoreconfHook, fetchurl, fetchpatch }: stdenv.mkDerivation rec { - name = "alsa-firmware-1.2.1"; + pname = "alsa-firmware"; + version = "1.2.1"; src = fetchurl { - url = "mirror://alsa/firmware/${name}.tar.bz2"; + url = "mirror://alsa/firmware/alsa-firmware-${version}.tar.bz2"; sha256 = "1aq8z8ajpjvcx7bwhwp36bh5idzximyn77ygk3ifs0my3mbpr8mf"; }; diff --git a/pkgs/os-specific/linux/apparmor/default.nix b/pkgs/os-specific/linux/apparmor/default.nix index 5acf8e560e3..344913888d5 100644 --- a/pkgs/os-specific/linux/apparmor/default.nix +++ b/pkgs/os-specific/linux/apparmor/default.nix @@ -20,7 +20,7 @@ }: let - apparmor-version = "3.0.1"; + apparmor-version = "3.0.3"; apparmor-meta = component: with lib; { homepage = "https://apparmor.net/"; @@ -32,7 +32,7 @@ let apparmor-sources = fetchurl { url = "https://launchpad.net/apparmor/${lib.versions.majorMinor apparmor-version}/${apparmor-version}/+download/apparmor-${apparmor-version}.tar.gz"; - sha256 = "096zbg3v7b51x7f1ly61mzd3iy9alad6sd4lam98j2d6v5ragbcg"; + sha256 = "0nasq8pdmzkrf856yg1v8z5hcs0nn6gw2qr60ab0a7j9ixfv0g8m"; }; aa-teardown = writeShellScript "aa-teardown" '' @@ -56,7 +56,7 @@ let name = "0003-Added-missing-typedef-definitions-on-parser.patch"; sha256 = "0yyaqz8jlmn1bm37arggprqz0njb4lhjni2d9c8qfqj0kll0bam0"; }) - ]; + ]; # Set to `true` after the next FIXME gets fixed or this gets some # common derivation infra. Too much copy-paste to fix one by one. diff --git a/pkgs/os-specific/linux/audit/default.nix b/pkgs/os-specific/linux/audit/default.nix index 30327fb1082..6fa7ba28d8e 100644 --- a/pkgs/os-specific/linux/audit/default.nix +++ b/pkgs/os-specific/linux/audit/default.nix @@ -8,10 +8,11 @@ assert enablePython -> python != null; stdenv.mkDerivation rec { - name = "audit-2.8.5"; # at the next release, remove the patches below! + pname = "audit"; + version = "2.8.5"; # at the next release, remove the patches below! src = fetchurl { - url = "https://people.redhat.com/sgrubb/audit/${name}.tar.gz"; + url = "https://people.redhat.com/sgrubb/audit/audit-${version}.tar.gz"; sha256 = "1dzcwb2q78q7x41shcachn7f4aksxbxd470yk38zh03fch1l2p8f"; }; diff --git a/pkgs/os-specific/linux/bbswitch/default.nix b/pkgs/os-specific/linux/bbswitch/default.nix index 837906fb554..4d081225f11 100644 --- a/pkgs/os-specific/linux/bbswitch/default.nix +++ b/pkgs/os-specific/linux/bbswitch/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, fetchurl, fetchpatch, kernel, runtimeShell }: +{ lib, stdenv, fetchFromGitHub, fetchpatch, kernel, runtimeShell }: let baseName = "bbswitch"; @@ -10,9 +10,11 @@ in stdenv.mkDerivation { inherit name; - src = fetchurl { - url = "https://github.com/Bumblebee-Project/${baseName}/archive/v${version}.tar.gz"; - sha256 = "0xql1nv8dafnrcg54f3jsi3ny3cd2ca9iv73pxpgxd2gfczvvjkn"; + src = fetchFromGitHub { + owner = "Bumblebee-Project"; + repo = "bbswitch"; + rev = "v${version}"; + hash = "sha256-FHC8myKnouNDERVds2QCJj1ZstjHrOzFpb+FDiSBjL4="; }; patches = [ @@ -36,6 +38,8 @@ stdenv.mkDerivation { --replace "/lib/modules" "${kernel.dev}/lib/modules" ''; + makeFlags = kernel.makeFlags; + installPhase = '' mkdir -p $out/lib/modules/${kernel.modDirVersion}/misc cp bbswitch.ko $out/lib/modules/${kernel.modDirVersion}/misc @@ -59,5 +63,6 @@ stdenv.mkDerivation { platforms = [ "x86_64-linux" "i686-linux" ]; homepage = "https://github.com/Bumblebee-Project/bbswitch"; maintainers = with maintainers; [ abbradar ]; + license = licenses.gpl2Plus; }; } diff --git a/pkgs/os-specific/linux/bcc/default.nix b/pkgs/os-specific/linux/bcc/default.nix index 221f38faa87..929981df470 100644 --- a/pkgs/os-specific/linux/bcc/default.nix +++ b/pkgs/os-specific/linux/bcc/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, fetchFromGitHub +{ lib, stdenv, fetchFromGitHub, fetchpatch , makeWrapper, cmake, llvmPackages, kernel , flex, bison, elfutils, python, luajit, netperf, iperf, libelf , systemtap, bash, libbpf @@ -29,6 +29,12 @@ python.pkgs.buildPythonApplication rec { # This is needed until we fix # https://github.com/NixOS/nixpkgs/issues/40427 ./fix-deadlock-detector-import.patch + # Add definition for BTF_KIND_FLOAT, added in Linux 5.14 + # Can be removed once linuxHeaders (used here via glibc) are bumped to 5.14+. + (fetchpatch { + url = "https://salsa.debian.org/debian/bpfcc/-/raw/71136ef5b66a2ecefd635a7aca2e0e835ff09095/debian/patches/0004-compat-defs.patch"; + sha256 = "05s1zxihwkvbl2r2mqc5dj7fpcipqyvwr11v8b9hqbwjkm3qpz40"; + }) ]; propagatedBuildInputs = [ python.pkgs.netaddr ]; diff --git a/pkgs/os-specific/linux/bluez/default.nix b/pkgs/os-specific/linux/bluez/default.nix index a3899fd47c5..3d345e68f3c 100644 --- a/pkgs/os-specific/linux/bluez/default.nix +++ b/pkgs/os-specific/linux/bluez/default.nix @@ -21,11 +21,11 @@ ]; in stdenv.mkDerivation rec { pname = "bluez"; - version = "5.60"; + version = "5.61"; src = fetchurl { url = "mirror://kernel/linux/bluetooth/${pname}-${version}.tar.xz"; - sha256 = "sha256-cQmZWA0B7lnsWF5efAf9lO3e3AAaom/nRkxUb52UUwQ="; + sha256 = "sha256-g6/WxSF5VUv+q7y1OP7C62vpCorDxAhxtJ162LScQjs="; }; buildInputs = [ diff --git a/pkgs/os-specific/linux/bridge-utils/default.nix b/pkgs/os-specific/linux/bridge-utils/default.nix index 12655c3bed6..92e7606c9bd 100644 --- a/pkgs/os-specific/linux/bridge-utils/default.nix +++ b/pkgs/os-specific/linux/bridge-utils/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl, autoreconfHook }: stdenv.mkDerivation rec { - name = "bridge-utils-1.5"; + pname = "bridge-utils"; + version = "1.5"; src = fetchurl { - url = "mirror://sourceforge/bridge/${name}.tar.gz"; + url = "mirror://sourceforge/bridge/bridge-utils-${version}.tar.gz"; sha256 = "42f9e5fb8f6c52e63a98a43b81bd281c227c529f194913e1c51ec48a393b6688"; }; diff --git a/pkgs/os-specific/linux/cpufrequtils/default.nix b/pkgs/os-specific/linux/cpufrequtils/default.nix index 6f94d0f8925..d64996c4961 100644 --- a/pkgs/os-specific/linux/cpufrequtils/default.nix +++ b/pkgs/os-specific/linux/cpufrequtils/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl, libtool, gettext }: stdenv.mkDerivation rec { - name = "cpufrequtils-008"; + pname = "cpufrequtils"; + version = "008"; src = fetchurl { - url = "http://ftp.be.debian.org/pub/linux/utils/kernel/cpufreq/${name}.tar.gz"; + url = "http://ftp.be.debian.org/pub/linux/utils/kernel/cpufreq/cpufrequtils-${version}.tar.gz"; sha256 = "127i38d4w1hv2dzdy756gmbhq25q3k34nqb2s0xlhsfhhdqs0lq0"; }; diff --git a/pkgs/os-specific/linux/cpupower-gui/default.nix b/pkgs/os-specific/linux/cpupower-gui/default.nix new file mode 100644 index 00000000000..2fcc55e14cb --- /dev/null +++ b/pkgs/os-specific/linux/cpupower-gui/default.nix @@ -0,0 +1,93 @@ +{ lib +, stdenv +, fetchFromGitHub +, buildPythonApplication +, appstream-glib +, dbus-python +, desktop-file-utils +, gettext +, glib +, gobject-introspection +, gtk3 +, hicolor-icon-theme +, libappindicator +, libhandy +, meson +, ninja +, pkg-config +, pygobject3 +, pyxdg +, systemd +, wrapGAppsHook +}: + +buildPythonApplication rec { + pname = "cpupower-gui"; + version = "1.0.0"; + + # This packages doesn't have a setup.py + format = "other"; + + src = fetchFromGitHub { + owner = "vagnum08"; + repo = pname; + rev = "v${version}"; + sha256 = "05lvpi3wgyi741sd8lgcslj8i7yi3wz7jwl7ca3y539y50hwrdas"; + }; + + nativeBuildInputs = [ + appstream-glib + desktop-file-utils # needed for update-desktop-database + gettext + glib # needed for glib-compile-schemas + gobject-introspection # need for gtk namespace to be available + hicolor-icon-theme # needed for postinstall script + meson + ninja + pkg-config + wrapGAppsHook + + # Python packages + dbus-python + libappindicator + pygobject3 + pyxdg + ]; + + buildInputs = [ + glib + gtk3 + libhandy + ]; + + propagatedBuildInputs = [ + dbus-python + libappindicator + pygobject3 + pyxdg + ]; + + mesonFlags = [ + "-Dsystemddir=${placeholder "out"}/lib/systemd" + ]; + + preConfigure = '' + patchShebangs build-aux/meson/postinstall.py + ''; + + strictDeps = false; + dontWrapGApps = true; + + makeWrapperArgs = [ "\${gappsWrapperArgs[@]}" ]; + + postFixup = '' + wrapPythonProgramsIn $out/lib "$out $propagatedBuildInputs" + ''; + + meta = with lib; { + description = "Change the frequency limits of your cpu and its governor"; + homepage = "https://github.com/vagnum08/cpupower-gui/"; + license = licenses.gpl3Plus; + maintainers = with maintainers; [ unode ]; + }; +} diff --git a/pkgs/os-specific/linux/cramfsprogs/default.nix b/pkgs/os-specific/linux/cramfsprogs/default.nix index 3f3e8a075b1..59fbfed1b72 100644 --- a/pkgs/os-specific/linux/cramfsprogs/default.nix +++ b/pkgs/os-specific/linux/cramfsprogs/default.nix @@ -16,6 +16,10 @@ stdenv.mkDerivation rec { # So patch the "missing include" bug ourselves. patches = [ ./include-sysmacros.patch ]; + makeFlags = [ + "CC=${stdenv.cc.targetPrefix}cc" + ]; + installPhase = '' install --target $out/bin -D cramfsck mkcramfs ''; diff --git a/pkgs/os-specific/linux/cryptsetup/default.nix b/pkgs/os-specific/linux/cryptsetup/default.nix index e7304e19679..9522e9e5224 100644 --- a/pkgs/os-specific/linux/cryptsetup/default.nix +++ b/pkgs/os-specific/linux/cryptsetup/default.nix @@ -3,13 +3,13 @@ stdenv.mkDerivation rec { pname = "cryptsetup"; - version = "2.3.6"; + version = "2.4.0"; outputs = [ "out" "dev" "man" ]; src = fetchurl { - url = "mirror://kernel/linux/utils/cryptsetup/v2.3/${pname}-${version}.tar.xz"; - sha256 = "sha256-spa3oh6ldsKxgGEcyxnQauyN3a7ffHBLDGqBIQwlY18="; + url = "mirror://kernel/linux/utils/cryptsetup/v2.4/${pname}-${version}.tar.xz"; + sha256 = "sha256-xci9oxFZqcAQ6nLnCAU8xCUs9e69ylIOFQq8Bgkof/g="; }; # Disable 4 test cases that fail in a sandbox @@ -29,6 +29,7 @@ stdenv.mkDerivation rec { configureFlags = [ "--enable-cryptsetup-reencrypt" "--with-crypto_backend=openssl" + "--disable-ssh-token" ]; nativeBuildInputs = [ pkg-config ]; diff --git a/pkgs/os-specific/linux/ddcci/default.nix b/pkgs/os-specific/linux/ddcci/default.nix index 92c33077d68..5ee5eafb020 100644 --- a/pkgs/os-specific/linux/ddcci/default.nix +++ b/pkgs/os-specific/linux/ddcci/default.nix @@ -36,7 +36,7 @@ stdenv.mkDerivation rec { description = "Kernel module driver for DDC/CI monitors"; homepage = "https://gitlab.com/ddcci-driver-linux/ddcci-driver-linux"; license = licenses.gpl2Plus; - maintainers = with maintainers; [ bricewge ]; + maintainers = with maintainers; [ ]; platforms = platforms.linux; broken = kernel.kernelOlder "5.1"; }; diff --git a/pkgs/os-specific/linux/devmem2/default.nix b/pkgs/os-specific/linux/devmem2/default.nix index 86f6f916cef..fbf47204b3e 100644 --- a/pkgs/os-specific/linux/devmem2/default.nix +++ b/pkgs/os-specific/linux/devmem2/default.nix @@ -1,7 +1,8 @@ { lib, stdenv, fetchurl }: stdenv.mkDerivation { - name = "devmem2-2004-08-05"; + pname = "devmem2"; + version = "unstable-2004-08-05"; src = fetchurl { urls = [ diff --git a/pkgs/os-specific/linux/disk-indicator/default.nix b/pkgs/os-specific/linux/disk-indicator/default.nix index f754882ccd0..8a083b8b894 100644 --- a/pkgs/os-specific/linux/disk-indicator/default.nix +++ b/pkgs/os-specific/linux/disk-indicator/default.nix @@ -1,7 +1,8 @@ { lib, stdenv, fetchgit, libX11 }: stdenv.mkDerivation { - name = "disk-indicator-2014-05-19"; + pname = "disk-indicator"; + version = "unstable-2014-05-19"; src = fetchgit { url = "git://github.com/MeanEYE/Disk-Indicator.git"; diff --git a/pkgs/os-specific/linux/dmidecode/default.nix b/pkgs/os-specific/linux/dmidecode/default.nix index a4e09492deb..a12d97280f1 100644 --- a/pkgs/os-specific/linux/dmidecode/default.nix +++ b/pkgs/os-specific/linux/dmidecode/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl, fetchpatch }: stdenv.mkDerivation rec { - name = "dmidecode-3.2"; + pname = "dmidecode"; + version = "3.2"; src = fetchurl { - url = "mirror://savannah/dmidecode/${name}.tar.xz"; + url = "mirror://savannah/dmidecode/dmidecode-${version}.tar.xz"; sha256 = "1pcfhcgs2ifdjwp7amnsr3lq95pgxpr150bjhdinvl505px0cw07"; }; diff --git a/pkgs/os-specific/linux/dmraid/default.nix b/pkgs/os-specific/linux/dmraid/default.nix index c1e0dfc5ae4..3a6f31fa552 100644 --- a/pkgs/os-specific/linux/dmraid/default.nix +++ b/pkgs/os-specific/linux/dmraid/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl, fetchpatch, lvm2 }: stdenv.mkDerivation rec { - name = "dmraid-1.0.0.rc16"; + pname = "dmraid"; + version = "1.0.0.rc16"; src = fetchurl { - url = "https://people.redhat.com/~heinzm/sw/dmraid/src/old/${name}.tar.bz2"; + url = "https://people.redhat.com/~heinzm/sw/dmraid/src/old/dmraid-${version}.tar.bz2"; sha256 = "0m92971gyqp61darxbiri6a48jz3wq3gkp8r2k39320z0i6w8jgq"; }; diff --git a/pkgs/os-specific/linux/drbd/default.nix b/pkgs/os-specific/linux/drbd/default.nix index ae3e986e14a..85be205749a 100644 --- a/pkgs/os-specific/linux/drbd/default.nix +++ b/pkgs/os-specific/linux/drbd/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl, flex, systemd, perl }: stdenv.mkDerivation rec { - name = "drbd-8.4.4"; + pname = "drbd"; + version = "8.4.4"; src = fetchurl { - url = "http://oss.linbit.com/drbd/8.4/${name}.tar.gz"; + url = "http://oss.linbit.com/drbd/8.4/drbd-${version}.tar.gz"; sha256 = "1w4889h1ak7gy9w33kd4fgjlfpgmp6hzfya16p1pkc13bjf22mm0"; }; diff --git a/pkgs/os-specific/linux/edac-utils/default.nix b/pkgs/os-specific/linux/edac-utils/default.nix index 63c539602f1..6171f8ed307 100644 --- a/pkgs/os-specific/linux/edac-utils/default.nix +++ b/pkgs/os-specific/linux/edac-utils/default.nix @@ -2,7 +2,8 @@ , sysfsutils, dmidecode, kmod }: stdenv.mkDerivation { - name = "edac-utils-2015-01-07"; + pname = "edac-utils"; + version = "unstable-2015-01-07"; src = fetchFromGitHub { owner = "grondo"; diff --git a/pkgs/os-specific/linux/ell/default.nix b/pkgs/os-specific/linux/ell/default.nix index a43b9eff3c8..5fea8c19796 100644 --- a/pkgs/os-specific/linux/ell/default.nix +++ b/pkgs/os-specific/linux/ell/default.nix @@ -7,14 +7,14 @@ stdenv.mkDerivation rec { pname = "ell"; - version = "0.41"; + version = "0.43"; outputs = [ "out" "dev" ]; src = fetchgit { url = "https://git.kernel.org/pub/scm/libs/${pname}/${pname}.git"; rev = version; - sha256 = "sha256-UCE+PgGmbePlOoAc8jXxCX6fHr16qf1AQMKxizfSTJM="; + sha256 = "sha256-ttKFKV8spxnkFpZHV4Dn9BxJdjxYLWYrHY+qq6uAOlg="; }; nativeBuildInputs = [ diff --git a/pkgs/os-specific/linux/firejail/default.nix b/pkgs/os-specific/linux/firejail/default.nix index 1a9b7e34f5a..47fce3df533 100644 --- a/pkgs/os-specific/linux/firejail/default.nix +++ b/pkgs/os-specific/linux/firejail/default.nix @@ -20,6 +20,9 @@ stdenv.mkDerivation rec { # By default fbuilder hardcodes the firejail binary to the install path. # On NixOS the firejail binary is a setuid wrapper available in $PATH. ./fbuilder-call-firejail-on-path.patch + # Disable symlink check on /etc/hosts, see + # https://github.com/netblue30/firejail/issues/2758#issuecomment-805174951 + ./remove-link-check.patch ]; prePatch = '' diff --git a/pkgs/os-specific/linux/firejail/remove-link-check.patch b/pkgs/os-specific/linux/firejail/remove-link-check.patch new file mode 100644 index 00000000000..477df57a241 --- /dev/null +++ b/pkgs/os-specific/linux/firejail/remove-link-check.patch @@ -0,0 +1,48 @@ +From ccc726f8ec877d8cda720daa2498e43629b6dd48 Mon Sep 17 00:00:00 2001 +From: Jonas Heinrich <onny@project-insanity.org> +Date: Sun, 19 Sep 2021 11:48:06 +0200 +Subject: [PATCH 1/2] remove hosts file link check + +--- + src/firejail/fs_hostname.c | 4 ---- + 1 file changed, 4 deletions(-) + +diff --git a/src/firejail/fs_hostname.c b/src/firejail/fs_hostname.c +index 42255070c4..97ce70f9c1 100644 +--- a/src/firejail/fs_hostname.c ++++ b/src/firejail/fs_hostname.c +@@ -132,10 +132,6 @@ char *fs_check_hosts_file(const char *fname) { + invalid_filename(fname); + char *rv = expand_home(fname, cfg.homedir); + +- // no a link +- if (is_link(rv)) +- goto errexit; +- + // the user has read access to the file + if (access(rv, R_OK)) + goto errexit; + +From c2c51e7ca56075e7388b4f50922b148615d1b125 Mon Sep 17 00:00:00 2001 +From: Jonas Heinrich <onny@project-insanity.org> +Date: Sun, 19 Sep 2021 11:49:08 +0200 +Subject: [PATCH 2/2] remove hosts file link check + +--- + src/firejail/fs_hostname.c | 3 --- + 1 file changed, 3 deletions(-) + +diff --git a/src/firejail/fs_hostname.c b/src/firejail/fs_hostname.c +index 97ce70f9c1..b228707131 100644 +--- a/src/firejail/fs_hostname.c ++++ b/src/firejail/fs_hostname.c +@@ -154,9 +154,6 @@ void fs_mount_hosts_file(void) { + struct stat s; + if (stat("/etc/hosts", &s) == -1) + goto errexit; +- // not a link +- if (is_link("/etc/hosts")) +- goto errexit; + // owned by root + if (s.st_uid != 0) + goto errexit; diff --git a/pkgs/os-specific/linux/firmware/b43-firmware-cutter/default.nix b/pkgs/os-specific/linux/firmware/b43-firmware-cutter/default.nix index 79de65fcb98..389078db0af 100644 --- a/pkgs/os-specific/linux/firmware/b43-firmware-cutter/default.nix +++ b/pkgs/os-specific/linux/firmware/b43-firmware-cutter/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl }: stdenv.mkDerivation rec { - name = "b43-fwcutter-019"; + pname = "b43-fwcutter"; + version = "019"; src = fetchurl { - url = "https://bues.ch/b43/fwcutter/${name}.tar.bz2"; + url = "https://bues.ch/b43/fwcutter/b43-fwcutter-${version}.tar.bz2"; sha256 = "1ki1f5fy3yrw843r697f8mqqdz0pbsbqnvg4yzkhibpn1lqqbsnn"; }; diff --git a/pkgs/os-specific/linux/firmware/rtl8192su-firmware/default.nix b/pkgs/os-specific/linux/firmware/rtl8192su-firmware/default.nix index 6cbaa4acb8d..3363140ad56 100644 --- a/pkgs/os-specific/linux/firmware/rtl8192su-firmware/default.nix +++ b/pkgs/os-specific/linux/firmware/rtl8192su-firmware/default.nix @@ -1,7 +1,8 @@ { lib, stdenv, fetchFromGitHub }: with lib; stdenv.mkDerivation { - name = "rtl8192su-unstable-2016-10-05"; + pname = "rtl8192su"; + version = "unstable-2016-10-05"; src = fetchFromGitHub { owner = "chunkeey"; diff --git a/pkgs/os-specific/linux/firmware/system76-firmware/default.nix b/pkgs/os-specific/linux/firmware/system76-firmware/default.nix index a7bc3610699..4d0ae9a1d5a 100644 --- a/pkgs/os-specific/linux/firmware/system76-firmware/default.nix +++ b/pkgs/os-specific/linux/firmware/system76-firmware/default.nix @@ -2,13 +2,13 @@ rustPlatform.buildRustPackage rec { pname = "system76-firmware"; # Check Makefile when updating, make sure postInstall matches make install - version = "1.0.28"; + version = "1.0.29"; src = fetchFromGitHub { owner = "pop-os"; repo = pname; rev = version; - sha256 = "sha256-hv8Vdpg/Tt3eo2AdFlOEG182jH5Oy7/BX3p1EMPQjnc="; + sha256 = "sha256-4wvVls6Z42GtC/MVFTvCv1UV/w5nt4p9oTMU4Bqh4JU="; }; nativeBuildInputs = [ pkg-config makeWrapper ]; @@ -17,7 +17,7 @@ rustPlatform.buildRustPackage rec { cargoBuildFlags = [ "--workspace" ]; - cargoSha256 = "sha256-A39zvxvZB3j59giPAVeucHPzqwofnugmLweiPXh5Uzg="; + cargoSha256 = "sha256-x2FO4UWtsvUeKgPxaqjdxtp9vWJq9vLIqQPyGF8nQG4="; # Purposefully don't install systemd unit file, that's for NixOS postInstall = '' diff --git a/pkgs/os-specific/linux/fswebcam/default.nix b/pkgs/os-specific/linux/fswebcam/default.nix index 18cdc21f0b6..08c35d79f3d 100644 --- a/pkgs/os-specific/linux/fswebcam/default.nix +++ b/pkgs/os-specific/linux/fswebcam/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl, libv4l, gd }: stdenv.mkDerivation rec { - name = "fswebcam-20200725"; + pname = "fswebcam"; + version = "2020-07-25"; src = fetchurl { - url = "https://www.sanslogic.co.uk/fswebcam/files/${name}.tar.gz"; + url = "https://www.sanslogic.co.uk/fswebcam/files/fswebcam-${lib.replaceStrings ["."] [""] version}.tar.gz"; sha256 = "1dazsrcaw9s30zz3jpxamk9lkff5dkmflp1s0jjjvdbwa0k6k6ii"; }; diff --git a/pkgs/os-specific/linux/fuse/default.nix b/pkgs/os-specific/linux/fuse/default.nix index b060b908284..b1d9d3dc41e 100644 --- a/pkgs/os-specific/linux/fuse/default.nix +++ b/pkgs/os-specific/linux/fuse/default.nix @@ -11,7 +11,7 @@ in { }; fuse_3 = mkFuse { - version = "3.10.4"; - sha256Hash = "1ml4bs4wx5dbz5xpnd5g8b9avmn7g7jvf16fbdlk0da8il0qd2rx"; + version = "3.10.5"; + sha256Hash = "1yxh85m8fnn3w21f6g6vza7k2giizmyhcbkms4rmkcd2dd2rzk3y"; }; } diff --git a/pkgs/os-specific/linux/fxload/default.nix b/pkgs/os-specific/linux/fxload/default.nix index 3255c992f86..8c1a778ec8b 100644 --- a/pkgs/os-specific/linux/fxload/default.nix +++ b/pkgs/os-specific/linux/fxload/default.nix @@ -1,10 +1,11 @@ {lib, stdenv, fetchurl}: -stdenv.mkDerivation { - name = "fxload-2002_04_11"; +stdenv.mkDerivation rec { + pname = "fxload"; + version = "2002.04.11"; src = fetchurl { - url = "mirror://sourceforge/linux-hotplug/fxload-2002_04_11.tar.gz"; + url = "mirror://sourceforge/linux-hotplug/fxload-${lib.replaceStrings ["."] ["_"] version}.tar.gz"; sha256 = "1hql93bp3dxrv1p67nc63xsbqwljyynm997ysldrc3n9ifi6s48m"; }; diff --git a/pkgs/os-specific/linux/google-authenticator/default.nix b/pkgs/os-specific/linux/google-authenticator/default.nix index ce90a1d432f..fcf75ac7821 100644 --- a/pkgs/os-specific/linux/google-authenticator/default.nix +++ b/pkgs/os-specific/linux/google-authenticator/default.nix @@ -1,12 +1,14 @@ -{ stdenv, lib, fetchurl, autoreconfHook, pam, qrencode }: +{ stdenv, lib, fetchFromGitHub, autoreconfHook, pam, qrencode }: stdenv.mkDerivation rec { pname = "google-authenticator-libpam"; version = "1.09"; - src = fetchurl { - url = "https://github.com/google/google-authenticator-libpam/archive/${version}.tar.gz"; - sha256 = "0dyhgizl2jcrnfn5sxipxawqrbr6qgjh7aggw8fz3hix861pj7db"; + src = fetchFromGitHub { + owner = "google"; + repo = "google-authenticator-libpam"; + rev = version; + hash = "sha256-DS0h6FWMNKnSSj039bH6iyWrERa5M7LBSkbyig6pyxY="; }; nativeBuildInputs = [ autoreconfHook ]; diff --git a/pkgs/os-specific/linux/hd-idle/default.nix b/pkgs/os-specific/linux/hd-idle/default.nix index 3e4b0815146..301a218ff62 100644 --- a/pkgs/os-specific/linux/hd-idle/default.nix +++ b/pkgs/os-specific/linux/hd-idle/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl }: stdenv.mkDerivation rec { - name = "hd-idle-1.05"; + pname = "hd-idle"; + version = "1.05"; src = fetchurl { - url = "mirror://sourceforge/project/hd-idle/${name}.tgz"; + url = "mirror://sourceforge/project/hd-idle/hd-idle-${version}.tgz"; sha256 = "031sm996s0rhy3z91b9xvyimsj2yd2fhsww2al2hxda5s5wzxzjf"; }; diff --git a/pkgs/os-specific/linux/ioport/default.nix b/pkgs/os-specific/linux/ioport/default.nix index 543495ec2af..6da154648fc 100644 --- a/pkgs/os-specific/linux/ioport/default.nix +++ b/pkgs/os-specific/linux/ioport/default.nix @@ -1,12 +1,16 @@ { lib, stdenv, perl, fetchurl }: -stdenv.mkDerivation { - name = "ioport-1.2"; +stdenv.mkDerivation rec { + pname = "ioport"; + version = "1.2"; + src = fetchurl { - url = "https://people.redhat.com/rjones/ioport/files/ioport-1.2.tar.gz"; + url = "https://people.redhat.com/rjones/ioport/files/ioport-${version}.tar.gz"; sha256 = "1h4d5g78y7kla0zl25jgyrk43wy3m3bygqg0blki357bc55irb3z"; }; + buildInputs = [ perl ]; + meta = with lib; { description = "Direct access to I/O ports from the command line"; homepage = "https://people.redhat.com/rjones/ioport/"; diff --git a/pkgs/os-specific/linux/iotop-c/default.nix b/pkgs/os-specific/linux/iotop-c/default.nix index ca0eddac666..ea40ff79f64 100644 --- a/pkgs/os-specific/linux/iotop-c/default.nix +++ b/pkgs/os-specific/linux/iotop-c/default.nix @@ -2,13 +2,13 @@ stdenv.mkDerivation rec { pname = "iotop-c"; - version = "1.18"; + version = "1.19"; src = fetchFromGitHub { owner = "Tomas-M"; repo = "iotop"; rev = "v${version}"; - sha256 = "sha256-5RbxryvRKWJvjuJJwDK6GYnwdtHGfW7XEc75q4omxIA="; + sha256 = "sha256-CuZwOIhjl6fpEvfw/4CTjKQkxazLL/NGujmNcx1Jrbc="; }; nativeBuildInputs = [ pkg-config ]; diff --git a/pkgs/os-specific/linux/iotop/default.nix b/pkgs/os-specific/linux/iotop/default.nix index a91175aa59f..0376ff1a55e 100644 --- a/pkgs/os-specific/linux/iotop/default.nix +++ b/pkgs/os-specific/linux/iotop/default.nix @@ -1,10 +1,11 @@ { lib, fetchurl, python3Packages, fetchpatch }: python3Packages.buildPythonApplication rec { - name = "iotop-0.6"; + pname = "iotop"; + version = "0.6"; src = fetchurl { - url = "http://guichaz.free.fr/iotop/files/${name}.tar.bz2"; + url = "http://guichaz.free.fr/iotop/files/iotop-${version}.tar.bz2"; sha256 = "0nzprs6zqax0cwq8h7hnszdl3d2m4c2d4vjfxfxbnjfs9sia5pis"; }; diff --git a/pkgs/os-specific/linux/iproute/default.nix b/pkgs/os-specific/linux/iproute/default.nix index ea3c4d36958..74003ff83b8 100644 --- a/pkgs/os-specific/linux/iproute/default.nix +++ b/pkgs/os-specific/linux/iproute/default.nix @@ -1,17 +1,25 @@ -{ lib, stdenv, fetchurl +{ lib, stdenv, fetchurl, fetchpatch , buildPackages, bison, flex, pkg-config , db, iptables, libelf, libmnl }: stdenv.mkDerivation rec { pname = "iproute2"; - version = "5.13.0"; + version = "5.14.0"; src = fetchurl { url = "mirror://kernel/linux/utils/net/${pname}/${pname}-${version}.tar.xz"; - sha256 = "sha256-cqLlN3TKyeZfe2F97rsgWfh+iWDW6XE+TXiM6pZvGzY="; + sha256 = "1m4ifnxq7lxnm95l5354z8dk3xj6w9isxmbz53266drgln2sf3r1"; }; + patches = [ + # To avoid ./configure failing due to invalid arguments: + (fetchpatch { # configure: restore backward compatibility + url = "https://git.kernel.org/pub/scm/network/iproute2/iproute2.git/patch/?id=a3272b93725a406bc98b67373da67a4bdf6fcdb0"; + sha256 = "0hyagh2lf6rrfss4z7ca8q3ydya6gg7vfhh25slhpgcn6lnk0xbv"; + }) + ]; + preConfigure = '' # Don't try to create /var/lib/arpd: sed -e '/ARPDDIR/d' -i Makefile diff --git a/pkgs/os-specific/linux/iproute/mptcp.nix b/pkgs/os-specific/linux/iproute/mptcp.nix index 12723213901..8a4cde0c79e 100644 --- a/pkgs/os-specific/linux/iproute/mptcp.nix +++ b/pkgs/os-specific/linux/iproute/mptcp.nix @@ -11,12 +11,13 @@ iproute2.overrideAttrs (oa: rec { sha256 = "07fihvwlaj0ng8s8sxqhd0a9h1narcnp4ibk88km9cpsd32xv4q3"; }; - preConfigure = '' - # Don't try to create /var/lib/arpd: - sed -e '/ARPDDIR/d' -i Makefile + preConfigure = oa.preConfigure + '' patchShebangs configure ''; + # We override "patches" to never apply any iproute2 patches: + patches = [ ]; + meta = with lib; { homepage = "https://github.com/multipath-tcp/iproute-mptcp"; description = "IP-Route extensions for MultiPath TCP"; diff --git a/pkgs/os-specific/linux/ipsec-tools/default.nix b/pkgs/os-specific/linux/ipsec-tools/default.nix index 33152cc51c1..f10364121a4 100644 --- a/pkgs/os-specific/linux/ipsec-tools/default.nix +++ b/pkgs/os-specific/linux/ipsec-tools/default.nix @@ -7,10 +7,11 @@ # the time being. stdenv.mkDerivation rec { - name = "ipsec-tools-0.8.2"; + pname = "ipsec-tools"; + version = "0.8.2"; src = fetchurl { - url = "mirror://sourceforge/ipsec-tools/${name}.tar.bz2"; + url = "mirror://sourceforge/ipsec-tools/ipsec-tools-${version}.tar.bz2"; sha256 = "0b9gfbz78k2nj0k7jdlm5kajig628ja9qm0z5yksiwz22s3v7dlf"; }; diff --git a/pkgs/os-specific/linux/iwd/default.nix b/pkgs/os-specific/linux/iwd/default.nix index e0a1a566d77..33e1f1783ab 100644 --- a/pkgs/os-specific/linux/iwd/default.nix +++ b/pkgs/os-specific/linux/iwd/default.nix @@ -8,16 +8,17 @@ , readline , openssl , python3Packages +, fetchpatch }: stdenv.mkDerivation rec { pname = "iwd"; - version = "1.15"; + version = "1.17"; src = fetchgit { url = "https://git.kernel.org/pub/scm/network/wireless/iwd.git"; rev = version; - sha256 = "sha256-qGQDIzJfeBT9VLwr9Ci9vXcM0ZvFvjL2E9PcKoZ8E94="; + sha256 = "sha256-uWWdKjxctz8fdiIkSiuOYNcZPhxEWDXaA8QPLnd/I9c="; }; outputs = [ "out" "man" ] @@ -56,6 +57,14 @@ stdenv.mkDerivation rec { "--with-systemd-networkdir=${placeholder "out"}/lib/systemd/network/" ]; + patches = [ + # Fix failure in test-eapol. Remove when bumping to 1.18 + (fetchpatch { + url = "https://git.kernel.org/pub/scm/network/wireless/iwd.git/patch/?id=ed10b00afa3f4c087b46d7ba0b60a47bd05d8b39"; + sha256 = "0n8ixrbfh428ajncakcb9kd2n4fw82kw9sfskn1d9ny0lrg39nvg"; + }) + ]; + postUnpack = '' mkdir -p iwd/ell ln -s ${ell.src}/ell/useful.h iwd/ell/useful.h diff --git a/pkgs/os-specific/linux/jujuutils/default.nix b/pkgs/os-specific/linux/jujuutils/default.nix index 554898cedeb..12e4c15e62c 100644 --- a/pkgs/os-specific/linux/jujuutils/default.nix +++ b/pkgs/os-specific/linux/jujuutils/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl, linuxHeaders }: -stdenv.mkDerivation { - name = "jujuutils-0.2"; +stdenv.mkDerivation rec { + pname = "jujuutils"; + version = "0.2"; src = fetchurl { - url = "https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/jujuutils/jujuutils-0.2.tar.gz"; + url = "https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/jujuutils/jujuutils-${version}.tar.gz"; sha256 = "1r74m7s7rs9d6y7cffi7mdap3jf96qwm1v6jcw53x5cikgmfxn4x"; }; diff --git a/pkgs/os-specific/linux/kernel/common-config.nix b/pkgs/os-specific/linux/kernel/common-config.nix index c82f872e488..717fdaee72a 100644 --- a/pkgs/os-specific/linux/kernel/common-config.nix +++ b/pkgs/os-specific/linux/kernel/common-config.nix @@ -35,7 +35,12 @@ let options = { debug = { - DEBUG_INFO = if (features.debug or false) then yes else no; + # Necessary for BTF + DEBUG_INFO = mkMerge [ + (whenOlder "5.2" (if (features.debug or false) then yes else no)) + (whenAtLeast "5.2" yes) + ]; + DEBUG_INFO_BTF = whenAtLeast "5.2" (option yes); DEBUG_KERNEL = yes; DEBUG_DEVRES = no; DYNAMIC_DEBUG = yes; @@ -881,6 +886,22 @@ let # Keeping it a built-in ensures it will be used if possible. FB_SIMPLE = yes; + } // optionalAttrs (versionAtLeast version "5.4" && (stdenv.hostPlatform.system == "x86_64-linux" || stdenv.hostPlatform.system == "aarch64-linux")) { + # Required for various hardware features on Chrome OS devices + CHROME_PLATFORMS = yes; + CHROMEOS_TBMC = module; + + CROS_EC = module; + + CROS_EC_I2C = module; + CROS_EC_SPI = module; + CROS_EC_LPC = module; + CROS_EC_ISHTP = module; + + CROS_KBD_LED_BACKLIGHT = module; + } // optionalAttrs (versionAtLeast version "5.4" && stdenv.hostPlatform.system == "x86_64-linux") { + CHROMEOS_LAPTOP = module; + CHROMEOS_PSTORE = module; }; }; in diff --git a/pkgs/os-specific/linux/kernel/hardened/patches.json b/pkgs/os-specific/linux/kernel/hardened/patches.json index dc379de3161..36c7b557818 100644 --- a/pkgs/os-specific/linux/kernel/hardened/patches.json +++ b/pkgs/os-specific/linux/kernel/hardened/patches.json @@ -1,32 +1,38 @@ { "4.14": { "extra": "-hardened1", - "name": "linux-hardened-4.14.245-hardened1.patch", - "sha256": "035sq0l15afhyfivkavd08pyaywsrcl6f468gykmbq9j3i2swbb6", - "url": "https://github.com/anthraxx/linux-hardened/releases/download/4.14.245-hardened1/linux-hardened-4.14.245-hardened1.patch" + "name": "linux-hardened-4.14.247-hardened1.patch", + "sha256": "0k3ii26ry0cszxs5n4ljll61p1kdi3dn5cvzjr8zb78bfrk7lbra", + "url": "https://github.com/anthraxx/linux-hardened/releases/download/4.14.247-hardened1/linux-hardened-4.14.247-hardened1.patch" }, "4.19": { "extra": "-hardened1", - "name": "linux-hardened-4.19.205-hardened1.patch", - "sha256": "14v3kwkkhyng0wfz4spca6z7wvsxj4kplj144qv1k3fm9yy2cy3h", - "url": "https://github.com/anthraxx/linux-hardened/releases/download/4.19.205-hardened1/linux-hardened-4.19.205-hardened1.patch" + "name": "linux-hardened-4.19.207-hardened1.patch", + "sha256": "1yn6c8axvnmck1ignw4k3pi458x0m2qm7g5vjwf2rw8cnzskrs48", + "url": "https://github.com/anthraxx/linux-hardened/releases/download/4.19.207-hardened1/linux-hardened-4.19.207-hardened1.patch" }, "5.10": { "extra": "-hardened1", - "name": "linux-hardened-5.10.61-hardened1.patch", - "sha256": "0hg67w9s6nzfmar8y01cnc46b2m2sa6s1xz85x1z1c46vw9558f0", - "url": "https://github.com/anthraxx/linux-hardened/releases/download/5.10.61-hardened1/linux-hardened-5.10.61-hardened1.patch" + "name": "linux-hardened-5.10.68-hardened1.patch", + "sha256": "11cn72lzgc6vcbx4xbdvfxrfwy3hfn7sqjxf5laqw9jdhacnlhvn", + "url": "https://github.com/anthraxx/linux-hardened/releases/download/5.10.68-hardened1/linux-hardened-5.10.68-hardened1.patch" }, "5.13": { "extra": "-hardened1", - "name": "linux-hardened-5.13.13-hardened1.patch", - "sha256": "1rb4jpz8zbpijybpm7dwxr05f9nmf6b9av2b651ffxg5vziw17l3", - "url": "https://github.com/anthraxx/linux-hardened/releases/download/5.13.13-hardened1/linux-hardened-5.13.13-hardened1.patch" + "name": "linux-hardened-5.13.19-hardened1.patch", + "sha256": "1cj99y2xn7l89lf4mn7arp0r98r4nmvql3ffjpngzv8hsf79xgg7", + "url": "https://github.com/anthraxx/linux-hardened/releases/download/5.13.19-hardened1/linux-hardened-5.13.19-hardened1.patch" + }, + "5.14": { + "extra": "-hardened1", + "name": "linux-hardened-5.14.7-hardened1.patch", + "sha256": "18i0qxhzga2vg0kal5ifsks0vra6gj21q6whcjry9sglxandn2vg", + "url": "https://github.com/anthraxx/linux-hardened/releases/download/5.14.7-hardened1/linux-hardened-5.14.7-hardened1.patch" }, "5.4": { "extra": "-hardened1", - "name": "linux-hardened-5.4.143-hardened1.patch", - "sha256": "0xv29cclypywq52908zppxpjrxllcdb67chw7lcia60y1aqsg83z", - "url": "https://github.com/anthraxx/linux-hardened/releases/download/5.4.143-hardened1/linux-hardened-5.4.143-hardened1.patch" + "name": "linux-hardened-5.4.148-hardened1.patch", + "sha256": "0kb2d9csm8bbjark2ii0n1jpfcr6avdr8r5g97awzbg9jxkfs0j4", + "url": "https://github.com/anthraxx/linux-hardened/releases/download/5.4.148-hardened1/linux-hardened-5.4.148-hardened1.patch" } } diff --git a/pkgs/os-specific/linux/kernel/linux-4.14.nix b/pkgs/os-specific/linux/kernel/linux-4.14.nix index 8869d0cf653..01f51e8bc57 100644 --- a/pkgs/os-specific/linux/kernel/linux-4.14.nix +++ b/pkgs/os-specific/linux/kernel/linux-4.14.nix @@ -3,7 +3,7 @@ with lib; buildLinux (args // rec { - version = "4.14.246"; + version = "4.14.248"; # modDirVersion needs to be x.y.z, will automatically add .0 if needed modDirVersion = if (modDirVersionArg == null) then concatStringsSep "." (take 3 (splitVersion "${version}.0")) else modDirVersionArg; @@ -13,6 +13,6 @@ buildLinux (args // rec { src = fetchurl { url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz"; - sha256 = "0fpgig84shpas1jc0h4s3aw9brkcq1as84gjbk4bfhc48bpi4mlw"; + sha256 = "0m5nsd41b08xppcf7vvx8zgj3h3sp3n6xrgxfkccn6n4bk7yx4y9"; }; } // (args.argsOverride or {})) diff --git a/pkgs/os-specific/linux/kernel/linux-4.19.nix b/pkgs/os-specific/linux/kernel/linux-4.19.nix index d081f92332b..4148c9ecff5 100644 --- a/pkgs/os-specific/linux/kernel/linux-4.19.nix +++ b/pkgs/os-specific/linux/kernel/linux-4.19.nix @@ -3,7 +3,7 @@ with lib; buildLinux (args // rec { - version = "4.19.206"; + version = "4.19.208"; # modDirVersion needs to be x.y.z, will automatically add .0 if needed modDirVersion = if (modDirVersionArg == null) then concatStringsSep "." (take 3 (splitVersion "${version}.0")) else modDirVersionArg; @@ -13,6 +13,6 @@ buildLinux (args // rec { src = fetchurl { url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz"; - sha256 = "1h44lvzxd0cngj71bk8qba9dz7jlqj68ir6xjwfafglb81ppgsxp"; + sha256 = "1556bk46v7pjd2xrvkldq254yc18cn9jll25ba8zig57562ahkg7"; }; } // (args.argsOverride or {})) diff --git a/pkgs/os-specific/linux/kernel/linux-4.4.nix b/pkgs/os-specific/linux/kernel/linux-4.4.nix index 1469508eb0e..e2cae309230 100644 --- a/pkgs/os-specific/linux/kernel/linux-4.4.nix +++ b/pkgs/os-specific/linux/kernel/linux-4.4.nix @@ -1,12 +1,12 @@ { buildPackages, fetchurl, perl, buildLinux, nixosTests, stdenv, ... } @ args: buildLinux (args // rec { - version = "4.4.283"; + version = "4.4.285"; extraMeta.branch = "4.4"; extraMeta.broken = stdenv.isAarch64; src = fetchurl { url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz"; - sha256 = "1d9v4h4cbc4i371lhhwpxbmg88gna6xyi2ahfvv0clz60802y982"; + sha256 = "0h8jzb2cg0wg4s07iqkghfxkxrnlxadwk3i3gvg2xs3ra0wrisp1"; }; } // (args.argsOverride or {})) diff --git a/pkgs/os-specific/linux/kernel/linux-4.9.nix b/pkgs/os-specific/linux/kernel/linux-4.9.nix index 89f45b8021a..2225651f671 100644 --- a/pkgs/os-specific/linux/kernel/linux-4.9.nix +++ b/pkgs/os-specific/linux/kernel/linux-4.9.nix @@ -1,12 +1,12 @@ { buildPackages, fetchurl, perl, buildLinux, nixosTests, stdenv, ... } @ args: buildLinux (args // rec { - version = "4.9.282"; + version = "4.9.284"; extraMeta.branch = "4.9"; extraMeta.broken = stdenv.isAarch64; src = fetchurl { url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz"; - sha256 = "059fin4si93ya13xy831w84q496ksxidpd3kyw38918sfy4p6wk7"; + sha256 = "0054b0cm0h2mbf6rxzdgd3c2rfz7xa32qkyr5lv58l2852hf0ri8"; }; } // (args.argsOverride or {})) diff --git a/pkgs/os-specific/linux/kernel/linux-5.10.nix b/pkgs/os-specific/linux/kernel/linux-5.10.nix index b36deaadb4b..0f44d6b3e6a 100644 --- a/pkgs/os-specific/linux/kernel/linux-5.10.nix +++ b/pkgs/os-specific/linux/kernel/linux-5.10.nix @@ -3,7 +3,7 @@ with lib; buildLinux (args // rec { - version = "5.10.62"; + version = "5.10.69"; # modDirVersion needs to be x.y.z, will automatically add .0 if needed modDirVersion = if (modDirVersionArg == null) then concatStringsSep "." (take 3 (splitVersion "${version}.0")) else modDirVersionArg; @@ -13,6 +13,6 @@ buildLinux (args // rec { src = fetchurl { url = "mirror://kernel/linux/kernel/v5.x/linux-${version}.tar.xz"; - sha256 = "1cc6z2xzi1s69805jk4f91iarx19v0yyqvssx1f1mc0l9l1db389"; + sha256 = "1jhcl8qh4w4m2jnbp0glr6xbpn7phv17q6w3d247djnc7g2rwbr3"; }; } // (args.argsOverride or {})) diff --git a/pkgs/os-specific/linux/kernel/linux-5.13.nix b/pkgs/os-specific/linux/kernel/linux-5.13.nix index dbccfd2cae7..3f5ae2e13f5 100644 --- a/pkgs/os-specific/linux/kernel/linux-5.13.nix +++ b/pkgs/os-specific/linux/kernel/linux-5.13.nix @@ -3,7 +3,7 @@ with lib; buildLinux (args // rec { - version = "5.13.14"; + version = "5.13.19"; # modDirVersion needs to be x.y.z, will automatically add .0 if needed modDirVersion = if (modDirVersionArg == null) then concatStringsSep "." (take 3 (splitVersion "${version}.0")) else modDirVersionArg; @@ -13,6 +13,6 @@ buildLinux (args // rec { src = fetchurl { url = "mirror://kernel/linux/kernel/v5.x/linux-${version}.tar.xz"; - sha256 = "06lbjsbr86qa8yai5gfclbfxvcqsw33kxj9b4r93hh6z1wajmx82"; + sha256 = "0yxbcd1k4l4cmdn0hzcck4s0yvhvq9fpwp120dv9cz4i9rrfqxz8"; }; } // (args.argsOverride or { })) diff --git a/pkgs/os-specific/linux/kernel/linux-5.14.nix b/pkgs/os-specific/linux/kernel/linux-5.14.nix index a16b35f55cb..35e03223d31 100644 --- a/pkgs/os-specific/linux/kernel/linux-5.14.nix +++ b/pkgs/os-specific/linux/kernel/linux-5.14.nix @@ -3,7 +3,7 @@ with lib; buildLinux (args // rec { - version = "5.14.1"; + version = "5.14.8"; # modDirVersion needs to be x.y.z, will automatically add .0 if needed modDirVersion = if (modDirVersionArg == null) then concatStringsSep "." (take 3 (splitVersion "${version}.0")) else modDirVersionArg; @@ -13,6 +13,6 @@ buildLinux (args // rec { src = fetchurl { url = "mirror://kernel/linux/kernel/v5.x/linux-${version}.tar.xz"; - sha256 = "1iq8s031fviccc4710biwl7gxqdimm3nhlvxd0m3fykvhhmcanq0"; + sha256 = "12cvvrxky92z1g9kj7pgb83yg9pnv2fvi7jf0pyagvqjqladl3na"; }; } // (args.argsOverride or { })) diff --git a/pkgs/os-specific/linux/kernel/linux-5.4.nix b/pkgs/os-specific/linux/kernel/linux-5.4.nix index ea8cf7042a2..840a9dadbaf 100644 --- a/pkgs/os-specific/linux/kernel/linux-5.4.nix +++ b/pkgs/os-specific/linux/kernel/linux-5.4.nix @@ -3,7 +3,7 @@ with lib; buildLinux (args // rec { - version = "5.4.144"; + version = "5.4.149"; # modDirVersion needs to be x.y.z, will automatically add .0 if needed modDirVersion = if (modDirVersionArg == null) then concatStringsSep "." (take 3 (splitVersion "${version}.0")) else modDirVersionArg; @@ -13,6 +13,6 @@ buildLinux (args // rec { src = fetchurl { url = "mirror://kernel/linux/kernel/v5.x/linux-${version}.tar.xz"; - sha256 = "11aqp12xwbg7ysac3f9iaxwkhvasdg9bw4r43jj8af5bf61bjhxw"; + sha256 = "1s1zka0iay0drgkdnmzf587jbrg1gx13xv26k5r1qc7dik8xc6p7"; }; } // (args.argsOverride or {})) diff --git a/pkgs/os-specific/linux/kernel/linux-libre.nix b/pkgs/os-specific/linux/kernel/linux-libre.nix index 3642dfe442d..d9f8912416a 100644 --- a/pkgs/os-specific/linux/kernel/linux-libre.nix +++ b/pkgs/os-specific/linux/kernel/linux-libre.nix @@ -1,8 +1,8 @@ { stdenv, lib, fetchsvn, linux , scripts ? fetchsvn { url = "https://www.fsfla.org/svn/fsfla/software/linux-libre/releases/branches/"; - rev = "18298"; - sha256 = "027fp6h7295cc9m5g46phqd6hixcnvihpfsyrnzvsxz6pkvjzpw4"; + rev = "18314"; + sha256 = "0fic073zafwdsw7i0j4z57a4aknk8kpgnbrxpbi181n5axdlm99k"; } , ... }: diff --git a/pkgs/os-specific/linux/kernel/linux-lqx.nix b/pkgs/os-specific/linux/kernel/linux-lqx.nix index dae6072aa78..e4c9f03539f 100644 --- a/pkgs/os-specific/linux/kernel/linux-lqx.nix +++ b/pkgs/os-specific/linux/kernel/linux-lqx.nix @@ -1,8 +1,8 @@ { lib, fetchFromGitHub, buildLinux, linux_zen, ... } @ args: let - version = "5.13.9"; - suffix = "lqx1"; + version = "5.14.6"; + suffix = "lqx4"; in buildLinux (args // { @@ -14,11 +14,11 @@ buildLinux (args // { owner = "zen-kernel"; repo = "zen-kernel"; rev = "v${version}-${suffix}"; - sha256 = "sha256-aAnwPw1qoGhUdWN/uaQa+5bi0DFZB/wDfNow7FgMMFE="; + sha256 = "sha256-arje/B/oXW/2QUHKi1vJ2n20zNbri1bcMU58mE0evOM="; }; extraMeta = { - branch = "5.13/master"; + branch = "5.14/master"; maintainers = with lib.maintainers; [ atemu ]; description = linux_zen.meta.description + " (Same as linux_zen but less aggressive release schedule)"; }; diff --git a/pkgs/os-specific/linux/kernel/linux-rt-5.10.nix b/pkgs/os-specific/linux/kernel/linux-rt-5.10.nix index 826d99883e4..daa3c67da96 100644 --- a/pkgs/os-specific/linux/kernel/linux-rt-5.10.nix +++ b/pkgs/os-specific/linux/kernel/linux-rt-5.10.nix @@ -6,7 +6,7 @@ , ... } @ args: let - version = "5.10.59-rt52"; # updated by ./update-rt.sh + version = "5.10.65-rt53"; # updated by ./update-rt.sh branch = lib.versions.majorMinor version; kversion = builtins.elemAt (lib.splitString "-" version) 0; in buildLinux (args // { @@ -18,14 +18,14 @@ in buildLinux (args // { src = fetchurl { url = "mirror://kernel/linux/kernel/v5.x/linux-${kversion}.tar.xz"; - sha256 = "107anv16khx055rpkvfd532rdcfg4ffbs7bhp45hdqi3bz0ssg1k"; + sha256 = "0riyq1gdm18642fpnhpcw8hspcjqzprzhqnygjxabjjvrvdxxlzd"; }; kernelPatches = let rt-patch = { name = "rt"; patch = fetchurl { url = "mirror://kernel/linux/kernel/projects/rt/${branch}/older/patch-${version}.patch.xz"; - sha256 = "0i66z1njppn9qvl8msarcgbvmgby6hv8w0k0rmlizwj09i1pmwdx"; + sha256 = "1sxyic3895dch3x7cabiip5lxv9wqypn22hcy02jg9825260cmd3"; }; }; in [ rt-patch ] ++ kernelPatches; diff --git a/pkgs/os-specific/linux/kernel/linux-rt-5.4.nix b/pkgs/os-specific/linux/kernel/linux-rt-5.4.nix index 7a1f477f847..7be45dc3e68 100644 --- a/pkgs/os-specific/linux/kernel/linux-rt-5.4.nix +++ b/pkgs/os-specific/linux/kernel/linux-rt-5.4.nix @@ -6,7 +6,7 @@ , ... } @ args: let - version = "5.4.143-rt63"; # updated by ./update-rt.sh + version = "5.4.143-rt64"; # updated by ./update-rt.sh branch = lib.versions.majorMinor version; kversion = builtins.elemAt (lib.splitString "-" version) 0; in buildLinux (args // { @@ -21,7 +21,7 @@ in buildLinux (args // { name = "rt"; patch = fetchurl { url = "mirror://kernel/linux/kernel/projects/rt/${branch}/older/patch-${version}.patch.xz"; - sha256 = "13d9sx6vw3hlh0cpccfsfqkjj6yfjmbh4wp4x6ry84i39lrfbwg3"; + sha256 = "0prfrvk2ds20sclikizzgg5qf4mfcyaymp9r272d5nj35293622n"; }; }; in [ rt-patch ] ++ kernelPatches; diff --git a/pkgs/os-specific/linux/kernel/linux-xanmod.nix b/pkgs/os-specific/linux/kernel/linux-xanmod.nix index 5034f66e2fc..4acb48479dd 100644 --- a/pkgs/os-specific/linux/kernel/linux-xanmod.nix +++ b/pkgs/os-specific/linux/kernel/linux-xanmod.nix @@ -1,7 +1,7 @@ { lib, stdenv, buildLinux, fetchFromGitHub, ... } @ args: let - version = "5.13.13"; + version = "5.14.8"; release = "1"; suffix = "xanmod${release}-cacule"; in @@ -13,7 +13,7 @@ buildLinux (args // rec { owner = "xanmod"; repo = "linux"; rev = modDirVersion; - sha256 = "sha256-qRJuTkTmsKbCCGrzq62o+1RrvTGM74p4mqy9AQ8hvD0="; + sha256 = "sha256-ikASMx5Lbp2BUfjMppnT8Y0UZdKMWqTze78XYoUTeiU="; }; structuredExtraConfig = with lib.kernel; { @@ -53,7 +53,7 @@ buildLinux (args // rec { }; extraMeta = { - branch = "5.13-cacule"; + branch = "5.14-cacule"; maintainers = with lib.maintainers; [ fortuneteller2k lovesegfault ]; description = "Built with custom settings and new features built to provide a stable, responsive and smooth desktop experience"; broken = stdenv.isAarch64; diff --git a/pkgs/os-specific/linux/kernel/linux-zen.nix b/pkgs/os-specific/linux/kernel/linux-zen.nix index 7750b776575..1c064059047 100644 --- a/pkgs/os-specific/linux/kernel/linux-zen.nix +++ b/pkgs/os-specific/linux/kernel/linux-zen.nix @@ -2,7 +2,7 @@ let # having the full version string here makes it easier to update - modDirVersion = "5.13.13-zen1"; + modDirVersion = "5.14.3-zen1"; parts = lib.splitString "-" modDirVersion; version = lib.elemAt parts 0; suffix = lib.elemAt parts 1; @@ -19,7 +19,7 @@ buildLinux (args // { owner = "zen-kernel"; repo = "zen-kernel"; rev = "v${modDirVersion}"; - sha256 = "sha256-aTTbhXy0wsDDCSbX1k27l9g3FliqwE6TbRq2zkI3mnw="; + sha256 = "sha256-ByewBT+1z83jCuEMmNvtmhHaEk4qjHa2Kgue8wVfPIY="; }; structuredExtraConfig = with lib.kernel; { diff --git a/pkgs/os-specific/linux/kernel/manual-config.nix b/pkgs/os-specific/linux/kernel/manual-config.nix index 77add0aef53..12eca63e216 100644 --- a/pkgs/os-specific/linux/kernel/manual-config.nix +++ b/pkgs/os-specific/linux/kernel/manual-config.nix @@ -1,5 +1,5 @@ { lib, buildPackages, runCommand, nettools, bc, bison, flex, perl, rsync, gmp, libmpc, mpfr, openssl -, libelf, cpio, elfutils, zstd, gawk, python3Minimal +, libelf, cpio, elfutils, zstd, gawk, python3Minimal, zlib, pahole , writeTextFile }: @@ -316,10 +316,12 @@ stdenv.mkDerivation ((drvAttrs config stdenv.hostPlatform.linux-kernel kernelPat ++ optional (lib.versionAtLeast version "4.14" && lib.versionOlder version "5.8") libelf # Removed util-linuxMinimal since it should not be a dependency. ++ optionals (lib.versionAtLeast version "4.16") [ bison flex ] - ++ optional (lib.versionAtLeast version "5.2") cpio + ++ optionals (lib.versionAtLeast version "5.2") [ cpio pahole ] ++ optional (lib.versionAtLeast version "5.8") elfutils ; + buildInputs = optional (lib.versionAtLeast version "5.2") zlib; + hardeningDisable = [ "bindnow" "format" "fortify" "stackprotector" "pic" "pie" ]; # Absolute paths for compilers avoid any PATH-clobbering issues. diff --git a/pkgs/os-specific/linux/kmod/darwin.patch b/pkgs/os-specific/linux/kmod/darwin.patch index e112e691525..4d9931b03ee 100644 --- a/pkgs/os-specific/linux/kmod/darwin.patch +++ b/pkgs/os-specific/linux/kmod/darwin.patch @@ -69,14 +69,17 @@ diff --git a/shared/macro.h b/shared/macro.h index 4fc5405..b5a2702 100644 --- a/shared/macro.h +++ b/shared/macro.h -@@ -71,3 +71,7 @@ - #endif - - #define UNIQ __COUNTER__ -+ -+ #if !defined(__linux__) +@@ -53,6 +53,10 @@ + #define CONCATENATE(x, y) XCONCATENATE(x, y) + #define UNIQ(x) CONCATENATE(x, __COUNTER__) + ++#if !defined(__linux__) +#define program_invocation_short_name getprogname() +#endif ++ + /* Temporaries for importing index handling */ + #define NOFAIL(x) (x) + #define fatal(x...) do { } while (0) diff --git a/shared/missing.h b/shared/missing.h index 4c0d136..ad8ec0f 100644 --- a/shared/missing.h diff --git a/pkgs/os-specific/linux/kmod/default.nix b/pkgs/os-specific/linux/kmod/default.nix index ef8296cf16f..2cb263854ab 100644 --- a/pkgs/os-specific/linux/kmod/default.nix +++ b/pkgs/os-specific/linux/kmod/default.nix @@ -1,5 +1,5 @@ { stdenv, lib, fetchurl, autoreconfHook, pkg-config -, libxslt, xz, elf-header +, libxslt, xz, zstd, elf-header , withStatic ? stdenv.hostPlatform.isStatic }: @@ -9,23 +9,24 @@ let in stdenv.mkDerivation rec { pname = "kmod"; - version = "27"; + version = "29"; src = fetchurl { url = "mirror://kernel/linux/utils/kernel/${pname}/${pname}-${version}.tar.xz"; - sha256 = "035wzfzjx4nwidk747p8n085mgkvy531ppn16krrajx2dkqzply1"; + sha256 = "0am54mi5rk72g5q7k6l6f36gw3r9vwgjmyna43ywcjhqmakyx00b"; }; nativeBuildInputs = [ autoreconfHook pkg-config libxslt ]; - buildInputs = [ xz ] ++ lib.optional stdenv.isDarwin elf-header; + buildInputs = [ xz zstd ] ++ lib.optional stdenv.isDarwin elf-header; configureFlags = [ "--sysconfdir=/etc" "--with-xz" + "--with-zstd" "--with-modulesdirs=${modulesDirs}" ] ++ lib.optional withStatic "--enable-static"; - patches = [ ./module-dir.patch ./no-name-field.patch ] + patches = [ ./module-dir.patch ] ++ lib.optional stdenv.isDarwin ./darwin.patch ++ lib.optional withStatic ./enable-static.patch; @@ -49,7 +50,7 @@ in stdenv.mkDerivation rec { homepage = "https://git.kernel.org/pub/scm/utils/kernel/kmod/kmod.git/"; downloadPage = "https://www.kernel.org/pub/linux/utils/kernel/kmod/"; changelog = "https://git.kernel.org/pub/scm/utils/kernel/kmod/kmod.git/plain/NEWS?h=v${version}"; - license = licenses.lgpl21; + license = with licenses; [ lgpl21Plus gpl2Plus ]; # GPLv2+ for tools platforms = platforms.unix; }; } diff --git a/pkgs/os-specific/linux/kmod/no-name-field.patch b/pkgs/os-specific/linux/kmod/no-name-field.patch deleted file mode 100644 index 282f59e55e5..00000000000 --- a/pkgs/os-specific/linux/kmod/no-name-field.patch +++ /dev/null @@ -1,24 +0,0 @@ - ---- - tools/modinfo.c | 5 ++++- - 1 file changed, 4 insertions(+), 1 deletion(-) - -diff --git a/tools/modinfo.c b/tools/modinfo.c -index 0231bb0..7b2259e 100644 ---- a/tools/modinfo.c -+++ b/tools/modinfo.c -@@ -178,7 +178,10 @@ static int modinfo_do(struct kmod_module *mod) - is_builtin = (filename == NULL); - - if (is_builtin) { -- printf("%-16s%s%c", "name:", kmod_module_get_name(mod), separator); -+ if (field == NULL || field != NULL && streq(field, "name")){ -+ printf("%-16s%s%c", "name:", -+ kmod_module_get_name(mod), separator); -+ } - filename = "(builtin)"; - } - --- -2.28.0 - diff --git a/pkgs/os-specific/linux/kmscube/default.nix b/pkgs/os-specific/linux/kmscube/default.nix index 6db3a9583ec..53b4cd60fb1 100644 --- a/pkgs/os-specific/linux/kmscube/default.nix +++ b/pkgs/os-specific/linux/kmscube/default.nix @@ -1,7 +1,8 @@ { lib, stdenv, fetchgit, autoreconfHook, libdrm, libX11, libGL, mesa, pkg-config }: stdenv.mkDerivation { - name = "kmscube-2018-06-17"; + pname = "kmscube"; + version = "unstable-2018-06-17"; src = fetchgit { url = "git://anongit.freedesktop.org/mesa/kmscube"; diff --git a/pkgs/os-specific/linux/latencytop/default.nix b/pkgs/os-specific/linux/latencytop/default.nix index 30ec6cdc7b5..56e412379f8 100644 --- a/pkgs/os-specific/linux/latencytop/default.nix +++ b/pkgs/os-specific/linux/latencytop/default.nix @@ -1,13 +1,14 @@ { lib, stdenv, fetchurl, ncurses, glib, pkg-config, gtk2 }: stdenv.mkDerivation rec { - name = "latencytop-0.5"; + pname = "latencytop"; + version = "0.5"; patchPhase = "sed -i s,/usr,$out, Makefile"; preInstall = "mkdir -p $out/sbin"; src = fetchurl { - urls = [ "http://latencytop.org/download/${name}.tar.gz" + urls = [ "http://latencytop.org/download/latencytop-${version}.tar.gz" "http://dbg.download.sourcemage.org/mirror/latencytop-0.5.tar.gz" ]; sha256 = "1vq3j9zdab6njly2wp900b3d5244mnxfm88j2bkiinbvxbxp4zwy"; }; diff --git a/pkgs/os-specific/linux/libatasmart/default.nix b/pkgs/os-specific/linux/libatasmart/default.nix index c422f5e01bb..d5be78e913b 100644 --- a/pkgs/os-specific/linux/libatasmart/default.nix +++ b/pkgs/os-specific/linux/libatasmart/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl, pkg-config, udev, buildPackages }: stdenv.mkDerivation rec { - name = "libatasmart-0.19"; + pname = "libatasmart"; + version = "0.19"; src = fetchurl { - url = "http://0pointer.de/public/${name}.tar.xz"; + url = "http://0pointer.de/public/libatasmart-${version}.tar.xz"; sha256 = "138gvgdwk6h4ljrjsr09pxk1nrki4b155hqdzyr8mlk3bwsfmw31"; }; diff --git a/pkgs/os-specific/linux/libbpf/default.nix b/pkgs/os-specific/linux/libbpf/default.nix index 2e497584fab..649ad88a3d1 100644 --- a/pkgs/os-specific/linux/libbpf/default.nix +++ b/pkgs/os-specific/linux/libbpf/default.nix @@ -7,30 +7,15 @@ with builtins; stdenv.mkDerivation rec { pname = "libbpf"; - version = "0.1.1"; + version = "0.4.0"; src = fetchFromGitHub { owner = "libbpf"; repo = "libbpf"; rev = "v${version}"; - sha256 = "0ilnnm4q22f8fagwp8kb37licy4ks861i2iqh2djsypqhnxvx3fv"; + sha256 = "1by5w7g3i2fc10bi6f0j8jqi2nq0x8r973j2qx7qlfryjxr7b2v3"; }; - patches = [ - (fetchpatch { # included upstream for > 0.1.0 - name = "link-zlib.patch"; - url = "https://github.com/libbpf/libbpf/commit/8b14cb43ff837.diff"; - sha256 = "17mvjrs7s727drz013a8qlyj0345ldi2kph6pazcmxv6kl1qrz2z"; - }) - ]; - patchFlags = "-p2"; - # https://github.com/libbpf/libbpf/pull/201#issuecomment-689174740 - postPatch = '' - substituteInPlace ../scripts/check-reallocarray.sh \ - --replace 'mktemp /tmp/' 'mktemp ' \ - --replace '/bin/rm' 'rm' - ''; - nativeBuildInputs = [ pkg-config ]; buildInputs = [ libelf zlib ]; diff --git a/pkgs/os-specific/linux/libfabric/default.nix b/pkgs/os-specific/linux/libfabric/default.nix deleted file mode 100644 index 2abe07b0964..00000000000 --- a/pkgs/os-specific/linux/libfabric/default.nix +++ /dev/null @@ -1,29 +0,0 @@ -{ lib, stdenv, fetchFromGitHub, pkg-config, autoreconfHook, libpsm2 }: - -stdenv.mkDerivation rec { - pname = "libfabric"; - version = "1.13.0"; - - enableParallelBuilding = true; - - src = fetchFromGitHub { - owner = "ofiwg"; - repo = pname; - rev = "v${version}"; - sha256 = "sha256-felGKpdihOi4TCp95T1ti7fErQVphP0vYGRKEwlQt4Q="; - }; - - nativeBuildInputs = [ pkg-config autoreconfHook ] ; - - buildInputs = [ libpsm2 ] ; - - configureFlags = [ "--enable-psm2=${libpsm2}" ] ; - - meta = with lib; { - homepage = "http://libfabric.org/"; - description = "Open Fabric Interfaces"; - license = with licenses; [ gpl2 bsd2 ]; - platforms = [ "x86_64-linux" ]; - maintainers = [ maintainers.bzizou ]; - }; -} diff --git a/pkgs/os-specific/linux/libpsm2/default.nix b/pkgs/os-specific/linux/libpsm2/default.nix index 1ac4580b13f..8b979d47956 100644 --- a/pkgs/os-specific/linux/libpsm2/default.nix +++ b/pkgs/os-specific/linux/libpsm2/default.nix @@ -13,6 +13,12 @@ stdenv.mkDerivation rec { buildInputs = [ numactl pkg-config ]; + makeFlags = [ + # Disable blanket -Werror to avoid build failures + # on fresh toolchains like gcc-11. + "WERROR=" + ]; + installFlags = [ "DESTDIR=$(out)" "UDEVDIR=/etc/udev" @@ -35,7 +41,7 @@ stdenv.mkDerivation rec { homepage = "https://github.com/intel/opa-psm2"; description = "The PSM2 library supports a number of fabric media and stacks"; license = with licenses; [ gpl2 bsd3 ]; - platforms = [ "x86_64-linux" ]; + platforms = [ "x86_64-linux" ]; maintainers = [ maintainers.bzizou ]; }; } diff --git a/pkgs/os-specific/linux/libvolume_id/default.nix b/pkgs/os-specific/linux/libvolume_id/default.nix index 87b7d33c5d8..653094c9188 100644 --- a/pkgs/os-specific/linux/libvolume_id/default.nix +++ b/pkgs/os-specific/linux/libvolume_id/default.nix @@ -1,10 +1,11 @@ {lib, stdenv, fetchurl}: -stdenv.mkDerivation { - name = "libvolume_id-0.81.1"; +stdenv.mkDerivation rec { + pname = "libvolume_id"; + version = "0.81.1"; src = fetchurl { - url = "https://www.marcuscom.com/downloads/libvolume_id-0.81.1.tar.bz2"; + url = "https://www.marcuscom.com/downloads/libvolume_id-${version}.tar.bz2"; sha256 = "029z04vdxxsl8gycm9whcljhv6dy4b12ybsxdb99jr251gl1ifs5"; }; @@ -21,5 +22,6 @@ stdenv.mkDerivation { meta = with lib; { platforms = platforms.linux; license = licenses.gpl2; + homepage = "http://www.marcuscom.com/downloads/"; }; } diff --git a/pkgs/os-specific/linux/lightum/default.nix b/pkgs/os-specific/linux/lightum/default.nix index ec56a89ce88..8da12d78bc9 100644 --- a/pkgs/os-specific/linux/lightum/default.nix +++ b/pkgs/os-specific/linux/lightum/default.nix @@ -1,7 +1,8 @@ { lib, stdenv, fetchgit, libX11, libXScrnSaver, libXext, glib, dbus, pkg-config, systemd }: stdenv.mkDerivation { - name = "lightum-2014-06-07"; + pname = "lightum"; + version = "unstable-2014-06-07"; src = fetchgit { url = "https://github.com/poliva/lightum"; rev = "123e6babe0669b23d4c1dfa5511088608ff2baa8"; diff --git a/pkgs/os-specific/linux/lksctp-tools/default.nix b/pkgs/os-specific/linux/lksctp-tools/default.nix index 8bbd3ab7f42..19d6f10e3de 100644 --- a/pkgs/os-specific/linux/lksctp-tools/default.nix +++ b/pkgs/os-specific/linux/lksctp-tools/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl }: stdenv.mkDerivation rec { - name = "lksctp-tools-1.0.17"; + pname = "lksctp-tools"; + version = "1.0.17"; src = fetchurl { - url = "mirror://sourceforge/lksctp/${name}.tar.gz"; + url = "mirror://sourceforge/lksctp/lksctp-tools-${version}.tar.gz"; sha256 = "05da6c2v3acc18ndvmkrag6x5lf914b7s0xkkr6wkvrbvd621sqs"; }; diff --git a/pkgs/os-specific/linux/lm-sensors/default.nix b/pkgs/os-specific/linux/lm-sensors/default.nix index 21324a5d6ce..fda11400e8f 100644 --- a/pkgs/os-specific/linux/lm-sensors/default.nix +++ b/pkgs/os-specific/linux/lm-sensors/default.nix @@ -1,5 +1,12 @@ -{ lib, stdenv, fetchzip, bison, flex, which, perl -, sensord ? false, rrdtool ? null +{ lib +, stdenv +, fetchFromGitHub +, bison +, flex +, which +, perl +, sensord ? false +, rrdtool ? null }: assert sensord -> rrdtool != null; @@ -7,16 +14,18 @@ assert sensord -> rrdtool != null; stdenv.mkDerivation rec { pname = "lm-sensors"; version = "3.6.0"; - dashedVersion = lib.replaceStrings ["."] ["-"] version; + dashedVersion = lib.replaceStrings [ "." ] [ "-" ] version; - src = fetchzip { - url = "https://github.com/lm-sensors/lm-sensors/archive/V${dashedVersion}.tar.gz"; - sha256 = "1ipf6wjx037sqyhy0r5jh4983h216anq9l68ckn2x5c3qc4wfmzn"; + src = fetchFromGitHub { + owner = "lm-sensors"; + repo = "lm-sensors"; + rev = "V${dashedVersion}"; + hash = "sha256-9lfHCcODlS7sZMjQhK0yQcCBEoGyZOChx/oM0CU37sY="; }; nativeBuildInputs = [ bison flex which ]; buildInputs = [ perl ] - ++ lib.optional sensord rrdtool; + ++ lib.optional sensord rrdtool; makeFlags = [ "PREFIX=${placeholder "out"}" diff --git a/pkgs/os-specific/linux/lsscsi/default.nix b/pkgs/os-specific/linux/lsscsi/default.nix index 6286735b758..d87820f2466 100644 --- a/pkgs/os-specific/linux/lsscsi/default.nix +++ b/pkgs/os-specific/linux/lsscsi/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl }: -stdenv.mkDerivation { - name = "lsscsi-0.32"; +stdenv.mkDerivation rec { + pname = "lsscsi"; + version = "0.32"; src = fetchurl { - url = "http://sg.danny.cz/scsi/lsscsi-0.32.tgz"; + url = "http://sg.danny.cz/scsi/lsscsi-${version}.tgz"; sha256 = "sha256-CoAOnpTcoqtwLWXXJ3eujK4Hjj100Ly+1kughJ6AKaE="; }; diff --git a/pkgs/os-specific/linux/lvm2/default.nix b/pkgs/os-specific/linux/lvm2/default.nix index 2e52e49639e..fed7152d07a 100644 --- a/pkgs/os-specific/linux/lvm2/default.nix +++ b/pkgs/os-specific/linux/lvm2/default.nix @@ -67,23 +67,14 @@ stdenv.mkDerivation rec { sed -i 's|^#define LVM_CONFIGURE_LINE.*$|#define LVM_CONFIGURE_LINE "<removed>"|g' ./include/configure.h ''; - - patches = lib.optionals stdenv.hostPlatform.isMusl [ - (fetchpatch { - name = "fix-stdio-usage.patch"; - url = "https://git.alpinelinux.org/aports/plain/main/lvm2/fix-stdio-usage.patch?h=3.7-stable&id=31bd4a8c2dc00ae79a821f6fe0ad2f23e1534f50"; - sha256 = "0m6wr6qrvxqi2d2h054cnv974jq1v65lqxy05g1znz946ga73k3p"; - }) + patches = [ + # Musl fixes from Alpine. + ./fix-stdio-usage.patch (fetchpatch { name = "mallinfo.patch"; url = "https://git.alpinelinux.org/aports/plain/main/lvm2/mallinfo.patch?h=3.7-stable&id=31bd4a8c2dc00ae79a821f6fe0ad2f23e1534f50"; sha256 = "0g6wlqi215i5s30bnbkn8w7axrs27y3bnygbpbnf64wwx7rxxlj0"; }) - (fetchpatch { - name = "mlockall-default-config.patch"; - url = "https://git.alpinelinux.org/aports/plain/main/lvm2/mlockall-default-config.patch?h=3.7-stable&id=31bd4a8c2dc00ae79a821f6fe0ad2f23e1534f50"; - sha256 = "1ivbj3sphgf8n1ykfiv5rbw7s8dgnj5jcr9jl2v8cwf28lkacw5l"; - }) ]; doCheck = false; # requires root diff --git a/pkgs/os-specific/linux/lvm2/fix-stdio-usage.patch b/pkgs/os-specific/linux/lvm2/fix-stdio-usage.patch new file mode 100644 index 00000000000..59666ffbad5 --- /dev/null +++ b/pkgs/os-specific/linux/lvm2/fix-stdio-usage.patch @@ -0,0 +1,53 @@ +diff --git a/lib/commands/toolcontext.c b/lib/commands/toolcontext.c +index 296618686..96343eeb7 100644 +--- a/lib/commands/toolcontext.c ++++ b/lib/commands/toolcontext.c +@@ -1619,7 +1619,7 @@ struct cmd_context *create_toolcontext(unsigned is_clvmd, + /* FIXME Make this configurable? */ + reset_lvm_errno(1); + +-#ifndef VALGRIND_POOL ++#if !defined(VALGRIND_POOL) && defined(__GLIBC__) + /* Set in/out stream buffering before glibc */ + if (set_buffering + #ifdef SYS_gettid +@@ -2006,7 +2006,7 @@ void destroy_toolcontext(struct cmd_context *cmd) + + if (cmd->pending_delete_mem) + dm_pool_destroy(cmd->pending_delete_mem); +-#ifndef VALGRIND_POOL ++#if !defined(VALGRIND_POOL) && defined(__GLIBC__) + if (cmd->linebuffer) { + /* Reset stream buffering to defaults */ + if (is_valid_fd(STDIN_FILENO) && +diff --git a/tools/lvmcmdline.c b/tools/lvmcmdline.c +index d97ff5720..bbbda82bd 100644 +--- a/tools/lvmcmdline.c ++++ b/tools/lvmcmdline.c +@@ -3342,7 +3342,7 @@ static int _check_standard_fds(void) + int err = is_valid_fd(STDERR_FILENO); + + if (!is_valid_fd(STDIN_FILENO) && +- !(stdin = fopen(_PATH_DEVNULL, "r"))) { ++ !freopen(_PATH_DEVNULL, "r", stdin)) { + if (err) + perror("stdin stream open"); + else +@@ -3352,7 +3352,7 @@ static int _check_standard_fds(void) + } + + if (!is_valid_fd(STDOUT_FILENO) && +- !(stdout = fopen(_PATH_DEVNULL, "w"))) { ++ !freopen(_PATH_DEVNULL, "w", stdout)) { + if (err) + perror("stdout stream open"); + /* else no stdout */ +@@ -3360,7 +3360,7 @@ static int _check_standard_fds(void) + } + + if (!is_valid_fd(STDERR_FILENO) && +- !(stderr = fopen(_PATH_DEVNULL, "w"))) { ++ !freopen(_PATH_DEVNULL, "w", stderr)) { + printf("stderr stream open: %s\n", + strerror(errno)); + return 0; diff --git a/pkgs/os-specific/linux/mba6x_bl/default.nix b/pkgs/os-specific/linux/mba6x_bl/default.nix index 441476d5f06..fe9c11ace1f 100644 --- a/pkgs/os-specific/linux/mba6x_bl/default.nix +++ b/pkgs/os-specific/linux/mba6x_bl/default.nix @@ -1,7 +1,8 @@ { fetchFromGitHub, kernel, lib, stdenv }: stdenv.mkDerivation { - name = "mba6x_bl-2016-12-08"; + pname = "mba6x_bl"; + version = "unstable-2016-12-08"; src = fetchFromGitHub { owner = "patjak"; diff --git a/pkgs/os-specific/linux/mdadm/default.nix b/pkgs/os-specific/linux/mdadm/default.nix index 935ded63709..01d2bba32a4 100644 --- a/pkgs/os-specific/linux/mdadm/default.nix +++ b/pkgs/os-specific/linux/mdadm/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, util-linux, coreutils, fetchurl, groff, system-sendmail }: stdenv.mkDerivation rec { - name = "mdadm-4.1"; + pname = "mdadm"; + version = "4.1"; src = fetchurl { - url = "mirror://kernel/linux/utils/raid/mdadm/${name}.tar.xz"; + url = "mirror://kernel/linux/utils/raid/mdadm/mdadm-${version}.tar.xz"; sha256 = "0jjgjgqijpdp7ijh8slzzjjw690kydb1jjadf0x5ilq85628hxmb"; }; diff --git a/pkgs/os-specific/linux/mingetty/default.nix b/pkgs/os-specific/linux/mingetty/default.nix index 8a2cf69dd36..eb58dc55367 100644 --- a/pkgs/os-specific/linux/mingetty/default.nix +++ b/pkgs/os-specific/linux/mingetty/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl }: -stdenv.mkDerivation { - name = "mingetty-1.08"; +stdenv.mkDerivation rec { + pname = "mingetty"; + version = "1.08"; src = fetchurl { - url = "mirror://sourceforge/mingetty/mingetty-1.08.tar.gz"; + url = "mirror://sourceforge/mingetty/mingetty-${version}.tar.gz"; sha256 = "05yxrp44ky2kg6qknk1ih0kvwkgbn9fbz77r3vci7agslh5wjm8g"; }; diff --git a/pkgs/os-specific/linux/mkinitcpio-nfs-utils/default.nix b/pkgs/os-specific/linux/mkinitcpio-nfs-utils/default.nix index eeea1d74dca..da2ba4b9ff2 100644 --- a/pkgs/os-specific/linux/mkinitcpio-nfs-utils/default.nix +++ b/pkgs/os-specific/linux/mkinitcpio-nfs-utils/default.nix @@ -1,13 +1,14 @@ { lib, stdenv, fetchurl }: stdenv.mkDerivation rec { - name = "mkinitcpio-nfs-utils-0.3"; + pname = "mkinitcpio-nfs-utils"; + version = "0.3"; src = fetchurl { - url = "https://sources.archlinux.org/other/mkinitcpio/${name}.tar.xz"; + url = "https://sources.archlinux.org/other/mkinitcpio/mkinitcpio-nfs-utils-${version}.tar.xz"; sha256 = "0fc93sfk41ycpa33083kyd7i4y00ykpbhj5qlw611bjghj4x946j"; # ugh, upstream... - name = "${name}.tar.gz"; + name = "mkinitcpio-nfs-utils-${version}.tar.gz"; }; makeFlags = [ "DESTDIR=$(out)" "bindir=/bin" ]; diff --git a/pkgs/os-specific/linux/mxu11x0/default.nix b/pkgs/os-specific/linux/mxu11x0/default.nix index 3498625be75..d5129ca7f73 100644 --- a/pkgs/os-specific/linux/mxu11x0/default.nix +++ b/pkgs/os-specific/linux/mxu11x0/default.nix @@ -1,7 +1,8 @@ { lib, stdenv, fetchurl, kernel }: stdenv.mkDerivation { - name = "mxu11x0-1.4-${kernel.version}"; + pname = "mxu11x0"; + version = "1.4-${kernel.version}"; src = fetchurl { url = "https://www.moxa.com/Moxa/media/PDIM/S100000385/moxa-uport-1000-series-linux-3.x-and-4.x-for-uport-11x0-series-driver-v1.4.tgz"; diff --git a/pkgs/os-specific/linux/nixos-rebuild/nixos-rebuild.sh b/pkgs/os-specific/linux/nixos-rebuild/nixos-rebuild.sh index b58c3b60bf9..198a6eae600 100755 --- a/pkgs/os-specific/linux/nixos-rebuild/nixos-rebuild.sh +++ b/pkgs/os-specific/linux/nixos-rebuild/nixos-rebuild.sh @@ -16,6 +16,7 @@ showSyntax() { # Parse the command line. origArgs=("$@") +copyClosureFlags=() extraBuildFlags=() lockFlags=() flakeFlags=() @@ -60,6 +61,9 @@ while [ "$#" -gt 0 ]; do upgrade=1 upgrade_all=1 ;; + -s|--use-substitutes) + copyClosureFlags+=("$i") + ;; --max-jobs|-j|--cores|-I|--builders) j="$1"; shift 1 extraBuildFlags+=("$i" "$j") @@ -157,11 +161,11 @@ targetHostCmd() { copyToTarget() { if ! [ "$targetHost" = "$buildHost" ]; then if [ -z "$targetHost" ]; then - NIX_SSHOPTS=$SSHOPTS nix-copy-closure --from "$buildHost" "$1" + NIX_SSHOPTS=$SSHOPTS nix-copy-closure "${copyClosureFlags[@]}" --from "$buildHost" "$1" elif [ -z "$buildHost" ]; then - NIX_SSHOPTS=$SSHOPTS nix-copy-closure --to "$targetHost" "$1" + NIX_SSHOPTS=$SSHOPTS nix-copy-closure "${copyClosureFlags[@]}" --to "$targetHost" "$1" else - buildHostCmd nix-copy-closure --to "$targetHost" "$1" + buildHostCmd nix-copy-closure "${copyClosureFlags[@]}" --to "$targetHost" "$1" fi fi } @@ -425,7 +429,7 @@ if [[ -n $buildNix && -z $flake ]]; then if [ -a "$nixDrv" ]; then nix-store -r "$nixDrv"'!'"out" --add-root "$tmpDir/nix" --indirect >/dev/null if [ -n "$buildHost" ]; then - nix-copy-closure --to "$buildHost" "$nixDrv" + nix-copy-closure "${copyClosureFlags[@]}" --to "$buildHost" "$nixDrv" # The nix build produces multiple outputs, we add them all to the remote path for p in $(buildHostCmd nix-store -r "$(readlink "$nixDrv")" "${buildArgs[@]}"); do remoteNix="$remoteNix${remoteNix:+:}$p/bin" diff --git a/pkgs/os-specific/linux/nss_ldap/default.nix b/pkgs/os-specific/linux/nss_ldap/default.nix index 0121c4a6f1c..23bc8ff0dfa 100644 --- a/pkgs/os-specific/linux/nss_ldap/default.nix +++ b/pkgs/os-specific/linux/nss_ldap/default.nix @@ -1,10 +1,11 @@ {lib, stdenv, fetchurl, openldap, perl}: -stdenv.mkDerivation { - name = "nss_ldap-265"; +stdenv.mkDerivation rec { + pname = "nss_ldap"; + version = "265"; src = fetchurl { - url = "http://www.padl.com/download/nss_ldap-265.tar.gz"; + url = "http://www.padl.com/download/nss_ldap-${version}.tar.gz"; sha256 = "1a16q9p97d2blrj0h6vl1xr7dg7i4s8x8namipr79mshby84vdbp"; }; diff --git a/pkgs/os-specific/linux/numad/default.nix b/pkgs/os-specific/linux/numad/default.nix index 21d5a871f4e..0526c02f75f 100644 --- a/pkgs/os-specific/linux/numad/default.nix +++ b/pkgs/os-specific/linux/numad/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl }: stdenv.mkDerivation rec { - name = "numad-0.5"; + pname = "numad"; + version = "0.5"; src = fetchurl { - url = "https://git.fedorahosted.org/cgit/numad.git/snapshot/${name}.tar.xz"; + url = "https://git.fedorahosted.org/cgit/numad.git/snapshot/numad-${version}.tar.xz"; sha256 = "08zd1yc3w00yv4mvvz5sq1gf91f6p2s9ljcd72m33xgnkglj60v4"; }; diff --git a/pkgs/os-specific/linux/nvidia-x11/default.nix b/pkgs/os-specific/linux/nvidia-x11/default.nix index 7dccdccaf7b..6d21a4fca61 100644 --- a/pkgs/os-specific/linux/nvidia-x11/default.nix +++ b/pkgs/os-specific/linux/nvidia-x11/default.nix @@ -19,10 +19,10 @@ rec { # Policy: use the highest stable version as the default (on our master). stable = if stdenv.hostPlatform.system == "x86_64-linux" then generic { - version = "470.63.01"; - sha256_64bit = "sha256:057dsc0j3136r5gc08id3rwz9c0x7i01xkcwfk77vqic9b6486kg"; - settingsSha256 = "sha256:0lizp4hn49yvca2yd76yh3awld98pkaa35a067lpcld35vb5brgv"; - persistencedSha256 = "sha256:1f3gdpa23ipjy2xwf7qnxmw7w8xxhqy25rmcz34xkngjf4fn4pbs"; + version = "470.74"; + sha256_64bit = "sha256:0snzrb78f283rl92r5cqnr7bdk3yfkqpjac80sqskwi9wgg17r9k"; + settingsSha256 = "sha256:0hd9973l0zd8a0ia1dysfrk30jqxff1rr07b79ggvqd1xnvv0iqn"; + persistencedSha256 = "sha256:0i8wfhz53hdnabdcx9awki3nk6xa6dadzn91iswhmfm4jj6964jf"; } else legacy_390; diff --git a/pkgs/os-specific/linux/nvidia-x11/generic.nix b/pkgs/os-specific/linux/nvidia-x11/generic.nix index 282d9728821..6f58e3e8f1d 100644 --- a/pkgs/os-specific/linux/nvidia-x11/generic.nix +++ b/pkgs/os-specific/linux/nvidia-x11/generic.nix @@ -111,7 +111,7 @@ let description = "X.org driver and kernel module for NVIDIA graphics cards"; license = licenses.unfreeRedistributable; platforms = [ "x86_64-linux" ] ++ optionals (!i686bundled) [ "i686-linux" ]; - maintainers = with maintainers; [ baracoder ]; + maintainers = with maintainers; [ ]; priority = 4; # resolves collision with xorg-server's "lib/xorg/modules/extensions/libglx.so" inherit broken; }; diff --git a/pkgs/os-specific/linux/opengl/xorg-sys/default.nix b/pkgs/os-specific/linux/opengl/xorg-sys/default.nix index 33df8c0cc34..b7f1b657440 100644 --- a/pkgs/os-specific/linux/opengl/xorg-sys/default.nix +++ b/pkgs/os-specific/linux/opengl/xorg-sys/default.nix @@ -9,7 +9,8 @@ {lib, stdenv, xorg, expat, libdrm}: stdenv.mkDerivation { - name = "xorg-sys-opengl-3"; + pname = "xorg-sys-opengl"; + version = "3"; builder = ./builder.sh; neededLibs = map (p: p.out) [xorg.libXxf86vm xorg.libXext expat libdrm stdenv.cc.cc]; diff --git a/pkgs/os-specific/linux/otpw/default.nix b/pkgs/os-specific/linux/otpw/default.nix index fed7930bf14..14381ac68c1 100644 --- a/pkgs/os-specific/linux/otpw/default.nix +++ b/pkgs/os-specific/linux/otpw/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl, pam }: stdenv.mkDerivation rec { - name = "otpw-1.3"; + pname = "otpw"; + version = "1.3"; src = fetchurl { - url = "https://www.cl.cam.ac.uk/~mgk25/download/${name}.tar.gz"; + url = "https://www.cl.cam.ac.uk/~mgk25/download/otpw-${version}.tar.gz"; sha256 = "1k3hc7xbxz6hkc55kvddi3cibafwf93ivn58sy1l888d3l5dwmrk"; }; diff --git a/pkgs/os-specific/linux/pam_ccreds/default.nix b/pkgs/os-specific/linux/pam_ccreds/default.nix index bfe9ac7c830..4b2cc7a3822 100644 --- a/pkgs/os-specific/linux/pam_ccreds/default.nix +++ b/pkgs/os-specific/linux/pam_ccreds/default.nix @@ -1,10 +1,11 @@ {lib, stdenv, fetchurl, pam, openssl, db}: stdenv.mkDerivation rec { - name = "pam_ccreds-10"; + pname = "pam_ccreds"; + version = "10"; src = fetchurl { - url = "https://www.padl.com/download/${name}.tar.gz"; + url = "https://www.padl.com/download/pam_ccreds-${version}.tar.gz"; sha256 = "1h7zyg1b1h69civyvrj95w22dg0y7lgw3hq4gqkdcg35w1y76fhz"; }; patchPhase = '' diff --git a/pkgs/os-specific/linux/pam_krb5/default.nix b/pkgs/os-specific/linux/pam_krb5/default.nix index cb04fa5b424..af5fbccff05 100644 --- a/pkgs/os-specific/linux/pam_krb5/default.nix +++ b/pkgs/os-specific/linux/pam_krb5/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl, pam, libkrb5 }: stdenv.mkDerivation rec { - name = "pam-krb5-4.10"; + pname = "pam-krb5"; + version = "4.10"; src = fetchurl { - url = "https://archives.eyrie.org/software/kerberos/${name}.tar.gz"; + url = "https://archives.eyrie.org/software/kerberos/pam-krb5-${version}.tar.gz"; sha256 = "09wzxd5zrj5bzqpb01qf148npj5k8hmd2bx2ij1qsy40hdxqyq79"; }; diff --git a/pkgs/os-specific/linux/pam_ldap/default.nix b/pkgs/os-specific/linux/pam_ldap/default.nix index e327a551b23..988256808db 100644 --- a/pkgs/os-specific/linux/pam_ldap/default.nix +++ b/pkgs/os-specific/linux/pam_ldap/default.nix @@ -1,10 +1,11 @@ { stdenv, fetchurl, pam, openldap, perl }: stdenv.mkDerivation rec { - name = "pam_ldap-186"; + pname = "pam_ldap"; + version = "186"; src = fetchurl { - url = "https://www.padl.com/download/${name}.tar.gz"; + url = "https://www.padl.com/download/pam_ldap-${version}.tar.gz"; sha256 = "0lv4f7hc02jrd2l3gqxd247qq62z11sp3fafn8lgb8ymb7aj5zn8"; }; diff --git a/pkgs/os-specific/linux/pam_usb/default.nix b/pkgs/os-specific/linux/pam_usb/default.nix index 1a66e986d8b..8411c4fdbfa 100644 --- a/pkgs/os-specific/linux/pam_usb/default.nix +++ b/pkgs/os-specific/linux/pam_usb/default.nix @@ -33,10 +33,11 @@ let in stdenv.mkDerivation rec { - name = "pam_usb-0.5.0"; + pname = "pam_usb"; + version = "0.5.0"; src = fetchurl { - url = "mirror://sourceforge/pamusb/${name}.tar.gz"; + url = "mirror://sourceforge/pamusb/pam_usb-${version}.tar.gz"; sha256 = "1g1w0s9d8mfld8abrn405ll5grv3xgs0b0hsganrz6qafdq9j7q1"; }; diff --git a/pkgs/os-specific/linux/pax-utils/default.nix b/pkgs/os-specific/linux/pax-utils/default.nix index 40159cd2acd..db576302997 100644 --- a/pkgs/os-specific/linux/pax-utils/default.nix +++ b/pkgs/os-specific/linux/pax-utils/default.nix @@ -2,11 +2,11 @@ stdenv.mkDerivation rec { pname = "pax-utils"; - version = "1.2.8"; + version = "1.3.3"; src = fetchurl { url = "http://distfiles.gentoo.org/distfiles/${pname}-${version}.tar.xz"; - sha256 = "sha256-urTIhG4dLMNmnPqSMdIdszWEHX1Y+eGc0Jn+bOYmsVc="; + sha256 = "sha256-7sp/vZi8Zr6tSncADCAl2fF+qCAbhCRYgkBs4AubaxQ="; }; makeFlags = [ "PREFIX=$(out)" ]; @@ -20,7 +20,7 @@ stdenv.mkDerivation rec { binary files. ''; homepage = "https://wiki.gentoo.org/wiki/Hardened/PaX_Utilities"; - license = licenses.gpl2; + license = licenses.gpl2Only; platforms = platforms.unix; maintainers = with maintainers; [ thoughtpolice joachifm ]; }; diff --git a/pkgs/os-specific/linux/pcmciautils/default.nix b/pkgs/os-specific/linux/pcmciautils/default.nix index a4da6be691e..bca58bd808e 100644 --- a/pkgs/os-specific/linux/pcmciautils/default.nix +++ b/pkgs/os-specific/linux/pcmciautils/default.nix @@ -7,10 +7,11 @@ # FIXME: should add an option to choose between hotplug and udev. stdenv.mkDerivation rec { - name = "pcmciautils-018"; + pname = "pcmciautils"; + version = "018"; src = fetchurl { - url = "https://kernel.org/pub/linux/utils/kernel/pcmcia/${name}.tar.gz"; + url = "https://kernel.org/pub/linux/utils/kernel/pcmcia/pcmciautils-${version}.tar.gz"; sha256 = "0sfm3w2n73kl5w7gb1m6q8gy5k4rgwvzz79n6yhs9w3sag3ix8sk"; }; diff --git a/pkgs/os-specific/linux/perf-tools/default.nix b/pkgs/os-specific/linux/perf-tools/default.nix index 7d5d6d59ea8..8c3e31e4538 100644 --- a/pkgs/os-specific/linux/perf-tools/default.nix +++ b/pkgs/os-specific/linux/perf-tools/default.nix @@ -1,7 +1,8 @@ { lib, stdenv, fetchFromGitHub, perl }: stdenv.mkDerivation { - name = "perf-tools-20171219"; + pname = "perf-tools"; + version = "unstable-2017-12-19"; src = fetchFromGitHub { owner = "brendangregg"; @@ -39,6 +40,6 @@ stdenv.mkDerivation { homepage = "https://github.com/brendangregg/perf-tools"; description = "Performance analysis tools based on Linux perf_events (aka perf) and ftrace"; maintainers = [ maintainers.eelco ]; - license = licenses.gpl2; + license = licenses.gpl2Plus; }; } diff --git a/pkgs/os-specific/linux/pflask/default.nix b/pkgs/os-specific/linux/pflask/default.nix index f3e63133d1e..92294b58e42 100644 --- a/pkgs/os-specific/linux/pflask/default.nix +++ b/pkgs/os-specific/linux/pflask/default.nix @@ -1,13 +1,14 @@ -{ lib, stdenv, fetchurl, python, wafHook }: +{ lib, stdenv, fetchFromGitHub, python, wafHook }: stdenv.mkDerivation rec { pname = "pflask"; - version = "git-2015-12-17"; - rev = "599418bb6453eaa0ccab493f9411f13726c1a636"; + version = "unstable-2015-12-17"; - src = fetchurl { - url = "https://github.com/ghedo/pflask/archive/${rev}.tar.gz"; - sha256 = "2545fca37f9da484b46b6fb5e3a9bbba6526a9725189fe4af5227ef6e6fca440"; + src = fetchFromGitHub { + owner = "ghedo"; + repo = "pflask"; + rev = "599418bb6453eaa0ccab493f9411f13726c1a636"; + hash = "sha256-0RjitZd2JUK7WUEJuw4qhUx3joY5OI0Hh74mTzp7GmY="; }; nativeBuildInputs = [ wafHook ]; @@ -15,9 +16,9 @@ stdenv.mkDerivation rec { meta = { description = "Lightweight process containers for Linux"; - homepage = "https://ghedo.github.io/pflask/"; - license = lib.licenses.bsd2; - platforms = lib.platforms.linux; + homepage = "https://ghedo.github.io/pflask/"; + license = lib.licenses.bsd2; + platforms = lib.platforms.linux; maintainers = with lib.maintainers; [ ]; }; } diff --git a/pkgs/os-specific/linux/pm-utils/default.nix b/pkgs/os-specific/linux/pm-utils/default.nix index 17723983c69..4076641717f 100644 --- a/pkgs/os-specific/linux/pm-utils/default.nix +++ b/pkgs/os-specific/linux/pm-utils/default.nix @@ -12,10 +12,11 @@ let in stdenv.mkDerivation rec { - name = "pm-utils-1.4.1"; + pname = "pm-utils"; + version = "1.4.1"; src = fetchurl { - url = "https://pm-utils.freedesktop.org/releases/${name}.tar.gz"; + url = "https://pm-utils.freedesktop.org/releases/pm-utils-${version}.tar.gz"; sha256 = "02qc6zaf7ams6qcc470fwb6jvr4abv3lrlx16clqpn36501rkn4f"; }; diff --git a/pkgs/os-specific/linux/procdump/default.nix b/pkgs/os-specific/linux/procdump/default.nix index 75ca2cb165e..0b40a4dd036 100644 --- a/pkgs/os-specific/linux/procdump/default.nix +++ b/pkgs/os-specific/linux/procdump/default.nix @@ -2,13 +2,13 @@ stdenv.mkDerivation rec { pname = "procdump"; - version = "1.1.1"; + version = "1.2"; src = fetchFromGitHub { owner = "Microsoft"; repo = "ProcDump-for-Linux"; rev = version; - sha256 = "0h5fhk39d10kjbinzw1yp6nr8w8l300mn9qxrkpivdkyfn6bpq2f"; + sha256 = "sha256-gVswAezHl7E2cBTJEQhPFXhHkzhWVHSpPF8m0s8+ekc="; }; nativeBuildInputs = [ zlib ]; diff --git a/pkgs/os-specific/linux/qmk-udev-rules/default.nix b/pkgs/os-specific/linux/qmk-udev-rules/default.nix new file mode 100644 index 00000000000..7fb5b092ca4 --- /dev/null +++ b/pkgs/os-specific/linux/qmk-udev-rules/default.nix @@ -0,0 +1,33 @@ +{ lib, stdenv, fetchFromGitHub }: + +## Usage +# In NixOS, simply add this package to services.udev.packages: +# services.udev.packages = [ pkgs.qmk-udev-rules ]; + +stdenv.mkDerivation rec { + pname = "qmk-udev-rules"; + version = "0.13.23"; + + src = fetchFromGitHub { + owner = "qmk"; + repo = "qmk_firmware"; + rev = version; + sha256 = "08d2ri9g6lky3ixd5h0scm95hgc52lcjr3vcnmpdxn780q9ygmkm"; + }; + + dontBuild = true; + + installPhase = '' + runHook preInstall + install -D util/udev/50-qmk.rules $out/lib/udev/rules.d/50-qmk.rules + runHook postInstall + ''; + + meta = with lib; { + homepage = "https://github.com/qmk/qmk_firmware"; + description = "Official QMK udev rules list"; + platforms = platforms.linux; + license = licenses.gpl2Only; + maintainers = with maintainers; [ ekleog ]; + }; +} diff --git a/pkgs/os-specific/linux/sch_cake/default.nix b/pkgs/os-specific/linux/sch_cake/default.nix index 851a903cf07..facf690a9bd 100644 --- a/pkgs/os-specific/linux/sch_cake/default.nix +++ b/pkgs/os-specific/linux/sch_cake/default.nix @@ -3,7 +3,8 @@ assert lib.versionAtLeast kernel.version "4.4"; stdenv.mkDerivation { - name = "sch_cake-2017-07-16"; + pname = "sch_cake"; + version = "unstable-2017-07-16"; src = fetchFromGitHub { owner = "dtaht"; diff --git a/pkgs/os-specific/linux/sdparm/default.nix b/pkgs/os-specific/linux/sdparm/default.nix index 08e61a98f6b..a9137b18f39 100644 --- a/pkgs/os-specific/linux/sdparm/default.nix +++ b/pkgs/os-specific/linux/sdparm/default.nix @@ -2,11 +2,11 @@ stdenv.mkDerivation rec { pname = "sdparm"; - version = "1.11"; + version = "1.12"; src = fetchurl { url = "http://sg.danny.cz/sg/p/${pname}-${version}.tar.xz"; - sha256 = "1nqjc4w2w47zavcbf5xmm53x1zbwgljaw1lpajcdi537cgy32fa8"; + sha256 = "sha256-xMnvr9vrZi4vlxJwfsSQkyvU0BC7ESmueplSZUburb4="; }; meta = with lib; { diff --git a/pkgs/os-specific/linux/smemstat/default.nix b/pkgs/os-specific/linux/smemstat/default.nix index 64525052af2..1510981c176 100644 --- a/pkgs/os-specific/linux/smemstat/default.nix +++ b/pkgs/os-specific/linux/smemstat/default.nix @@ -2,10 +2,10 @@ stdenv.mkDerivation rec { pname = "smemstat"; - version = "0.02.08"; + version = "0.02.10"; src = fetchurl { url = "https://kernel.ubuntu.com/~cking/tarballs/smemstat/smemstat-${version}.tar.xz"; - sha256 = "1agigvkv1868cskivzrwyiixl658x5bv7xpz4xjc8mlii4maivpp"; + sha256 = "sha256-Vrs1jOg5yHdEffVo769aaxSawo4iZtGrFJ65Nu+RhcU="; }; buildInputs = [ ncurses ]; installFlags = [ "DESTDIR=$(out)" ]; diff --git a/pkgs/os-specific/linux/sydbox/default.nix b/pkgs/os-specific/linux/sydbox/default.nix new file mode 100644 index 00000000000..bdaf77147f2 --- /dev/null +++ b/pkgs/os-specific/linux/sydbox/default.nix @@ -0,0 +1,77 @@ +{ lib +, stdenv +, fetchurl +, pkg-config +, autoreconfHook +, python3 +, perl +, libxslt +, docbook_xsl +, docbook_xml_dtd_42 +, libseccomp +, installTests ? true, gnumake, which +, debugBuild ? false, libunwind +}: + +stdenv.mkDerivation rec { + pname = "sydbox-1"; + version = "2.2.0"; + + outputs = [ "out" "dev" "man" "doc" ] + ++ lib.optional installTests "installedTests"; + + src = fetchurl { + url = "https://git.exherbo.org/${pname}.git/snapshot/${pname}-${version}.tar.xz"; + sha256 = "0664myrrzbvsw73q5b7cqwgv4hl9a7vkm642s1r96gaxm16jk0z7"; + }; + + nativeBuildInputs = [ + pkg-config + autoreconfHook + python3 + perl + libxslt.bin + docbook_xsl + docbook_xml_dtd_42 + ]; + + buildInputs = [ + libseccomp + ] ++ lib.optional debugBuild libunwind + ++ lib.optionals installTests [ + gnumake + python3 + perl + which + ]; + + enableParallelBuilding = true; + + configureFlags = [ ] + ++ lib.optionals installTests [ "--enable-installed-tests" + "--libexecdir=${placeholder "installedTests"}/libexec" ] + ++ lib.optional debugBuild "--enable-debug"; + + makeFlags = [ "SYD_INCLUDEDIR=${stdenv.cc.libc.dev}/include" ]; + + doCheck = true; + checkPhase = '' + # Many of the regular test cases in t/ do not work inside the build sandbox + make -C syd check + ''; + + postInstall = if installTests then '' + moveToOutput bin/syd-test $installedTests + '' else '' + # Tests are installed despite --disable-installed-tests + rm -r $out/bin/syd-test $out/libexec + ''; + + meta = with lib; { + homepage = "https://sydbox.exherbo.org/"; + description = "seccomp-based application sandbox"; + license = licenses.gpl2; + platforms = platforms.linux; + maintainers = with maintainers; [ mvs ]; + }; +} diff --git a/pkgs/os-specific/linux/sysdig/default.nix b/pkgs/os-specific/linux/sysdig/default.nix index 23e78dd848e..564fbca37ba 100644 --- a/pkgs/os-specific/linux/sysdig/default.nix +++ b/pkgs/os-specific/linux/sysdig/default.nix @@ -31,7 +31,7 @@ stdenv.mkDerivation rec { NIX_CFLAGS_COMPILE = "-DluaL_reg=luaL_Reg -DluaL_getn(L,i)=((int)lua_objlen(L,i))"; preConfigure = '' - cmakeFlagsArray+=(-DCMAKE_EXE_LINKER_FLAGS="-ltbb -lcurl") + cmakeFlagsArray+=(-DCMAKE_EXE_LINKER_FLAGS="-ltbb -lcurl -labsl_synchronization") export INSTALL_MOD_PATH="$out" '' + optionalString (kernel != null) '' diff --git a/pkgs/os-specific/linux/sysfsutils/default.nix b/pkgs/os-specific/linux/sysfsutils/default.nix index 4daac076e58..b5f067fffd7 100644 --- a/pkgs/os-specific/linux/sysfsutils/default.nix +++ b/pkgs/os-specific/linux/sysfsutils/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl }: stdenv.mkDerivation rec { - name = "sysfsutils-2.1.0"; + pname = "sysfsutils"; + version = "2.1.0"; src = fetchurl { - url = "mirror://sourceforge/linux-diag/${name}.tar.gz"; + url = "mirror://sourceforge/linux-diag/sysfsutils-${version}.tar.gz"; sha256 = "e865de2c1f559fff0d3fc936e660c0efaf7afe662064f2fb97ccad1ec28d208a"; }; diff --git a/pkgs/os-specific/linux/sysklogd/default.nix b/pkgs/os-specific/linux/sysklogd/default.nix index af180b5e524..4d9844f516b 100644 --- a/pkgs/os-specific/linux/sysklogd/default.nix +++ b/pkgs/os-specific/linux/sysklogd/default.nix @@ -1,10 +1,11 @@ {lib, stdenv, fetchurl}: -stdenv.mkDerivation { - name = "sysklogd-1.5.1"; +stdenv.mkDerivation rec { + pname = "sysklogd"; + version = "1.5.1"; src = fetchurl { - url = "http://www.infodrom.org/projects/sysklogd/download/sysklogd-1.5.1.tar.gz"; + url = "http://www.infodrom.org/projects/sysklogd/download/sysklogd-${version}.tar.gz"; sha256 = "00f2wy6f0qng7qzga4iicyzl9j8b7mp6mrpfky5jxj93ms2w2rji"; }; @@ -14,6 +15,17 @@ stdenv.mkDerivation { installFlags = [ "BINDIR=$(out)/sbin" "MANDIR=$(out)/share/man" "INSTALL=install" ]; + makeFlags = [ + "CC=${stdenv.cc.targetPrefix}cc" + ]; + + postPatch = '' + # Disable stripping during installation, stripping will be done anyway. + # Fixes cross-compilation. + substituteInPlace Makefile \ + --replace "-m 500 -s" "-m 500" + ''; + preConfigure = '' sed -e 's@-o \''${MAN_USER} -g \''${MAN_GROUP} -m \''${MAN_PERMS} @@' -i Makefile diff --git a/pkgs/os-specific/linux/sysstat/default.nix b/pkgs/os-specific/linux/sysstat/default.nix index 2eff999ac7c..2d5b3e2ab55 100644 --- a/pkgs/os-specific/linux/sysstat/default.nix +++ b/pkgs/os-specific/linux/sysstat/default.nix @@ -1,10 +1,11 @@ { lib, stdenv, fetchurl, gettext, bzip2 }: stdenv.mkDerivation rec { - name = "sysstat-12.4.3"; + pname = "sysstat"; + version = "12.4.3"; src = fetchurl { - url = "http://pagesperso-orange.fr/sebastien.godard/${name}.tar.xz"; + url = "http://pagesperso-orange.fr/sebastien.godard/sysstat-${version}.tar.xz"; sha256 = "sha256-rkMkMfRarLyrrPu+Ep4lBeIVyvqc6ZbXVQxgkaRvC/0="; }; diff --git a/pkgs/os-specific/linux/system76-power/default.nix b/pkgs/os-specific/linux/system76-power/default.nix index fbc26ca8719..38ce20deeab 100644 --- a/pkgs/os-specific/linux/system76-power/default.nix +++ b/pkgs/os-specific/linux/system76-power/default.nix @@ -2,19 +2,19 @@ rustPlatform.buildRustPackage rec { pname = "system76-power"; - version = "1.1.16"; + version = "1.1.17"; src = fetchFromGitHub { owner = "pop-os"; repo = "system76-power"; rev = version; - sha256 = "sha256-OtrhvUkNNgg6KlrqjwiBKL4zuQZBWevb0xgtSlEW2rQ="; + sha256 = "sha256-9ndukZPNB0qtU0hA9eUYpiAC8Tw1eF16W+sVU7XKvsg="; }; nativeBuildInputs = [ pkg-config ]; buildInputs = [ dbus libusb1 ]; - cargoSha256 = "sha256-ImACDbnUbwc0ZXgF3xxzes8+vUjt76B1xxgqzhgAYX4="; + cargoSha256 = "sha256-6mtBY77d2WAwTpj+g0KVpW/n39uanAL2GNHWC8Qbtqk="; postInstall = '' install -D -m 0644 data/system76-power.conf $out/etc/dbus-1/system.d/system76-power.conf diff --git a/pkgs/os-specific/linux/systemd/0001-Start-device-units-for-uninitialised-encrypted-devic.patch b/pkgs/os-specific/linux/systemd/0001-Start-device-units-for-uninitialised-encrypted-devic.patch index ac2d0018160..8a1cdc1da84 100644 --- a/pkgs/os-specific/linux/systemd/0001-Start-device-units-for-uninitialised-encrypted-devic.patch +++ b/pkgs/os-specific/linux/systemd/0001-Start-device-units-for-uninitialised-encrypted-devic.patch @@ -1,4 +1,4 @@ -From 2f4a5e9c9ef1cd57662e8bd4c24e1029a00d55b5 Mon Sep 17 00:00:00 2001 +From 57e31a2d4a5d5bd7a9e1cd8a0d8bc6a00624ad68 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra <eelco.dolstra@logicblox.com> Date: Tue, 8 Jan 2013 15:46:30 +0100 Subject: [PATCH 01/19] Start device units for uninitialised encrypted devices @@ -13,7 +13,7 @@ unit. (However, this ignores the fsck unit, so it's not perfect...) 1 file changed, 4 deletions(-) diff --git a/rules.d/99-systemd.rules.in b/rules.d/99-systemd.rules.in -index 7c22eefdb7..e3a55e00b5 100644 +index 25b8a590a6..d18999ea87 100644 --- a/rules.d/99-systemd.rules.in +++ b/rules.d/99-systemd.rules.in @@ -17,10 +17,6 @@ SUBSYSTEM=="ubi", TAG+="systemd" @@ -28,5 +28,5 @@ index 7c22eefdb7..e3a55e00b5 100644 SUBSYSTEM=="block", ENV{ID_PART_GPT_AUTO_ROOT}=="1", ENV{ID_FS_TYPE}!="crypto_LUKS", SYMLINK+="gpt-auto-root" SUBSYSTEM=="block", ENV{ID_PART_GPT_AUTO_ROOT}=="1", ENV{ID_FS_TYPE}=="crypto_LUKS", SYMLINK+="gpt-auto-root-luks" -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0002-Don-t-try-to-unmount-nix-or-nix-store.patch b/pkgs/os-specific/linux/systemd/0002-Don-t-try-to-unmount-nix-or-nix-store.patch index f54430f764e..129e0825d9f 100644 --- a/pkgs/os-specific/linux/systemd/0002-Don-t-try-to-unmount-nix-or-nix-store.patch +++ b/pkgs/os-specific/linux/systemd/0002-Don-t-try-to-unmount-nix-or-nix-store.patch @@ -1,4 +1,4 @@ -From 4e96b2e074c4a4f4ce900409872ce2f86704ee5b Mon Sep 17 00:00:00 2001 +From 43465a392b47238a32f8719f603ed9e2c9bb0363 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra <eelco.dolstra@logicblox.com> Date: Fri, 12 Apr 2013 13:16:57 +0200 Subject: [PATCH 02/19] Don't try to unmount /nix or /nix/store @@ -12,7 +12,7 @@ https://github.com/NixOS/nixos/issues/126 2 files changed, 4 insertions(+) diff --git a/src/shared/fstab-util.c b/src/shared/fstab-util.c -index 292b97cd69..791b8e6b7e 100644 +index f683f05981..5a04c2c2a6 100644 --- a/src/shared/fstab-util.c +++ b/src/shared/fstab-util.c @@ -40,6 +40,8 @@ bool fstab_is_extrinsic(const char *mount, const char *opts) { @@ -25,10 +25,10 @@ index 292b97cd69..791b8e6b7e 100644 "/etc")) return true; diff --git a/src/shutdown/umount.c b/src/shutdown/umount.c -index 3a72a13e1a..541320dc9d 100644 +index c2a26242c0..9936398f32 100644 --- a/src/shutdown/umount.c +++ b/src/shutdown/umount.c -@@ -500,6 +500,8 @@ static int delete_md(MountPoint *m) { +@@ -496,6 +496,8 @@ static int delete_md(MountPoint *m) { static bool nonunmountable_path(const char *path) { return path_equal(path, "/") @@ -38,5 +38,5 @@ index 3a72a13e1a..541320dc9d 100644 || path_equal(path, "/usr") #endif -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0003-Fix-NixOS-containers.patch b/pkgs/os-specific/linux/systemd/0003-Fix-NixOS-containers.patch index 37caffb97d7..91fdebc7ad3 100644 --- a/pkgs/os-specific/linux/systemd/0003-Fix-NixOS-containers.patch +++ b/pkgs/os-specific/linux/systemd/0003-Fix-NixOS-containers.patch @@ -1,4 +1,4 @@ -From 3d1b2e56a6ed6cc86a64f6f89765a2900e576402 Mon Sep 17 00:00:00 2001 +From a99666d3d7012c2162fdacf84a57fc0b848fd957 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra <eelco.dolstra@logicblox.com> Date: Wed, 16 Apr 2014 10:59:28 +0200 Subject: [PATCH 03/19] Fix NixOS containers @@ -10,10 +10,10 @@ container, so checking early whether it exists will fail. 1 file changed, 2 insertions(+) diff --git a/src/nspawn/nspawn.c b/src/nspawn/nspawn.c -index 7515380fcd..14f8a82eb8 100644 +index 04685fecba..0e5ece5f91 100644 --- a/src/nspawn/nspawn.c +++ b/src/nspawn/nspawn.c -@@ -5323,6 +5323,7 @@ static int run(int argc, char *argv[]) { +@@ -5590,6 +5590,7 @@ static int run(int argc, char *argv[]) { goto finish; } } else { @@ -21,7 +21,7 @@ index 7515380fcd..14f8a82eb8 100644 const char *p, *q; if (arg_pivot_root_new) -@@ -5337,6 +5338,7 @@ static int run(int argc, char *argv[]) { +@@ -5604,6 +5605,7 @@ static int run(int argc, char *argv[]) { r = -EINVAL; goto finish; } @@ -30,5 +30,5 @@ index 7515380fcd..14f8a82eb8 100644 } else { -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0004-Look-for-fsck-in-the-right-place.patch b/pkgs/os-specific/linux/systemd/0004-Look-for-fsck-in-the-right-place.patch index 2f14a9d6a7e..bdd205dd29e 100644 --- a/pkgs/os-specific/linux/systemd/0004-Look-for-fsck-in-the-right-place.patch +++ b/pkgs/os-specific/linux/systemd/0004-Look-for-fsck-in-the-right-place.patch @@ -1,4 +1,4 @@ -From 3a721cf70e952e933ef5374006bbb11a3a0ad36a Mon Sep 17 00:00:00 2001 +From 3f0780b25bdbe4156a2f761c90083bbba5f4d473 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra <eelco.dolstra@logicblox.com> Date: Thu, 1 May 2014 14:10:10 +0200 Subject: [PATCH 04/19] Look for fsck in the right place @@ -8,7 +8,7 @@ Subject: [PATCH 04/19] Look for fsck in the right place 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/fsck/fsck.c b/src/fsck/fsck.c -index 510689f3b7..25cab5acae 100644 +index cd7adfaeb9..68cebdd158 100644 --- a/src/fsck/fsck.c +++ b/src/fsck/fsck.c @@ -368,7 +368,7 @@ static int run(int argc, char *argv[]) { @@ -21,5 +21,5 @@ index 510689f3b7..25cab5acae 100644 cmdline[i++] = "-T"; -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0005-Add-some-NixOS-specific-unit-directories.patch b/pkgs/os-specific/linux/systemd/0005-Add-some-NixOS-specific-unit-directories.patch index 0acccacd613..8680d147ad1 100644 --- a/pkgs/os-specific/linux/systemd/0005-Add-some-NixOS-specific-unit-directories.patch +++ b/pkgs/os-specific/linux/systemd/0005-Add-some-NixOS-specific-unit-directories.patch @@ -1,4 +1,4 @@ -From 8b7f881cf22e98e907506f4c403b9e304e332bf9 Mon Sep 17 00:00:00 2001 +From 82698c6a5142e710c302f9c38367ed00d8ec94ba Mon Sep 17 00:00:00 2001 From: Eelco Dolstra <eelco.dolstra@logicblox.com> Date: Fri, 19 Dec 2014 14:46:17 +0100 Subject: [PATCH 05/19] Add some NixOS-specific unit directories @@ -10,14 +10,14 @@ units provided by packages installed into the default profile via Also, remove /usr and /lib as these don't exist on NixOS. --- src/basic/path-lookup.c | 17 ++--------------- - src/core/systemd.pc.in | 5 +++-- - 2 files changed, 5 insertions(+), 17 deletions(-) + src/core/systemd.pc.in | 8 ++++---- + 2 files changed, 6 insertions(+), 19 deletions(-) diff --git a/src/basic/path-lookup.c b/src/basic/path-lookup.c -index 96b82170d0..bf66bd6b77 100644 +index 05eb17d66c..1cd141d012 100644 --- a/src/basic/path-lookup.c +++ b/src/basic/path-lookup.c -@@ -94,11 +94,7 @@ int xdg_user_data_dir(char **ret, const char *suffix) { +@@ -91,11 +91,7 @@ int xdg_user_data_dir(char **ret, const char *suffix) { } static const char* const user_data_unit_paths[] = { @@ -29,7 +29,7 @@ index 96b82170d0..bf66bd6b77 100644 NULL }; -@@ -616,15 +612,13 @@ int lookup_paths_init( +@@ -613,15 +609,13 @@ int lookup_paths_init( persistent_config, SYSTEM_CONFIG_UNIT_DIR, "/etc/systemd/system", @@ -40,13 +40,13 @@ index 96b82170d0..bf66bd6b77 100644 STRV_IFNOTNULL(runtime_attached), STRV_IFNOTNULL(generator), - "/usr/local/lib/systemd/system", - SYSTEM_DATA_UNIT_PATH, + SYSTEM_DATA_UNIT_DIR, - "/usr/lib/systemd/system", - STRV_IFNOTNULL(flags & LOOKUP_PATHS_SPLIT_USR ? "/lib/systemd/system" : NULL), STRV_IFNOTNULL(generator_late)); break; -@@ -640,14 +634,11 @@ int lookup_paths_init( +@@ -637,14 +631,11 @@ int lookup_paths_init( persistent_config, USER_CONFIG_UNIT_DIR, "/etc/systemd/user", @@ -62,7 +62,7 @@ index 96b82170d0..bf66bd6b77 100644 STRV_IFNOTNULL(generator_late)); break; -@@ -797,7 +788,6 @@ char **generator_binary_paths(UnitFileScope scope) { +@@ -794,7 +785,6 @@ char **generator_binary_paths(UnitFileScope scope) { case UNIT_FILE_SYSTEM: add = strv_new("/run/systemd/system-generators", "/etc/systemd/system-generators", @@ -70,7 +70,7 @@ index 96b82170d0..bf66bd6b77 100644 SYSTEM_GENERATOR_DIR); break; -@@ -805,7 +795,6 @@ char **generator_binary_paths(UnitFileScope scope) { +@@ -802,7 +792,6 @@ char **generator_binary_paths(UnitFileScope scope) { case UNIT_FILE_USER: add = strv_new("/run/systemd/user-generators", "/etc/systemd/user-generators", @@ -78,7 +78,7 @@ index 96b82170d0..bf66bd6b77 100644 USER_GENERATOR_DIR); break; -@@ -844,12 +833,10 @@ char **env_generator_binary_paths(bool is_system) { +@@ -841,12 +830,10 @@ char **env_generator_binary_paths(bool is_system) { if (is_system) add = strv_new("/run/systemd/system-environment-generators", "/etc/systemd/system-environment-generators", @@ -92,10 +92,10 @@ index 96b82170d0..bf66bd6b77 100644 if (!add) diff --git a/src/core/systemd.pc.in b/src/core/systemd.pc.in -index b5cc8f94a5..a701cd05f8 100644 +index fc0f8c34fa..ded74ce50a 100644 --- a/src/core/systemd.pc.in +++ b/src/core/systemd.pc.in -@@ -38,10 +38,11 @@ systemdsystemconfdir=${systemd_system_conf_dir} +@@ -38,10 +38,10 @@ systemdsystemconfdir=${systemd_system_conf_dir} systemd_user_conf_dir=${sysconfdir}/systemd/user systemduserconfdir=${systemd_user_conf_dir} @@ -105,10 +105,22 @@ index b5cc8f94a5..a701cd05f8 100644 -systemd_user_unit_path=${systemd_user_conf_dir}:/etc/systemd/user:/run/systemd/user:/usr/local/lib/systemd/user:/usr/local/share/systemd/user:${systemd_user_unit_dir}:/usr/lib/systemd/user:/usr/share/systemd/user +systemd_user_unit_path=${systemd_user_conf_dir}:/etc/systemd/user:/nix/var/nix/profiles/default/lib/systemd/user:/run/systemd/user:${systemduserunitdir} -+ systemduserunitpath=${systemd_user_unit_path} systemd_system_generator_dir=${root_prefix}/lib/systemd/system-generators +@@ -50,10 +50,10 @@ systemdsystemgeneratordir=${systemd_system_generator_dir} + systemd_user_generator_dir=${prefix}/lib/systemd/user-generators + systemdusergeneratordir=${systemd_user_generator_dir} + +-systemd_system_generator_path=/run/systemd/system-generators:/etc/systemd/system-generators:/usr/local/lib/systemd/system-generators:${systemd_system_generator_dir} ++systemd_system_generator_path=/run/systemd/system-generators:/etc/systemd/system-generators:${systemd_system_generator_dir} + systemdsystemgeneratorpath=${systemd_system_generator_path} + +-systemd_user_generator_path=/run/systemd/user-generators:/etc/systemd/user-generators:/usr/local/lib/systemd/user-generators:${systemd_user_generator_dir} ++systemd_user_generator_path=/run/systemd/user-generators:/etc/systemd/user-generators:${systemd_user_generator_dir} + systemdusergeneratorpath=${systemd_user_generator_path} + + systemd_sleep_dir=${root_prefix}/lib/systemd/system-sleep -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0006-Get-rid-of-a-useless-message-in-user-sessions.patch b/pkgs/os-specific/linux/systemd/0006-Get-rid-of-a-useless-message-in-user-sessions.patch index bda27ac1762..f6fa5833518 100644 --- a/pkgs/os-specific/linux/systemd/0006-Get-rid-of-a-useless-message-in-user-sessions.patch +++ b/pkgs/os-specific/linux/systemd/0006-Get-rid-of-a-useless-message-in-user-sessions.patch @@ -1,4 +1,4 @@ -From 7a6529ee27028860b93bc539e8bbf3f2374d712f Mon Sep 17 00:00:00 2001 +From e2a8db60ebfb1e0477ce989f6c3d4a95f2e08120 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra <eelco.dolstra@logicblox.com> Date: Mon, 11 May 2015 15:39:38 +0200 Subject: [PATCH 06/19] Get rid of a useless message in user sessions @@ -9,23 +9,23 @@ Namely lots of variants of in containers. --- - src/core/unit.c | 3 ++- + src/core/manager.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) -diff --git a/src/core/unit.c b/src/core/unit.c -index 45a417a090..8af3cb08d6 100644 ---- a/src/core/unit.c -+++ b/src/core/unit.c -@@ -2163,7 +2163,8 @@ static void unit_check_binds_to(Unit *u) { - } +diff --git a/src/core/manager.c b/src/core/manager.c +index 8884437347..e23d47b4a4 100644 +--- a/src/core/manager.c ++++ b/src/core/manager.c +@@ -1375,7 +1375,8 @@ static unsigned manager_dispatch_stop_when_bound_queue(Manager *m) { + if (!unit_is_bound_by_inactive(u, &culprit)) + continue; - assert(other); -- log_unit_info(u, "Unit is bound to inactive unit %s. Stopping, too.", other->id); -+ if (u->type != UNIT_MOUNT || detect_container() <= 0) -+ log_unit_info(u, "Unit is bound to inactive unit %s. Stopping, too.", other->id); +- log_unit_debug(u, "Unit is stopped because bound to inactive unit %s.", culprit->id); ++ if (u->type != UNIT_MOUNT || detect_container() <= 0) ++ log_unit_debug(u, "Unit is stopped because bound to inactive unit %s.", culprit->id); - /* A unit we need to run is gone. Sniff. Let's stop this. */ - r = manager_add_job(u->manager, JOB_STOP, u, JOB_FAIL, NULL, &error, NULL); + /* If stopping a unit fails continuously we might enter a stop loop here, hence stop acting on the + * service being unnecessary after a while. */ -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0007-hostnamed-localed-timedated-disable-methods-that-cha.patch b/pkgs/os-specific/linux/systemd/0007-hostnamed-localed-timedated-disable-methods-that-cha.patch index d51e1c0f566..17c53e2e518 100644 --- a/pkgs/os-specific/linux/systemd/0007-hostnamed-localed-timedated-disable-methods-that-cha.patch +++ b/pkgs/os-specific/linux/systemd/0007-hostnamed-localed-timedated-disable-methods-that-cha.patch @@ -1,4 +1,4 @@ -From 5580303956ca7d8eb431d23c2af0030c9cc0e6e9 Mon Sep 17 00:00:00 2001 +From 56ae06b48c6852071dfc57c1203c04f07309d757 Mon Sep 17 00:00:00 2001 From: Gabriel Ebner <gebner@gebner.org> Date: Sun, 6 Dec 2015 14:26:36 +0100 Subject: [PATCH 07/19] hostnamed, localed, timedated: disable methods that @@ -11,10 +11,10 @@ Subject: [PATCH 07/19] hostnamed, localed, timedated: disable methods that 3 files changed, 25 insertions(+) diff --git a/src/hostname/hostnamed.c b/src/hostname/hostnamed.c -index a1794bdab1..77134731e1 100644 +index 36702f2fb0..669257ea2f 100644 --- a/src/hostname/hostnamed.c +++ b/src/hostname/hostnamed.c -@@ -643,6 +643,9 @@ static int method_set_static_hostname(sd_bus_message *m, void *userdata, sd_bus_ +@@ -797,6 +797,9 @@ static int method_set_static_hostname(sd_bus_message *m, void *userdata, sd_bus_ if (r < 0) return r; @@ -24,7 +24,7 @@ index a1794bdab1..77134731e1 100644 name = empty_to_null(name); context_read_etc_hostname(c); -@@ -702,6 +705,9 @@ static int set_machine_info(Context *c, sd_bus_message *m, int prop, sd_bus_mess +@@ -860,6 +863,9 @@ static int set_machine_info(Context *c, sd_bus_message *m, int prop, sd_bus_mess if (r < 0) return r; @@ -35,20 +35,20 @@ index a1794bdab1..77134731e1 100644 context_read_machine_info(c); diff --git a/src/locale/localed.c b/src/locale/localed.c -index 736dacdee9..53e0ee935e 100644 +index df0eb030d4..d026eae97e 100644 --- a/src/locale/localed.c +++ b/src/locale/localed.c -@@ -317,6 +317,9 @@ static int method_set_locale(sd_bus_message *m, void *userdata, sd_bus_error *er +@@ -360,6 +360,9 @@ static int method_set_locale(sd_bus_message *m, void *userdata, sd_bus_error *er if (r < 0) return r; + return sd_bus_error_setf(error, SD_BUS_ERROR_NOT_SUPPORTED, -+ "Changing system settings via systemd is not supported on NixOS."); ++ "Changing system settings via systemd is not supported on NixOS."); + + use_localegen = locale_gen_check_available(); + /* If single locale without variable name is provided, then we assume it is LANG=. */ - if (strv_length(l) == 1 && !strchr(l[0], '=')) { - if (!locale_is_valid(l[0])) -@@ -432,6 +435,9 @@ static int method_set_vc_keyboard(sd_bus_message *m, void *userdata, sd_bus_erro +@@ -485,6 +488,9 @@ static int method_set_vc_keyboard(sd_bus_message *m, void *userdata, sd_bus_erro if (r < 0) return r; @@ -58,7 +58,7 @@ index 736dacdee9..53e0ee935e 100644 keymap = empty_to_null(keymap); keymap_toggle = empty_to_null(keymap_toggle); -@@ -606,6 +612,9 @@ static int method_set_x11_keyboard(sd_bus_message *m, void *userdata, sd_bus_err +@@ -665,6 +671,9 @@ static int method_set_x11_keyboard(sd_bus_message *m, void *userdata, sd_bus_err if (r < 0) return r; @@ -69,10 +69,10 @@ index 736dacdee9..53e0ee935e 100644 model = empty_to_null(model); variant = empty_to_null(variant); diff --git a/src/timedate/timedated.c b/src/timedate/timedated.c -index 76fe04900d..e87c4c8919 100644 +index 66b454269d..0a8fe25d0f 100644 --- a/src/timedate/timedated.c +++ b/src/timedate/timedated.c -@@ -646,6 +646,10 @@ static int method_set_timezone(sd_bus_message *m, void *userdata, sd_bus_error * +@@ -668,6 +668,10 @@ static int method_set_timezone(sd_bus_message *m, void *userdata, sd_bus_error * if (r < 0) return r; @@ -83,7 +83,7 @@ index 76fe04900d..e87c4c8919 100644 if (!timezone_is_valid(z, LOG_DEBUG)) return sd_bus_error_setf(error, SD_BUS_ERROR_INVALID_ARGS, "Invalid or not installed time zone '%s'", z); -@@ -725,6 +729,9 @@ static int method_set_local_rtc(sd_bus_message *m, void *userdata, sd_bus_error +@@ -747,6 +751,9 @@ static int method_set_local_rtc(sd_bus_message *m, void *userdata, sd_bus_error if (r < 0) return r; @@ -93,7 +93,7 @@ index 76fe04900d..e87c4c8919 100644 if (lrtc == c->local_rtc && !fix_system) return sd_bus_reply_method_return(m, NULL); -@@ -907,6 +914,9 @@ static int method_set_ntp(sd_bus_message *m, void *userdata, sd_bus_error *error +@@ -930,6 +937,9 @@ static int method_set_ntp(sd_bus_message *m, void *userdata, sd_bus_error *error if (r < 0) return r; @@ -104,5 +104,5 @@ index 76fe04900d..e87c4c8919 100644 if (r < 0) return r; -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0008-Fix-hwdb-paths.patch b/pkgs/os-specific/linux/systemd/0008-Fix-hwdb-paths.patch index 2b1c02b233c..f272ef23dc0 100644 --- a/pkgs/os-specific/linux/systemd/0008-Fix-hwdb-paths.patch +++ b/pkgs/os-specific/linux/systemd/0008-Fix-hwdb-paths.patch @@ -1,32 +1,28 @@ -From 874698425f6d68fc0d662cb17c7c29e0af3e8c25 Mon Sep 17 00:00:00 2001 +From b783b2da164482f26ac5e6e347dc41930c072ea5 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov <ab@fmap.me> Date: Thu, 7 Jul 2016 02:47:13 +0300 Subject: [PATCH 08/19] Fix hwdb paths Patch by vcunat. --- - src/libsystemd/sd-hwdb/sd-hwdb.c | 7 +------ - 1 file changed, 1 insertion(+), 6 deletions(-) + src/libsystemd/sd-hwdb/hwdb-internal.h | 7 ++----- + 1 file changed, 2 insertions(+), 5 deletions(-) -diff --git a/src/libsystemd/sd-hwdb/sd-hwdb.c b/src/libsystemd/sd-hwdb/sd-hwdb.c -index cb3c77ce96..7b8c80071f 100644 ---- a/src/libsystemd/sd-hwdb/sd-hwdb.c -+++ b/src/libsystemd/sd-hwdb/sd-hwdb.c -@@ -297,13 +297,8 @@ static int trie_search_f(sd_hwdb *hwdb, const char *search) { - } +diff --git a/src/libsystemd/sd-hwdb/hwdb-internal.h b/src/libsystemd/sd-hwdb/hwdb-internal.h +index 5ddc2211e6..ee621eec46 100644 +--- a/src/libsystemd/sd-hwdb/hwdb-internal.h ++++ b/src/libsystemd/sd-hwdb/hwdb-internal.h +@@ -82,8 +82,5 @@ struct trie_value_entry2_f { + } _packed_; - static const char hwdb_bin_paths[] = -- "/etc/systemd/hwdb/hwdb.bin\0" - "/etc/udev/hwdb.bin\0" -- "/usr/lib/systemd/hwdb/hwdb.bin\0" --#if HAVE_SPLIT_USR -- "/lib/systemd/hwdb/hwdb.bin\0" --#endif -- UDEVLIBEXECDIR "/hwdb.bin\0"; -+ ; - - _public_ int sd_hwdb_new(sd_hwdb **ret) { - _cleanup_(sd_hwdb_unrefp) sd_hwdb *hwdb = NULL; + #define hwdb_bin_paths \ +- "/etc/systemd/hwdb/hwdb.bin\0" \ +- "/etc/udev/hwdb.bin\0" \ +- "/usr/lib/systemd/hwdb/hwdb.bin\0" \ +- _CONF_PATHS_SPLIT_USR_NULSTR("systemd/hwdb/hwdb.bin") \ +- UDEVLIBEXECDIR "/hwdb.bin\0" ++ "/etc/udev/hwdb.bin\0" ++ -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0009-Change-usr-share-zoneinfo-to-etc-zoneinfo.patch b/pkgs/os-specific/linux/systemd/0009-Change-usr-share-zoneinfo-to-etc-zoneinfo.patch index a1e8ec963c7..791e47065d6 100644 --- a/pkgs/os-specific/linux/systemd/0009-Change-usr-share-zoneinfo-to-etc-zoneinfo.patch +++ b/pkgs/os-specific/linux/systemd/0009-Change-usr-share-zoneinfo-to-etc-zoneinfo.patch @@ -1,4 +1,4 @@ -From 367d0dad3d1853048569e315931cb8a27e16a098 Mon Sep 17 00:00:00 2001 +From e24c05ef8cfe48c4f0ebdb92e8147ae2151e4c87 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov <ab@fmap.me> Date: Tue, 11 Oct 2016 13:12:08 +0300 Subject: [PATCH 09/19] Change /usr/share/zoneinfo to /etc/zoneinfo @@ -6,11 +6,11 @@ Subject: [PATCH 09/19] Change /usr/share/zoneinfo to /etc/zoneinfo NixOS uses this path. --- man/localtime.xml | 4 ++-- - src/basic/time-util.c | 6 +++--- + src/basic/time-util.c | 8 ++++---- src/firstboot/firstboot.c | 2 +- src/nspawn/nspawn.c | 4 ++-- src/timedate/timedated.c | 8 ++++---- - 5 files changed, 12 insertions(+), 12 deletions(-) + 5 files changed, 13 insertions(+), 13 deletions(-) diff --git a/man/localtime.xml b/man/localtime.xml index e486474c44..5f373d0723 100644 @@ -35,28 +35,37 @@ index e486474c44..5f373d0723 100644 <literal>Etc/UTC</literal>. The resulting link should lead to the corresponding binary diff --git a/src/basic/time-util.c b/src/basic/time-util.c -index 5318d6378d..04069dc27b 100644 +index 5d162e8ffe..1bec83e555 100644 --- a/src/basic/time-util.c +++ b/src/basic/time-util.c -@@ -1277,7 +1277,7 @@ int get_timezones(char ***ret) { - n_allocated = 2; - n_zones = 1; +@@ -1269,7 +1269,7 @@ static int get_timezones_from_zone1970_tab(char ***ret) { + + assert(ret); - f = fopen("/usr/share/zoneinfo/zone1970.tab", "re"); + f = fopen("/etc/zoneinfo/zone1970.tab", "re"); - if (f) { - for (;;) { - _cleanup_free_ char *line = NULL; -@@ -1372,7 +1372,7 @@ bool timezone_is_valid(const char *name, int log_level) { + if (!f) + return -errno; + +@@ -1308,7 +1308,7 @@ static int get_timezones_from_tzdata_zi(char ***ret) { + _cleanup_strv_free_ char **zones = NULL; + int r; + +- f = fopen("/usr/share/zoneinfo/tzdata.zi", "re"); ++ f = fopen("/etc/zoneinfo/tzdata.zi", "re"); + if (!f) + return -errno; + +@@ -1421,7 +1421,7 @@ int verify_timezone(const char *name, int log_level) { if (p - name >= PATH_MAX) - return false; + return -ENAMETOOLONG; - t = strjoina("/usr/share/zoneinfo/", name); + t = strjoina("/etc/zoneinfo/", name); fd = open(t, O_RDONLY|O_CLOEXEC); - if (fd < 0) { -@@ -1470,7 +1470,7 @@ int get_timezone(char **ret) { + if (fd < 0) +@@ -1512,7 +1512,7 @@ int get_timezone(char **ret) { if (r < 0) return r; /* returns EINVAL if not a symlink */ @@ -66,10 +75,10 @@ index 5318d6378d..04069dc27b 100644 return -EINVAL; diff --git a/src/firstboot/firstboot.c b/src/firstboot/firstboot.c -index 742b43f9fc..f2cb121816 100644 +index 2cb4f80d5d..ebeaeac52f 100644 --- a/src/firstboot/firstboot.c +++ b/src/firstboot/firstboot.c -@@ -459,7 +459,7 @@ static int process_timezone(void) { +@@ -491,7 +491,7 @@ static int process_timezone(void) { if (isempty(arg_timezone)) return 0; @@ -79,10 +88,10 @@ index 742b43f9fc..f2cb121816 100644 (void) mkdir_parents(etc_localtime, 0755); if (symlink(e, etc_localtime) < 0) diff --git a/src/nspawn/nspawn.c b/src/nspawn/nspawn.c -index 14f8a82eb8..8632dadec6 100644 +index 0e5ece5f91..cc46435472 100644 --- a/src/nspawn/nspawn.c +++ b/src/nspawn/nspawn.c -@@ -1810,8 +1810,8 @@ static int userns_mkdir(const char *root, const char *path, mode_t mode, uid_t u +@@ -1887,8 +1887,8 @@ int userns_mkdir(const char *root, const char *path, mode_t mode, uid_t uid, gid static const char *timezone_from_path(const char *path) { return PATH_STARTSWITH_SET( path, @@ -94,10 +103,10 @@ index 14f8a82eb8..8632dadec6 100644 static bool etc_writable(void) { diff --git a/src/timedate/timedated.c b/src/timedate/timedated.c -index e87c4c8919..964a40ba81 100644 +index 0a8fe25d0f..2f02b9a520 100644 --- a/src/timedate/timedated.c +++ b/src/timedate/timedated.c -@@ -269,7 +269,7 @@ static int context_read_data(Context *c) { +@@ -279,7 +279,7 @@ static int context_read_data(Context *c) { r = get_timezone(&t); if (r == -EINVAL) @@ -106,7 +115,7 @@ index e87c4c8919..964a40ba81 100644 else if (r < 0) log_warning_errno(r, "Failed to get target of /etc/localtime: %m"); -@@ -293,7 +293,7 @@ static int context_write_data_timezone(Context *c) { +@@ -303,7 +303,7 @@ static int context_write_data_timezone(Context *c) { if (isempty(c->zone) || streq(c->zone, "UTC")) { @@ -115,7 +124,7 @@ index e87c4c8919..964a40ba81 100644 if (unlink("/etc/localtime") < 0 && errno != ENOENT) return -errno; -@@ -301,9 +301,9 @@ static int context_write_data_timezone(Context *c) { +@@ -311,9 +311,9 @@ static int context_write_data_timezone(Context *c) { return 0; } @@ -128,5 +137,5 @@ index e87c4c8919..964a40ba81 100644 return -ENOMEM; -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0010-localectl-use-etc-X11-xkb-for-list-x11.patch b/pkgs/os-specific/linux/systemd/0010-localectl-use-etc-X11-xkb-for-list-x11.patch index 334156495fc..d9b04811386 100644 --- a/pkgs/os-specific/linux/systemd/0010-localectl-use-etc-X11-xkb-for-list-x11.patch +++ b/pkgs/os-specific/linux/systemd/0010-localectl-use-etc-X11-xkb-for-list-x11.patch @@ -1,4 +1,4 @@ -From bf285fe7e12bd22f95c14bcefbb5008888c32bfa Mon Sep 17 00:00:00 2001 +From 09f6ca91b4131637038686dafd57b5da642c100e Mon Sep 17 00:00:00 2001 From: Imuli <i@imu.li> Date: Wed, 19 Oct 2016 08:46:47 -0400 Subject: [PATCH 10/19] localectl: use /etc/X11/xkb for list-x11-* @@ -10,10 +10,10 @@ NixOS has an option to link the xkb data files to /etc/X11, but not to 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/locale/localectl.c b/src/locale/localectl.c -index 7d2e887660..91c5139eed 100644 +index 548ac8eb2c..5e372f1566 100644 --- a/src/locale/localectl.c +++ b/src/locale/localectl.c -@@ -277,7 +277,7 @@ static int list_x11_keymaps(int argc, char **argv, void *userdata) { +@@ -280,7 +280,7 @@ static int list_x11_keymaps(int argc, char **argv, void *userdata) { } state = NONE, look_for; int r; @@ -23,5 +23,5 @@ index 7d2e887660..91c5139eed 100644 return log_error_errno(errno, "Failed to open keyboard mapping list. %m"); -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0011-build-don-t-create-statedir-and-don-t-touch-prefixdi.patch b/pkgs/os-specific/linux/systemd/0011-build-don-t-create-statedir-and-don-t-touch-prefixdi.patch index 902018ee4b9..f88b802b298 100644 --- a/pkgs/os-specific/linux/systemd/0011-build-don-t-create-statedir-and-don-t-touch-prefixdi.patch +++ b/pkgs/os-specific/linux/systemd/0011-build-don-t-create-statedir-and-don-t-touch-prefixdi.patch @@ -1,4 +1,4 @@ -From 293b19c5fdbda1b4ee579a7e8ba12f024a6f34c9 Mon Sep 17 00:00:00 2001 +From d5716cd93fdaad16b590a581f39d95954f40748e Mon Sep 17 00:00:00 2001 From: Franz Pletz <fpletz@fnordicwalking.de> Date: Sun, 11 Feb 2018 04:37:44 +0100 Subject: [PATCH 11/19] build: don't create statedir and don't touch prefixdir @@ -8,11 +8,11 @@ Subject: [PATCH 11/19] build: don't create statedir and don't touch prefixdir 1 file changed, 3 deletions(-) diff --git a/meson.build b/meson.build -index 580964c3fa..f99d4f3ab5 100644 +index 738879eb21..453ee4b1c0 100644 --- a/meson.build +++ b/meson.build -@@ -3518,9 +3518,6 @@ install_data('LICENSE.GPL2', - 'src/libsystemd/sd-bus/GVARIANT-SERIALIZATION', +@@ -3538,9 +3538,6 @@ install_data('LICENSE.GPL2', + 'docs/GVARIANT-SERIALIZATION.md', install_dir : docdir) -meson.add_install_script('sh', '-c', mkdir_p.format(systemdstatedir)) @@ -20,7 +20,7 @@ index 580964c3fa..f99d4f3ab5 100644 - ############################################################ - check_help = find_program('tools/check-help.sh') + # Ensure that changes to the docs/ directory do not break the -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0012-inherit-systemd-environment-when-calling-generators.patch b/pkgs/os-specific/linux/systemd/0012-inherit-systemd-environment-when-calling-generators.patch index 05fce10e856..f5a6fde26b1 100644 --- a/pkgs/os-specific/linux/systemd/0012-inherit-systemd-environment-when-calling-generators.patch +++ b/pkgs/os-specific/linux/systemd/0012-inherit-systemd-environment-when-calling-generators.patch @@ -1,4 +1,4 @@ -From 63777e7f690b67952bf4571f8e09e5d8e769d3c0 Mon Sep 17 00:00:00 2001 +From 40a5df71e7af5feefacae9fc95bf94e72c6c12f4 Mon Sep 17 00:00:00 2001 From: Andreas Rammhold <andreas@rammhold.de> Date: Fri, 2 Nov 2018 21:15:42 +0100 Subject: [PATCH 12/19] inherit systemd environment when calling generators. @@ -12,19 +12,20 @@ tries to gather environments with that they call "environment-generators" and then seems to pass that on to all the other executables that are being called from managers. --- - src/core/manager.c | 11 ++++++++--- - 1 file changed, 8 insertions(+), 3 deletions(-) + src/core/manager.c | 13 +++++++++---- + 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/src/core/manager.c b/src/core/manager.c -index 6858950107..07a599ede7 100644 +index e23d47b4a4..1047aadebc 100644 --- a/src/core/manager.c +++ b/src/core/manager.c -@@ -4142,9 +4142,14 @@ static int manager_run_generators(Manager *m) { +@@ -4145,10 +4145,15 @@ static int manager_run_generators(Manager *m) { argv[4] = NULL; RUN_WITH_UMASK(0022) - (void) execute_directories((const char* const*) paths, DEFAULT_TIMEOUT_USEC, NULL, NULL, -- (char**) argv, m->transient_environment, EXEC_DIR_PARALLEL | EXEC_DIR_IGNORE_ERRORS); +- (char**) argv, m->transient_environment, +- EXEC_DIR_PARALLEL | EXEC_DIR_IGNORE_ERRORS | EXEC_DIR_SET_SYSTEMD_EXEC_PID); - + (void) execute_directories((const char* const*) paths, DEFAULT_TIMEOUT_USEC, + // On NixOS we must propagate PATH to generators so they are @@ -33,10 +34,11 @@ index 6858950107..07a599ede7 100644 + // function (envp) is set to NULL. This propagates systemd's + // environment (e.g. PATH) that was setup + // before calling systemd from stage-2-init.sh. -+ NULL, NULL, (char**) argv, /* NixOS: use inherited env */ NULL, EXEC_DIR_PARALLEL | EXEC_DIR_IGNORE_ERRORS); ++ NULL, NULL, (char**) argv, /* NixOS: use inherited env */ NULL, ++ EXEC_DIR_PARALLEL | EXEC_DIR_IGNORE_ERRORS | EXEC_DIR_SET_SYSTEMD_EXEC_PID); r = 0; finish: -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0013-add-rootprefix-to-lookup-dir-paths.patch b/pkgs/os-specific/linux/systemd/0013-add-rootprefix-to-lookup-dir-paths.patch index b9bab2d387e..da6aa2627ff 100644 --- a/pkgs/os-specific/linux/systemd/0013-add-rootprefix-to-lookup-dir-paths.patch +++ b/pkgs/os-specific/linux/systemd/0013-add-rootprefix-to-lookup-dir-paths.patch @@ -1,4 +1,4 @@ -From 561dc3b864d96753b5dc448e6e1a80460d5f0bc4 Mon Sep 17 00:00:00 2001 +From fe3aff271cf127c1484533237fe0a024e07ae7bc Mon Sep 17 00:00:00 2001 From: Andreas Rammhold <andreas@rammhold.de> Date: Thu, 9 May 2019 11:15:22 +0200 Subject: [PATCH 13/19] add rootprefix to lookup dir paths @@ -34,5 +34,5 @@ index 2e60abb4f1..732ec51d36 100644 #define CONF_PATHS(n) \ CONF_PATHS_USR(n) \ -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0014-systemd-shutdown-execute-scripts-in-etc-systemd-syst.patch b/pkgs/os-specific/linux/systemd/0014-systemd-shutdown-execute-scripts-in-etc-systemd-syst.patch index c737b61e749..1ed19358a15 100644 --- a/pkgs/os-specific/linux/systemd/0014-systemd-shutdown-execute-scripts-in-etc-systemd-syst.patch +++ b/pkgs/os-specific/linux/systemd/0014-systemd-shutdown-execute-scripts-in-etc-systemd-syst.patch @@ -1,4 +1,4 @@ -From 8f619304804b02f4e9d7a340ca90359f96adc6e8 Mon Sep 17 00:00:00 2001 +From 31732478745f7a200004fb8ec013f54dbc536f2e Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov <ab@fmap.me> Date: Thu, 25 Jul 2019 20:45:55 +0300 Subject: [PATCH 14/19] systemd-shutdown: execute scripts in @@ -10,7 +10,7 @@ This is needed for NixOS to use such scripts as systemd directory is immutable. 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shutdown/shutdown.c b/src/shutdown/shutdown.c -index 0d07865542..26d974ef73 100644 +index a98cfc4d8a..b0b34edda7 100644 --- a/src/shutdown/shutdown.c +++ b/src/shutdown/shutdown.c @@ -312,7 +312,7 @@ int main(int argc, char *argv[]) { @@ -23,5 +23,5 @@ index 0d07865542..26d974ef73 100644 /* The log target defaults to console, but the original systemd process will pass its log target in through a * command line argument, which will override this default. Also, ensure we'll never log to the journal or -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0015-systemd-sleep-execute-scripts-in-etc-systemd-system-.patch b/pkgs/os-specific/linux/systemd/0015-systemd-sleep-execute-scripts-in-etc-systemd-system-.patch index 3059216f7c5..2777de09fad 100644 --- a/pkgs/os-specific/linux/systemd/0015-systemd-sleep-execute-scripts-in-etc-systemd-system-.patch +++ b/pkgs/os-specific/linux/systemd/0015-systemd-sleep-execute-scripts-in-etc-systemd-system-.patch @@ -1,4 +1,4 @@ -From 577b11afe38fc185d785ca8f125f518a4eb21a00 Mon Sep 17 00:00:00 2001 +From 3f2277b86f39cb55936ae11c2365feb283b547cb Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov <ab@fmap.me> Date: Thu, 25 Jul 2019 20:46:58 +0300 Subject: [PATCH 15/19] systemd-sleep: execute scripts in @@ -10,10 +10,10 @@ This is needed for NixOS to use such scripts as systemd directory is immutable. 1 file changed, 1 insertion(+) diff --git a/src/sleep/sleep.c b/src/sleep/sleep.c -index 39ab554290..880ac7ccb0 100644 +index a3aeb24633..0ed6a34d79 100644 --- a/src/sleep/sleep.c +++ b/src/sleep/sleep.c -@@ -178,6 +178,7 @@ static int execute(char **modes, char **states) { +@@ -182,6 +182,7 @@ static int execute( }; static const char* const dirs[] = { SYSTEM_SLEEP_PATH, @@ -22,5 +22,5 @@ index 39ab554290..880ac7ccb0 100644 }; -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0016-kmod-static-nodes.service-Update-ConditionFileNotEmp.patch b/pkgs/os-specific/linux/systemd/0016-kmod-static-nodes.service-Update-ConditionFileNotEmp.patch index ad19d910e1e..6ef53e95d02 100644 --- a/pkgs/os-specific/linux/systemd/0016-kmod-static-nodes.service-Update-ConditionFileNotEmp.patch +++ b/pkgs/os-specific/linux/systemd/0016-kmod-static-nodes.service-Update-ConditionFileNotEmp.patch @@ -1,4 +1,4 @@ -From ba19f629c1806ca2d2ab58154e45bce4ae4a3f0c Mon Sep 17 00:00:00 2001 +From 330490aa8a44206bc03205654680913ab01408a1 Mon Sep 17 00:00:00 2001 From: Florian Klink <flokli@flokli.de> Date: Sat, 7 Mar 2020 22:40:27 +0100 Subject: [PATCH 16/19] kmod-static-nodes.service: Update ConditionFileNotEmpty @@ -10,10 +10,10 @@ On NixOS, kernel modules of the currently booted systems are located at 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/units/kmod-static-nodes.service.in b/units/kmod-static-nodes.service.in -index f4170d6a99..9a6a591bea 100644 +index 777e82d16b..b6abc2bba0 100644 --- a/units/kmod-static-nodes.service.in +++ b/units/kmod-static-nodes.service.in -@@ -12,7 +12,7 @@ Description=Create list of static device nodes for the current kernel +@@ -12,7 +12,7 @@ Description=Create List of Static Device Nodes DefaultDependencies=no Before=sysinit.target systemd-tmpfiles-setup-dev.service ConditionCapability=CAP_SYS_MODULE @@ -23,5 +23,5 @@ index f4170d6a99..9a6a591bea 100644 [Service] Type=oneshot -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0017-path-util.h-add-placeholder-for-DEFAULT_PATH_NORMAL.patch b/pkgs/os-specific/linux/systemd/0017-path-util.h-add-placeholder-for-DEFAULT_PATH_NORMAL.patch index 585a0aa112e..775c8e09847 100644 --- a/pkgs/os-specific/linux/systemd/0017-path-util.h-add-placeholder-for-DEFAULT_PATH_NORMAL.patch +++ b/pkgs/os-specific/linux/systemd/0017-path-util.h-add-placeholder-for-DEFAULT_PATH_NORMAL.patch @@ -1,4 +1,4 @@ -From c639f311bd27c2bff62a22c34bc92613aaf77587 Mon Sep 17 00:00:00 2001 +From 216018be7b422586b937dae8fd83f51989479a41 Mon Sep 17 00:00:00 2001 From: Florian Klink <flokli@flokli.de> Date: Sun, 8 Mar 2020 01:05:54 +0100 Subject: [PATCH 17/19] path-util.h: add placeholder for DEFAULT_PATH_NORMAL @@ -10,7 +10,7 @@ systemd itself uses extensively. 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/basic/path-util.h b/src/basic/path-util.h -index d613709f0b..5cced4c115 100644 +index 26e7362d1f..a8f8a863ec 100644 --- a/src/basic/path-util.h +++ b/src/basic/path-util.h @@ -24,11 +24,11 @@ @@ -29,5 +29,5 @@ index d613709f0b..5cced4c115 100644 #if HAVE_SPLIT_USR # define DEFAULT_PATH DEFAULT_PATH_SPLIT_USR -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0018-logind-seat-debus-show-CanMultiSession-again.patch b/pkgs/os-specific/linux/systemd/0018-logind-seat-debus-show-CanMultiSession-again.patch index f634e74e663..21d466b02bb 100644 --- a/pkgs/os-specific/linux/systemd/0018-logind-seat-debus-show-CanMultiSession-again.patch +++ b/pkgs/os-specific/linux/systemd/0018-logind-seat-debus-show-CanMultiSession-again.patch @@ -1,4 +1,4 @@ -From ebb37f81c28aaa80acd9187a7d77dcb3cb3828db Mon Sep 17 00:00:00 2001 +From beb594ff3bceb95598ffa8ec47c31bacb2449473 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel <ttuegel@mailbox.org> Date: Mon, 26 Oct 2020 21:21:38 +0100 Subject: [PATCH 18/19] logind-seat-debus: show CanMultiSession again @@ -9,10 +9,10 @@ Fixes the "switch user" function in Plasma < 5.20. 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/login/logind-seat-dbus.c b/src/login/logind-seat-dbus.c -index a60ed2d3c2..69b6271075 100644 +index cceb3b1d2d..94b4723bb9 100644 --- a/src/login/logind-seat-dbus.c +++ b/src/login/logind-seat-dbus.c -@@ -450,7 +450,7 @@ static const sd_bus_vtable seat_vtable[] = { +@@ -419,7 +419,7 @@ static const sd_bus_vtable seat_vtable[] = { SD_BUS_PROPERTY("Id", "s", NULL, offsetof(Seat, id), SD_BUS_VTABLE_PROPERTY_CONST), SD_BUS_PROPERTY("ActiveSession", "(so)", property_get_active_session, 0, SD_BUS_VTABLE_PROPERTY_EMITS_CHANGE), @@ -22,5 +22,5 @@ index a60ed2d3c2..69b6271075 100644 SD_BUS_PROPERTY("CanGraphical", "b", property_get_can_graphical, 0, SD_BUS_VTABLE_PROPERTY_EMITS_CHANGE), SD_BUS_PROPERTY("Sessions", "a(so)", property_get_sessions, 0, 0), -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0019-pkg-config-derive-prefix-from-prefix.patch b/pkgs/os-specific/linux/systemd/0019-pkg-config-derive-prefix-from-prefix.patch index 2d93cdef9a3..da071603557 100644 --- a/pkgs/os-specific/linux/systemd/0019-pkg-config-derive-prefix-from-prefix.patch +++ b/pkgs/os-specific/linux/systemd/0019-pkg-config-derive-prefix-from-prefix.patch @@ -1,4 +1,4 @@ -From 5439a516995f9fd57fc91c2cdd016bb18f31aadf Mon Sep 17 00:00:00 2001 +From 2e7477dc29095141a0556ded11f0ee370d82bfbb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= <joerg@thalheim.io> Date: Sun, 6 Dec 2020 08:34:19 +0100 Subject: [PATCH 19/19] pkg-config: derive prefix from --prefix @@ -16,7 +16,7 @@ Co-Authored-By: Florian Klink <flokli@flokli.de> 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/systemd.pc.in b/src/core/systemd.pc.in -index a701cd05f8..85d6911bdf 100644 +index ded74ce50a..0262f53154 100644 --- a/src/core/systemd.pc.in +++ b/src/core/systemd.pc.in @@ -11,7 +11,7 @@ @@ -24,10 +24,10 @@ index a701cd05f8..85d6911bdf 100644 # shall have underscores. -prefix=/usr -+prefix=@prefix@ - root_prefix=@rootprefix_noslash@ ++prefix={{PREFIX}} + root_prefix={{ROOTPREFIX_NOSLASH}} rootprefix=${root_prefix} - sysconf_dir=@sysconfdir@ + sysconf_dir={{SYSCONF_DIR}} -- -2.30.1 +2.32.0 diff --git a/pkgs/os-specific/linux/systemd/0020-core-respect-install_sysconfdir_samples-in-meson-fil.patch b/pkgs/os-specific/linux/systemd/0020-core-respect-install_sysconfdir_samples-in-meson-fil.patch new file mode 100644 index 00000000000..4567c2fa316 --- /dev/null +++ b/pkgs/os-specific/linux/systemd/0020-core-respect-install_sysconfdir_samples-in-meson-fil.patch @@ -0,0 +1,31 @@ +From 1a2d24d210c9329e8b900fdb01576c57374581d8 Mon Sep 17 00:00:00 2001 +From: Andreas Rammhold <andreas@rammhold.de> +Date: Mon, 26 Jul 2021 16:57:43 +0200 +Subject: [PATCH 20/20] core: respect install_sysconfdir_samples in meson file + +The refactoring done in e11a25cadbe caused the configuration files to be +installed into the pkgsysconfdir regardless of the state of the +install_sysconfdir_samples boolean that indicated whether or not the +sample files should be installed. +--- + src/core/meson.build | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/src/core/meson.build b/src/core/meson.build +index f0d2c6f642..4ff7e00e36 100644 +--- a/src/core/meson.build ++++ b/src/core/meson.build +@@ -187,6 +187,10 @@ foreach item : in_files + file = item[0] + dir = item[1] + ++ if not install_sysconfdir_samples and dir == pkgsysconfdir ++ continue ++ endif ++ + custom_target( + file, + input : file + '.in', +-- +2.32.0 + diff --git a/pkgs/os-specific/linux/systemd/0021-login-respect-install_sysconfdir_samples-in-meson-fi.patch b/pkgs/os-specific/linux/systemd/0021-login-respect-install_sysconfdir_samples-in-meson-fi.patch new file mode 100644 index 00000000000..b048249e051 --- /dev/null +++ b/pkgs/os-specific/linux/systemd/0021-login-respect-install_sysconfdir_samples-in-meson-fi.patch @@ -0,0 +1,29 @@ +From 189ba3af8b21cfc53527453907e800a2917b1bfd Mon Sep 17 00:00:00 2001 +From: Andreas Rammhold <andreas@rammhold.de> +Date: Mon, 26 Jul 2021 17:20:34 +0200 +Subject: [PATCH] login: respect install_sysconfdir_samples in meson file + +The refactoring done in c900d89faa0 caused the configuration files to be +installed into the pkgsysconfdir regardless of the state of the +install_sysconfdir_samples boolean that indicates whether or not the +sample files should be installed. +--- + src/login/meson.build | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/login/meson.build b/src/login/meson.build +index 8c20e6be65..b637adc9a2 100644 +--- a/src/login/meson.build ++++ b/src/login/meson.build +@@ -67,7 +67,7 @@ pam_systemd_c = files('pam_systemd.c') + + enable_logind = conf.get('ENABLE_LOGIND') == 1 + in_files = [ +- ['logind.conf', pkgsysconfdir, enable_logind], ++ ['logind.conf', pkgsysconfdir, enable_logind and install_sysconfdir_samples], + ['70-uaccess.rules', udevrulesdir, enable_logind and conf.get('HAVE_ACL') == 1], + ['71-seat.rules', udevrulesdir, enable_logind], + ['73-seat-late.rules', udevrulesdir, enable_logind], +-- +2.32.0 + diff --git a/pkgs/os-specific/linux/systemd/0022-core-Handle-lookup-paths-being-symlinks.patch b/pkgs/os-specific/linux/systemd/0022-core-Handle-lookup-paths-being-symlinks.patch new file mode 100644 index 00000000000..c7d022b1ffd --- /dev/null +++ b/pkgs/os-specific/linux/systemd/0022-core-Handle-lookup-paths-being-symlinks.patch @@ -0,0 +1,80 @@ +From 5f17b65d30480e489e135b403a072b38535b2911 Mon Sep 17 00:00:00 2001 +From: Andreas Rammhold <andreas@rammhold.de> +Date: Wed, 18 Aug 2021 19:10:08 +0200 +Subject: [PATCH] core: handle lookup paths being symlinks + +With a recent change paths leaving the statically known lookup paths +would be treated differently then those that remained within those. That +was done (AFAIK) to consistently handle alias names. Unfortunately that +means that on some distributions, especially those where /etc/ consists +mostly of symlinks, would trigger that new detection for every single +unit in /etc/systemd/system. The reason for that is that the units +directory itself is already a symlink. +--- + src/basic/unit-file.c | 33 +++++++++++++++++++++++++++++++-- + 1 file changed, 31 insertions(+), 2 deletions(-) + +diff --git a/src/basic/unit-file.c b/src/basic/unit-file.c +index 884a0674a9..3ae2a115d0 100644 +--- a/src/basic/unit-file.c ++++ b/src/basic/unit-file.c +@@ -254,6 +254,7 @@ int unit_file_build_name_map( + + _cleanup_hashmap_free_ Hashmap *ids = NULL, *names = NULL; + _cleanup_set_free_free_ Set *paths = NULL; ++ _cleanup_strv_free_ char **expanded_search_paths = NULL; + uint64_t timestamp_hash; + char **dir; + int r; +@@ -273,6 +274,34 @@ int unit_file_build_name_map( + return log_oom(); + } + ++ /* Go over all our search paths, chase their symlinks and store the ++ * result in the expanded_search_paths list. ++ * ++ * This is important for cases where any of the unit directories itself ++ * are symlinks into other directories and would therefore cause all of ++ * the unit files to be recognized as linked units. ++ * ++ * This is important for distributions such as NixOS where most paths ++ * in /etc/ are symlinks to some other location on the filesystem (e.g. ++ * into /nix/store/). ++ */ ++ STRV_FOREACH(dir, (char**) lp->search_path) { ++ _cleanup_free_ char *resolved_dir = NULL; ++ r = strv_extend(&expanded_search_paths, *dir); ++ if (r < 0) ++ return log_oom(); ++ ++ r = chase_symlinks(*dir, NULL, 0, &resolved_dir, NULL); ++ if (r < 0) { ++ if (r != -ENOENT) ++ log_warning_errno(r, "Failed to resolve symlink %s, ignoring: %m", *dir); ++ continue; ++ } ++ ++ if (strv_consume(&expanded_search_paths, TAKE_PTR(resolved_dir)) < 0) ++ return log_oom(); ++ } ++ + STRV_FOREACH(dir, (char**) lp->search_path) { + struct dirent *de; + _cleanup_closedir_ DIR *d = NULL; +@@ -351,11 +380,11 @@ int unit_file_build_name_map( + continue; + } + +- /* Check if the symlink goes outside of our search path. ++ /* Check if the symlink goes outside of our (expanded) search path. + * If yes, it's a linked unit file or mask, and we don't care about the target name. + * Let's just store the link source directly. + * If not, let's verify that it's a good symlink. */ +- char *tail = path_startswith_strv(simplified, lp->search_path); ++ char *tail = path_startswith_strv(simplified, expanded_search_paths); + if (!tail) { + log_debug("%s: linked unit file: %s → %s", + __func__, filename, simplified); +-- +2.32.0 + diff --git a/pkgs/os-specific/linux/systemd/0023-path-util-make-find_executable-work-without-proc-mounted.patch b/pkgs/os-specific/linux/systemd/0023-path-util-make-find_executable-work-without-proc-mounted.patch new file mode 100644 index 00000000000..026d0278797 --- /dev/null +++ b/pkgs/os-specific/linux/systemd/0023-path-util-make-find_executable-work-without-proc-mounted.patch @@ -0,0 +1,29 @@ +From 93413acd3ef3a637a0f31a1d133b103e1dc81fd6 Mon Sep 17 00:00:00 2001 +From: Yu Watanabe <watanabe.yu+github@gmail.com> +Date: Mon, 23 Aug 2021 06:16:48 +0900 +Subject: [PATCH] path-util: make find_executable() work without /proc mounted + +Follow-up for 888f65ace6296ed61285d31db846babf1c11885e. + +Hopefully fixes #20514. +--- + src/basic/path-util.c | 6 +++++- + 1 file changed, 5 insertions(+), 1 deletion(-) + +diff --git a/src/basic/path-util.c b/src/basic/path-util.c +index d11f254a9f6a..a21981616b59 100644 +--- a/src/basic/path-util.c ++++ b/src/basic/path-util.c +@@ -630,7 +630,11 @@ static int check_x_access(const char *path, int *ret_fd) { + return r; + + r = access_fd(fd, X_OK); +- if (r < 0) ++ if (r == -ENOSYS) { ++ /* /proc is not mounted. Fallback to access(). */ ++ if (access(path, X_OK) < 0) ++ return -errno; ++ } else if (r < 0) + return r; + + if (ret_fd) diff --git a/pkgs/os-specific/linux/systemd/default.nix b/pkgs/os-specific/linux/systemd/default.nix index 01d2db5b2f1..9f92c34cee6 100644 --- a/pkgs/os-specific/linux/systemd/default.nix +++ b/pkgs/os-specific/linux/systemd/default.nix @@ -12,7 +12,6 @@ , coreutils , gperf , getent -, patchelf , glibcLocales , glib , substituteAll @@ -40,6 +39,7 @@ , gnupg , zlib , xz +, tpm2-tss , libuuid , libapparmor , intltool @@ -58,6 +58,12 @@ , bashInteractive , libmicrohttpd + # the (optional) BPF feature requires bpftool, libbpf, clang and llmv-strip to be avilable during build time. + # Only libbpf should be a runtime dependency. +, bpftools +, libbpf +, llvmPackages + , withAnalyze ? true , withApparmor ? true , withCompression ? true # adds bzip2, lz4 and xz @@ -65,10 +71,12 @@ , withCryptsetup ? true , withDocumentation ? true , withEfi ? stdenv.hostPlatform.isEfi +, withFido2 ? true , withHomed ? false , withHostnamed ? true , withHwdb ? true , withImportd ? true +, withLibBPF ? false # currently fails while generating BPF objects , withLocaled ? true , withLogind ? true , withMachined ? true @@ -83,6 +91,7 @@ , withShellCompletions ? true , withTimedated ? true , withTimesyncd ? true +, withTpm2Tss ? true , withUserDb ? true , libfido2 , p11-kit @@ -90,7 +99,6 @@ # name argument , pname ? "systemd" - , libxslt , docbook_xsl , docbook_xml_dtd_42 @@ -108,15 +116,13 @@ assert withCoredump -> withCompression; assert withHomed -> withCryptsetup; -assert withCryptsetup -> -(cryptsetup != null); +assert withCryptsetup -> (cryptsetup != null); let wantCurl = withRemote || withImportd; - - version = "247.6"; + version = "249.4"; in stdenv.mkDerivation { - inherit version pname; + inherit pname version; # We use systemd/systemd-stable for src, and ship NixOS-specific patches inside nixpkgs directly # This has proven to be less error-prone than the previous systemd fork. @@ -124,7 +130,7 @@ stdenv.mkDerivation { owner = "systemd"; repo = "systemd-stable"; rev = "v${version}"; - sha256 = "sha256-7XYEq3Qw25suwjbtPzx9lVPHUu9ZY/1bADXl2wQbkJc="; + sha256 = "0pqi9gbk9kgwvd0idf13ybxz7s4h5przn01bwj6fna44jr0wy41c"; }; # If these need to be regenerated, `git am path/to/00*.patch` them into a @@ -152,18 +158,26 @@ stdenv.mkDerivation { ./0018-logind-seat-debus-show-CanMultiSession-again.patch ./0019-pkg-config-derive-prefix-from-prefix.patch - # Fix -Werror=format. - (fetchpatch { - url = "https://github.com/systemd/systemd/commit/ab1aa6368a883bce88e3162fee2bea14aacedf23.patch"; - sha256 = "1b280l5jrjsg8qhsang199mpqjhkpix4c8bm3blknjnq9iv43add"; - }) - - # Fix CVE-2021-33910, disclosed 2021-07-20 - (fetchpatch { - name = "CVE-2021-33910.patch"; - url = "https://github.com/systemd/systemd/commit/441e0115646d54f080e5c3bb0ba477c892861ab9.patch"; - sha256 = "1g1lk95igaadg67kah9bpi4zsc01rg398sd1247ghjsvl5hxn4v4"; - }) + # In v249 a bunch of meson files had been touched as part of the migration to + # jinja2 for templating. Unfortunately some of those files lost the `install_sysconfdir_samples` check. + # The following two patches are part of a PR that was filed to fix those cases. + # https://github.com/systemd/systemd/pull/20303 + ./0020-core-respect-install_sysconfdir_samples-in-meson-fil.patch + ./0021-login-respect-install_sysconfdir_samples-in-meson-fi.patch + + # In v248 or v249 we started to get in trouble due to our /etc/systemd/sytem being + # a symlink and thus being treated differently by systemd. With the below + # patch we mitigate that effect by special casing all our root unit dirs + # if they are symlinks. This does exactly what we need (AFAICT). + ./0022-core-Handle-lookup-paths-being-symlinks.patch + + # The way files are being tested for being executable changed in v248/v249 + # which caused our confinement setup to fail as we do not mount /proc by + # default. + # The issue has been reported upstream and this patch carries the upstream + # fix for the same. Upstream now has a test for this scenario. + # https://github.com/systemd/systemd/issues/20514 + ./0023-path-util-make-find_executable-work-without-proc-mounted.patch ]; postPatch = '' @@ -177,14 +191,14 @@ stdenv.mkDerivation { "find_program('${stdenv.cc.bintools.targetPrefix}objcopy'" '' + ( let - # The folllowing dlopen patches ensure that all the features that are - # implemented via dlopen(3) are available (or explicitly deactivated) by - # pointing dlopen to the absolute store path instead of relying on the - # linkers runtime lookup code. + # The folllowing patches references to dynamic libraries to ensure that + # all the features that are implemented via dlopen(3) are available (or + # explicitly deactivated) by pointing dlopen to the absolute store path + # instead of relying on the linkers runtime lookup code. # - # All of the dlopen calls have to be handled. When new ones are introduced - # by upstream (or one of our patches) they must be explicitly declared, - # otherwise the build will fail. + # All of the shared library references have to be handled. When new ones + # are introduced by upstream (or one of our patches) they must be + # explicitly declared, otherwise the build will fail. # # As of systemd version 247 we've seen a few errors like `libpcre2.… not # found` when using e.g. --grep with journalctl. Those errors should @@ -203,32 +217,45 @@ stdenv.mkDerivation { # path location). # # To get a list of dynamically loaded libraries issue something like - # `grep -ri 'dlopen("lib' $src` and update the below list. - dlopenLibs = [ - # We did never provide support for libxkbcommon & qrencode - { name = "libxkbcommon.so.0"; pkg = null; } - { name = "libqrencode.so.4"; pkg = null; } - - # We did not provide libpwquality before so it is safe to disable it for - # now. - { name = "libpwquality.so.1"; pkg = null; } - - # Only include cryptsetup if it is enabled. We might not be able to - # provide it during "bootstrap" in e.g. the minimal systemd build as - # cryptsetup has udev (aka systemd) in it's dependencies. - { name = "libcryptsetup.so.12"; pkg = if withCryptsetup then cryptsetup else null; } - - # We are using libidn2 so we only provide that and ignore the others. - # Systemd does this decision during configure time and uses ifdef's to - # enable specific branches. We can safely ignore (nuke) the libidn "v1" - # libraries. - { name = "libidn2.so.0"; pkg = libidn2; } - { name = "libidn.so.12"; pkg = null; } - { name = "libidn.so.11"; pkg = null; } - - # journalctl --grep requires libpcre so lets provide it - { name = "libpcre2-8.so.0"; pkg = pcre2; } - ]; + # `grep -ri '"lib[a-zA-Z0-9-]*\.so[\.0-9a-zA-z]*"'' $src` and update the below list. + dlopenLibs = + let + opt = condition: pkg: if condition then pkg else null; + in + [ + # bpf compilation support + { name = "libbpf.so.0"; pkg = opt withLibBPF libbpf; } + + # We did never provide support for libxkbcommon & qrencode + { name = "libxkbcommon.so.0"; pkg = null; } + { name = "libqrencode.so.4"; pkg = null; } + + # We did not provide libpwquality before so it is safe to disable it for + # now. + { name = "libpwquality.so.1"; pkg = null; } + + # Only include cryptsetup if it is enabled. We might not be able to + # provide it during "bootstrap" in e.g. the minimal systemd build as + # cryptsetup has udev (aka systemd) in it's dependencies. + { name = "libcryptsetup.so.12"; pkg = opt withCryptsetup cryptsetup; } + + # We are using libidn2 so we only provide that and ignore the others. + # Systemd does this decision during configure time and uses ifdef's to + # enable specific branches. We can safely ignore (nuke) the libidn "v1" + # libraries. + { name = "libidn2.so.0"; pkg = libidn2; } + { name = "libidn.so.12"; pkg = null; } + { name = "libidn.so.11"; pkg = null; } + + # journalctl --grep requires libpcre so lets provide it + { name = "libpcre2-8.so.0"; pkg = pcre2; } + + # Support for TPM2 in systemd-cryptsetup, systemd-repart and systemd-cryptenroll + { name = "libtss2-esys.so.0"; pkg = opt withTpm2Tss tpm2-tss; } + { name = "libtss2-rc.so.0"; pkg = opt withTpm2Tss tpm2-tss; } + { name = "libtss2-mu.so.0"; pkg = opt withTpm2Tss tpm2-tss; } + { name = "libfido2.so.1"; pkg = opt withFido2 libfido2; } + ]; patchDlOpen = dl: let @@ -236,9 +263,9 @@ stdenv.mkDerivation { in if dl.pkg == null then '' # remove the dependency on the library by replacing it with an invalid path - for file in $(grep -lr 'dlopen("${dl.name}"' src); do + for file in $(grep -lr '"${dl.name}"' src); do echo "patching dlopen(\"${dl.name}\", …) in $file to an invalid store path ("/nix/store/eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee-not-implemented/${dl.name}")…" - substituteInPlace "$file" --replace 'dlopen("${dl.name}"' 'dlopen("/nix/store/eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee-not-implemented/${dl.name}"' + substituteInPlace "$file" --replace '"${dl.name}"' '"/nix/store/eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee-not-implemented/${dl.name}"' done '' else '' # ensure that the library we provide actually exists @@ -247,22 +274,29 @@ stdenv.mkDerivation { exit 1 fi # make the path to the dependency explicit - for file in $(grep -lr 'dlopen("${dl.name}"' src); do + for file in $(grep -lr '"${dl.name}"' src); do echo "patching dlopen(\"${dl.name}\", …) in $file to ${library}…" - substituteInPlace "$file" --replace 'dlopen("${dl.name}"' 'dlopen("${library}"' + substituteInPlace "$file" --replace '"${dl.name}"' '"${library}"' done + ''; in # patch all the dlopen calls to contain absolute paths to the libraries lib.concatMapStringsSep "\n" patchDlOpen dlopenLibs ) - # finally ensure that there are no left-over dlopen calls that we didn't handle + # finally ensure that there are no left-over dlopen calls (or rather strings pointing to shared libraries) that we didn't handle + '' - if grep -qr 'dlopen("[^/]' src; then - echo "Found unhandled dlopen calls: " - grep -r 'dlopen("[^/]' src + if grep -qr '"lib[a-zA-Z0-9-]*\.so[\.0-9a-zA-z]*"' src; then + echo "Found unhandled dynamic library calls: " + grep -r '"lib[a-zA-Z0-9-]*\.so[\.0-9a-zA-z]*"' src exit 1 fi + '' + # Finally patch shebangs that might need patching. + # Should no longer be necessary with v250. + # https://github.com/systemd/systemd/pull/19638 + + '' + patchShebangs . ''; outputs = [ "out" "man" "dev" ]; @@ -273,9 +307,7 @@ stdenv.mkDerivation { gperf ninja meson - coreutils # meson calls date, stat etc. glibcLocales - patchelf getent m4 @@ -286,8 +318,14 @@ stdenv.mkDerivation { docbook_xsl docbook_xml_dtd_42 docbook_xml_dtd_45 - (buildPackages.python3Packages.python.withPackages (ps: with ps; [ python3Packages.lxml ])) - ]; + (buildPackages.python3Packages.python.withPackages (ps: with ps; [ lxml jinja2 ])) + ] + ++ lib.optional withLibBPF [ + bpftools + llvmPackages.clang + llvmPackages.libllvm + ] + ; buildInputs = [ @@ -315,12 +353,15 @@ stdenv.mkDerivation { ++ lib.optional withResolved libgpgerror ++ lib.optional withSelinux libselinux ++ lib.optional withRemote libmicrohttpd - ++ lib.optionals withHomed [ p11-kit libfido2 ] + ++ lib.optionals withHomed [ p11-kit ] + ++ lib.optionals (withHomed || withCryptsetup) [ libfido2 ] + ++ lib.optionals withLibBPF [ libbpf ] ; #dontAddPrefix = true; mesonFlags = [ + "-Dversion-tag=${version}" "-Ddbuspolicydir=${placeholder "out"}/share/dbus-1/system.d" "-Ddbussessionservicedir=${placeholder "out"}/share/dbus-1/services" "-Ddbussystemservicedir=${placeholder "out"}/share/dbus-1/system-services" @@ -368,14 +409,14 @@ stdenv.mkDerivation { "-Db_pie=true" "-Dinstall-sysconfdir=false" /* - As of now, systemd doesn't allow runtime configuration of these values. So - the settings in /etc/login.defs have no effect on it. Many people think this - should be supported however, see - - https://github.com/systemd/systemd/issues/3855 - - https://github.com/systemd/systemd/issues/4850 - - https://github.com/systemd/systemd/issues/9769 - - https://github.com/systemd/systemd/issues/9843 - - https://github.com/systemd/systemd/issues/10184 + As of now, systemd doesn't allow runtime configuration of these values. So + the settings in /etc/login.defs have no effect on it. Many people think this + should be supported however, see + - https://github.com/systemd/systemd/issues/3855 + - https://github.com/systemd/systemd/issues/4850 + - https://github.com/systemd/systemd/issues/9769 + - https://github.com/systemd/systemd/issues/9843 + - https://github.com/systemd/systemd/issues/10184 */ "-Dsystem-uid-max=999" "-Dsystem-gid-max=999" @@ -411,6 +452,8 @@ stdenv.mkDerivation { "-Dnss-mymachines=false" "-Dnss-resolve=false" "-Dnss-systemd=false" + ] ++ lib.optionals withLibBPF [ + "-Dbpf-framework=true" ]; preConfigure = '' @@ -459,7 +502,8 @@ stdenv.mkDerivation { --replace '"tar"' '"${gnutar}/bin/tar"' done - substituteInPlace src/journal/catalog.c \ + + substituteInPlace src/libsystemd/sd-journal/catalog.c \ --replace /usr/lib/systemd/catalog/ $out/lib/systemd/catalog/ ''; diff --git a/pkgs/os-specific/linux/tbs/default.nix b/pkgs/os-specific/linux/tbs/default.nix index d2b0bc08071..f2a7b692baa 100644 --- a/pkgs/os-specific/linux/tbs/default.nix +++ b/pkgs/os-specific/linux/tbs/default.nix @@ -18,7 +18,8 @@ let }; in stdenv.mkDerivation { - name = "tbs-2018.04.18-${kernel.version}"; + pname = "tbs"; + version = "2018.04.18-${kernel.version}"; srcs = [ media build ]; sourceRoot = build.name; diff --git a/pkgs/os-specific/linux/tunctl/default.nix b/pkgs/os-specific/linux/tunctl/default.nix index 549a607b152..646e3702fed 100644 --- a/pkgs/os-specific/linux/tunctl/default.nix +++ b/pkgs/os-specific/linux/tunctl/default.nix @@ -1,9 +1,11 @@ {lib, stdenv, fetchurl}: -stdenv.mkDerivation { - name = "tunctl-1.5"; +stdenv.mkDerivation rec { + pname = "tunctl"; + version = "1.5"; + src = fetchurl { - url = "mirror://sourceforge/tunctl/tunctl-1.5.tar.gz"; + url = "mirror://sourceforge/tunctl/tunctl-${version}.tar.gz"; sha256 = "aa2a6c4cc6bfacb11e0d9f62334a6638a0d435475c61230116f00b6af8b14fff"; }; diff --git a/pkgs/os-specific/linux/upower/default.nix b/pkgs/os-specific/linux/upower/default.nix index 08bebefed13..d2f17c6666a 100644 --- a/pkgs/os-specific/linux/upower/default.nix +++ b/pkgs/os-specific/linux/upower/default.nix @@ -1,4 +1,5 @@ -{ lib, stdenv +{ lib +, stdenv , fetchurl , pkg-config , libxslt @@ -16,13 +17,13 @@ stdenv.mkDerivation { pname = "upower"; - version = "0.99.11"; + version = "0.99.13"; outputs = [ "out" "dev" ]; src = fetchurl { - url = "https://gitlab.freedesktop.org/upower/upower/uploads/93cfe7c8d66ed486001c4f3f55399b7a/upower-0.99.11.tar.xz"; - sha256 = "1vxxvmz2cxb1qy6ibszaz5bskqdy9nd9fxspj9fv3gfmrjzzzdb4"; + url = "https://gitlab.freedesktop.org/upower/upower/uploads/177df5b9f9b76f25a2ad9da41aa0c1fa/upower-0.99.13.tar.xz"; + sha256 = "sha256-XK1w+RVAzH3BIcsX4K1kXl5mPIaC9gp75C7jjNeyPXo="; }; nativeBuildInputs = [ diff --git a/pkgs/os-specific/linux/usermount/default.nix b/pkgs/os-specific/linux/usermount/default.nix index d0c690a9527..87b38b9af6e 100644 --- a/pkgs/os-specific/linux/usermount/default.nix +++ b/pkgs/os-specific/linux/usermount/default.nix @@ -1,7 +1,8 @@ { lib, stdenv, fetchgit, pkg-config, dbus, libnotify, udisks2, gdk-pixbuf }: stdenv.mkDerivation { - name = "usermount-0.1"; + pname = "usermount"; + version = "0.1"; src = fetchgit { url = "https://github.com/tom5760/usermount.git"; diff --git a/pkgs/os-specific/linux/v86d/default.nix b/pkgs/os-specific/linux/v86d/default.nix index 36270cdfcc0..254abb5838e 100644 --- a/pkgs/os-specific/linux/v86d/default.nix +++ b/pkgs/os-specific/linux/v86d/default.nix @@ -1,14 +1,19 @@ -{ lib, stdenv, fetchurl -, kernel, klibc +{ lib +, stdenv +, fetchFromGitHub +, kernel +, klibc }: stdenv.mkDerivation rec { name = "v86d-${version}-${kernel.version}"; version = "0.1.10"; - src = fetchurl { - url = "https://github.com/mjanusz/v86d/archive/v86d-${version}.tar.gz"; - sha256 = "1flnpp8rc945cxr6jr9dlm8mi8gr181zrp2say4269602s1a4ymg"; + src = fetchFromGitHub { + owner = "mjanusz"; + repo = "v86d"; + rev = "v86d-${version}"; + hash = "sha256-95LRzVbO/DyddmPwQNNQ290tasCGoQk7FDHlst6LkbA="; }; patchPhase = '' diff --git a/pkgs/os-specific/linux/xf86-video-nested/default.nix b/pkgs/os-specific/linux/xf86-video-nested/default.nix index 7c93fa91854..bba646e583b 100644 --- a/pkgs/os-specific/linux/xf86-video-nested/default.nix +++ b/pkgs/os-specific/linux/xf86-video-nested/default.nix @@ -3,7 +3,8 @@ }: stdenv.mkDerivation { - name = "xf86-video-nested-2017-06-12"; + pname = "xf86-video-nested"; + version = "unstable-2017-06-12"; src = fetchgit { url = "git://anongit.freedesktop.org/xorg/driver/xf86-video-nested"; diff --git a/pkgs/os-specific/linux/zfs/default.nix b/pkgs/os-specific/linux/zfs/default.nix index bf45a503761..c9f0438c86f 100644 --- a/pkgs/os-specific/linux/zfs/default.nix +++ b/pkgs/os-specific/linux/zfs/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, fetchFromGitHub +{ pkgs, lib, stdenv, fetchFromGitHub , autoreconfHook269, util-linux, nukeReferences, coreutils , perl, nixosTests , configFile ? "all" @@ -16,7 +16,7 @@ , enablePython ? true # for determining the latest compatible linuxPackages -, linuxPackages_5_13 +, linuxPackages_5_14 ? pkgs.linuxKernel.packages.linux_5_14 }: with lib; @@ -196,6 +196,7 @@ let license = licenses.cddl; platforms = platforms.linux; maintainers = with maintainers; [ hmenke jcumming jonringer wizeman fpletz globin mic92 ]; + mainProgram = "zfs"; # If your Linux kernel version is not yet supported by zfs, try zfsUnstable. # On NixOS set the option boot.zfs.enableUnstable. broken = buildKernel && (kernelCompatible != null) && !kernelCompatible; @@ -207,25 +208,28 @@ in { # to be adapted zfsStable = common { # check the release notes for compatible kernels - kernelCompatible = kernel.kernelAtLeast "3.10" && kernel.kernelOlder "5.14"; - latestCompatibleLinuxPackages = linuxPackages_5_13; + kernelCompatible = kernel.kernelAtLeast "3.10" && kernel.kernelOlder "5.15"; + latestCompatibleLinuxPackages = linuxPackages_5_14; # this package should point to the latest release. - version = "2.1.0"; + version = "2.1.1"; - sha256 = "sha256-YdY4SStXZGBBdAHdM3R/unco7ztxI3s0/buPSNSeh5o="; + sha256 = "sha256-UUuJa5w/GsEvsgH/BnXFsP/dsOt9wwmPqKzDxLPrhiY="; }; zfsUnstable = common { # check the release notes for compatible kernels kernelCompatible = kernel.kernelAtLeast "3.10" && kernel.kernelOlder "5.15"; - latestCompatibleLinuxPackages = linuxPackages_5_13; + latestCompatibleLinuxPackages = linuxPackages_5_14; # this package should point to a version / git revision compatible with the latest kernel release - version = "unstable-2021-08-30"; - rev = "3b89d9518df2c7fd747e349873a3d4d498beb20e"; + # IMPORTANT: Always use a tagged release candidate or commits from the + # zfs-<version>-staging branch, because this is tested by the OpenZFS + # maintainers. + version = "2.1.1"; + # rev = "0000000000000000000000000000000000000000"; - sha256 = "sha256-wVbjpVrPQmhJmMqdGUf0IwlCIoOsT7Zfj5lxSKcOsgg="; + sha256 = "sha256-UUuJa5w/GsEvsgH/BnXFsP/dsOt9wwmPqKzDxLPrhiY="; isUnstable = true; }; |