Skip to content
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

Build unstable kernel for VisionFive 2 #950

Closed
onny opened this issue May 19, 2024 · 2 comments
Closed

Build unstable kernel for VisionFive 2 #950

onny opened this issue May 19, 2024 · 2 comments

Comments

@onny
Copy link
Contributor

onny commented May 19, 2024

Hey,

I'm trying to build the latest unstable kernel for Starfive VisionFive 2 kernel. I git cloned the nixos-hardware-repository and changed revision and hash in starfive/visionfive/v2/linux-6.6.nix

      src = fetchFromGitHub {
        owner = "starfive-tech";
        repo = "linux";
        rev = "430c94788670c08f6b28c8253c62214da5d942a1";
        hash = "sha256-EfccTNP8OLj0pvpBlftgPyXvTi6EJVuciVwyRsYatTk=";
      };

Unfortunately don't know how to do this via overlays.

I added my local nixos-hardware fork to the flake which defines my system (following this tutorial https://wiki.nixos.org/wiki/NixOS_on_RISCV/VisionFive_2 ). When trying to build I get this error

       >     [CC]     raid/x86.o
       >     [CC]     raid/x86z.o
       >     [SED]    fsck/bcachefsck_all
       >     [SED]    fsck/bcachefsck_fail@.service
       >     [SED]    fsck/bcachefsck@.service
       >     [SED]    fsck/bcachefsck_all_fail.service
       >     [SED]    fsck/bcachefsck_all.service
       >     [AR]     libbcachefs.a
       > /nix/store/h3bhzvz9ipglcybbcvkxvm4vg9lwvqg4-bash-5.2p26/bin/bash: line 1: ar: command not found

Is it related to cross compiling or is "binutils" with "ar" missing somewhere?

@malteneuss
Copy link
Contributor

malteneuss commented May 25, 2024

Cross-compiling seems to be a lot of luck. I can't even get the current linux kernel to build :( #956

Have you tried using your visionfive2 board as a remote builder to do native compiling instead? I tried it the Rapsberry Pi 5 and went quite well. I will try that as well for the Visionfive2.

Btw, do you know the status or a tracking page of starfive patches in the upstream Linux kernel and maybe UEFI or u-boot? As far as i understand the nixpkgs maintainers don't want to add custom linux kernels and firmwares anymore as that apparently was too much maintenance overhead in the past. Would be great know when NixOS will run out of the box.

@onny
Copy link
Contributor Author

onny commented May 28, 2024

Looking for the mainline kernel to work #958

@onny onny closed this as completed May 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants