{-# OPTIONS_GHC -Wno-missing-fields #-}
{-# LANGUAGE CPP #-}
#include "ghclib_api.h"
module Language.Haskell.GhclibParserEx.Config(
fakeSettings
, fakeLlvmConfig
)
where
import Config
#if defined (GHCLIB_API_811)
import GHC.Driver.Session
#else
import DynFlags
#endif
import Fingerprint
#if defined (GHCLIB_API_811) || defined (GHCLIB_API_810)
import GHC.Platform
import ToolSettings
#else
import Platform
#endif
fakeSettings :: Settings
fakeSettings :: Settings
fakeSettings = Settings :: Platform
-> FilePath
-> FilePath
-> Maybe FilePath
-> FilePath
-> FilePath
-> FilePath
-> FilePath
-> [(FilePath, FilePath)]
-> [FilePath]
-> FilePath
-> Bool
-> Bool
-> Bool
-> Bool
-> Bool
-> FilePath
-> (FilePath, [Option])
-> FilePath
-> (FilePath, [Option])
-> (FilePath, [Option])
-> (FilePath, [Option])
-> (FilePath, [Option])
-> (FilePath, [Option])
-> FilePath
-> FilePath
-> FilePath
-> FilePath
-> FilePath
-> (FilePath, [Option])
-> (FilePath, [Option])
-> (FilePath, [Option])
-> FilePath
-> [FilePath]
-> [FilePath]
-> Fingerprint
-> [FilePath]
-> [FilePath]
-> [FilePath]
-> [FilePath]
-> [FilePath]
-> [FilePath]
-> [FilePath]
-> [FilePath]
-> [FilePath]
-> PlatformConstants
-> Settings
Settings
#if defined (GHCLIB_API_811) || defined (GHCLIB_API_810)
{ sGhcNameVersion=ghcNameVersion
, sFileSettings=fileSettings
, sTargetPlatform=platform
, sPlatformMisc=platformMisc
, sPlatformConstants=platformConstants
, sToolSettings=toolSettings
}
#else
{ sTargetPlatform :: Platform
sTargetPlatform=Platform
platform
, sPlatformConstants :: PlatformConstants
sPlatformConstants=PlatformConstants
platformConstants
, sProjectVersion :: FilePath
sProjectVersion=FilePath
cProjectVersion
, sProgramName :: FilePath
sProgramName="ghc"
, sOpt_P_fingerprint :: Fingerprint
sOpt_P_fingerprint=Fingerprint
fingerprint0
}
#endif
where
#if defined (GHCLIB_API_811) || defined (GHCLIB_API_810)
toolSettings = ToolSettings {
toolSettings_opt_P_fingerprint=fingerprint0
}
fileSettings = FileSettings {}
platformMisc = PlatformMisc {}
ghcNameVersion =
GhcNameVersion{ghcNameVersion_programName="ghc"
,ghcNameVersion_projectVersion=cProjectVersion
}
#endif
platform :: Platform
platform =
$WPlatform :: Arch
-> OS -> Int -> Bool -> Bool -> Bool -> Bool -> Bool -> Platform
Platform{
#if defined (GHCLIB_API_811) || defined (GHCLIB_API_810)
platformWordSize = PW8
, platformMini = PlatformMini {platformMini_arch=ArchUnknown, platformMini_os=OSUnknown}
#else
platformWordSize :: Int
platformWordSize=8
, platformOS :: OS
platformOS=OS
OSUnknown
#endif
, platformUnregisterised :: Bool
platformUnregisterised=Bool
True
}
platformConstants :: PlatformConstants
platformConstants =
PlatformConstants :: ()
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Int
-> Bool
-> Bool
-> Int
-> Integer
-> Integer
-> Integer
-> PlatformConstants
PlatformConstants{pc_DYNAMIC_BY_DEFAULT :: Bool
pc_DYNAMIC_BY_DEFAULT=Bool
False,pc_WORD_SIZE :: Int
pc_WORD_SIZE=8}
#if defined (GHCLIB_API_811) || defined (GHCLIB_API_810)
fakeLlvmConfig :: LlvmConfig
fakeLlvmConfig = LlvmConfig [] []
#else
fakeLlvmConfig :: (LlvmTargets, LlvmPasses)
fakeLlvmConfig :: (LlvmTargets, LlvmPasses)
fakeLlvmConfig = ([], [])
#endif