File tree Expand file tree Collapse file tree 2 files changed +14
-1
lines changed Expand file tree Collapse file tree 2 files changed +14
-1
lines changed Original file line number Diff line number Diff line change
1
+ {-# LANGUAGE ScopedTypeVariables #-}
2
+
1
3
module StackTest
2
4
( run'
3
5
, run
@@ -37,6 +39,7 @@ module StackTest
37
39
, isLinux
38
40
, getIsAlpine
39
41
, isARM
42
+ , isAarch64
40
43
, isMacOSX
41
44
, defaultResolverArg
42
45
, removeFileIgnore
@@ -334,6 +337,10 @@ getIsAlpine = doesFileExist "/etc/alpine-release"
334
337
isARM :: Bool
335
338
isARM = arch == " arm"
336
339
340
+ -- | Is the architecture Aarch64?
341
+ isAarch64 :: Bool
342
+ isAarch64 = arch == " aarch64"
343
+
337
344
-- | Is the OS Mac OS X?
338
345
isMacOSX :: Bool
339
346
isMacOSX = os == " darwin"
Original file line number Diff line number Diff line change
1
+ import Control.Monad ( unless )
1
2
import StackTest
2
3
3
4
main :: IO ()
4
- main = do
5
+ -- See https://github.com/haskell/cabal/issues/7763. On macOS (Apple silicon),
6
+ -- fails with Cabal error:
7
+ -- "Cabal-simple_SvXsv1f__3.2.1.0_ghc-8.10.7: Cannot build some foreign libraries:
8
+ -- Building foreign libraries is currently only supported on OSX, Linux and
9
+ -- Windows"
10
+ main = unless ( isAarch64 && isMacOSX ) $ do
5
11
-- The '--install-ghc' flag is passed here, because etc/scripts/release.hs
6
12
-- passes `--no-install-ghc` when `--alpine` is passed to its 'check'
7
13
-- command.
You can’t perform that action at this time.
0 commit comments