From c0ecd321736d9ea6452a8f7433f091bd9060b1a8 Mon Sep 17 00:00:00 2001 From: Rodrigo Arias Mallo Date: Wed, 24 Jan 2024 10:00:19 +0100 Subject: [PATCH] Remove unneeded override of stdenv The march and mtune flags are passed by the crossSystem gcc attributes, which are placed *before* the flags to gcc. This may end up causing some packages to break, but it is working fine so far. --- overlay.nix | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/overlay.nix b/overlay.nix index 628a773..fea2755 100644 --- a/overlay.nix +++ b/overlay.nix @@ -31,16 +31,6 @@ final: prev: filesToInstall = ["u-boot.bin" "u-boot"]; }; - # To cross compile for riscv64, we need to populate this env variable, not - # NIX_CFLAGS_COMPILE, otherwise we affect the packages for x86. - stdenv = if prev.stdenv.buildPlatform != prev.stdenv.hostPlatform - then - prev.stdenvAdapters.addAttrsToDerivation { - NIX_CFLAGS_COMPILE_riscv64_unknown_linux_gnu = "-march=rv64g"; - } prev.stdenv - else - prev.stdenv; - opensbi-uboot = prev.opensbi.overrideAttrs (old: { makeFlags = old.makeFlags ++ [ # Build OpenSBI without compressed instructions