-
Notifications
You must be signed in to change notification settings - Fork 0
/
INSTALL
300 lines (243 loc) · 12 KB
/
INSTALL
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
(***********************************************************************)
(* *)
(* EFUNS PACKAGE *)
(* *)
(* Fabrice Le Fessant, projet Para/SOR, INRIA Rocquencourt *)
(* *)
(* Copyright 1999 Institut National de Recherche en Informatique et *)
(* Automatique. Distributed only by permission. *)
(* *)
(***********************************************************************)
|-----------------|
| RELEASE NOTES |
|-----------------|
I'm pleased to release the new version 017 of the Efuns package.
The Efuns package contains:
- The Xlib library for Ocaml (complete emulation of the C Xlib library)
- The Dynlink library for native code (allow you to dynamically load
cmo files in native programs).
- The Toplevel library (allow you to evaluate ocaml expressions inside
any program as in the toplevel).
- The Gwml Generic Window-Manager (a wm configurable in Ocaml).
- The Efuns Emacs clone editor (an editor configurable in Ocaml).
- The wXtoolkit (a toolkit of widgets based on Xlib)
Changes:
The BIG change in this new release is the almost complete configurability
of efuns and gwml using a .efunsrc and .gwmlrc file with very simple syntax
to define many options (colors, fonts, key bindings, gwml decorations, efuns
abbreviations, etc ... ) Each file is created the first time the
corresponding program is run, and options can be modified and saved from the
program.
In GwML, you can now use images, load themes from WindowMaker or Afterstep, and
add funny decorations to your windows (try the /usr/local/share/GwML/... decos).
The package is available on:
http://pauillac.inria.fr/para/cdrom/prog/unix/efuns
Mailing-lists:
Note: I use Efuns for editing my Ocaml files every day, and Gwml as my
current window-manager. These programs can be improved a lot. Just try
it. I'm available to help everyone wanting to use or improve these
libraries and programs.
|----------------|
| REQUIREMENTS |
|----------------|
You need Objective-Caml installed, at least version 2.01.
This package was released for Objective-Caml 2.04. For later versions,
you may check at the URL specified in the RELEASE NOTES.
To compile GwML with image support, you need to have Imlib installed.
This is normally done on Linux systems where Gnome is installed, but you can also
download it from ftp.gnome.org.
|----------------|
| INSTALLATION |
|----------------|
1. Execute the ./configure script. Default options values for this script are
in .cache.default . When an option has been set once, other calls to
configure will keep this option, unless you specify a new value or remove
the .cache file.
-srcdir: Where the sources of Ocaml are. This is only required if you want to
compile the Toplevel library. This automatically forces Efuns and GwML to
use the toplevel library.
-help: all options.
-prefix: set the directory prefix (/usr,/usr/local,~/local, etc ...)
for the installation.
-libdir: directory where Ocaml is installed, and where some libraries
will be installed. This directory is found automatically using "ocamlc -v".
-bindir: directory where "efuns" and "gwml" executables will be installed.
(def: /usr/local/bin)
-efunsdir: directory where Efuns files will be installed
(def: /usr/local/lib/efuns)
-gwmldir: directory where Gwml files will be installed
(def: /usr/local/lib/gwml)
-byte_threads: should the bytecode version use threads (safe is not).
-opt_threads: should the native code version usr threads (safe is not).
-efunsdyn: Which library should be used to build Efuns (dynlink or toplevel).
-gwmldyn: Which library should be used to build Gwml (dynlink or toplevel).
The configure script will verify your version of Ocaml, and create some
links in some directories.
2. Build dependencies: "make depend" (done automatically by the
configure script).
3. Compile in bytecode: "make byte"
4. Compile in native code: "make opt" (or "make all" for byte and opt)
5. Install the bytecode version: "make install"
6. Install the native version: "make installopt"
7. cd gwml; make install-themes
|-----------------|
| CONFIGURATION |
|-----------------|
Normally, sources are installed in the $PREFIX/lib/gwml and
$PREFIX/lib/efuns directories, so that you can modify these files, and
compile them again (using "gwml -c" or "efuns -c" to avoid clashes between
the versions of ocaml currently installed and the one used to compile the
package.
GwML is configured by modifying the gwmlrc.ml file, and recompiling it
(in your own .gwml-$(VERSION)) directory (.gwml-16+1 for example). You can
also modify the ~/.gwmlrc.ml file (without recompiling), but you cannot
change a lot of things that way.
Efuns is configured by modifying the efunsrc.ml file, and recompiling it.
GwML can also be configured by modifying the .Xdefaults (see doc/gwml.tex)
or the ~/.gwmlrc created the first time it is started.
|-----------------|
| DOCUMENTATION |
|-----------------|
For now, few documentation is provided in the doc/ directory. The best way
(for now) to learn how to use them is to look at the sources. In particular,
efuns/xlib/examples and efuns/toolkit/examples contain several demos of Xlib
and WXlib applications. You can also send e-mails to:
You can also subscribe to these mailing-lists by sending a mail to:
with the names of the list to which you want to subscribe or unsubscribe.
These lists are not moderated, thus, if you notice some spams, send a mail to
the previous address and the list will become moderated.
In the doc/ directory, you can find documentation for:
- Efuns: ProGuide.txt et efuns-users-help.txt
- Gwml: gwml.tex (use "make gwml.ps" to create the postscript version).
- wXlib: wxlib.tex (use "make wxlib.ps" to create the postscript version).
- xlib: encoding.txt et proto.txt (for the X protocol).
Here is a small documentation for all libraries and programs:
* Xlib:
=======
This library is an implementation of the C Xlib in Objective-Caml.
This library doesn't use any C code. It performs all the operations
in Objective-Caml (TCP connection with the server, translation of
requests into X protocol packets, translation of reply/events packets
to Ocaml events). All useful types are in the Xtypes module.
X protocol requests are in the X module, while other useful functions
are in the Xlib module. Other modules are more specialized (Icccm for ICCCM
compliance, XA for atoms, XC for cursors, XK for keysyms, Shape for the
shape extension, Xpm for pixmaps, Xrm for ressources, Zpixmap for
Zpixmap images, Xtext for text functions, KeyBind for Key functions).
In extension, it contains a Graphics module providing the same interface
as the Graphics module of the standard library. Thus, programs designed
for this library are allowed to use all X powerful functions.
All useful types are in xlib/xtypes.ml. Useful constants are in
xlib/xtypes.ml, xlib/xA.ml (atoms), xlib/xK.ml (keysyms) and xC.ml
(cursors).. The X protocol is implemented in three modules: X (calls with
replies are synchronous, calls with no reply are asynchronous), Xsync (all
calls are synchronous, and errors are raised immediately), and Xasync (all
calls are asynchronous, and tokens(Jeton.t) are given to retrieve results and
errors later).
Functions names are quite similar to the C functions. For example,
XCreateWindow -> X.createWindow (or Xsync or Xasync). Parameters may appear
in different orders (have a look at xlib/x.mli for their exact types, or
xlib/x.ml for their meanings).
Other useful functions are implemented in other modules, such as Xlib
(openDisplay, nextEvent, ...), Xutils (raiseWindow, textExtents, ...), Xrm
(ressources management), Xpm (pixmaps and bitmaps), Shape (shape extension),
XA (atoms), XC (Cursors) and XK (keysyms), KeyBind (lookupString,
keycodeToKeysym, ...) and Icccm (ICCCM protocol).
* AsmDynlink:
=============
This library provide the same functionnalities as
the bytecode version (ie to load bytecode modules in executables),
and has the same interface. The library contains an interpreter for
Ocaml bytecode and a linker. It is about 3/4 times slower than the
C interpreter.
* Efuns:
========
A clone of Emacs with lot of key bindings (C-h K) and several
editing modes (tex_mode, ocaml_mode, makefile_mode, etc ...). Try it by
editing efuns/simple.ml for example.
Usage: efuns -help
Efuns always tries to load "efunsrc.cmo" at startup. This file is searched
in the following path $HOME:$HOME/.efuns/:$CAMLDIR:$EFUNSPATH where CAMLDIR
is an envirronment variable for the Objective Caml installation directory and
EFUNSPATH an envirronment variable for a path to find Efuns files.
* Gwml:
=======
Gwml is a window-manager, inspired from GWM, the Generic Window Manager. It
is configurable in Ocaml Have a look at gwml/config/gwmlrc.ml for my config
(based on the Std*.ml default config). You can even do a "make" in
gwml/config to install this config in ~/.gwml-???. GwML starts by loading the
gwmlrc.cmo file in ~/.gwml-??? where ??? is the version (016 for example).
* Toplevel:
===========
A library to evaluate ocaml strings in a program (even native).
Look at toplevel/dyneval.mli for its interface. (Note that the dynlink
library is included in the toplevel library). To try it, build Gwml with
GWML_DYNLINK=toplevel and try "gwml -talk".
|--------------|
| KNOWN BUGS |
|--------------|
* Xlib
1. Shape extension not tested yet.
* Efuns
1. Bad indentation of function call parameters in Ocaml mode.
2. A second cursor can appear on a frame (use M-x to remove it).
3. Selection by mouse is difficult when scrolling is used or for
multiple lines line.
* Gwml
1. Wobs borderwidths are not taken into account.
2. Shaped windows are not well decorated.
3. If a menu is present when a new window is created, it stays on screen
(click on it with a button to destroy it)
4. Imlib uses a different connection to the X server. This means that,
if the server is grabbed, any call to Imlib will be blocked.
* WXlib
1. Not multithreaded
* Dynlink:
1. C functions must be added through the
Linker.Prims.insert_one: string -> ('a -> 'b) -> unit
function, which doesn't exist on the bytecode version.
(we should ask ocamlopt to generate the same table as ocamlc).
* Toplevel:
1. Segfault when running ocamlc (modules of ocamlc are loaded
dynamically) on big files (> 100Kb).
|-------------|
| TODO LIST |
|-------------|
* Efuns:
1. Add "print-buffer" function, and maybe a dialog box for configuration ?
2. Add minor mode "flyspell"
3. Simplify the use of local variables:
3.1 Add local variables to modes:
Search sort: buffer, minor modes, major mode, location
3.2 Add new functions to modify or print variable values:
set-local-variable (current buffer)
set-<minor-mode>-variable (minor modes, all buffers)
set-major-variable (major modes, all buffers)
set-global-variable (all buffers)
3.3 Set local variables from buffer comments when buffer is loaded.
EFUNS_START
set-local variable value;
add-local variable value;
EFUNS_END
3.4 Set local variable from files in the filesystem tree:
.efuns_vars (in local directory or parents with depth load-vars-depth)
* Gwml
1. Use WXlib widgets instead of proprietary widgets
|-------------------------------|
| PROBLEMS/ COMMENTS/ CONTACT |
|-------------------------------|
See the DOCUMENTATION section for mailing-lists. You can also directly send
a mail to:
Fabrice LE FESSANT
Moscova/Para/Sor Projects
INRIA Rocquencourt, FRANCE
Email: [email protected]
http://pauillac.inria.fr/~lefessan
http://pauillac.inria.fr/efuns
http://pauillac.inria.fr/gwml
http://pauillac.inria.fr/~lefessan/src