Skip to content

Commit

Permalink
Merge PR coq#18336: Split the Micromega library in two components.
Browse files Browse the repository at this point in the history
Reviewed-by: ejgallego
Ack-by: SkySkimmer
Co-authored-by: ejgallego <[email protected]>
  • Loading branch information
coqbot-app[bot] and ejgallego authored Jan 3, 2024
2 parents 0aab3e0 + 8986248 commit 0e4d060
Show file tree
Hide file tree
Showing 10 changed files with 20 additions and 5 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
overlay smtcoq https://github.com/SkySkimmer/smtcoq micromega-split-library 18336
1 change: 1 addition & 0 deletions lib/core_plugins_findlib_compat.ml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ let legacy_to_findlib = [
("derive_plugin", ["plugins";"derive"]) ;
("firstorder_plugin", ["plugins";"firstorder"]) ;
("ltac_plugin", ["plugins";"ltac"]) ;
("micromega_core_plugin", ["plugins";"micromega_core";]) ;
("micromega_plugin", ["plugins";"micromega"]) ;
("ring_plugin", ["plugins";"ring"]) ;
("ssr_plugin", ["plugins";"ssr"]) ;
Expand Down
16 changes: 12 additions & 4 deletions plugins/micromega/dune
Original file line number Diff line number Diff line change
@@ -1,18 +1,26 @@
(library
(name micromega_core_plugin)
(public_name coq-core.plugins.micromega_core)
(modules micromega numCompat mutils sos_types sos_lib sos)
(synopsis "Coq's micromega core plugin")
(libraries zarith coq-core.clib))

(library
(name micromega_plugin)
(public_name coq-core.plugins.micromega)
; be careful not to link the executable to the plugin!
(modules (:standard \ csdpcert g_zify zify))
(modules (:standard \ micromega numCompat mutils sos_types sos_lib sos csdpcert g_zify zify))
(flags :standard -open Micromega_core_plugin)
(synopsis "Coq's micromega plugin")
(libraries coq-core.plugins.ltac))
(libraries coq-core.plugins.ltac coq-core.plugins.micromega_core))

(executable
(name csdpcert)
(public_name csdpcert)
(package coq-core)
(modules csdpcert)
(flags :standard -open Micromega_plugin)
(libraries coq-core.plugins.micromega))
(flags :standard -open Micromega_core_plugin)
(libraries coq-core.plugins.micromega_core))

(library
(name zify_plugin)
Expand Down
Empty file.
1 change: 1 addition & 0 deletions test-suite/micromega/witness_tactics.v
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ Require Import ZArith QArith.
From Coq.micromega Require Import RingMicromega EnvRing Tauto.
From Coq.micromega Require Import ZMicromega QMicromega.

Declare ML Module "micromega_core_plugin:coq-core.plugins.micromega_core".
Declare ML Module "micromega_plugin:coq-core.plugins.micromega".

Goal True.
Expand Down
1 change: 1 addition & 0 deletions theories/micromega/Lia.v
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
Require Import ZMicromega RingMicromega VarMap DeclConstant.
Require Import BinNums.
Require Coq.micromega.Tauto.
Declare ML Module "micromega_core_plugin:coq-core.plugins.micromega_core".
Declare ML Module "micromega_plugin:coq-core.plugins.micromega".

Ltac zchecker :=
Expand Down
1 change: 1 addition & 0 deletions theories/micromega/Lqa.v
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ Require Import RingMicromega.
Require Import VarMap.
Require Import DeclConstant.
Require Coq.micromega.Tauto.
Declare ML Module "micromega_core_plugin:coq-core.plugins.micromega_core".
Declare ML Module "micromega_plugin:coq-core.plugins.micromega".

Ltac rchange :=
Expand Down
1 change: 1 addition & 0 deletions theories/micromega/Lra.v
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ Require Import RingMicromega.
Require Import VarMap.
Require Coq.micromega.Tauto.
Require Import Rregisternames.
Declare ML Module "micromega_core_plugin:coq-core.plugins.micromega_core".
Declare ML Module "micromega_plugin:coq-core.plugins.micromega".

Ltac rchange :=
Expand Down
1 change: 1 addition & 0 deletions theories/micromega/Psatz.v
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ Require Lia.
Require Lra.
Require Lqa.

Declare ML Module "micromega_core_plugin:coq-core.plugins.micromega_core".
Declare ML Module "micromega_plugin:coq-core.plugins.micromega".

Ltac lia := Lia.lia.
Expand Down
2 changes: 1 addition & 1 deletion tools/dune_rule_gen/coq_rules.ml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ module FlagUtil = struct
|> Util.list_concat_map (fun p -> [Arg.A "-I"; Arg.Path p])

let findlib_plugin_fixup p =
["number_string_notation"; "zify"; "tauto"; "ssreflect"]
["number_string_notation"; "zify"; "tauto"; "ssreflect"; "micromega_core"]
@ (List.filter (fun s -> not (String.equal s "syntax" || String.equal s "ssr")) p)

(* This can also go when the -I flags are gone, by passing the meta
Expand Down

0 comments on commit 0e4d060

Please sign in to comment.