aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--cabal-helper.cabal1
-rw-r--r--lib/Distribution/Helper.hs9
-rw-r--r--src/CabalHelper/Compiletime/Compat/ProgramDb.hs31
3 files changed, 7 insertions, 34 deletions
diff --git a/cabal-helper.cabal b/cabal-helper.cabal
index ede2124..384a849 100644
--- a/cabal-helper.cabal
+++ b/cabal-helper.cabal
@@ -133,7 +133,6 @@ library c-h-internal
exposed-modules:
CabalHelper.Compiletime.Cabal
CabalHelper.Compiletime.Compat.Environment
- CabalHelper.Compiletime.Compat.ProgramDb
CabalHelper.Compiletime.Compat.Version
CabalHelper.Compiletime.Compat.Parsec
CabalHelper.Compiletime.Compile
diff --git a/lib/Distribution/Helper.hs b/lib/Distribution/Helper.hs
index 3d7074e..8a3781c 100644
--- a/lib/Distribution/Helper.hs
+++ b/lib/Distribution/Helper.hs
@@ -157,13 +157,18 @@ import CabalHelper.Shared.Common
import CabalHelper.Runtime.HelperMain (helper_main)
import CabalHelper.Compiletime.Compat.Version
-import qualified CabalHelper.Compiletime.Compat.ProgramDb as ProgDb
- ( defaultProgramDb, programPath, lookupProgram, ghcProgram, ghcPkgProgram )
+
import Distribution.System (buildPlatform)
import Distribution.Text (display)
import Distribution.Verbosity (Verbosity, silent, normal, verbose, deafening)
import Distribution.Simple.GHC as GHC (configure)
+import qualified Distribution.Simple.Program as ProgDb
+ ( lookupProgram, lookupKnownProgram, programPath
+ , configureProgram, userMaybeSpecifyPath
+ , ghcProgram, ghcPkgProgram, haddockProgram )
+import qualified Distribution.Simple.Program.Db as ProgDb
+
-- $type-conventions
-- Throughout the API we use the following conventions for type variables:
--
diff --git a/src/CabalHelper/Compiletime/Compat/ProgramDb.hs b/src/CabalHelper/Compiletime/Compat/ProgramDb.hs
deleted file mode 100644
index eb0f26d..0000000
--- a/src/CabalHelper/Compiletime/Compat/ProgramDb.hs
+++ /dev/null
@@ -1,31 +0,0 @@
--- cabal-helper: Simple interface to Cabal's configuration state
--- Copyright (C) 2018 Daniel Gröber <cabal-helper@dxld.at>
---
--- This program is free software: you can redistribute it and/or modify
--- it under the terms of the GNU General Public License as published by
--- the Free Software Foundation, either version 3 of the License, or
--- (at your option) any later version.
---
--- This program is distributed in the hope that it will be useful,
--- but WITHOUT ANY WARRANTY; without even the implied warranty of
--- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
--- GNU General Public License for more details.
---
--- You should have received a copy of the GNU General Public License
--- along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-{-# LANGUAGE CPP #-}
-module CabalHelper.Compiletime.Compat.ProgramDb
- ( defaultProgramDb
- , programPath
- , lookupProgram
- , ghcProgram
- , ghcPkgProgram
- ) where
-
-import Distribution.Simple.Program
-
-#if !MIN_VERSION_Cabal(2,0,0)
-defaultProgramDb :: ProgramConfiguration
-defaultProgramDb = defaultProgramConfiguration
-#endif