From 21f7f432cd5b19fbbcbfe77b8b66853ef2304dc3 Mon Sep 17 00:00:00 2001 From: chn Date: Sat, 21 Sep 2024 04:37:39 +0800 Subject: [PATCH] fix oneapi --- pkgs/intel-oneapi/2023.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/intel-oneapi/2023.nix b/pkgs/intel-oneapi/2023.nix index ae2124b..0286e64 100644 --- a/pkgs/intel-oneapi/2023.nix +++ b/pkgs/intel-oneapi/2023.nix @@ -16,6 +16,7 @@ , gcc7 , wrapCCWith , linuxHeaders +, config }: # The distribution of intel packages is a mess. We are doing the installation @@ -398,7 +399,7 @@ let echo "-L${intel-compiler-shared}/lib" >> $out/nix-support/cc-ldflags echo "-L${cc}/lib" >> $out/nix-support/cc-ldflags - cp ${mygcc}/nix-support/cc-cflags-before $out/nix-support + echo "-march=${config.oneapiArch} -mtune=${config.oneapiArch}" >> $out/nix-support/cc-cflags-before # Need the gcc in the path echo 'export "PATH=${mygcc}/bin:$PATH"' >> $out/nix-support/cc-wrapper-hook