-
-
Notifications
You must be signed in to change notification settings - Fork 14.7k
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
zfs 2.15 fails to build with kernel 5.18.6 #179551
Comments
I can reproduce this, but there is something fishy going on. The ZFS kernel module should be built on Hydra and substituted. Why is this not happening? |
Looks like this is fixed in openzfs/zfs#13575. Let's hope that the ZFS team will make a new release soon. |
Thank you for finding this issue - i've searched the zfs issue tracker but didn't stumble across this one. Though, as you also mentioned - i thought, if Hydra is green, i'm good to go? |
Commits fixing openzfs/zfs#13575 don't apply cleanly to 2.1.5 release, but I managed to cherry-pick the ones that fix NixOS build. I'm typing this comment from NixOS ZFS root on 5.18 now. Here's the overlay: https://gist.github.com/mpasternacki/819b7ff33c0df3f37b5687cfdeabf954 |
In case you're in a rush to update, linux-zen seems to not treat all warnings as errors and don't have this issue... |
I've opened an issue on ZFS in the hope to speed things up a little bit: openzfs/zfs#13622 |
This is the configuration I am using for now. An overlay for the userspace tools is not necessary since these build without problems. {
boot.kernelPackages = pkgs.linuxPackages_5_18.extend (final: prev: {
zfs = prev.zfs.overrideAttrs ({ NIX_CFLAGS_COMPILE ? [], ... }: {
NIX_CFLAGS_COMPILE = NIX_CFLAGS_COMPILE ++ [ "-Wno-error=attribute-warning" ];
});
});
} or if you want to patch your checkout of nixpkgs: diff --git a/pkgs/os-specific/linux/zfs/default.nix b/pkgs/os-specific/linux/zfs/default.nix
index eec2d1ad04a..a56c92044a5 100644
--- a/pkgs/os-specific/linux/zfs/default.nix
+++ b/pkgs/os-specific/linux/zfs/default.nix
@@ -109,6 +109,8 @@ let
# for zdb to get the rpath to libgcc_s, needed for pthread_cancel to work
NIX_CFLAGS_LINK = "-lgcc_s";
+ NIX_CFLAGS_COMPILE = [ "-Wno-error=attribute-warning" ];
+
hardeningDisable = [ "fortify" "stackprotector" "pic" ];
configureFlags = [ |
Successfully builds with #180275 (which includes a backport to the WERROR skipping from unstable, and is on the way to |
Steps To Reproduce
Steps to reproduce the behavior:
nixos-rebuild
with updated channelBuild log
The failing parts are:
Additional context
This may be a zfs problem, not a nix problem, but i am not sure about that. It may even be a "me"-problem, though i have no custom config around zfs- or kernel-versions.
Notify maintainers
@Madouura @hmenke @jcumming @jonringer @wizeman @fpletz @globin
Metadata
The text was updated successfully, but these errors were encountered: