2
'\" Generated from file '/home/aku/Projects/Packages/Critcl/dev-master/embedded/man/files/critcl_devguide\&.n' by tcllib/doctools with format 'nroff'
3
'\" Copyright (c) Jean-Claude Wippler
4
'\" Copyright (c) Steve Landers
5
'\" Copyright (c) 2011-2013 Andreas Kupries
7
'\" The definitions below are for supplemental macros used in Tcl/Tk
10
'\" .AP type name in/out ?indent?
11
'\" Start paragraph describing an argument to a library procedure.
12
'\" type is type of argument (int, etc.), in/out is either "in", "out",
13
'\" or "in/out" to describe whether procedure reads or modifies arg,
14
'\" and indent is equivalent to second arg of .IP (shouldn't ever be
15
'\" needed; use .AS below instead)
18
'\" Give maximum sizes of arguments for setting tab stops. Type and
19
'\" name are examples of largest possible arguments that will be passed
20
'\" to .AP later. If args are omitted, default tab stops are used.
23
'\" Start box enclosure. From here until next .BE, everything will be
24
'\" enclosed in one large box.
27
'\" End of box enclosure.
30
'\" Begin code excerpt.
35
'\" .VS ?version? ?br?
36
'\" Begin vertical sidebar, for use in marking newly-changed parts
37
'\" of man pages. The first argument is ignored and used for recording
38
'\" the version when the .VS was added, so that the sidebars can be
39
'\" found and removed when they reach a certain age. If another argument
40
'\" is present, then a line break is forced before starting the sidebar.
43
'\" End of vertical sidebar.
46
'\" Begin an indented unfilled display.
49
'\" End of indented unfilled display.
52
'\" Start of list of standard options for a Tk widget. The
53
'\" options follow on successive lines, in four columns separated
57
'\" End of list of standard options for a Tk widget.
59
'\" .OP cmdName dbName dbClass
60
'\" Start of description of a specific option. cmdName gives the
61
'\" option's name as specified in the class command, dbName gives
62
'\" the option's name in the option database, and dbClass gives
63
'\" the option's class in the option database.
66
'\" Print arg1 underlined, then print arg2 normally.
68
'\" RCS: @(#) $Id: man.macros,v 1.1 2009/01/30 04:56:47 andreas_kupries Exp $
70
'\" # Set up traps and other miscellaneous stuff for Tcl/Tk man pages.
74
'\" # Start an argument description
78
. ie !"\\$2"" .TP \\n()Cu
83
\&\\$1 \\fI\\$2\\fP (\\$3)
96
'\" # define tabbing values for .AP
99
.if !"\\$1"" .nr )A \\w'\\$1'u+3n
102
.if !"\\$2"" .nr )B \\w'\\$2'u+\\n()Au+3n
103
.nr )C \\n()Bu+\\w'(in/out)'u+2n
105
.AS Tcl_Interp Tcl_CreateInterp in/out
106
'\" # BS - start boxed text
107
'\" # ^y = starting y location
115
.if n \l'\\n(.lu\(ul'
118
'\" # BE - end boxed text (draw box now)
123
.ie n \l'\\n(^lu\(ul'
125
.\" Draw four-sided box normally, but don't draw top of
126
.\" box if the box started on an earlier page.
128
\h'-1.5n'\L'|\\n(^yu-1v'\l'\\n(^lu+3n\(ul'\L'\\n(^tu+1v-\\n(^yu'\l'|0u-1.5n\(ul'
131
\h'-1.5n'\L'|\\n(^yu-1v'\h'\\n(^lu+3n'\L'\\n(^tu+1v-\\n(^yu'\l'|0u-1.5n\(ul'
138
'\" # VS - start vertical sidebar
139
'\" # ^Y = starting y location
140
'\" # ^v = 1 (for troff; for nroff this doesn't matter)
144
.ie n 'mc \s12\(br\s0
147
'\" # VE - end of vertical sidebar
155
\h'|\\n(^lu+3n'\L'|\\n(^Yu-1v\(bv'\v'\\n(^tu+1v-\\n(^Yu'\h'-|\\n(^lu+3n'
162
'\" # Special macro to handle page bottom: finish off current
163
'\" # box/sidebar if in box/sidebar mode, then invoked standard
164
'\" # page bottom macro.
171
.\" Draw three-sided box if this is the box's first page,
172
.\" draw two sides but no top otherwise.
173
.ie !\\n(^b-1 \h'-1.5n'\L'|\\n(^yu-1v'\l'\\n(^lu+3n\(ul'\L'\\n(^tu+1v-\\n(^yu'\h'|0u'\c
174
.el \h'-1.5n'\L'|\\n(^yu-1v'\h'\\n(^lu+3n'\L'\\n(^tu+1v-\\n(^yu'\h'|0u'\c
177
.nr ^x \\n(^tu+1v-\\n(^Yu
178
\kx\h'-\\nxu'\h'|\\n(^lu+3n'\ky\L'-\\n(^xu'\v'\\n(^xu'\h'|0u'\c
191
'\" # DS - begin display
197
'\" # DE - end display
203
'\" # SO - start of list of standard options
205
.SH "STANDARD OPTIONS"
211
'\" # SE - end of list of standard options
216
See the \\fBoptions\\fR manual entry for details on the standard options.
218
'\" # OP - start of full description for a single option
223
Command-Line Name: \\fB\\$1\\fR
224
Database Name: \\fB\\$2\\fR
225
Database Class: \\fB\\$3\\fR
229
'\" # CS - begin code excerpt
235
'\" # CE - end code excerpt
243
.TH "critcl_devguide" n 3\&.1\&.8 doc "C Runtime In Tcl (CriTcl)"
246
critcl_devguide \- Critcl - The Developer's Guide
248
Welcome to the \fIC Runtime In Tcl\fR, \fICriTcl\fR for short, a
249
system to build C extension packages for Tcl on the fly, from C code
250
embedded within Tcl scripts, for all who wish to make their code go
253
This document is a guide for developers working on Critcl,
254
i\&.e\&. maintainers fixing bugs, extending the package's functionality,
259
\fICritcl - License\fR,
261
\fICritcl - How To Get The Sources\fR, and
263
\fICritcl - The Installer's Guide\fR
265
first, if that was not done already\&.
267
Here we assume that the sources are already available in a directory
268
of your choice, and that you not only know how to build and install
269
them, but also have all the necessary requisites to actually do
270
so\&. The guide to the sources in particular also explains which source
271
code management system is used, where to find it, how to set it up,
273
.SH "PLAYING WITH CRITCL"
275
The sources of Critcl, should you have gotten them, contain
276
several larger examples show-casing various aspects of the
277
system\&. These demonstration packages can all be found in the
278
sub-directory "\fIexamples/\fR" of the sources\&.
280
Lots of smaller examples can be found in the document
281
\fIUsing CriTcl\fR, an introduction to Critcl by way of a of
282
examples\&. These focus more on specific critcl commands than the
283
overall picture shown by the large examples mentioned in the previous
285
.SH "DEVELOPING FOR CRITCL"
286
.SS "ARCHITECTURE & CONCEPTS"
287
The system consists of two main layers, as seen in the figure below,
288
plus a support layer containing general packages the system uses during
316
At the top we have an application built on top of the core packages,
317
providing command line access to the second and third usage modes,
318
i\&.e\&. \fIGenerate Package\fR and \fIGenerate TEA Package\fR\&.
326
Below that is the core package providing the essential functionality
327
of the system, plus various utility packages which make common tasks
336
Lastly a layer of supporting packages, mostly external to critcl\&.
340
For this pure-Tcl package to be fast users should get one of several
341
possible accelerator packages:
355
\fBstubs::container\fR
363
\fBstubs::gen::init\fR
365
\fBstubs::gen::header\fR
367
\fBstubs::gen::decl\fR
369
\fBstubs::gen::macro\fR
371
\fBstubs::gen::slot\fR
373
\fBstubs::gen::lib\fR
377
To develop for critcl the following packages and applications must be
378
available in the environment\&. These are all used by the \fBbuild\&.tcl\fR
379
helper application\&.
382
A Tcl application provided by Tcllib, for the validation and
383
conversion of \fIdoctools\fR-formatted text\&.
386
A Tcl application provided by Tklib, for the validation and conversion
387
of \fBdiagram\fR-formatted figures into raster images\&.
389
Do not confuse this with the Gnome \fBdia\fR application,
390
which is a graphical editor for figures and diagrams, and completely
394
A Tcl package provided by Tcllib, providing file system utilities\&.
396
\fBvfs::mk4\fR, \fBvfs\fR
397
Tcl packages written in C providing access to Tcl's VFS facilities,
398
required for the generation of critcl starkits and starpacks\&.
400
.SS "DIRECTORY STRUCTURE"
406
This helper application provides various operations needed by a
407
developer for critcl, like regenerating the documentation, the
408
figures, building and installing critcl, etc\&.
410
Running the command like
418
will provide more details about the available operations and their
426
This directory contains the documentation sources, for both the text, and the figures\&.
427
The texts are written in \fIdoctools\fR format, whereas the figures are written for
428
tklib's \fBdia\fR(gram) package and application\&.
431
This directory contains the documentation converted to regular manpages
433
It is called embedded because these files, while derived, are part of the
434
git repository, i\&.e\&. embedded into it\&. This enables us to place these files
435
where they are visible when serving the prject's web interface\&.
441
"\fItest/all\&.tcl\fR"
443
"\fItest/testutilities\&.tcl\fR"
445
"\fItest/*\&.test\fR"
446
These files are a standard testsuite based on Tcl's \fBtcltest\fR package,
447
with some utility code snarfed from \fBTcllib\fR\&.
449
This currently tests only some of the \fBstubs::*\fR packages\&.
452
These files (but not "\fIall\&.tcl\fR", and "\fItestutilities\&.tcl\fR") are
453
example files (Tcl with embedded C) which can be run through critcl for testing\&.
455
\fITODO:\fR These should be converted into a proper test suite\&.
458
Package Code, General structure
462
Package Code, Per Package
468
"\fIlib/critcl/critcl\&.tcl\fR"
469
The Tcl code implementing the package\&.
471
"\fIlib/critcl/Config\fR"
472
The configuration file for the standard targets and their settings\&.
474
"\fIlib/critcl/critcl_c/\fR"
475
Various C code snippets used by the package\&.
476
This directory also contains the copies of the Tcl header files used
477
to compile the assembled C code, for the major brnaches of Tcl,
478
i\&.e\&. 8\&.4, 8\&.5, and 8\&.6\&.
484
"\fIlib/critcl-util/util\&.tcl\fR"
485
The Tcl code implementing the package\&.
491
"\fIlib/app-critcl/critcl\&.tcl\fR"
492
The Tcl code implementing the package\&.
498
"\fIlib/critcl-iassoc/iassoc\&.tcl\fR"
499
The Tcl code implementing the package\&.
501
"\fIlib/critcl-iassoc/iassoc\&.h\fR"
502
C code template used by the package\&.
508
"\fIlib/critcl-class/class\&.tcl\fR"
509
The Tcl code implementing the package\&.
511
"\fIlib/critcl-class/class\&.h\fR"
512
C code template used by the package\&.
520
"\fIlib/util84/dict\&.tcl\fR"
522
"\fIlib/util84/lassign\&.tcl\fR"
523
These are two packages implementing forward compatibility emulations
524
of the \fBdict\fR and \fBlassign\fR commands introduced with Tcl 8\&.5\&.
525
These are used automatically when critcl is run by Tcl 8\&.4\&.
532
A set of non-public (still) packages which provide read and write
533
access to and represent Tcl stubs tables\&. These were created by taking
534
the "\fIgenStubs\&.tcl\fR" helper application coming with the Tcl core
535
sources apart along its internal logical lines\&.
542
Arjen Markus' work on a critcl/Fortran\&. The code is outdated and has
543
not been adapted to the changes in critcl version 3 yet\&.
561
These are all external packages whose code has been inlined in the
562
repository for easier development (less dependencies to pull), and
563
quicker deployment from the repository (generation of starkit and
569
\fBsnitbutton\fR, and
571
are for the support of the Wikit GUI accessible from starkit and -pack
572
when the application functionality (\fBcritcl::app\fR) is run with
573
an empty command line\&.
575
\fITODO:\fR These should all be checked against their origin
576
for updates and changes since they were inlined\&.
580
Jean Claude Wippler, Steve Landers, Andreas Kupries
581
.SH "BUGS, IDEAS, FEEDBACK"
582
This document, and the package it describes, will undoubtedly contain
583
bugs and other problems\&.
584
Please report them at \fIhttps://github\&.com/andreas-kupries/critcl/issues\fR\&.
585
Ideas for enhancements you may have for either package, application,
586
and/or the documentation are also very welcome and should be reported
587
at \fIhttps://github\&.com/andreas-kupries/critcl/issues\fR as well\&.
589
C code, Embedded C Code, code generator, compile & run, compiler, dynamic code generation, dynamic compilation, generate package, linker, on demand compilation, on-the-fly compilation
591
Glueing/Embedded C code
594
Copyright (c) Jean-Claude Wippler
595
Copyright (c) Steve Landers
596
Copyright (c) 2011-2013 Andreas Kupries
b'\\ No newline at end of file'