diff --git a/Cabal/src/Distribution/Compat/GetShortPathName.hs b/Cabal/src/Distribution/Compat/GetShortPathName.hs index f6c9517dd71a5efcc1321c8d9a5634710f5de494..b6826bb60f2c9650803ac98af210dbc1e087cc1c 100644 --- a/Cabal/src/Distribution/Compat/GetShortPathName.hs +++ b/Cabal/src/Distribution/Compat/GetShortPathName.hs @@ -23,7 +23,7 @@ import System.Win32 (LPCTSTR, LPTSTR, DWORD) import Foreign.Marshal.Array (allocaArray) {- FOURMOLU_DISABLE -} -#ifdef x86_64_HOST_ARCH +#if defined(x86_64_HOST_ARCH) || defined(aarch64_HOST_ARCH) #define WINAPI ccall #else #define WINAPI stdcall diff --git a/Cabal/src/Distribution/Compat/Time.hs b/Cabal/src/Distribution/Compat/Time.hs index cce1ceaf819c2303e1aec1086449c78532af4b6e..4743e1edb7b9b65a79c509221f04660a6d9b0bb2 100644 --- a/Cabal/src/Distribution/Compat/Time.hs +++ b/Cabal/src/Distribution/Compat/Time.hs @@ -94,7 +94,7 @@ getModTime path = allocaBytes size_WIN32_FILE_ATTRIBUTE_DATA $ \info -> do return $! ModTime (qwTime :: Word64) {- FOURMOLU_DISABLE -} -#ifdef x86_64_HOST_ARCH +#if defined(x86_64_HOST_ARCH) || defined(aarch64_HOST_ARCH) #define CALLCONV ccall #else #define CALLCONV stdcall diff --git a/Cabal/src/Distribution/Simple/InstallDirs.hs b/Cabal/src/Distribution/Simple/InstallDirs.hs index 86e6fa08777bfb31924f6480e27a57ab292af52a..41143ea36eed10f3c9092b7284d48320eb9bdafc 100644 --- a/Cabal/src/Distribution/Simple/InstallDirs.hs +++ b/Cabal/src/Distribution/Simple/InstallDirs.hs @@ -537,7 +537,7 @@ csidl_PROGRAM_FILES = 0x0026 -- csidl_PROGRAM_FILES_COMMON = 0x002b {- FOURMOLU_DISABLE -} -#ifdef x86_64_HOST_ARCH +#if defined(x86_64_HOST_ARCH) || defined(aarch64_HOST_ARCH) #define CALLCONV ccall #else #define CALLCONV stdcall diff --git a/cabal-install/src/Distribution/Client/Win32SelfUpgrade.hs b/cabal-install/src/Distribution/Client/Win32SelfUpgrade.hs index 89b75610261384c7a6c48a3f64a53a551c946d12..13a7da5c9827bc0782d1a2a3adaa84052c9e7401 100644 --- a/cabal-install/src/Distribution/Client/Win32SelfUpgrade.hs +++ b/cabal-install/src/Distribution/Client/Win32SelfUpgrade.hs @@ -166,7 +166,7 @@ deleteOldExeFile verbosity oldPID tmpPath = do -- A bunch of functions sadly not provided by the Win32 package. {- FOURMOLU_DISABLE -} -#ifdef x86_64_HOST_ARCH +#if defined(x86_64_HOST_ARCH) || defined(aarch64_HOST_ARCH) #define CALLCONV ccall #else #define CALLCONV stdcall