Commit 32881636 authored by Guillaume Melquiond's avatar Guillaume Melquiond

Point Coq to Why3 realizations by adding a -R option inside its prover commands.

My first idea was to use "-R @libdir@/coq", or some other variable I would
have defined in configure.in, but it didn't work at all. Indeed, such path
variables depend on cascaded substitution, which work fine inside
make files and shell scripts, but not at all inside Why3 config files.
Note that this is a documented feature of Autoconf so I doubt there is any
way to circumvent it.

So I ended up adding a new format specifier inside call_provers: %l is
substituted by Config.libdir.
parent f796cd6d
...@@ -235,7 +235,7 @@ version_ok = "8.2pl1" ...@@ -235,7 +235,7 @@ version_ok = "8.2pl1"
version_ok = "8.2" version_ok = "8.2"
version_old = "8.1" version_old = "8.1"
version_old = "8.0" version_old = "8.0"
command = "@LOCALBIN@why3-cpulimit 0 %m -s %e -l %f" command = "@LOCALBIN@why3-cpulimit 0 %m -s %e -R %l/coq Why3 -l %f"
driver = "drivers/coq.drv" driver = "drivers/coq.drv"
editor = "coqide" editor = "coqide -R %l/coq Why3"
...@@ -129,6 +129,7 @@ let call_on_file ~command ?(timelimit=0) ?(memlimit=0) ...@@ -129,6 +129,7 @@ let call_on_file ~command ?(timelimit=0) ?(memlimit=0)
| "t" -> on_timelimit := true; string_of_int timelimit | "t" -> on_timelimit := true; string_of_int timelimit
| "m" -> string_of_int memlimit | "m" -> string_of_int memlimit
| "b" -> string_of_int (memlimit * 1024) | "b" -> string_of_int (memlimit * 1024)
| "l" -> Config.libdir
| _ -> failwith "unknown format specifier, use %%f, %%t, %%m or %%b" | _ -> failwith "unknown format specifier, use %%f, %%t, %%m or %%b"
in in
let subst s = let subst s =
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment