-
-
Notifications
You must be signed in to change notification settings - Fork 14.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
patch ati-drivers for kernel 4.6 #18237
Conversation
@jerith666, thanks for your PR! By analyzing the annotation information on this pull request, we identified @edwtjo, @heydojo and @MarcWeber to be potential reviewers |
@@ -1,4 +1,4 @@ | |||
{ stdenv, fetchurl, kernel ? null, which | |||
{ stdenv, fetchurl, kernel ? null, linux, which |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
linux
? I'm confident one should use the existing kernel
parameter instead. That can be null
, but that's for case when a kernel module isn't built and such patches shouldn't be needed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's what I thought too, but when I was running my build locally, kernel
was null
. That seemed weird to me, although I don't see kernel
being passed in explicitly where this is called (at https://github.com/jerith666/nixpkgs/blob/df9b7c1274551bc1ce0b1e71bb35e4cfbad143ae/pkgs/top-level/all-packages.nix#L11276). But I also don't understand what args callPackage
is expected to fill in automatically.
At any rate, here is what I get:
$ git diff
diff --git a/pkgs/os-specific/linux/ati-drivers/default.nix b/pkgs/os-specific/linux/ati-drivers/default.nix
index d54b0ab..621d756 100644
--- a/pkgs/os-specific/linux/ati-drivers/default.nix
+++ b/pkgs/os-specific/linux/ati-drivers/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, kernel ? null, linux, which
+{ stdenv, fetchurl, kernel ? null, which
, xorg, makeWrapper, glibc, patchelf, unzip
, fontconfig, freetype, mesa # for fgl_glxgears
, # Whether to build the libraries only (i.e. not the kernel module or
@@ -72,7 +72,7 @@ stdenv.mkDerivation rec {
./patches/15.9-mtrr.patch
./patches/15.9-preempt.patch
./patches/15.9-sep_printf.patch ]
- ++ optionals ( (builtins.compareVersions linux.version "4.6") >= 0 )
+ ++ optionals ( (builtins.compareVersions kernel.version "4.6") >= 0 )
[ ./patches/kernel-4.6-get_user_pages.patch
./patches/kernel-4.6-page_cache_release-put_page.patch ];
$ nixos-rebuild build -I nixpkgs=/home/matt/git/nixos/nixpkgs
building Nix...
building the system configuration...
error: value is null while a set was expected, at /home/matt/git/nixos/nixpkgs/pkgs/os-specific/linux/ati-drivers/default.nix:75:44
(use ‘--show-trace’ to show detailed location information)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I expect you have a 64-bit system with driSupport32Bit = true
: there you get 64-bit version build against the kernel and a 32-bit version with libsOnly == true
(i.e. without kernel).
The Travis CI failure was in building the OpenJDK docs, which seems spurious to me. |
this uses the patch from https://github.com/manjaro/packages-extra/commit/ddae91f2 to account for torvalds/linux@d4edcf0d and the patch from https://www.virtualbox.org/ticket/15298 to account for torvalds/linux@09cbfeaf
df9b7c1
to
7bc91ff
Compare
Did someone test this? cc @ocharles |
Looks reasonable and builds OK. I assume @jerith666 runs on it. |
It still won't build with 4.7, but that's a relatively new branch. |
@vcunat I do indeed run on this. I guess I should've said that explicitly in the description? I thought @domenkozar was asking for someone else to test it. Anyway, thanks for the merge! |
I haven't looked at 4.7, it probably won't come to the top of my list for a bit yet. :-/ |
I see you checked the "tested execution" box; that should be enough IMHO. |
Motivation for this change
fixes #18202
Things done
(nix.useSandbox on NixOS,
or option
build-use-sandbox
innix.conf
on non-NixOS)
nix-shell -p nox --run "nox-review wip"
./result/bin/
)this uses the patch from
https://github.com/manjaro/packages-extra/commit/ddae91f2 to account
for torvalds/linux@d4edcf0d and the patch
from https://www.virtualbox.org/ticket/15298 to account for
torvalds/linux@09cbfeaf