Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Port to jbuilder #444

Merged
merged 7 commits into from
May 11, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@ lib-http/irmin_http_static.ml
_build
*~
*.install
*.merlin
13 changes: 0 additions & 13 deletions .merlin

This file was deleted.

11 changes: 5 additions & 6 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,15 @@
language: c
install: wget https://raw.githubusercontent.com/ocaml/ocaml-travisci-skeleton/master/.travis-opam.sh
script: bash -ex .travis-opam.sh
sudo: required
env:
global:
- ALCOTEST_SHOW_ERRORS=1
- REVDEPS="irmin-indexeddb"
- PINS="irmin.dev:. irmin-http.dev:. irmin-git.dev:. irmin-mirage.dev:. irmin-unix.dev:."
- PINS="irmin.dev:. irmin-mem.dev:. irmin-fs.dev:. irmin-http.dev:. irmin-git.dev:. irmin-mirage.dev:. irmin-unix.dev:."
matrix:
- OCAML_VERSION=4.03 PACKAGE="irmin-unix.dev" TESTS=true EXTRA_DEPS=inotify
- OCAML_VERSION=4.03 PACKAGE="irmin-git.dev"
- OCAML_VERSION=4.03 PACKAGE="irmin-fs.dev" TESTS=true
- OCAML_VERSION=4.04 PACKAGE="irmin-mem.dev" TESTS=true
- OCAML_VERSION=4.03 PACKAGE="irmin-git.dev" TESTS=true
- OCAML_VERSION=4.04 PACKAGE="irmin-http.dev" TESTS=true
- OCAML_VERSION=4.03 PACKAGE="irmin-mirage.dev"
- OCAML_VERSION=4.04 PACKAGE="irmin-http.dev"
- OCAML_VERSION=4.04 PACKAGE="irmin-unix.dev" TESTS=true EXTRA_DEPS=inotify
- OCAML_VERSION=4.04 PACKAGE="irmin-mirage.dev"
49 changes: 24 additions & 25 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,36 +1,38 @@
BUILD=jbuilder build --dev
RUNTEST=jbuilder runtest -j 1

all:
$(MAKE) core
$(MAKE) git
$(MAKE) http
$(MAKE) mirage
$(MAKE) unix
$(BUILD)
$(RUNTEST)

core:
ocaml pkg/pkg.ml build -n irmin -q --tests true
ocaml pkg/pkg.ml test -n irmin
$(BUILD) -p irmin

mem:
$(BUILD) -p irmin-mem
$(RUNTEST) test/irmin-mem

fs:
$(BUILD) -p irmin-fs
$(RUNTEST) test/irmin-fs

git:
ocaml pkg/pkg.ml build -n irmin-git -q --tests true
ocaml pkg/pkg.ml test -n irmin-git
$(BUILD) -p irmin-git
$(RUNTEST) test/main_git

http:
ocaml pkg/pkg.ml build -n irmin-http -q --tests true
ocaml pkg/pkg.ml test -n irmin-http
$(BUILD) -p irmin-http
$(RUNTEST) test/main_http

mirage:
ocaml pkg/pkg.ml build -n irmin-mirage -q --tests true
ocaml pkg/pkg.ml test -n irmin-mirage
$(BUILD) -p irmin-mirage

unix:
ocaml pkg/pkg.ml build -n irmin-unix -q --tests true
ocaml pkg/pkg.ml test -n irmin-unix
$(BUILD) -p irmin-unix
$(RUNTEST) test/main_unix

clean:
ocaml pkg/pkg.ml clean -n irmin
ocaml pkg/pkg.ml clean -n irmin-git
ocaml pkg/pkg.ml clean -n irmin-http
ocaml pkg/pkg.ml clean -n irmin-mirage
ocaml pkg/pkg.ml clean -n irmin-unix
rm -rf _build

REPO=../opam-repository
PACKAGES=$(REPO)/packages
Expand All @@ -43,9 +45,6 @@ pkg-%:
rm -f $(PACKAGES)/$*/$*.opam
cd $(PACKAGES) && git add $*

