From 38208e57670d33b35655b1488b0c6a0d039a0053 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A9cate=20Moonlight?= Date: Mon, 24 Jun 2024 13:11:00 +0200 Subject: [PATCH 1/3] Disable arch-native flag when building releases that we distribute --- cabal.release.project | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cabal.release.project b/cabal.release.project index 5ce38e721a5..f7a451c4fa3 100644 --- a/cabal.release.project +++ b/cabal.release.project @@ -2,4 +2,7 @@ import: project-cabal/pkgs/cabal.config import: project-cabal/pkgs/install.config import: project-cabal/pkgs/tests.config +package * + flags: -arch-native + index-state: hackage.haskell.org 2024-06-17T00:00:01Z From 4244fb52fdb4ef0b3e8d973f16d04a0a4c5e4633 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A9cate=20Moonlight?= Date: Mon, 24 Jun 2024 14:46:51 +0200 Subject: [PATCH 2/3] Use the constraints stanza --- cabal.release.project | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cabal.release.project b/cabal.release.project index f7a451c4fa3..ffd7c18adc1 100644 --- a/cabal.release.project +++ b/cabal.release.project @@ -2,7 +2,7 @@ import: project-cabal/pkgs/cabal.config import: project-cabal/pkgs/install.config import: project-cabal/pkgs/tests.config -package * - flags: -arch-native +constraints: + hashable -arch-native index-state: hackage.haskell.org 2024-06-17T00:00:01Z From c1a1de388e2e99da40a05c286853f3f7c9692f7d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A9cate=20Moonlight?= Date: Mon, 24 Jun 2024 18:12:18 +0200 Subject: [PATCH 3/3] Also disable the flag in cabal.validate.project --- cabal.validate.project | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/cabal.validate.project b/cabal.validate.project index 52c78411107..2e3084cccf0 100644 --- a/cabal.validate.project +++ b/cabal.validate.project @@ -7,3 +7,8 @@ tests: True write-ghc-environment-files: never program-options ghc-options: -Werror + +-- This project file is used to distribute the cabal-head binary, +-- as such we cannot enable "-march=native". +constraints: + hashable -arch-native