install utop-full with access to compiler libraries

Ignore-this: 2612df285dd4900ca4eb4af08d5a4d93

darcs-hash:20120731150940-c41ad-2e08c11a1830ad058e1a856b31b2d74a87350dca
This commit is contained in:
Jeremie Dimino 2012-07-31 17:09:40 +02:00
parent 41e8b10e64
commit 09659b1dbe
3 changed files with 76 additions and 7 deletions

18
_oasis
View File

@ -65,6 +65,14 @@ Executable utop
BuildDepends: utop, findlib, lambda-term, lwt.syntax, threads BuildDepends: utop, findlib, lambda-term, lwt.syntax, threads
DataFiles: utop.el ($datadir/emacs/site-lisp) DataFiles: utop.el ($datadir/emacs/site-lisp)
Executable "utop-full"
Install: true
Path: src/top
CompiledObject: byte
MainIs: uTop_top_full.ml
BuildDepends: utop, findlib, lambda-term, lwt.syntax, threads
DataFiles: utop.el ($datadir/emacs/site-lisp)
# +-------------------------------------------------------------------+ # +-------------------------------------------------------------------+
# | Doc | # | Doc |
# +-------------------------------------------------------------------+ # +-------------------------------------------------------------------+
@ -93,6 +101,16 @@ Document "utop-man"
DataFiles: man/utop.1.gz DataFiles: man/utop.1.gz
InstallDir: $mandir/man1 InstallDir: $mandir/man1
Document "utop-full-man"
Type: custom (0.3)
Title: Man page for utop
Install: true
BuildTools: gzip
XCustom: $gzip -c man/utop-full.1 > man/utop-full.1.gz
XCustomClean: $rm man/utop-full.1.gz
DataFiles: man/utop-full.1.gz
InstallDir: $mandir/man1
Document "utoprc-man" Document "utoprc-man"
Type: custom (0.3) Type: custom (0.3)
Title: Man page for utoprc Title: Man page for utoprc

46
man/utop-full.1 Normal file
View File

@ -0,0 +1,46 @@
\" utop.1
\" ------
\" Copyright : (c) 2011, Jeremie Dimino <jeremie@dimino.org>
\" Licence : BSD3
\"
\" This file is a part of utop.
.TH UTOP-FULL 1 "August 2011"
.SH NAME
utop-full \- Universal toplevel for OCaml
.SH SYNOPSIS
.B utop
[
.I options
]
[
.I object-files
]
[
.I script-file
]
.SH DESCRIPTION
.B utop-full
is the same as
.B utop (1)
except that compiler libraries are available.
.SH OPTIONS
Same as
.BR utop (1).
.SH FILES
Same as
.BR utop (1).
.SH AUTHOR
Jérémie Dimino <jeremie@dimino.org>
.SH "SEE ALSO"
.BR utoprc (5),
.BR lambda-term-inputrc (5),
.BR ocaml (1).

View File

@ -54,9 +54,9 @@ let () =
(* Expunge compiler modules *) (* Expunge compiler modules *)
rule "toplevel expunge" rule "toplevel expunge"
~dep:"%.top" ~dep:"src/top/uTop_top.top"
~prod:"%.byte" ~prod:"src/top/uTop_top.byte"
(fun env _ -> (fun _ _ ->
(* Build the list of explicit dependencies. *) (* Build the list of explicit dependencies. *)
let packages = let packages =
Tags.fold Tags.fold
@ -65,7 +65,7 @@ let () =
String.after tag 4 :: packages String.after tag 4 :: packages
else else
packages) packages)
(tags_of_pathname (env "%.byte")) (tags_of_pathname "src/top/uTop_top.byte")
[] []
in in
(* Build the list of dependencies. *) (* Build the list of dependencies. *)
@ -93,8 +93,13 @@ let () =
let modules = StringSet.add "Toploop" modules in let modules = StringSet.add "Toploop" modules in
let modules = StringSet.add "Topmain" modules in let modules = StringSet.add "Topmain" modules in
Cmd (S [A (stdlib / "expunge"); Cmd (S [A (stdlib / "expunge");
A (env "%.top"); A "src/top/uTop_top.top";
A (env "%.byte"); A "src/top/uTop_top.byte";
A "UTop"; A "UTop_private"; S(List.map (fun x -> A x) (StringSet.elements modules))])) A "UTop"; A "UTop_private"; S(List.map (fun x -> A x) (StringSet.elements modules))]));
rule "full toplevel (not expunged)"
~dep:"src/top/uTop_top.top"
~prod:"src/top/uTop_top_full.byte"
(fun _ _ -> cp "src/top/uTop_top.top" "src/top/uTop_top_full.byte")
| _ -> | _ ->
()) ())