about summary refs log tree commit diff
path: root/pkgs/os-specific
diff options
context:
space:
mode:
authorFrederik Rietdijk <fridh@fridh.nl>2019-02-16 09:29:54 +0100
committerFrederik Rietdijk <fridh@fridh.nl>2019-02-16 09:29:54 +0100
commit6fe10d27799c284c72876f792c7b12d7fa54602b (patch)
treeb3594f3899a031eca0563cf36c4813f60b6c76e9 /pkgs/os-specific
parent5a322693f4de4763e951f5df3f0026e914957ae4 (diff)
parent039f359a7d366e6d8594a4238aac6fcb4dbd7be8 (diff)
downloadnixlib-6fe10d27799c284c72876f792c7b12d7fa54602b.tar
nixlib-6fe10d27799c284c72876f792c7b12d7fa54602b.tar.gz
nixlib-6fe10d27799c284c72876f792c7b12d7fa54602b.tar.bz2
nixlib-6fe10d27799c284c72876f792c7b12d7fa54602b.tar.lz
nixlib-6fe10d27799c284c72876f792c7b12d7fa54602b.tar.xz
nixlib-6fe10d27799c284c72876f792c7b12d7fa54602b.tar.zst
nixlib-6fe10d27799c284c72876f792c7b12d7fa54602b.zip
Merge master into staging-next
Diffstat (limited to 'pkgs/os-specific')
-rw-r--r--pkgs/os-specific/linux/kernel/interpreter-trunc.patch44
-rw-r--r--pkgs/os-specific/linux/kernel/linux-4.14.nix4
-rw-r--r--pkgs/os-specific/linux/kernel/linux-4.19.nix4
-rw-r--r--pkgs/os-specific/linux/kernel/linux-4.20.nix4
-rw-r--r--pkgs/os-specific/linux/kernel/linux-4.9.nix4
-rw-r--r--pkgs/os-specific/linux/kernel/linux-testing-bcachefs.nix6
-rw-r--r--pkgs/os-specific/linux/kernel/patches.nix7
-rw-r--r--pkgs/os-specific/linux/syslinux/default.nix36
-rw-r--r--pkgs/os-specific/linux/syslinux/perl-deps.patch81
9 files changed, 70 insertions, 120 deletions
diff --git a/pkgs/os-specific/linux/kernel/interpreter-trunc.patch b/pkgs/os-specific/linux/kernel/interpreter-trunc.patch
new file mode 100644
index 000000000000..a0eceec2258f
--- /dev/null
+++ b/pkgs/os-specific/linux/kernel/interpreter-trunc.patch
@@ -0,0 +1,44 @@
+From cb5b020a8d38f77209d0472a0fea755299a8ec78 Mon Sep 17 00:00:00 2001
+From: Linus Torvalds <torvalds@linux-foundation.org>
+Date: Thu, 14 Feb 2019 15:02:18 -0800
+Subject: Revert "exec: load_script: don't blindly truncate shebang string"
+
+This reverts commit 8099b047ecc431518b9bb6bdbba3549bbecdc343.
+
+It turns out that people do actually depend on the shebang string being
+truncated, and on the fact that an interpreter (like perl) will often
+just re-interpret it entirely to get the full argument list.
+
+Reported-by: Samuel Dionne-Riel <samuel@dionne-riel.com>
+Acked-by: Kees Cook <keescook@chromium.org>
+Cc: Oleg Nesterov <oleg@redhat.com>
+Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
+---
+ fs/binfmt_script.c | 10 +++-------
+ 1 file changed, 3 insertions(+), 7 deletions(-)
+
+diff --git a/fs/binfmt_script.c b/fs/binfmt_script.c
+index d0078cbb718b..7cde3f46ad26 100644
+--- a/fs/binfmt_script.c
++++ b/fs/binfmt_script.c
+@@ -42,14 +42,10 @@ static int load_script(struct linux_binprm *bprm)
+ 	fput(bprm->file);
+ 	bprm->file = NULL;
+ 
+-	for (cp = bprm->buf+2;; cp++) {
+-		if (cp >= bprm->buf + BINPRM_BUF_SIZE)
+-			return -ENOEXEC;
+-		if (!*cp || (*cp == '\n'))
+-			break;
+-	}
++	bprm->buf[BINPRM_BUF_SIZE - 1] = '\0';
++	if ((cp = strchr(bprm->buf, '\n')) == NULL)
++		cp = bprm->buf+BINPRM_BUF_SIZE-1;
+ 	*cp = '\0';
+-
+ 	while (cp > bprm->buf) {
+ 		cp--;
+ 		if ((*cp == ' ') || (*cp == '\t'))
+-- 
+cgit 1.2-0.3.lf.el7
+
diff --git a/pkgs/os-specific/linux/kernel/linux-4.14.nix b/pkgs/os-specific/linux/kernel/linux-4.14.nix
index 5f333205dd52..95050a37d28f 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 stdenv.lib;
 
 buildLinux (args // rec {
-  version = "4.14.99";
+  version = "4.14.101";
 
   # modDirVersion needs to be x.y.z, will automatically add .0 if needed
   modDirVersion = if (modDirVersionArg == null) then concatStrings (intersperse "." (take 3 (splitString "." "${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 = "02pbi5jck6fp7y5lihn077i0j3hssxcrbsfbxlyp62xjsnp8rycg";
+    sha256 = "16mnrn2lb6xhcmpqx8brk2w4g6igfb1cwkqkpvlnc7003g2zfbql";
   };
 } // (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 200264df22a5..ac6b3dad86bb 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 stdenv.lib;
 
 buildLinux (args // rec {
-  version = "4.19.21";
+  version = "4.19.23";
 
   # modDirVersion needs to be x.y.z, will automatically add .0 if needed
   modDirVersion = if (modDirVersionArg == null) then concatStrings (intersperse "." (take 3 (splitString "." "${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 = "1hdvk1lz9gi8b6gahqqb1r5zzndfw86qzsg1fji0shgy4vkys26v";
+    sha256 = "02hkiz5vlx2qhyi1hxar9d1cr2gfnrpjdrjjkh83yzxci9kjb6rd";
   };
 } // (args.argsOverride or {}))
diff --git a/pkgs/os-specific/linux/kernel/linux-4.20.nix b/pkgs/os-specific/linux/kernel/linux-4.20.nix
index 799f36f7dc27..382747b69d95 100644
--- a/pkgs/os-specific/linux/kernel/linux-4.20.nix
+++ b/pkgs/os-specific/linux/kernel/linux-4.20.nix
@@ -3,7 +3,7 @@
 with stdenv.lib;
 
 buildLinux (args // rec {
-  version = "4.20.8";
+  version = "4.20.10";
 
   # modDirVersion needs to be x.y.z, will automatically add .0 if needed
   modDirVersion = if (modDirVersionArg == null) then concatStrings (intersperse "." (take 3 (splitString "." "${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 = "0qnh0h7c7ni7j1cgm20sqsfkbri98bckxms494w9ig539b2ac35n";
+    sha256 = "1y1w3j65n2k4ibn9clapbhy5m2rbyspg2maql7q9k27vmplnppjk";
   };
 } // (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 334fb6e81b68..cdebebc74824 100644
--- a/pkgs/os-specific/linux/kernel/linux-4.9.nix
+++ b/pkgs/os-specific/linux/kernel/linux-4.9.nix
@@ -1,11 +1,11 @@
 { stdenv, buildPackages, fetchurl, perl, buildLinux, ... } @ args:
 
 buildLinux (args // rec {
-  version = "4.9.156";
+  version = "4.9.158";
   extraMeta.branch = "4.9";
 
   src = fetchurl {
     url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz";
-    sha256 = "05m82x2zg0nkc6ayk6akgpfhz31zp6dhhlklcfmi419p8fxbkcay";
+    sha256 = "1vvm2gw5cddy40amxxr1hcw0bis2zldzyicvjhy11wg6j3snk2lc";
   };
 } // (args.argsOverride or {}))
diff --git a/pkgs/os-specific/linux/kernel/linux-testing-bcachefs.nix b/pkgs/os-specific/linux/kernel/linux-testing-bcachefs.nix
index a3275786b338..82326a2ee73f 100644
--- a/pkgs/os-specific/linux/kernel/linux-testing-bcachefs.nix
+++ b/pkgs/os-specific/linux/kernel/linux-testing-bcachefs.nix
@@ -1,13 +1,13 @@
 { stdenv, buildPackages, fetchgit, perl, buildLinux, ... } @ args:
 
 buildLinux (args // rec {
-  version = "4.20.2019.01.23";
+  version = "4.20.2019.02.09";
   modDirVersion = "4.20.0";
 
   src = fetchgit {
     url = "https://evilpiepirate.org/git/bcachefs.git";
-    rev = "99750eab4d583132cf61f071082c7cf21f5295c0";
-    sha256 = "05wg9w5f68qg02yrciir9h1wx448869763hg3w7j23wc2qywhwqb";
+    rev = "09a546543006b60d44c4c51e7b40cd3ec7837a5e";
+    sha256 = "0p187vp9df0nnhawql0f2bj2sdim0f2b424106d41yxc8ayhz0d9";
   };
 
   extraConfig = "BCACHEFS_FS m";
diff --git a/pkgs/os-specific/linux/kernel/patches.nix b/pkgs/os-specific/linux/kernel/patches.nix
index 4c338b37deca..18fd311ca067 100644
--- a/pkgs/os-specific/linux/kernel/patches.nix
+++ b/pkgs/os-specific/linux/kernel/patches.nix
@@ -57,4 +57,11 @@ rec {
       sha256 = "1l8xq02rd7vakxg52xm9g4zng0ald866rpgm8kjlh88mwwyjkrwv";
     };
   };
+
+  # https://github.com/NixOS/nixpkgs/issues/53672
+  # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=cb5b020a8d38f77209d0472a0fea755299a8ec78
+  interpreter-trunc = {
+    name = "interpreter-trunc";
+    patch = ./interpreter-trunc.patch;
+  };
 }
diff --git a/pkgs/os-specific/linux/syslinux/default.nix b/pkgs/os-specific/linux/syslinux/default.nix
index 4b8ff89cb7ac..2562bb7e260b 100644
--- a/pkgs/os-specific/linux/syslinux/default.nix
+++ b/pkgs/os-specific/linux/syslinux/default.nix
@@ -1,40 +1,19 @@
-{ stdenv, fetchFromGitHub, fetchurl, nasm, perl, python, libuuid, mtools, makeWrapper }:
+{ stdenv, fetchFromRepoOrCz, fetchpatch, nasm, perl, python, libuuid, mtools, makeWrapper }:
 
 stdenv.mkDerivation rec {
-  name = "syslinux-2015-11-09";
+  # This is syslinux-6.04-pre3^1; syslinux-6.04-pre3 fails to run.
+  # Same issue here https://www.syslinux.org/archives/2019-February/026330.html
+  name = "syslinux-2019-02-07";
 
-  src = fetchFromGitHub {
-    owner = "geneC";
+  src = fetchFromRepoOrCz {
     repo = "syslinux";
-    rev = "0cc9a99e560a2f52bcf052fd85b1efae35ee812f";
-    sha256 = "0wk3r5ki4lc334f9jpml07wpl8d0bnxi9h1l4h4fyf9a0d7n4kmw";
+    rev = "b40487005223a78c3bb4c300ef6c436b3f6ec1f7";
+    sha256 = "1qrxl1114sr2i2791z9rf8v53g200aq30f08808d7i8qnmgvxl2w";
   };
 
-  patches = let
-    mkURL = commit: patchName:
-      "https://salsa.debian.org/images-team/syslinux/raw/${commit}/debian/patches/"
-      + patchName;
-  in [
-    ./perl-deps.patch
-    (fetchurl {
-      # ldlinux.elf: Not enough room for program headers, try linking with -N
-      name = "not-enough-room.patch";
-      url = mkURL "a556ad7" "0014_fix_ftbfs_no_dynamic_linker.patch";
-      sha256 = "0ijqjsjmnphmvsx0z6ppnajsfv6xh6crshy44i2a5klxw4nlvrsw";
-    })
-    (fetchurl {
-      # mbr.bin: too big (452 > 440)
-      # https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=906414
-      url = mkURL "7468ef0e38c43" "0016-strip-gnu-property.patch";
-      sha256 = "17n63b8wz6szv8npla1234g1ip7lqgzx2whrpv358ppf67lq8vwm";
-    })
-  ];
-
   postPatch = ''
     substituteInPlace Makefile --replace /bin/pwd $(type -P pwd)
-    substituteInPlace gpxe/src/Makefile.housekeeping --replace /bin/echo $(type -P echo)
     substituteInPlace utils/ppmtolss16 --replace /usr/bin/perl $(type -P perl)
-    substituteInPlace gpxe/src/Makefile --replace /usr/bin/perl $(type -P perl)
 
     # fix tests
     substituteInPlace tests/unittest/include/unittest/unittest.h \
@@ -74,6 +53,7 @@ stdenv.mkDerivation rec {
     homepage = http://www.syslinux.org/;
     description = "A lightweight bootloader";
     license = licenses.gpl2;
+    maintainers = [ maintainers.samueldr ];
     platforms = [ "i686-linux" "x86_64-linux" ];
   };
 }
diff --git a/pkgs/os-specific/linux/syslinux/perl-deps.patch b/pkgs/os-specific/linux/syslinux/perl-deps.patch
deleted file mode 100644
index 82c9820809e1..000000000000
--- a/pkgs/os-specific/linux/syslinux/perl-deps.patch
+++ /dev/null
@@ -1,81 +0,0 @@
-http://git.ipxe.org/ipxe.git/commitdiff/719b498
-
-diff -ru -x '*~' -x '*.orig' -x '*.rej' syslinux-4.02-orig/gpxe/src/arch/i386/Makefile.pcbios syslinux-4.02/gpxe/src/arch/i386/Makefile.pcbios
---- syslinux-4.02-orig/gpxe/src/arch/i386/Makefile.pcbios	2010-07-21 21:33:13.000000000 +0200
-+++ syslinux-4.02/gpxe/src/arch/i386/Makefile.pcbios	2010-08-06 23:32:57.000000000 +0200
-@@ -24,11 +24,11 @@
- 
- # Padding rules
- #
--PAD_rom		= $(PADIMG) --blksize=512 --byte=0xff $@
-+PAD_rom		= $(PERL) $(PADIMG) --blksize=512 --byte=0xff $@
- PAD_hrom	= $(PAD_rom)
- PAD_xrom	= $(PAD_rom)
--PAD_dsk		= $(PADIMG) --blksize=512 $@
--PAD_hd		= $(PADIMG) --blksize=32768 $@
-+PAD_dsk		= $(PERL) $(PADIMG) --blksize=512 $@
-+PAD_hd		= $(PERL) $(PADIMG) --blksize=32768 $@
- 
- # rule to make a non-emulation ISO boot image
- NON_AUTO_MEDIA	+= iso
-diff -ru -x '*~' -x '*.orig' -x '*.rej' syslinux-4.02-orig/gpxe/src/Makefile syslinux-4.02/gpxe/src/Makefile
---- syslinux-4.02-orig/gpxe/src/Makefile	2010-07-21 21:33:13.000000000 +0200
-+++ syslinux-4.02/gpxe/src/Makefile	2010-08-06 23:31:15.000000000 +0200
-@@ -31,12 +31,12 @@
- OBJCOPY		:= $(CROSS_COMPILE)objcopy
- NM		:= $(CROSS_COMPILE)nm
- OBJDUMP		:= $(CROSS_COMPILE)objdump
--PARSEROM	:= $(PERL) ./util/parserom.pl
--MAKEROM		:= $(PERL) ./util/makerom.pl
--SYMCHECK	:= $(PERL) ./util/symcheck.pl
--SORTOBJDUMP	:= $(PERL) ./util/sortobjdump.pl
--PADIMG		:= $(PERL) ./util/padimg.pl
--LICENCE		:= $(PERL) ./util/licence.pl
-+PARSEROM	:= ./util/parserom.pl
-+MAKEROM		:= ./util/makerom.pl
-+SYMCHECK	:= ./util/symcheck.pl
-+SORTOBJDUMP	:= ./util/sortobjdump.pl
-+PADIMG		:= ./util/padimg.pl
-+LICENCE		:= ./util/licence.pl
- NRV2B		:= ./util/nrv2b
- ZBIN		:= ./util/zbin
- ELF2EFI32	:= ./util/elf2efi32
-diff -ru -x '*~' -x '*.orig' -x '*.rej' syslinux-4.02-orig/gpxe/src/Makefile.housekeeping syslinux-4.02/gpxe/src/Makefile.housekeeping
---- syslinux-4.02-orig/gpxe/src/Makefile.housekeeping	2010-07-21 21:33:13.000000000 +0200
-+++ syslinux-4.02/gpxe/src/Makefile.housekeeping	2010-08-06 23:31:49.000000000 +0200
-@@ -456,7 +456,7 @@
- 		 '\n$(2) : $$($(4)_DEPS)\n' \
- 		 '\nTAGS : $$($(4)_DEPS)\n' \
- 		>> $(2)
--	@$(PARSEROM) $(1) >> $(2)
-+	@$(PERL) $(PARSEROM) $(1) >> $(2)
- 
- endef
- 
-@@ -657,7 +657,7 @@
- 	$(QM)$(ECHO) "  [LD] $@"
- 	$(Q)$(LD) $(LDFLAGS) -T $(LDSCRIPT) $(TGT_LD_FLAGS) $(BLIB) -o $@ \
- 		-Map $(BIN)/$*.tmp.map
--	$(Q)$(OBJDUMP) -ht $@ | $(SORTOBJDUMP) >> $(BIN)/$*.tmp.map
-+	$(Q)$(OBJDUMP) -ht $@ | $(PERL) $(SORTOBJDUMP) >> $(BIN)/$*.tmp.map
- 
- # Keep intermediate object file (useful for debugging)
- .PRECIOUS : $(BIN)/%.tmp
-@@ -714,7 +714,7 @@
- 		echo "files are missing a licence declaration:" ;\
- 		echo $(call unlicensed_deps_list,$<);\
- 		exit 1,\
--		$(LICENCE) $(call licence_list,$<))
-+		$(PERL) $(LICENCE) $(call licence_list,$<))
- 
- # Extract compression information from intermediate object file
- #
-@@ -941,7 +941,7 @@
- CLEANUP	+= $(BIN)/symtab
- 
- symcheck : $(SYMTAB)
--	$(SYMCHECK) $<
-+	$(PERL) $(SYMCHECK) $<
- 
- endif # defined(BIN)
-