Haskell make recipe fails for Paradox theorem prover using GHC

143 views Asked by At

I am trying to install the paradox theorem prover sourced from here.

When I run the makefile this is the command that runs: ghc -optl -static -lstdc++ -I../instantiate -I../minisat/current-base ../minisat/current-base/Solver.or ../minisat/current-base/Prop.or ../instantiate/MiniSatWrapper.or ../instantiate/MiniSatInstantiateClause.or -fglasgow-exts -O2 -static -threaded -main-is Paradox.Main.main --make Paradox.Main -o paradox

And it results in several errors like so:

Flags.hs:52:8:
    Could not find module ‘Char’
    Use -v to see a list of the files searched for.

for a variety of modules including but not limited to Char, CPUTime, IO.

The final error message is

Makefile:38: recipe for target 'paradox.exe' failed
make: *** [paradox.exe] Error 1

I don't know Haskell, nor am I very experienced with GNU make, but I am trying to install this package for a project and it is obscure enough to not be packaged for my OS (I'm running Arch Linux). As far as I know it is not packaged for any OS, so it is necessary to install from source.

As far as I can tell the problem starts with the following error message:

on the commandline: Warning: -fglasgow-exts is deprecated: Use individual extensions instead

I am using the version of the GHC provided in the Arch Linux package repository: package link

1

There are 1 answers

2
Reid Barton On BEST ANSWER

Looks like paradox was written for a rather old version of GHC. You can fix all these "Could not find module" errors by using GHC version 7.8 or older and setting

GHC     = ghc -hide-package base -package haskell98

in the Makefile, though you will likely encounter more errors after that.

The warning about -fglasgow-exts is mostly harmless, you can ignore it.