From da97f0dbf1834b6801f05744e55e73e0b926e481 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Attila=20Ol=C3=A1h?= Date: Sun, 19 Jul 2026 10:59:16 +0200 Subject: [PATCH] nix: build on darwin with -march=native --- flake.nix | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/flake.nix b/flake.nix index 276dbb6..df83d4c 100644 --- a/flake.nix +++ b/flake.nix @@ -45,7 +45,10 @@ checkInputs = [pythonEnv]; # Use x86-64-v3 (AVX2) for a portable binary; override with ARCH=native for local builds - ARCH = "x86-64-v3"; + ARCH = + if pkgs.stdenv.hostPlatform.isx86_64 + then "x86-64-v3" + else "native"; buildPhase = '' runHook preBuild @@ -95,7 +98,7 @@ description = "Run GLM-5.2 (744B MoE) on a consumer machine with ~25 GB RAM"; homepage = "https://github.com/JustVugg/colibri"; license = licenses.asl20; - platforms = platforms.linux; + platforms = with platforms; linux ++ darwin; mainProgram = "glm"; }; };