Skip to content
Tcl Source Code Changes To Embedding Support
Login

Changes To Embedding Support

Changes to "Embedding Support" between 2014-09-03 10:35:43 and 2014-09-03 10:37:43

︙
52
53
54
55
56
57
58

59
60
61


62
63
64


65
66
67
68
69
70
71
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66

67
68
69
70
71
72
73
74
75







+



+
+


-
+
+







  *  Adds  [/finfo?name=generic/tclZipVfs.c|tclZipVfs.c]
  *  Modifies [/finfo?name=unix/tclAppInit.c|tclAppInit.c]
  *  Modifies [/finfo?name=win/tclAppInit.c|tclAppInit.c]

To build a self-contained executable:
<verbatim>
cp tclsh mynewkit
# Build an empty zipfile and concat it to the executable
touch .empty
zip null.zip .empty
cat null.zip >> mynewkit
#
echo "puts {hello world}" > main.tcl
zip -A mynewkit main.tcl
./mynewkit
(Launches using the code embedded in main.tcl)
hello world
(Program exit)
</verbatim>

<h1>Discussion</h1>

This has been considered a single module, but tclPanic.c is essentially a self contained
bit without dependencies, while tclMain.c depends on nearly everything.  Most other parts
of Tcl that claim a dependence on this module are really just callers of <b>Tcl_Panic</b>.
︙