diff options
| -rw-r--r-- | Makefile | 3 | ||||
| -rw-r--r-- | scripts/coqmktop.ml | 11 |
2 files changed, 8 insertions, 6 deletions
@@ -405,7 +405,8 @@ $(COQMKTOP): $(COQMKTOPCMO) scripts/tolink.ml: Makefile $(SHOW)"ECHO... >" $@ - $(HIDE)echo "let core_libs = \""$(LIBCOQRUN) $(LINKCMO)"\"" > $@ + $(HIDE)echo "let copts = \"-cclib -lcoqrun\"" > $@ + $(HIDE)echo "let core_libs = \""$(LINKCMO)"\"" >> $@ $(HIDE)echo "let core_objs = \""$(OBJSCMO)"\"" >> $@ $(HIDE)echo "let ide = \""$(COQIDECMO)"\"" >> $@ diff --git a/scripts/coqmktop.ml b/scripts/coqmktop.ml index 632c3ebd6e..29defb5c2d 100644 --- a/scripts/coqmktop.ml +++ b/scripts/coqmktop.ml @@ -25,10 +25,10 @@ let libobjs = ocamlobjs @ camlp4objs let spaces = Str.regexp "[ \t\n]+" let split_list l = Str.split spaces l -let ide = split_list Tolink.ide - +let copts = split_list Tolink.copts let core_objs = split_list Tolink.core_objs let core_libs = split_list Tolink.core_libs +let ide = split_list Tolink.ide (* 3. Toplevel objects *) let camlp4topobjs = @@ -50,7 +50,7 @@ let coqide = ref false let echo = ref false let src_dirs () = - [ []; [ "config" ]; [ "toplevel" ] ] @ + [ []; ["kernel";"byterun"]; [ "config" ]; [ "toplevel" ] ] @ if !coqide then [[ "ide" ]] else [] let includes () = @@ -299,11 +299,12 @@ let main () = (* the list of the loaded modules *) let main_file = create_tmp_main_file modules in try - let args = options @ (includes ()) @ tolink @ dynlink @ [ main_file ] in + let args = + options @ (includes ()) @ copts @ tolink @ dynlink @ [ main_file ] in (* add topstart.cmo explicitly because we shunted ocamlmktop wrapper *) let args = if !top then args @ [ "topstart.cmo" ] else args in (* Now, with the .cma, we MUST use the -linkall option *) - let command = String.concat " " ((prog^" -linkall")::args) in + let command = String.concat " " (prog::args) in if !echo then begin print_endline command; |
