Skip to content

Commit 407a64e

Browse files
committed
Toplevel: deriving is optional
1 parent d430380 commit 407a64e

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

toplevel/Makefile

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ all: toplevel.js eval.js
66

77
OCPINDENT=$(shell ocamlfind query ocp-indent -format "-package %p.lib" 2> /dev/null)
88
HIGLO=$(shell ocamlfind query higlo.ocaml -format "-package %p -rectypes" 2> /dev/null)
9+
DERIVING=$(shell ocamlfind query js_of_ocaml.deriving -format "%p" 2> /dev/null)
910

1011
CPPO_OPT=
1112
ifneq ($(OCPINDENT),)
@@ -16,19 +17,20 @@ ifneq ($(HIGLO),)
1617
CPPO_OPT+= -D higlo
1718
endif
1819

20+
ifneq ($(DERIVING),)
21+
DERIVING_SYNTAX = js_of_ocaml.deriving.syntax deriving.syntax.std
22+
endif
23+
1924
ifneq ($(NO_SYNTAXES),1)
20-
SYNTAXES= lwt.syntax \
21-
js_of_ocaml.syntax \
22-
js_of_ocaml.deriving.syntax deriving.syntax.std
25+
SYNTAXES= lwt.syntax js_of_ocaml.syntax $(DERIVING_SYNTAX)
2326
endif
2427

2528
JSFILES= +weak.js +toplevel.js +dynlink.js +nat.js
2629

2730
PACKAGES= \
2831
lwt bigarray tyxml.functor \
2932
react reactiveData \
30-
js_of_ocaml \
31-
js_of_ocaml.deriving \
33+
js_of_ocaml $(DERIVING) \
3234
js_of_ocaml.tyxml \
3335
js_of_ocaml.toplevel \
3436
dynlink

0 commit comments

Comments
 (0)