from scratch

This commit is contained in:
Julin Shaji 2024-01-09 10:50:22 +05:30
commit 98d83551f2
8 changed files with 65 additions and 0 deletions

5
_CoqProject Normal file
View File

@ -0,0 +1,5 @@
-R _build/default/theories MyPlugin
-I _build/default/src
# src/META.clash-extr
# -R theories/ Clashextr
# -I src

21
coq-my-plugin.opam Normal file
View File

@ -0,0 +1,21 @@
# This file is generated by dune, edit dune-project instead
opam-version: "2.0"
license: "Apache-2.0"
depends: [
"dune" {>= "3.6"}
"odoc" {with-doc}
]
build: [
["dune" "subst"] {dev}
[
"dune"
"build"
"-p"
name
"-j"
jobs
"@install"
"@runtest" {with-test}
"@doc" {with-doc}
]
]

8
dune-project Normal file
View File

@ -0,0 +1,8 @@
(lang dune 3.6)
(using coq 0.6)
(license Apache-2.0)
(generate_opam_files true)
(package
(name coq-my-plugin)
(allow_empty))

10
src/dune Normal file
View File

@ -0,0 +1,10 @@
; https://github.com/coq-community/coq-plugin-template/blob/v8.16/src/dune
(library
(name my_plugin)
(public_name coq-my-plugin.plugin)
(libraries
coq-core.vernac
coq-core.plugins.extraction))
(coq.pp (modules g_myplugin))

5
src/g_myplugin.mlg Normal file
View File

@ -0,0 +1,5 @@
DECLARE PLUGIN "coq-my-plugin.plugin"
{
}

1
theories/MyPlugin.v Normal file
View File

@ -0,0 +1 @@
Declare ML Module "my_plugin:coq-my-plugin.plugin".

2
theories/Test.v Normal file
View File

@ -0,0 +1,2 @@
Require Import MyPlugin.

13
theories/dune Normal file
View File

@ -0,0 +1,13 @@
; https://github.com/coq-community/coq-plugin-template/blob/v8.16/src/dune
(coq.theory
(name MyPlugin) ; This will determine the top-level Coq
; module of your theory, modules will
; be MyPlugin.A, etc., when seen from the
; outside.
(package coq-my-plugin)
(plugins coq-my-plugin.plugin)) ; Here you should declare all
; OCaml plugin dependencies
; for your Coq files.