The tclcompile
package implements commands to compile Tcl scripts into the
Tcl's internal byte code form. The generated files can be loaded into a Tcl
application using the companion
tbcload package.
As basic usage example, evaluating the following in a Tcl shell
will generate a hello.tbc
file containing the byte code for the
Tcl script in hello.tcl
.
package require tclcompiler
compiler::compile hello.tcl
For detailed usage, limitations and other information, see the Chapter 6 of the TclPro User's Guide. Although dated, most of the information there is still applicable.
The package supports Tcl 8.6 and Tcl 9.0. However, files compiled for Tcl 8
cannot be loaded into a Tcl 9 interpreter with tbcload
and vice versa.
Copyright (c) 1999-2000 Ajuba Solutions
Copyright (c) 2018 ActiveState Software Inc.
Released under the BSD-3 license. See LICENSE file for details.