Warning: The install command is a part of the legacy v1 style of cabal usage. Please switch to using either the new project style and the new-install command or the legacy v1-install alias as new-style projects will become the default in the next version of cabal-install. Please file a bug if you cannot replicate a working v1- use case with the new-style commands. For more information, see: https://wiki.haskell.org/Cabal/NewBuild Resolving dependencies... Starting Only-0.1 Starting blaze-builder-0.4.1.0 Starting bytestring-builder-0.10.8.2.0 Starting base-compat-0.10.5 Building Only-0.1 Building bytestring-builder-0.10.8.2.0 Building blaze-builder-0.4.1.0 Building base-compat-0.10.5 Completed bytestring-builder-0.10.8.2.0 Starting dlist-0.8.0.5 Building dlist-0.8.0.5 Completed Only-0.1 Starting hashable-1.2.7.0 Building hashable-1.2.7.0 Completed blaze-builder-0.4.1.0 Completed dlist-0.8.0.5 Starting integer-logarithms-1.0.2.2 Starting haskell-src-exts-1.21.0 Building integer-logarithms-1.0.2.2 Building haskell-src-exts-1.21.0 Completed hashable-1.2.7.0 Starting old-locale-1.0.0.7 Completed base-compat-0.10.5 Starting postgresql-libpq-0.9.4.2 Completed integer-logarithms-1.0.2.2 Starting primitive-0.6.4.0 Building old-locale-1.0.0.7 Building primitive-0.6.4.0 Completed old-locale-1.0.0.7 Starting random-1.1 Building random-1.1 Failed to install postgresql-libpq-0.9.4.2 Build log ( /home/builder/.cabal/logs/ghc-8.6.3/postgresql-libpq-0.9.4.2-HyacS45qPUc33pszxfYdpM.log ): cabal: Entering directory '/tmp/cabal-tmp-2184/postgresql-libpq-0.9.4.2' [1 of 1] Compiling Main ( /tmp/cabal-tmp-2184/postgresql-libpq-0.9.4.2/dist/setup/setup.hs, /tmp/cabal-tmp-2184/postgresql-libpq-0.9.4.2/dist/setup/Main.o ) Linking /tmp/cabal-tmp-2184/postgresql-libpq-0.9.4.2/dist/setup/setup ... Configuring postgresql-libpq-0.9.4.2... setup: The program 'pg_config' is required but it could not be found. cabal: Leaving directory '/tmp/cabal-tmp-2184/postgresql-libpq-0.9.4.2' Starting tagged-0.8.6 Building tagged-0.8.6 Completed random-1.1 Completed tagged-0.8.6 Completed primitive-0.6.4.0 Completed haskell-src-exts-1.21.0 cabal: Error: some packages failed to install: postgresql-libpq-0.9.4.2-HyacS45qPUc33pszxfYdpM failed during the configure step. The exception was: ExitFailure 1 postgresql-orm-0.5.1-KTokIP3mY29LRuS5PbBGAA depends on postgresql-orm-0.5.1 which failed to install. postgresql-simple-0.6-AUYYqF1Ip9i6KjeltQZU0G depends on postgresql-simple-0.6 which failed to install.