Skip to content

Commit 1cb71ac

Browse files
committed
Update example project to be simpler. No need for topkg and ocamlbuild
and ocamlfind. I mean you do need them but for the user they're just calling `rebuild`.
1 parent 5133b8f commit 1cb71ac

5 files changed

Lines changed: 12 additions & 31 deletions

File tree

Makefile

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
# topkg (https://github.com/dbuenzli/topkg) is a small native packager for your lib
2-
# http://erratique.ch/software/topkg/doc/Topkg.html#basics
1+
# This example project uses rebuild, which is a simple wrapper around
2+
# ocamlbuild.
3+
# Docs: https://github.com/ocaml/ocamlbuild/blob/master/manual/manual.adoc
4+
35
build:
4-
cp pkg/META.in pkg/META
5-
ocamlbuild -package topkg pkg/build.native
6-
./build.native build
6+
rebuild -use-ocamlfind src/index.native
77

88
# some boilerplate to publish a new version to GitHub
99
release:
@@ -14,6 +14,6 @@ release:
1414
git push "git@github.com:reasonml/ReasonNativeProject.git" tag $(version)
1515

1616
clean:
17-
ocamlbuild -clean
17+
rm -rf _build
1818

1919
.PHONY: build release

_tags

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,7 @@
11
<node_modules>: -traverse
2+
3+
4+
# To add opam dependencies you can comment out the line below and list however
5+
# many deps like: package(unix), package(lwt), package(whateverelse)
6+
#
7+
# true: package(unix)

pkg/META.in

Lines changed: 0 additions & 7 deletions
This file was deleted.

pkg/build.ml

Lines changed: 0 additions & 17 deletions
This file was deleted.

src/test.re renamed to src/index.re

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,3 @@ let msg = "Hello Reason!";
66
print_string msg;
77
print_newline ();
88
print_string "!!!!!!\n";
9-

0 commit comments

Comments
 (0)