PKGS=$(basename $(wildcard *.opam))
opam-pkg:
$(MAKE) pkg-irmin
$(MAKE) pkg-irmin-git
$(MAKE) pkg-irmin-http
$(MAKE) pkg-irmin-mirage
$(MAKE) pkg-irmin-unix
$(MAKE) $(PKGS:%=pkg-%)
24 changes: 0 additions & 24 deletions _tags

This file was deleted.

1 change: 1 addition & 0 deletions irmin-fs.descr
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Generic file-system backend for Irmin
19 changes: 19 additions & 0 deletions irmin-fs.opam
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
opam-version: "1.2"
maintainer: "[email protected]"
authors: ["Thomas Gazagnaire" "Thomas Leonard"]
license: "ISC"
homepage: "https://github.com/mirage/irmin"
bug-reports: "https://github.com/mirage/irmin/issues"
dev-repo: "https://github.com/mirage/irmin.git"
doc: "https://mirage.github.io/irmin/"

build: ["jbuilder" "build" "-p" name "-j" jobs]
build-test: ["jbuilder" "runtest" "test/irmin-fs"]

depends: [
"jbuilder" {build}
"irmin" {>= "1.2.0"}
"alcotest" {test}
"mtime" {test & < "1.0.0"}
]
available: [ocaml-version >= "4.03.0"]
16 changes: 5 additions & 11 deletions irmin-git.opam
Original file line number Diff line number Diff line change
Expand Up @@ -7,19 +7,13 @@ bug-reports: "https://github.com/mirage/irmin/issues"
dev-repo: "https://github.com/mirage/irmin.git"
doc: "https://mirage.github.io/irmin/"

build: ["ocaml" "pkg/pkg.ml" "build" "--pinned" "%{pinned}%" "-n" name]

build-test: [
["ocaml" "pkg/pkg.ml" "build" "--pinned" "%{pinned}%" "-n" name "--tests" "true"]
["ocaml" "pkg/pkg.ml" "test" "-n" name]
]
build: ["jbuilder" "build" "-p" name "-j" jobs]
build-test: ["jbuilder" "runtest" "test/irmin-git"]

depends: [
"ocamlbuild" {build}
"ocamlfind" {build}
"topkg" {build & >= "0.9.0"}
"irmin" {>= "1.1.0"}
"git" {>= "1.10.0"}
"jbuilder" {build}
"irmin" {>= "1.1.0"}
"git" {>= "1.10.0"}
"alcotest" {test}
"git-unix" {test & >= "1.10.0"}
]
Expand Down
12 changes: 3 additions & 9 deletions irmin-http.opam
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,11 @@ bug-reports: "https://github.com/mirage/irmin/issues"
dev-repo: "https://github.com/mirage/irmin.git"
doc: "https://mirage.github.io/irmin/"

build:
["ocaml" "pkg/pkg.ml" "build" "--pinned" "%{pinned}%" "-n" name "--tests" "false"]
build: ["jbuilder" "build" "-p" name "-j" jobs]
build-test: ["jbuilder" "runtest" "test/irmin-mem"]

