diff --git a/clients/quadphone/cross.nix b/clients/quadphone/cross.nix index 0551f78..2a5f46e 100644 --- a/clients/quadphone/cross.nix +++ b/clients/quadphone/cross.nix @@ -124,13 +124,7 @@ in ); } ) - ( - _: prev: - builtins.mapAttrs ( - name: v: - if isPhoneCross prev then pick [ name ] v else v - ) prev - ) + (_: prev: builtins.mapAttrs (name: v: if isPhoneCross prev then pick [ name ] v else v) prev) ]; }; } diff --git a/clients/quadphone/nixphone.nix b/clients/quadphone/nixphone.nix index 9081990..e5fc4d0 100644 --- a/clients/quadphone/nixphone.nix +++ b/clients/quadphone/nixphone.nix @@ -1,9 +1,21 @@ -{ inputs, lib, ... }: +{ + inputs, + lib, + pkgs, + ... +}: { imports = [ inputs.nixphone.nixosModules.sdm845-oneplus-fajita ]; - quadphone.crossPackages = [ - "nix-direnv" + boot.kernelPatches = [ + { + name = "rust-fix-rustc-option-cross"; + patch = pkgs.fetchpatch { + name = "rust-kasan-kbuild-fix-rustc-option-when-cross-compiling.patch"; + url = "https://github.com/torvalds/linux/commit/4a44b17406cb5a93f90af3df9392b3a45eb336fb.patch"; + hash = "sha256-+mOEhCM+LDRFEk/7y1hEgpH1Ane4bdH1xmA55gaRCro="; + }; + } ]; # TODO: flutter apps don't cross compile, and the flake's package isn't cached diff --git a/flake.lock b/flake.lock index c64edd5..4e49034 100644 --- a/flake.lock +++ b/flake.lock @@ -722,7 +722,7 @@ }, "locked": { "lastModified": 0, - "narHash": "sha256-SkR1Brw/vcZnlekZGrhTs26/qMF1EzZ1oVjijZgjVhY=", + "narHash": "sha256-2UHvyoarUiV+3vfKxLnrIa2Fj6uokJ6YpxW/j34x0HM=", "type": "git", "url": "file:///home/quadradical/Documents/Code/nixos-gnome-mobile" },