&| '''What''': | ''Tcl-Compiler'' |&
&| '''Intro''': | https://nhi1.selfhost.co/wiki/Tcl-Compiler |&
&| '''Description''': | The ''Tcl-Compiler'' compiles ''Tcl-Scripts'' into native ''C-Code'' |&
&| '''Updated''': | 26 feb 2021 (reopen this project) |&
&| '''Contact''': | mailto:[email protected] (Andreas Otto) |&
** Links **
* [https://nhi1.selfhost.co/Token_Stream_Technology %|%What is the Token Stream Technology ?]
* [http://sourceforge.net/projects/tclcompiler %|%source-code at sourceforge.net]
* [https://nhi1.selfhost.co %|%Compiler Factory]
* [https://nhi1.selfhost.co/Tcl-Compiler_-_PERFORMANCE_TEST %|%POWER-Tcl performance figures]
** HOWTO PAGES **
* [https://nhi1.selfhost.co/POWER-Tcl/HOWTO_PROJECT.html %|% HOWTO setup a project]
* [https://nhi1.selfhost.co/POWER-Tcl/HOWTO_COMPILE.html %|% HOWTO compile a TCL package into a SHARD LIBRARY]
* [https://nhi1.selfhost.co/POWER-Tcl/HOWTO_INLINE_C.html %|% HOWTO write INLINE C code]
* [https://nhi1.selfhost.co/POWER-Tcl/HOWTO_MIC_TCL_AND_C.html %|% HOWTO mix TCL and C]
* [https://nhi1.selfhost.co/POWER-Tcl/HOWTO_MAKE.html %|% HOWTO use the make tool]
* [https://nhi1.selfhost.co/POWER-Tcl/HOWTO_SOURCE.html %|% HOWTO source]
* [https://nhi1.selfhost.co/POWER-Tcl/HOWTO_REPOSITORY.html %|% HOWTO use a repository]
* [https://nhi1.selfhost.co/POWER-Tcl/HOWTO_PLUGIN.html %|% HOWTO plugin]
** Updates **
*** 25 Apr 2021 ***
This is a nice example of an "Morning-Error" but this is also a nice example of an ''error'' in a '''POWER-Tcl''' compiled file.
As you see the ''STACK'' always works, even the ''errorInfo'' shows the stack with ''proc-names'' but without code.
But one thing is missing, the good old ''__FILE__'' and ''__LINE___'' from the wonderfull ''C'' debugging. ''Tcl'' misses
some really usefull debugging-infos from day one, and the most important miss is the ''line'' and ''file'' information.
* I thing adding more debugging features ins one point of the future in '''POWER-Tcl'''.
======none
Compiler3> cct make --edit
ENVIRONMENT ERROR [::Env::Check] : variable '' is not available (ERR08) -> please check 'Compiler' setup (ERR-07)
STACK >>>
::Env::Check {} {} ...
::FileLib::Resolve {} ...
::PkgLib::COMPILER_HOME ...
::PkgLib::Db::INDEXFILE . ...
file: pkg/libPkgLib2.0.so
======
*** 23 Apr 2021 ***
Today a pretty nice technology was added: I call it '''POWER-starter'''
In the past the '''POWER-Tcl''' was a normal ''tclsh'' with some enhancements, able to load and execute a ''POWER-Tcl-share-library''.
But now something '''NEW''' was added… instead creating a ''shared-library'' I add a feature called '''objexp'''
example: ''objexp'' on `StdLib`
======none
> cd cmp/StdLib
> cct make c.objexp
... compiles: tcl->c->o
> find export/ -name "*.o"
export/StdLib/COMPILER_STDLIB.o
export/StdLib/StdLib.o
export/FileLib/COMPILER_FILELIB.o
export/FileLib/FileLib.o
export/StackLib/COMPILER_STACKLIB.o
export/StackLib/StackLib.o
======
and now I use the `"*.o"` files to create a special ''tclsh'' just called ''cct''. This ''cct'' is now the ''POWER-Tcl'' starter:
OLD: cct (BASH script) -> set some environment -> exec `tclsh8.3 package Cct ...` (from POWER-Tcl) -> do the processing
NEW: cct (BINARY with ''Cct'' and other stuff) -> do the processing
This is a pretty quick start as there is NO single line of ''BASH'' or ''TCL'' script involved and everything is in pure C.
*** 20 Apr 2021 ***
1. update [https://nhi1.selfhost.co/POWER-Tcl/HOWTO_COMPILE.html %|% HOWTO compile]
1. update [https://nhi1.selfhost.co/POWER-Tcl/HOWTO_MAKE.html %|% HOWTO make]
1. add `TPACKAGE` project option to link a PROJECT with a installation PACKAGE
1. add `cct make --detail` to print out the project data:
======none
.../Compiler3/example/CctPlugin.CVS> cct make --details
PROJECT CctPlugin {
DEBUGMODE 0
FILE_TCL CctPlugin.tcl {
HEADER {}
META2C {
DEBUG 0
OPTIMIZATION 1
PRINT 0
SKIP {}
}
META2TCL {
PRINT 0
}
TCL2META {
CMD {}
PKG_REQUIRE Tcl
PRINT 0
SAFE 0
TEST 0
}
}
INSTDIR_C .../Compiler3/example/CctPlugin.CVS/CctPlugin.tpkg/arch/linuxi386/lib/pkg
INSTDIR_TCL .../Compiler3/example/CctPlugin.CVS/DIR-Tcl
MAJOR 1
MINOR 0
STRIP 1
TPACKAGE CctPlugin.tpkg
}
======
*** 19 Apr 2021 ***
This is a nice overview about the ''POWER-Tcl-development-workplace'' packages :
======none
.../Compiler3.CVS> cct build --list
name tclV pkgV restriction pattern dir
--------------- ----- ----- -------------- ------------------ ------------------------
Base 2.0 --pkg ALL EARLY RT ./cmp/Base
StdLib 2.0 2.0 ALL EARLY RT ./cmp/StdLib
External 2.0 2.0 ALL EARLY RT ./cmp/External
CctIndex 2.0 2.0 ALL EARLY RT ./cmp/CctIndex
Config 2.0 2.0 ALL EARLY RT ./cmp/Config
PkgLib 2.0 2.0 ALL EARLY RT ./cmp/PkgLib
TMakeLib 2.0 2.0 ALL CMP ./cmp/TMakeLib
MetaToTcl 3.0 3.0 ALL CMP ./cmp/MetaToTcl
MetaToC 3.0 3.0 ALL CMP ./cmp/MetaToC
Wish 3.0 ALL TK ./cmp/Wish
Agent 2.0 2.0 ALL CMP ./cmp/Agent
System 2.0 2.0 ALL EARLY RT ./cmp/System
InitScript 9.9 2.0 ALL RT ./cmp/InitScript
Target 2.0 2.0 ALL CMP EARLY RT ./cmp/Target
Md5sum 2.0 2.0 ALL EARLY RT ./cmp/Md5sum
Bras 2.1 ALL CMP ./cmp/Bras
Cct 2.0 2.0 ALL EARLY RT ./cmp/Cct
CctView 1.0 1.0 ALL EARLY RT ./cmp/CctView
CctRep 2.0 2.0 ALL CMP ./cmp/CctRep
CctBuild 1.0 1.0 ALL ./cmp/Build
TclToMeta 3.0 --pkg ALL CMP ./src/t2m8.3.4
CctRt 3.0 --pkg ALL EARLY RT ./src/cct8.3.4
CctPerf 2.0 2.0 ALL ./example/CctPerf.CVS
CctTest 2.0 2.0 ALL ./example/CctTest.CVS
CctDiff 2.0 2.0 ALL ./example/CctDiff.CVS
CctFind 2.0 2.0 ALL ./example/CctFind.CVS
CctPlugin 2.0 2.0 ALL ./example/CctPlugin.CVS
CctMan 2.0 2.0 ALL ./example/CctMan.CVS
BWidget 1.31 ALL ./example/BWidget
TclIDE 2.0 2.0 ALL ./example/TclIDE
TclHttpd 2.0 ALL ./example/TclHttpd
TclLib 2.0 ALL ./example/TclLib
Blowfish 1.0 1.0 ALL ./example/Blowfish
Cgi 1.0 1.0 ALL CGI ./example/Cgi.CVS
CgiGbook 2.0 ALL CGI ./example/CgiGbook.CVS
CgiFormmail 1.0 2.0 ALL CGI ./example/CgiFormmail.CVS
CgiPoll 1.0 1.0 ALL CGI ./example/CgiPoll.CVS
CgiKey 1.0 1.0 ALL CGI ./example/CgiKey.CVS
CgiUserkey 1.0 1.0 ALL CGI ./example/CgiUserkey.CVS
CgiHidden 1.0 1.0 ALL CGI ./example/CgiHidden.CVS
CctMail 1.0 1.0 ALL CGI ./example/CctMail.CVS
CctCrm 1.0 1.0 ALL ./example/Crm
OtCC 2.0 --pkg ALL CC ./src
OtTcl 8.34 --pkg ALL ./src
OtTk 8.34 --pkg ALL TK ./src
OtMetaKit 1.0 --pkg ALL CGI ./src
Readline 1.0 --pkg ALL EARLY RT ./src
TclRl 3.0 --pkg ALL EARLY RT ./src
TcLib --make ALL ./cmp/TcLib
TkLib --make ALL TK ./cmp/TkLib
======
*** 18 Apr 2021 ***
This week a lot of code-cleanup and feature-adding was done.
The new features are:
+++
package lock `cct pkg --lock pkgname` (also --unlock)
distribution upgrade `cct build --pkg upgrade`
plugin testing: `cct md5sum --test ...`
+++
**** HOWTO lock/unlock ****
The ''package-lock'' is important because in '''POWER-Tcl''' every code exist '''TWO''' times :
1. once as ordinary ''TCL'' code
1. once as '''POWER-Tcl''' binary code
The goal is that only '''ONE''' code is in duty. To solve this problem the ''binary'' can be ''locked'' and ''unlocked''.
To ''lock'' mean just renaming the `binary` to `binary.lock` and rebuild the package index files.
'''Example:''' edit ''plugin'' code without lock
======none
.../Compiler3.CVS> cct plugin --edit
CctPlugin ARGUMENT ERROR [::Args::Edit-Arg] : The package 'CctPlugin' uses the BINARY from the directory:
> .../Compiler3.CVS/lib/JavaKiller/exe/linuxi386/lib/pkg
To edit the package, the SOURCE must be available and the BINARY must be locked.
> Use 'cct pkg --lock CctPlugin' to lock the BINARY.
STACK >>>
::Args::Edit-Arg ...
::Args:: ...
::Args::Invoke2 --edit ...
::CctPlugin::Args::Main ...
::Args::CmdInvoke CctPlugin ...
::CctCmd::Invoke CctPlugin ...
::Args::Invoke2 plugin ...
::CctCmd::Args::Main ...
::Args::Main ...
::Main ...
file: Cct/Main.tcl
======
After edit is finished one simple command '`cct build --target CctPlugin --pkg upd`' recompile and install the new package:
======none
> cct build --target CctPlugin --pkg upd
> CctPlugin ./example/CctPlugin.CVS
BUILD MSG : ./example/CctPlugin.CVS -> cct make -s c.is
BUILD MSG : ./example/CctPlugin.CVS -> cct pkg --dir COMPILER_HOME --noidx --upd CctPlugin
package: CctPlugin_2_0
PKG UPD MSG: update package -> CctPlugin_2_0
PKG ADD MSG: work on package -> CctPlugin_2_0
PKG ADD MSG: setup arch -> linuxi386
PKG ADD MSG: check destination directory -> .../Compiler3.CVS/lib/JavaKiller
PKG ADD MSG: check destination directory -> .../Compiler3.CVS/lib/JavaKiller/exe
PKG ADD MSG: write package to destination directory -> .../Compiler3.CVS/lib/JavaKiller/var/pkg/install/CctPlugin_2_0
PKG ADD MSG: cleanup installation directory -> .../Compiler3.CVS/lib/JavaKiller/var/pkg/install/CctPlugin_2_0
PKG ADD MSG: cleanup installation directory -> .../Compiler3.CVS/lib/JavaKiller/var/pkg/arch/CctPlugin_2_0
PKG ADD MSG: write package finish -> CctPlugin_2_0
PKG ADD MSG: delete build/inst/arch directory -> done
PKG UPD MSG: clean package -> CctPlugin_2_0
BUILD MSG : . -> cct index --dir COMPILER_HOME --sys package
PKG INDEX : work in directory -> .../Compiler3.CVS/lib/JavaKiller/exe/linuxi386/lib/pkg
PKG INDEX : create pkgIndex.tcl (MSG01) -> START
PKG INDEX : create pkgIndex.tcl (MSG02) -> END
BUILD MSG : . -> cct index --dir COMPILER_HOME --sys cct
CCT INDEX : work in directory -> .../Compiler3.CVS/lib/JavaKiller/exe/linuxi386/lib/pkg
CCT INDEX : create Cct.cfg (MSG01) -> START
> found : CctPkg CctPlugin CctRep
CCT INDEX : create Cct.cfg (MSG02) -> END
BUILD MSG : . -> cct index --dir COMPILER_HOME --sys cgi
CGI INDEX : work in directory -> .../Compiler3.CVS/lib/JavaKiller/exe/linuxi386/lib/pkg
CGI INDEX : create Cgi.cnf (MSG01) -> START
> found :
CGI INDEX : no valid package found (WAR01) -> END
BUILD MSG : . -> cct index --dir COMPILER_HOME --sys create
SYS INDEX : work in directory -> .../Compiler3.CVS/lib/JavaKiller
SYS INDEX : create arch_pkgIndext.tcl (MSG01) -> START
SYS INDEX : create file -> linuxi386_pkgIndex.tcl
add package : AgProc AgVar Agent Args Blowfish Cct CctBlowfish CctBuild CctBwdemo CctCc CctCc CctCheck CctCmd CctComplete CctCrm CctDiff CctExport CctFind CctGbook CctHttpd CctIde CctIndex CctInfo CctInit CctKey CctKeygen CctMail CctMake CctMan CctMd5sum CctPerf CctPkg CctPlugin CctPoll CctProfiler CctRep CctTclsh CctTest CctTkdemo CctView CctWish Cgi CgiChat_main CgiCmd CgiFormmail CgiGbook_add_db CgiGbook_add_form CgiGbook_list_form CgiHidden CgiKey CgiPoll CgiPoll_res CgiUserkey Config External FileLib Find IAgent IBras IFind IIndex IMan IMetaToC IMetaToTcl ITMakeLib ITclHttpd ITclIDE ITclIDEserver ITkDiff IView IndexCct IndexCgi IndexPkg IndexSys IndexTcl InitScript LibMetaToTcl Md5sum MetaToC MetaToTcl PerfLib PkgLib Poll_db Poll_read StackLib StdLib System TMakeLib Target TclIDE TclIDEclient TclIDEserver TestDriver TkCon TkConProc TkDiff base64 bras cmdline counter csv fileutil ftp ftpd graph html htmlparse http http::admin http::auth http::cgi http::config http::counter http::debug http::demo http::direct http::dirlist http::doc http::eval http::imagemap http::include http::ismaptcl http::ismaptk http::log http::logstd http::mail http::mtype http::opentrace httpd httpd__admin httpd__auth httpd__cgi httpd__config httpd__counter httpd__debug httpd__demo httpd__direct httpd__dirlist httpd__doc httpd__eval httpd__imagemap httpd__include httpd__ismaptcl httpd__ismaptk httpd__log httpd__logstd httpd__mail httpd__mtype httpd__opentrace httpd__passcheck httpd__prodebug httpd__redirect httpd__safecgio httpd__session httpd__snmp httpd__srvui httpd__status httpd__stdin httpd__telnet httpd__threadmgr httpd__upload httpd__url httpd__utils httpd__version javascript log math matrix md5 mime ncgi nntp pop3 profiler queue report sha1 smtp stack start_httpd start_httpdthread stats struct tclreadline textutil tree typedcmdline uri
SYS INDEX : create arch_pkgIndext.tcl (MSG01) -> END
======
**** POWER-Tcl-Ide ****
* A lot of improvement got the '''POWER-Tcl-Ide'''.
The '''Ide''' is a total new development-concept, nothing equal was ever done.
The goal is to have a full featured '''Ide''' but only as ''command-line-tool'' with ''auto-complete''.
* YES - it is working
The ''auto-complete'' feature always give a hint to the user what to-do and the user interact with a ''POWER-Tcl-distrubution''
as target.
A typical ''IDE'' has a permanently running process, GUI, etc., but the POWER-Tcl-ide has no running process.
The only thing that POWER-Tcl has is a single command called '''`cct`''' and a tremendous startup speed that exceeds
anything known in modern programming.
example: if the user hit the `Tab` button the `bash` start the autocomplete `cct complete ...` and the `cct` return
everything possible what a user can do with the current ''command-line''.
Because always a full new `cct` is started (no server or something else is used) the `cct` need the tremendous startup-speed
to provide immediate response.
*** 13 Apr 2021 ***
Test the '''Early-Bird''' distribution, for example the package verification utility:
======none
> /build/compiler/EarlyBird> cct pkg --check2
PKG CHECK MSG: check part 1 -> find unused install template
PKG CHECK MSG: finish part 1
PKG CHECK MSG: check part 2 -> find unknown files
PKG CHECK MSG: finish part 2
======
In ''POWER-Tcl'' an application has '''always''' the TCL interpreter and all dependency packages included. <<br>>
The goal is that an installed application has '''no''' external dependencies. This is possible because <<br>>
TCL ist very small compared to JAVA or other "modern" software and TCL is FREE.
To put everything together the ''POWER-Tcl'' has an package-manager `cct pkg ...` which is also part of '''every''' application. <<br>>
To check if an application is ok the package-manager uses a package-database with an `md5sum+info` about every <<br>>
file installed. The command `cct pkg --check2` checks the entire application. The package-database is also a part of '''every''' application.
To build an application a new tool was added this week called `cct build ...` . This tool is part of the `POWER-Tcl-Developer-Workplace`.<<br>>
To build the ''Early-Bird'' application I use : `cct build --dir /build/compiler --dist Early --make c.is --pkg add` <<br>>
======none
usage: cct [master-option...] build [user-option ...] [--] args
short: build and install the distribution
master options :
-m ARCH platform target [linuxi386]
-d FLAG use debug mode [no]
> simulate the build, do NOT exec
-v FLAG use verbose mode [no]
-f FLAG use force mode [no]
> use 'force' for package installation
user options :
-i FLAG interactive mode [no]
-e TARGET edit target [NOT-SET]
--list FLAG list all targets [no]
--proc FLAG check the procs : cct check -o... [no]
--dir DIR set DISTDIR root [/my/dist]
--make ACTION compile the files : [NOT-SET]
> m.exp, m.rb, m.rm, tcl.all, tcl.exp, tcl.is
> tcl.rb, tcl.rm, c.all, c.cmp, c.exp, c.is
> c.rb, c.rm, c.wk, clean
--prj ACTION work on 'project.cct' file : [check]
> edit : vim 'project.cct'
> save : tar -czvf SAFE/DATE/target.tgz .project.cct
> check : cct check -p ...
--pkg ACTION work on package : [upd]
> add upd del edit incr lock unlock index
> edit : edit VERSION & pkg.tcl
> incr : increment MAJOR from VERSION
> index : create package index
--dist ACTION select distribution, set '--pattern' : [NOT-SET]
> WinRT LinRT LinCgi LinComp WinComp Early Dev
--pattern LIST select pattern (combine with '+-') : [NOT-SET]
> ALL CC CGI CMP EARLY RT TK
--target LIST specific target (disable '--pattern') : [NOT-SET]
> Agent, BWidget, Base, Blowfish, Bras, Cct, CctBuild
> CctCrm, CctDiff, CctFind, CctIndex, CctMail, CctMan, CctPerf
> CctPlugin, CctRep, CctRt, CctTest, CctView, Cgi, CgiFormmail
> CgiGbook, CgiHidden, CgiKey, CgiPoll, CgiUserkey, Config, External
> InitScript, Interface, Md5Sum, MetaToC, MetaToTcl, OtCC, OtMetaKit
> OtTcl, OtTk, PkgLib, Readline, StdLib, System, TMakeLib
> Target, TcLib, TclHttpd, TclIDE, TclLib, TclRl, TclToMeta
> TkCon, TkLib
default options :
--help FLAG print the help (-h) [no]
--info FLAG get information about command [no]
--edit FLAG open project and edit files [no]
--args LIST command-line arguments [*]
======
*** 9 Apr 2021 ***
* today I put back the famous `tclreadline` package.
`tclreadline` gives you a `bash` like interactive shell like `TkCon` for the commandline.
`tclreadline` is started with `cct tclsh` and no file as argument.
Note: A typical UNIX command like `ls -al` is evaluated directly without `exec` etc
Example: using `find` together with `tclreadline` empowerd '''TCL''' :
======none
tclsh8.3 [~/Project/Compiler3.CVS] find . -name README.md -ls
442018264 8 -rw-r--r-- 1 dev1usr users 4459 Apr 7 21:48 ./README.md
======
The `tclreadline` package was part of a project called '''POWER-os''' (a subproject of '''POWER-Tcl''') which is an entire ''LINUX'' without `bash` but using '''TCL''' as system-programming-language.
To install the `tclreadline` feature '''two''' ''POWER-Tcl-packages'' are involved:
Readline.tpkg: Compile and install the `libreadline` into the ''POWER-Tcl-runtime''
TclRl.tpkg: Compile and install the `tclreadline` into the ''POWER-Tcl-runtime''
All the configuration compiling and installation is done by ''POWER-Tcl'' with just '''ONE''' command :
+++
Readline.tpkg `cct pkg --add Readline`
TclRl.tpkg `cct pkg --add TclRl`
+++
***7 Apr 2021***
* [https://nhi1.selfhost.co/POWER-Tcl %|% add PLUGIN code and DOCUMENTATION ]
* Example: Add `CctPlugin` the reference ''plugin''
***3 Apr 2021***
* [https://nhi1.selfhost.co/POWER-Tcl %|% Compile the ''TCL'' default library ]
* Example: Add `http2.4` the ''TCL'' http protocol
***2 Apr 2021***
* [https://nhi1.selfhost.co/POWER-Tcl %|% Tasks done this week: 1. ''API-cleanup'', 2. ''testing'', 3. ''bug-fixing'' ]
* Example: Add `Md5Sum` with ''TCL'' and inline ''C'' mixed code
***28 Mar 2021***
* [https://nhi1.selfhost.co/POWER-Tcl %|% Early-Bird-Release of '''POWER-Tcl V3''']
***26 Mar 2021***
In the last few days I setup the tools for distribution:
* switch documentation tool from ''wiki'' to ''doxygen''
* add GNU ''automake'' for setup
* work on general ''code-cleanup''
* compile the libraries
***20 Mar 2021***
In the last few days I have been working on the following tasks:
* Frontend library improvement.
** much less code with more functions
* bash-readline-auto-complete-plugin
** the frontend command line tool ''cct'' generates the code for the autocomplete function of bash automatically.
* ''package'' and ''project'' file improvements
** the ''POWER-Tcl-package'' is used to distribute ''code'' and the final application
** the ''POWER-Tcl-project'' is used to configure the ''build-process''
One thing that '''Tcl-Compiler''' does very well is locating BUGS (proof by myself)
* If ''proc-names'' are changed or the number and type of arguments then '''Tcl-Compiler''' finds the broken references.
* If ''proc'' is used without a ''package require'' etc..
* Broken code, unexecutable branch of code etc..
There is a good chance to have '''end''' of next week a working ''early-bird'' edition.
* but with one throw-back (tcl-8.3.4) (the 20 years old '''tcl''')
* this ''tcl'' has all modern features like namespace, objects etc but missing all the ''oo'' code
***15 Mar 2021***
The compiling of ''TCL'' comes closer, step by step...,
* propably the largest technology-improvement for a scripting-language in 20 years.
* More details at: [https://nhi1.selfhost.co/Tcl-Compiler_-_HOWTO_MAKE %|% HOWTO use the make tool]
compiling ......... c_MRep.cr
.../Compiler3/lib/JavaKiller/exe/linuxi386/bin/tclsh8.3 package MetaToC
loading script Meta2C
loading script LibMeta2Tcl
loading script Agent
Compiling Step 1. (Parse)
Working on procedure ... <::Agent::MRep::Warning>
Working on procedure ... <::Agent::MRep::PkgList>
Working on procedure ... <::Agent::MRep::LFileList>
Working on procedure ... <::Agent::MRep::Read>
Working on procedure ... <::Agent::MRep::ReadArray>
Working on procedure ... <::Agent::MRep::LReadArray>
Working on procedure ... <::Agent::MRep::ReadList>
Working on procedure ... <::Agent::MRep::LReadList>
Working on procedure ... <::Agent::MRep::Write>
Working on procedure ... <::Agent::MRep::Close>
Working on procedure ... <::Agent::MRep::Delete>
Working on procedure ... <::Agent::MRep::DeletePkg>
Working on procedure ... <::Agent::MRep::ListWrite>
Working on procedure ... <::Agent::MRep::ArrayWrite>
Working on procedure ... <::Agent::MRep::List>
Compiling Step 2. (Header)
Compiling Step 3. (Include)
Compiling Step 4. (Static)
Compiling Step 5. (CmpLoc)
Compiling Step 6. (Prototype)
Compiling Step 7. (Template)
Compiling Step 8. (Procs)
Compiling Step 9. (Init)
create object ..... c_MRep_linuxi386
/usr/bin/gcc -DVERSION=\"3.0\" -D BUILD_TclToMeta -D OTTARGET_linuxi386 -I.../Compiler3/lib/JavaKiller/exe/linuxi386/include -I../../C -O -fPIC -Wall -c ../../C/MRep.c -o MRep.o
***13 Mar 2021***
* get the ''make'' tool back to work.
* today I had my first build :-)
Compiler3/cmp/Bras> cct -t IBras make m
compiling ......... m_IBras
PROTOTYPE not defined <PROC | PkgProvide , NS | >
PROTOTYPE not defined <PROC | Push , NS | ::StdLib>
PROTOTYPE not defined <PROC | ErrorN , NS | ::StdLib>
PROTOTYPE not defined <PROC | Pop , NS | ::StdLib>
PROTOTYPE not defined <PROC | COMPILER_HOME , NS | ::Env>
PROTOTYPE not defined <PROC | COMPILER_ARCH , NS | ::Env>
PROTOTYPE not defined <PROC | configure , NS | ::bras>
PROTOTYPE not defined <PROC | pinclude , NS | ::bras>
PROTOTYPE not defined <PROC | include , NS | ::bras>
PROTOTYPE not defined <PROC | dumprules , NS | ::bras>
PROTOTYPE not defined <PROC | consider , NS | ::bras>
PROTOTYPE not defined <PROC | trimErrorInfo , NS | ::bras>
meta .............. m
***11 Mar 2021***
* work on documentation
* improve the ''cct'' front-end API
***08 Mar 2021***
Today is a '''good''' day because today the `cct` tool is back.
* The main problem was that after '''20 years''' of silence, many code references are broken and parts of the tool need to be revised to make it work again.
* As I mentioned earlier, there are '''three''' Tcl-Compiler revisions and the ''current'' revision ('''3''') depends on part of the previous revision ('''2''') and so on.
*** example: cct ***
usage: cct [master option ...] command ...
master options :
-t STRING compiler package [NOT SET]
-a FLAG all "*" compiler packages [no]
-m STRING platform target [linuxi386]
-d FLAG use debug mode [no]
commands :
blowfish blowfish encryption
bwdemo start the BWidget demo
cc c/c++ cross-compiler
check checks various parts of the installation
crm customer relationship
diff the diff tool
export export internal code
find find/grep/change tool
gbook manage guestbook cgi
httpd the tcl web-server
ide the "Compiler" IDE
index create all kinds of indexes
info info about various details
init setup a new project
mail send emails
make interface to the make tool
man interface to the man pages
md5sum compute the md5 digest
perf interface to the tcl "perf" tool
pkg interface to the cct "package" tool
poll manage poll cgi
profiler plugin profiler
rep interface to the repository
tclsh the POWER-Tcl shell
test interface to the tcl "test" tool
tkdemo start the tk demo
view view plugin interface
wish the POWER-Tk shell
default options :
-h print the help
--help print the help
***07 mar 2021***
''first signs of life'', the current status of ''Tcl-Compiler'' is ongoing.
I need some time to get "used-to" 20J old code using tcl-8.3.4 interpreter :-)
Infact there are THREE ''Tcl-Compiler''
* '''Compiler1''' the initial one, very rudimentary
* '''Compiler2''' the one which was ''sold'', GOOD but not PERFECT
* '''Compiler3''' the current one, more PERFECT but UNFINISHED :-)
**** status: I work on Compiler3 ****
The ''Compiler3'' is more than just an compiler, it is more like an entire infrastructure including
* package: management, signing, distribution
* frontend: command-line, gui, web…
* speed: compile, anaylyze
All '''tcl''' features are available in '''one''' command -> '''cct'''.
* the ''tclsh'' is available as ''cct tclsh''
The goal of the '''cct''' is to give the user a ''perfect'' environment for '''tcl''' without doing
any ''setup mess''.
**** example: PkgLib ****
> cct -t TkCon pkg --add -h
loading script Cct
usage: cct [master option ...] pkg [user-option ...]
master options :
-t STRING compiler package [TkCon]
-a FLAG all "*" compiler packages [no]
-m STRING platform target [linuxi386]
-d FLAG use debug mode [no]
user-options :
--add FLAG install the package [yes]
--del FLAG remove the package [no]
--upd FLAG update the package [no]
--list FLAG short info about packages [no]
--info FLAG long info about a package [no]
--check FLAG check a given package [no]
--check2 FLAG check installation [no]
--init FLAG create a package from template [no]
--rec FLAG recover package database [no]
--clean FLAG cleanup COMPILER_HOME [no]
--find FILE find package for file [NOT SET]
--noidx FLAG don't create index files [no]
-f FLAG force mode, don't ask [no]
-d DIR installation base [DEFAULT]
default options :
-h print the help
--help print the help
additional informations :
1) the "-t" option provides the name of the package:
--del, --list, --info, --check -> PACKAGE_MAJOR_MINOR
--add --upd -> PACKAGE
2) the "--list" "--info" and "--check" option accept a
pattern for "-t" as argument
3) the "--rec" option does not recover all the lost data :
recover: PACKAGE, MAJOR, MINOR
lost: all other data, but set to useful defaults
4) with the master "-d" option no directory cleanup's
are done
5) "--noidx" is mostly used during mass package
installation
***04 mar 2021***
* Add first steps to build the [https://nhi1.selfhost.co/wiki/index.php?title=Tcl-Compiler#TCL_COMPILER %|% Tcl-Compiler]
* there is a '''$100.000 bounty''' to add ''Tcl-Compiler'' back to Tcl… that's fine -> [https://github.com/flightaware/Tcl-bounties %|% FlightAware's Tcl Bounty program]
***26 feb 2021***
'''Yesterday''' I had a look into the source-code of `tcl-compiler` and I was really surprised how '''beautiful''' the
source-code is :-)
* '''I''' ([Andreas Otto]) as the developer have complete forgot this code.
There was a discussion that I don't publish '''all''' of the source-code
* I can say the ''sourceforge'' should be complete!
As I mentioned 20 years ago the `tcl-compiler` can be used as plain '''tcl''' script and you can compile the
`tcl-compiler` itself as executable.
> be aware that `tcl-compiler` uses a '''minimal''' modified `tcl` distribution with TWO features added/improved
1. a `p-unkown` tcl function called if a '''unknown''' function is used
2. a `v-unkown` tcl function called if a '''unknown''' variable is used
the modified `tcl` is part of the code at ''sourceforge''
mfg
----
** OLD stuff below **
At the [First European Tcl/Tk Users Meeting] in 2001, [Andreas Otto] presented a
system he called simply, "Tcl Compiler".
** Attributes **
website: [http://sourceforge.net/projects/tclcompiler/%|%sourceforge.net]
website (original): [http://web.archive.org/web/20010801231826/http://www.compiler-factory.com/index.html%|%compiler-factory.com via archive.org]
website (even more original): [http://web.archive.org/web/20010419065804/http://home.t-online.de/home/aotto/compiler.html%|%t-online.de via archive.org]
current version: 2.2
release time: 2001-10-16
** Reading **
[https://groups.google.com/d/msg/comp.lang.tcl/TEgFxtAZm9s/BoQCw_grneEJ%|%Compiler 1.3 Release Announcement] ,[comp.lang.tcl] ,2001-04-17:
[http://web.archive.org/web/20010914013838/http://www.compiler-factory.com/WhitePaper_E.html%|%What Is Token-Stream]:
[http://web.archive.org/web/20011022004957/http://www.compiler-factory.com/Compiler-TUTORIAL_E.html%|%tutorial (dead)]: Anyone who has a copy of this please shout out!
[http://web.archive.org/web/20011022004957/http://www.compiler-factory.com/Compiler-HOWTO_COMPILE_E.html%|%How to Compile (dead link)]: [PYK] would really like to see this document if anyone still has a copy of it.
[http://web.archive.org/web/20011022004957/http://www.compiler-factory.com/Compiler-HOWTO_CROSS_COMPILE_E.html%|%How to Cross Compile]: ditto.
[https://groups.google.com/forum/#!topic/comp.lang.tcl/OHzCNynzCio%|%TCL Compiler - Code update] ,[comp.lang.tcl] ,2000-03-01:
[https://groups.google.com/forum/#!searchin/comp.lang.tcl/andreas$20otto/comp.lang.tcl/VBHdocjEcG0/wOGv9PQMNsQJ%|%Tcl Compiler] ,comp.lang.tcl ,2006-03-14:
** Resources **
[http://sourceforge.net/p/tclcompiler/code/3/tree/%|%repository]:
** See Also **
[GSoc Idea: Evaluate and Update Tcl Compiler]:
** Description **
[arjen] 2014-01-08 08:48:52:
The SourceForge project is still available, That might be a good starting point, if anyone wants to revive this tool.
[SEH]: I have been combing through the sourceforge code and (sparse) docs. It appears that the code base is not complete, the author held back a C runtime library that is necessary actually to run the compiled Tcl program. If someone has up-to-date contact information for the author, perhaps we could persuade him to make a full release. The project looks to be worth saving.
[SEH] 2021/03/15 -- I'm following your progress with interest... I encourage you to continue. I look forward to trying the compiler.
----
'''[rasputnik] - 2021-04-05 08:26:07'''
Does this all make any sense?
Read the page about Power-Tcl but cant understand a thing, maybe i'm too stupid but there's no information what is the tool, what it does, how it works. And no source code, no examples.
The only link to source code is to something 15 year old, but even that doesn't seem to provide any useful info about what it is.
<<categories>> Development | Performance