aboutsummaryrefslogtreecommitdiff
path: root/Makefile.common
diff options
context:
space:
mode:
authorletouzey2009-02-20 13:39:46 +0000
committerletouzey2009-02-20 13:39:46 +0000
commit7529f1422c794837b0beb0066ad5ef79ce798e86 (patch)
tree491752c8c5d7839756696ee8f972ade76fe13737 /Makefile.common
parente653b53692e2cc0bb4f84881b32d3242ea39be86 (diff)
coq-interface and coq-parser can be calls to coqtop with adequate code dynlink
From files in contrib/interface, we create (if natdynlink is available) two plugins named coqinterface_plugin.{cma,cmxs} and coqparser_plugin.{cma,cmxs}. These plugins are loaded respectively by CoqInterface.v and CoqParser.v. So coq-interface can be "coqtop -require CoqInterface", and coq-parser can be "coqtop -batch -l CoqParser" (this one cannot be compiled into a .vo, otherwise a customized toplevel is launched during the compilation). Turing coq-interface and coq-parser and their .opt versions into shell scripts allow to spare around 40 Mb of disk space... Nota: at dynlink, parse.ml was conflicting with the module Parse of the ocaml runtime, so I renamed it into coqparser.ml git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@11940 85f007b7-540e-0410-9357-904b9bb8a0f7
Diffstat (limited to 'Makefile.common')
-rw-r--r--Makefile.common17
1 files changed, 13 insertions, 4 deletions
diff --git a/Makefile.common b/Makefile.common
index d5fa289932..920df2d2b5 100644
--- a/Makefile.common
+++ b/Makefile.common
@@ -418,18 +418,23 @@ INTERFACECMX:=$(INTERFACE:.cmo=.cmx)
PARSERREQUIRES:=$(LINKCMO) $(LIBCOQRUN) # Solution de facilité...
PARSERREQUIRESCMX:=$(LINKCMX)
+COQINTERFACE:=bin/coq-interface$(EXE) bin/coq-parser$(EXE)
ifeq ($(BEST),opt)
- COQINTERFACE:=bin/coq-interface$(EXE) bin/coq-interface.opt$(EXE) bin/coq-parser$(EXE) bin/coq-parser.opt$(EXE)
-else
- COQINTERFACE:=bin/coq-interface$(EXE) bin/coq-parser$(EXE)
+ifeq ($(HASNATDYNLINK),false)
+ COQINTERFACE:=$(COQINTERFACE) bin/coq-interface.opt$(EXE) bin/coq-parser.opt$(EXE)
+endif
endif
PARSERCODE:=contrib/interface/line_parser.cmo contrib/interface/vtp.cmo \
- contrib/interface/xlate.cmo contrib/interface/parse.cmo
+ contrib/interface/xlate.cmo contrib/interface/coqparser.cmo
PARSERCMO:=$(PARSERREQUIRES) $(PARSERCODE)
PARSERCMX:= $(PARSERREQUIRESCMX) $(PARSERCODE:.cmo=.cmx)
+ifneq ($(HASNATDYNLINK),false)
INTERFACERC:= contrib/interface/vernacrc
+else
+INTERFACERC:= contrib/interface/vernacrc contrib/interface/CoqParser.v
+endif
CSDPCERTCMO:= contrib/micromega/mutils.cmo contrib/micromega/micromega.cmo \
contrib/micromega/mfourier.cmo contrib/micromega/certificate.cmo \
@@ -868,7 +873,11 @@ LIBFILESLIGHT:=$(THEORIESLIGHTVO)
## Specials
+ifneq ($(HASNATDYNLINK),false)
+INTERFACEVO:=contrib/interface/CoqInterface.vo
+else
INTERFACEVO:=
+endif
MANPAGES:=man/coq-tex.1 man/coqdep.1 man/gallina.1 \