GHC9.x

Install on M1 mac

Preqs:

brew install llvm@13

Add to path

export PATH="/opt/homebrew/opt/llvm@13/bin:$PATH"

Install via GHCup

Fix ffitarget_arm64.h not found on M1 Mac

fatal error: 'ffitarget_arm64.h' file not found

Fix:

C_INCLUDE_PATH="`xcrun --show-sdk-path`/usr/include/ffi" stack build --fast --pedantic

See also issue 20592