|
Packit |
bd2e5d |
Installing LablTk from sources
|
|
Packit |
bd2e5d |
------------------------------
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
PREREQUISITES
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
* OCaml (>= 4.02) should be installed
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
* Tcl/Tk (>= 8.03) should be installed
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
INSTALLATION INSTRUCTIONS FOR UNIX AND OSX
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
1- Configure the system. From the top directory, do:
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
./configure
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
In case of success, this generates config/Makefile which contains the
|
|
Packit |
bd2e5d |
OCaml library path and compilation options.
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
The "configure" script accepts the following options:
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
-use-findlib
|
|
Packit |
bd2e5d |
If you want to use ocamlfind for installation.
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
-libdir <dir> (default: `ocamlc -where`)
|
|
Packit |
bd2e5d |
Directory where the OCaml library was installed,
|
|
Packit |
bd2e5d |
where Makefile.config can be found.
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
-installdir <dir> (default: libdir/labltk)
|
|
Packit |
bd2e5d |
-installbindir <dir> (default: same as ocamlc)
|
|
Packit |
bd2e5d |
Where to install the library and the labltk script.
|
|
Packit |
bd2e5d |
When using findlib, the default is taken from it.
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
-tkdefs <cpp flags> (default: none)
|
|
Packit |
bd2e5d |
-tklibs <flags and libraries> (default: determined automatically)
|
|
Packit |
bd2e5d |
These options specify where to find the Tcl/Tk libraries for
|
|
Packit |
bd2e5d |
LablTk. "-tkdefs" helps to find the headers, and "-tklibs"
|
|
Packit |
bd2e5d |
the C libraries. "-tklibs" may contain either only -L/path and
|
|
Packit |
bd2e5d |
-Wl,... flags, in which case the library names are determined
|
|
Packit |
bd2e5d |
automatically, or the actual libraries, which are used as given.
|
|
Packit |
bd2e5d |
Examples:
|
|
Packit |
bd2e5d |
for an OSX installation using macports, use just
|
|
Packit |
bd2e5d |
./configure -tklibs -L/opt/local/lib -tkdefs -I/opt/local/include
|
|
Packit |
bd2e5d |
for Japanese Tcl/Tk whose headers are in specific directories
|
|
Packit |
bd2e5d |
and libraries in /usr/local/lib, you can use
|
|
Packit |
bd2e5d |
./configure -tklibs "-L/usr/local/lib -ltk8.0jp -ltcl8.0jp"
|
|
Packit |
bd2e5d |
-tkdefs "-I/usr/local/include/tcl8.0jp -I/usr/local/include/tk8.0jp"
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
-tk-no-x11
|
|
Packit |
bd2e5d |
Build LablTk without using X11. This option is needed on
|
|
Packit |
bd2e5d |
Cygwin, or if you want to use the Quartz version on Tk on OSX.
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
-verbose
|
|
Packit |
bd2e5d |
Verbose output of the configuration tests. Use it if the outcome
|
|
Packit |
bd2e5d |
of configure is not what you were expecting.
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
2- From the top directory do
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
make all
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
and optionally
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
make opt
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
3- From the top directory do
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
make install
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
It will install labltk at the above defined location.
|
|
Packit |
bd2e5d |
You may need to become superuser first.
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
INSTALLATION INSTRUCTIONS FOR WINDOWS
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
1- In the config subdirectory, overwrite Makefile with the file
|
|
Packit |
bd2e5d |
corresponding to your system
|
|
Packit |
bd2e5d |
|
|
Packit |
bd2e5d |
2- Continue from step 2 above
|