Skip to content

Commit 9f98555

Browse files
authored
Merge pull request #98 from coq-community/rocq-bignums
Add rocq-bignums opam package
2 parents cc2d9ee + 7433022 commit 9f98555

File tree

4 files changed

+56
-17
lines changed

4 files changed

+56
-17
lines changed

.github/workflows/docker-action.yml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,15 +32,21 @@ jobs:
3232
opam_file: 'coq-bignums.opam'
3333
custom_image: ${{ matrix.image }}
3434
install: |
35-
startGroup "Install coq and dependencies"
35+
startGroup "Install"
3636
sudo apt-get update -y -q
3737
opam remove -y coq-bignums || true # remove coq-bignums if ever in image
3838
opam repository add --all-switches --set-default coq-extra-dev https://coq.inria.fr/opam/extra-dev # docker-coq
3939
opam repository add --all-switches --set-default coq-core-dev https://coq.inria.fr/opam/core-dev # docker-coq
4040
opam pin add -n -y -k version coq ${{ matrix.coq_version }} # docker-coq
41-
opam pin add -n -y -k path $PACKAGE.dev $WORKDIR
41+
opam pin add -n -y -k path rocq-bignums.dev $WORKDIR
42+
opam pin add -n -y -k path coq-bignums.dev $WORKDIR
4243
opam update -y
43-
opam install --confirm-level=unsafe-yes -j 2 $PACKAGE --deps-only
44+
opam install --confirm-level=unsafe-yes -j 2 rocq-bignums --ignore-constraints-on=dune
45+
opam install --confirm-level=unsafe-yes -j 2 coq-bignums --ignore-constraints-on=dune
46+
endGroup
47+
script: |
48+
startGroup "Post install"
49+
opam list
4450
endGroup
4551
export: 'OPAMWITHTEST'
4652
env:

coq-bignums.opam

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,10 @@ dev-repo: "git+https://github.com/coq-community/bignums.git"
77
bug-reports: "https://github.com/coq-community/bignums/issues"
88
license: "LGPL-2.1-only"
99

10-
synopsis: "Bignums, the Coq library of arbitrarily large numbers"
11-
description: """
12-
This Coq library provides BigN, BigZ, and BigQ that used to
13-
be part of the standard library."""
10+
synopsis: "Compatibility wrapper for rocq-bignums"
1411

15-
build: [make "-j%{jobs}%"]
16-
install: [
17-
[make "install"]
18-
[make "-C" "tests" "-j%{jobs}%"] {with-test}
19-
]
2012
depends: [
21-
"ocaml"
22-
"rocq-core" {= "dev"}
13+
"rocq-bignums" {= version}
2314
"coq-stdlib"
2415
]
2516

rocq-bignums.opam

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
opam-version: "2.0"
2+
maintainer: "[email protected]"
3+
version: "dev"
4+
5+
homepage: "https://github.com/coq-community/bignums"
6+
dev-repo: "git+https://github.com/coq-community/bignums.git"
7+
bug-reports: "https://github.com/coq-community/bignums/issues"
8+
license: "LGPL-2.1-only"
9+
10+
synopsis: "Bignums, the Rocq library of arbitrarily large numbers"
11+
description: """
12+
This Rocq library provides BigN, BigZ, and BigQ that used to
13+
be part of the standard library."""
14+
15+
build: [make "-j%{jobs}%"]
16+
install: [
17+
[make "install"]
18+
[make "-C" "tests" "-j%{jobs}%"] {with-test}
19+
]
20+
depends: [
21+
"ocaml"
22+
"rocq-core" {= "dev"}
23+
"rocq-stdlib"
24+
]
25+
26+
tags: [
27+
"category:Miscellaneous/Coq Extensions"
28+
"category:Mathematics/Arithmetic and Number Theory/Number theory"
29+
"category:Mathematics/Arithmetic and Number Theory/Rational numbers"
30+
"keyword:integer numbers"
31+
"keyword:rational numbers"
32+
"keyword:arithmetic"
33+
"keyword:arbitrary precision"
34+
"logpath:Bignums"
35+
]
36+
authors: [
37+
"Laurent Théry"
38+
"Benjamin Grégoire"
39+
"Arnaud Spiwack"
40+
"Evgeny Makarov"
41+
"Pierre Letouzey"
42+
]

tests/Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
COQC=coqc
1+
ROCQC=rocq c
22

33
all: success output
44

@@ -7,10 +7,10 @@ success: $(addsuffix o,$(wildcard success/*.v))
77
output: $(addsuffix o,$(wildcard output/*.v))
88

99
success/%.vo: success/%.v
10-
$(COQC) $<
10+
$(ROCQC) $<
1111

1212
output/%.vo: output/%.v
1313
input=$<; \
1414
output=$${input%.v}.out.real; \
15-
$(COQC) $< 2>&1 > $$output; \
15+
$(ROCQC) $< 2>&1 > $$output; \
1616
diff --strip-trailing-cr $${input%.v}.out $$output

0 commit comments

Comments
 (0)