build-test: [
["ocaml" "pkg/pkg.ml" "build" "--pinned" "%{pinned}%" "-n" name "--tests" "true"]
["ocaml" "pkg/pkg.ml" "test" "-n" name]
]
depends: [
"ocamlbuild" {build}
"ocamlfind" {build}
"topkg" {build & >= "0.9.0"}
"jbuilder" {build}
"crunch"
"webmachine" {>= "0.3.2"}
"irmin" {>= "1.0.0"}
Expand Down
1 change: 1 addition & 0 deletions irmin-mem.descr
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
In-memory backend for Irmin
19 changes: 19 additions & 0 deletions irmin-mem.opam
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
opam-version: "1.2"
maintainer: "[email protected]"
authors: ["Thomas Gazagnaire" "Thomas Leonard"]
license: "ISC"
homepage: "https://github.com/mirage/irmin"
bug-reports: "https://github.com/mirage/irmin/issues"
dev-repo: "https://github.com/mirage/irmin.git"
doc: "https://mirage.github.io/irmin/"

build: ["jbuilder" "build" "-p" name "-j" jobs]
build-test: ["jbuilder" "runtest" "test/irmin-mem"]

depends: [
"jbuilder" {build}
"irmin" {>= "1.2.0"}
"alcotest" {test}
"mtime" {test & < "1.0.0"}
]
available: [ocaml-version >= "4.03.0"]
11 changes: 5 additions & 6 deletions irmin-mirage.opam
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,13 @@ homepage: "https://github.com/mirage/irmin"
bug-reports: "https://github.com/mirage/irmin/issues"
dev-repo: "https://github.com/mirage/irmin.git"

build: ["ocaml" "pkg/pkg.ml" "build" "--pinned" "%{pinned}%" "-n" name]
build: ["jbuilder" "build" "-p" name "-j" jobs]

depends: [
"ocamlbuild" {build}
"ocamlfind" {build}
"topkg" {build & >= "0.9.0"}
"irmin" {>= "1.0.0"}
"irmin-git" {>= "1.0.0"}
"jbuilder" {build}
"irmin" {>= "1.1.0"}
"irmin-git" {>= "1.1.0"}
"irmin-mem" {>= "1.2.0"}
"git-mirage" {>= "1.10.0"}
"ptime"
"mirage-kv-lwt"
Expand Down
16 changes: 5 additions & 11 deletions irmin-unix.opam
Original file line number Diff line number Diff line change
Expand Up @@ -7,21 +7,15 @@ bug-reports: "https://github.com/mirage/irmin/issues"
dev-repo: "https://github.com/mirage/irmin.git"
doc: "https://mirage.github.io/irmin/"

build: [
"ocaml" "pkg/pkg.ml" "build" "--pinned" "%{pinned}%" "-n" name "--tests" "false"
]
build-test: [
["ocaml" "pkg/pkg.ml" "build" "--pinned" "%{pinned}%" "-n" name "--tests" "true"]
["ocaml" "pkg/pkg.ml" "test" "-n" name]
]
build: ["jbuilder" "build" "-p" name "-j" jobs]
build-test: ["jbuilder" "runtest" "test/irmin-mem"]

depends: [
"ocamlbuild" {build}
"ocamlfind" {build}
"topkg" {build & >= "0.9.0"}
"jbuilder" {build}
"irmin" {>= "1.1.0"}
"irmin-git" {>= "1.1.0"}
"irmin-http" {>= "1.0.0"}
"irmin-http" {>= "1.1.0"}
"irmin-fs" {>= "1.2.0"}
"git-unix" {>= "1.10.0"}
"irmin-watcher" {>= "0.2.0"}
"irmin-mirage" {test & >= "1.0.0"}
Expand Down
24 changes: 8 additions & 16 deletions irmin.opam
Original file line number Diff line number Diff line change
Expand Up @@ -7,27 +7,19 @@ bug-reports: "https://github.com/mirage/irmin/issues"
dev-repo: "https://github.com/mirage/irmin.git"
doc: "https://mirage.github.io/irmin/"

build:
["ocaml" "pkg/pkg.ml" "build" "--pinned" "%{pinned}%" "-n" name "--tests" "false"]

build-test: [
["ocaml" "pkg/pkg.ml" "build" "--pinned" "%{pinned}%" "-n" name "--tests" "true"]
["ocaml" "pkg/pkg.ml" "test" "-n" name]
]
build: ["jbuilder" "build" "-p" name "-j" jobs]

depends: [
"ocamlbuild" {build}
"ocamlfind" {build}
"topkg" {build & >= "0.9.0"}
"jbuilder" {build}
"result"
"fmt"
"ocamlgraph"
"lwt" {>= "2.4.7"}
"logs" {>= "0.5.0"}
"uri" {>= "1.3.12"}
"cstruct" {>= "1.6.0"}
"jsonm" {>= "1.0.0"}
"uri" {>= "1.3.12"}
"astring"
"lwt" {>= "2.4.7"}
"ocamlgraph"
"hex"
"alcotest" {test}
"logs" {>= "0.5.0"}
"astring"
]
available: [ocaml-version >= "4.03.0"]
Loading