From fcc3b4641596b26351121a5bfcd73d55d71eb0e6 Mon Sep 17 00:00:00 2001 From: Kazu Yamamoto Date: Fri, 16 May 2014 09:27:23 +0900 Subject: [PATCH] defining C macro if not defined. --- Language/Haskell/GhcMod/GhcPkg.hs | 4 ++++ Language/Haskell/GhcMod/Monad.hs | 8 ++++++++ 2 files changed, 12 insertions(+) diff --git a/Language/Haskell/GhcMod/GhcPkg.hs b/Language/Haskell/GhcMod/GhcPkg.hs index a2580cf..ca8a8ab 100644 --- a/Language/Haskell/GhcMod/GhcPkg.hs +++ b/Language/Haskell/GhcMod/GhcPkg.hs @@ -10,6 +10,10 @@ module Language.Haskell.GhcMod.GhcPkg ( , getPackageDbStack ) where +#ifndef MIN_VERSION_Cabal +#define MIN_VERSION_Cabal(x,y,z) 1 +#endif + import Config (cProjectVersionInt) import Control.Applicative ((<$>)) #if MIN_VERSION_Cabal(1,18,0) diff --git a/Language/Haskell/GhcMod/Monad.hs b/Language/Haskell/GhcMod/Monad.hs index d49c693..d08ad11 100644 --- a/Language/Haskell/GhcMod/Monad.hs +++ b/Language/Haskell/GhcMod/Monad.hs @@ -15,6 +15,14 @@ module Language.Haskell.GhcMod.Monad ( , module Control.Monad.State.Class ) where +#ifndef MIN_VERSION_ghc +#define MIN_VERSION_ghc(x,y,z) 1 +#endif + +#ifndef MIN_VERSION_base +#define MIN_VERSION_base(x,y,z) 1 +#endif + import Language.Haskell.GhcMod.Types import Language.Haskell.GhcMod.Cradle import Language.Haskell.GhcMod.GHCApi