DELETED ChangeLog
Index: ChangeLog
==================================================================
--- ChangeLog
+++ /dev/null
@@ -1,1073 +0,0 @@
-2003-04-21 Andreas Kupries
-
- * devdoc/indexing.txt:
- * installer.tcl: Extended [gen_main_index] to include the header
- of Don's generated package index. This makes the final chosen
- master index a combination of [i7/ad] and [i4/sd] as the
- fallback position.
-
- * installer.tcl: Made sure that all [file copy] operations use
- -force. Fix for #719616.
-
-2003-04-19 Andreas Kupries
-
- * installer.tcl: Bug fix, the modules calendar, control, and math
- have a "tclIndex" file which has to be installed too. Also
- changed usage of 'tcl_pkgPath', as this variable does not exist
- on windows.
-
-2003-04-17 Andreas Kupries
-
- * configure.in: Switched over from the original build system
- * configure: to one where configure/Makefile are optional
- * Makefile.in: and delegating all real work to 'sak.tcl'.
- * INSTALL.txt: Updated documentation, reduced configure macros.
- * aclocal.m4:
- * sak.tcl:
- * devdoc/releaseguide.html:
-
-2003-04-17 Andreas Kupries
-
- * installer.tcl: Bug fixes in non-gui mode, added option to force
- cmdline mode.
-
- * sak.tcl: Added command to invoke the testsuite(s).
-
- * installer.tcl: Added GUI.
-
- * main.tcl: New file, entrypoint for *kit, *pack, redirects to
- 'installer.tcl'.
-
- * sak.tcl: Helper tool for tcllib development (Generate
- distribution, various forms of documentation, check the bundle
- of packages for problems.
-
- * Makefile.in: Added des to the list of modules. (That is the good
- thing which came out of the erroneous commit, we found this
- error.)
-
- * mkIndex.tcl: Reverting accidential commit of this file. The
- committed state works with a changed Makefile, but not with the
- current one.
-
-2003-04-16 Andreas Kupries
-
- * installer.tcl: Added 'des' to list. Reworked according to
- feedback from Don.
-
- * tcllib_version.tcl: Added, for sharing with other scripts.
-
- * modules/stats/pkgIndex: Now throwing an error when trying to
- load 'stats'.
-
- * modules/struct/ChangeLog: Typo correction.
-
-2003-04-15 Andreas Kupries
-
- * installer.tcl: Added 'md4' to installer.tcl
-
-2003-04-15 Pat Thoyts
-
- * modules/md4: New module md4 created: MD4 hash algorithm.
-
-2003-04-15 Andreas Kupries
-
- * installer.tcl: EXPERIMENTAL. New installer for tcllib. Currently
- only cmdline based. Use -help to get help.
-
-2003-04-13 Andreas Kupries
-
- * Makefile.in (check-doc-markup): Fixed setting for DOC_FLAGS. The
- option '-visualwarn' does not exist anymore. Replaced by the
- option '-deprecated'. Thanks to Larry Virden for reporting the
- problem.
-
-2003-04-11 Andreas Kupries
-
- * install.tcl: Changed to notify the user if the directory to
- install is not a source distribution but a CVS snapshot. Right
- now a direct installation of a CVS snapshot is not possible.
-
- * Fixed bug #614591 throughout. Numerous modules updated. Also
- first round of getting version number consistents, and updated
- for a 1.4 release of the whole.
-
-2003-04-09 Andreas Kupries
-
- * New module: devtools. Internal use only for now. Does not
- contain true packages.
-
-2003-04-01 Andreas Kupries
-
- * Makefile.in (MODULES): Added the soundex module.
-
-2003-03-28 Andreas Kupries
-
- * README: Updated information about acceptable documentation
- formats, i.e. added doctools, made it the most prefered
- format. This fixes the [Bug #685270], reported by Larry Virden
- .
-
-2003-03-24 Andreas Kupries
-
- * README: Updated to refer to the SF website for Tcllib. Thanks to
- Larry Virden for the report and
- fix. [Bug #707607].
-
-2003-03-17 Pat Thoyts
-
- * modules/ntp: New module ntp created for time related network
- protocol stuff. Added RFC868 (TIME) protocol client and example.
-
-2003-03-13 Andreas Kupries
-
- * Makefile.in (install-libraries): Extended special code for
- doctools to install the new idx and toc engines.
-
-2003-02-11 Pat Thoyts
-
- * modules/des: Imported and tcllib-ised the DES package
- from wiki page "DES in Tcl" by Jochen Loewer. NOT added to the
- main package list as it requires CBC/CFB/OFB modes for real use.
-
-2003-01-18 Andreas Kupries
-
- * More doctools changes: Command [strong] is deprecated now. Added
- the command [copyright]. Went through all manpages to eliminate
- [strong]. Partial setting of copyright information, where known.
-
-2003-01-13 Andreas Kupries
-
- * mkInstallScripts.tcl:
- * Makefile.in (install-libraries): Added module specific
- installation code.
-
- doctools: Install message catalogs and predefined formatting
- engines.
-
- textutil: Install hyphenation files.
-
- * Module doctools rewritten to make it a true package +
- application, instead of a pure application module. This means
- that this module now truly installs some functionality useable
- by other applications and packages.
-
-2003-01-03 Pat Thoyts
-
- * smtpd: enhanced error handling for FR #655611
- Handle some ESMTP options.
-
-2002-11-24 Gerald Lester
-
- * html: Fixed bug #643337 (changes made though 2002-12-2)
-
-2002-11-24 Gerald Lester
-
- * html: Fixed bug #596000
-
-2002-10-16 Andreas Kupries
-
- * struct (graph): Implemented FR 603924
-
-2002-10-14 Andreas Kupries
-
- * pop3: Fixed bug #620062.
-
-2002-10-09 Andreas Kupries
-
- * Makefile.in (install-libraries): Added code to skip directories
- without .tcl files. Some shells do not like a for with nothing
- to iterate over.
-
-2002-10-08 Pat Thoyts
-
- * smtpd: implemented feature request #531531 to use MIME tokens
-
-2002-09-25 Jeff Hobbs
-
- * Makefile.in: better DESTDIR/libdir support (steffen)
-
-2002-09-14 Andreas Kupries
-
- * mime: New field_decode, extended testsuite.
-
-2002-09-04 Andreas Kupries
-
- * all.tcl (tcltest::tooManyMessage): Additional command to create
- different error messages for 8.3 and 8.4. Used in the testsuite
- of pop3.
-
-2002-08-30 Andreas Kupries
-
- * cmdline:
- * counter:
- * dns:
- * ftpd:
- * html:
- * ncgi:
- * examples/ftp: Cleaned up nits ('info exist' --> 'info exists').
-
-2002-08-21 Andreas Kupries
-
- * examples/ftp: Fixed problem in ftpdemo.tcl.
-
-2002-08-19 Andreas Kupries
-
- * nntp: Updated documentation, see Tcllib SF #597102.
-
- * Makefile.in (install-doc): Fixed problem noted by Elchonon
- Edelson. Code to inline man.macros appended to existing
- files. Multiple execution of 'make install-doc' thus extended
- the manpages of tcllib with multiples of their original
- content. Not anymore.
-
-2002-08-16 Andreas Kupries
-
- * exif: Applied patch #582828. Partially applied #530970.
-
-2002-08-15 Andreas Kupries
-
- * Makefile.in (DOC_EXP): Use the tclsh found during configuration
- to run mpexpand. This ensures that mpexpand does not pick
- something from the path on its own, possibly something too old
- to understand TCLLIBPATH. Problem noted by Elchonon Edelson
- .
-
- * mime: Accepted SF Tcllib FR #595240. This entails the donation
- of the personal mail filter mbot, as written and used by
- Marshall T. Rose, as an example of the usage of the mime and
- smtp packages.
-
- * mime (smtp): Followup to patch SF #557520/2 (See 2002-07-25).
-
-2002-08-09 Andreas Kupries
-
- * Makefile.in (install-doc): Changed $$(basename) to
- `basename`. Portability problem. Works for Linux for example,
- but not everywhere else. See 2002-08-06 for the change which
- introduced this.
-
-2002-08-08 Andreas Kupries
-
- * htmlparse: Fixed SF bug #579853.
-
-2002-08-06 Andreas Kupries
-
- * Makefile.in (dist): Fixed SF Bug #567079, reported by Don Porter
- . No infinite recursion anymore for
- srcdir == builddir.
-
- * ftp: Fixed SF Bug #582668.
-
- * comm: Fixed SF Bug #589225.
-
- * Makefile.in (install-doc): Restored the code inlining the
- man.macros file into the generated nroff manpages. Got somehow
- deleted. Was still in the 'dist' target. Thanks to Reinhard Max
- for noticing this.
-
- * struct (pool): Fixed bug SF #585093.
- * struct (tree): Fixed bug SF #587533.
-
-2002-07-25 Andreas Kupries
-
- * mime: Applied SF patch #585455.
- * mime (smtp): Applied patch SF #557520/2.
-
-2002-07-08 Andreas Kupries
-
- * struct (tree): Fixed SF bug #578460.
-
- * doctools: Fixed bug #578465.
-
-2002-07-02 Don Porter
-
- * all.tcl: Corrected name of tcltest hook procedure
-
-2002-06-24 Andreas Kupries
-
- * csv: Fixed SF bug #565051.
-
- * mime: Fixed SF bug #548832.
-
-2002-06-17 Andreas Kupries
-
- * Applied patch for bug #567428. Bug reported by Larry Virden
- , patch by him too. Correction of
- spelling mistakes in the documentation of various modules +
- correction of comment placements which interfere with solaris
- conventions for nroff output.
-
-2002-06-10 Andreas Kupries
-
- * Released and tagged tcllib 1.3.0. ========================
-
-2002-06-07 Andreas Kupries
-
- * dns: Fixed SF bug #564670.
-
-2002-06-05 Andreas Kupries
-
- * all.tcl: Updated to use a default value for -modules if that
- option is not present.
-
- * install.tcl: New file, alternate installer for unix and
- windows. Execute with any tclsh and tcllib 1.3 is installed in
- the parent directory of the tcl script library
- directory. Courtesy Gerald Lester
- .
-
- * Makefile.in (install-doc): Changed to use the doctools generated
- nroff and html files instead of the manually written .n files.
-
- * configure.in (MINOR_VERSION): Updated to version 1.3
-
- * Makefile.in (doc): Removed tmml-doc from default set of
- documentation.
-
- * Makefile.in (dist, install): New target 'gen-main-index'
- encapsulates the generation of the package index for
- tcllib. This target is used by both the direct installation
- (install) and during the generation of a source distribution
- (dist).
-
- * mkIndex.tcl: Rewritten to make use of 'pkg_mkIndex' to get the
- list of all packages in tcllib. Added a message which deprecates
- [package require tcllib] if it is used.
-
-2002-06-03 Andreas Kupries
-
- * math (calculus): Fixed SF Tcllib Bug #553773.
-
- * ftpd:
- * html:
- * htmlparse:
- * base64:
- * uuencode: Updated version information.
-
-2002-05-29 Andreas Kupries
-
- * mime: Fixed SF Tcllib Bug #561416
-
-2002-05-27 Andreas Kupries
-
- * base64: Fixed SF Tcllib Bug #548354.
-
-2002-05-21 Andreas Kupries
-
- * doctools: Fixed bug #556509.
- * fileutil: Fixed bug #556504.
-
-2002-05-15 Andreas Kupries
-
- * pop3d: Fixed bug #532216. All parts of pop3d now have a
- testsuite.
-
-2002-05-14 Andreas Kupries
-
- * pop3d: Added testsuites for user database and simple mailbox
- storage.
-
- * fileutil: SF Bug #462015 closed. Proosed change rejected, added
- new commands to perform the desired operation instead.
-
-2002-05-09 Andreas Kupries
-
- * doctools: Fixed bug #534334 (actually more a FR).
-
- * examples/csv/csvdiff: Applied patch associated with tcllib SF
- bug #551133. Bug reported by ,
- patch by .
-
- Accepted FR #551127 and added code implementing the feature.
-
-2002-05-08 Andreas Kupries
-
- * struct (tree): Accepted FR #552972.
-
- * mime: Fixed bugs #539952, #553784.
-
-2002-05-08 Don Porter
-
- * all.tcl: Show full stack trace when an error occurs sourcing
- a test file.
-
-2002-04-24 Andreas Kupries
-
- * cmdline: Accepted patch #540313
-
- * examples/ftp/hpupdate.tcl: Accepted patch #548221 by Larry
- Virden .
- Fixed bug #548224 (Touch).
-
- * base64: Fixed bug #548112.
-
-2002-04-23 Andreas Kupries
-
- * doctools: Fixed bug #527025.
-
- * smtp (mime): Fixed bug #547336.
-
-2002-04-16 Andreas Kupries
-
- * Makefile.in (dist): Ensured that the deprecated module 'stats'
- is not distributed anymore. Use 'counter' instead.
- (*-force): Enforced generation of documentation, for developers.
-
-2002-04-10 Andreas Kupries
-
- * Makefile.in (MODULES): Added irc module.
-
-2002-04-04 Andreas Kupries
-
- * mime: Fixed bug #533025.
-
-2002-04-01 Andreas Kupries
-
- * Makefile.in (doc_generate): Added 'touch' command to prevent
- multiple execution of target.
-
- * struct (matrix): Fixed bug #532791.
-
- * doctools: Fixed SF Bug #535382.
-
-2002-03-25 Andreas Kupries
-
- * doctools: Implemented FR #530059 and FR #527029.
-
- * Fixed minor formatting errors in several existing doctools
- manpages.
-
- * struct (matrix): Fixed bug #532783.
-
-2002-03-19 Andreas Kupries
-
- * ftpd: Fixed SF Bug #531799.
-
- * New module: pop3d. A POP3 server.
- * Makefile.in: Added pop3d.
-
-2002-03-15 Andreas Kupries
-
- * math: Update of calculus. #528434
-
- * report, struct (matrix): Fixed bug #530207.
-
-2002-03-14 Andreas Kupries
-
- * textutil (expander): Fixed SF Bug #530056.
-
-2002-03-13 Andreas Kupries
-
- * doctools: Fixed bug #528390.
-
-2002-03-09 Andreas Kupries
-
- * struct (matrix): Accepted FR #524430 (-nocase).
-
- * doctools: FR #527716 accepted. Bug #527025 partially fixed.
-
-2002-03-07 Andreas Kupries
-
- * Makefile.in (doc_generate): Added "TCLLIBPATH=$(srcdir)/modules"
- in front of the mpexpand invocation so that it is forced to use
- the "expander" package inside of the distribution. This fixes
- Tcllib Bug #525007 reported by Don Porter
- .
-
-2002-03-02 Pat Thoyts
-
- * New module: dns
- * Makefile.in: updated for new module
-
-2002-02-27 Andreas Kupries
-
- * doctools: Done FR #517599. FR #520269.
-
- * mime: Fixed bug #519623.
-
- * Makefile.in (install-doc): Changed code determining the files to
- install to handle missing files better (use 'ls', suppress error
- messages).
-
-2002-02-18 Andreas Kupries
-
- * exif: New module. FR 517066 accepted.
-
-2002-02-14 Andreas Kupries
-
- * Makefile.in (statcheck, frink, procheck): Added developer
- targets to invoke two static code checkers.
-
- * Ran frink over the package and corrected several minor problems.
-
-2002-02-12 Andreas Kupries
-
- * Makefile.in: Added target for generation of documentation in
- various formats from .man pages
-
-2002-02-01 Andreas Kupries
-
- * mime: Applied patch 511692.
-
-2002-01-21 Andreas Kupries
-
- * Makefile.in (dist): Brought archive names and contents more in
- sync with earlier releases. This comes from work on release 1.2.
-
-2002-01-18 Andreas Kupries
-
- * Bumped version to 1.2, new release. Summary of changes here. See
- the individual Changelogs to see the detailed changes in each
- module.
-
- New modules: calendar, crc, doctools, irc, smtpd, and stooop.
-
- calendar: Version is 0.1
- crc: Version is 1.0
- doctools: Version is 1.0
- irc: Version is 0.1
- smtpd: Version is 1.0
- stooop: Version is 4.3
-
- Changed modules: base64, comm, control, csv, fileutil, ftp,
- html, math, mime, ncgi, nntp, pop3, struct, textutil, and uri.
-
- base64: Version stays @ 2.2, but got new subpackage.
- comm: Version up to 3.7.1
- control: Version up to 0.2
- csv: Version up to 0.2
- fileutil: Version up to 1.3
- ftp: Version up to 2.3
- html: Version up to 1.2
- math: Version up to 1.2
- mime: Version up to 1.3.1
- ncgi: Version up to 1.2.1
- nntp: Version up to 0.2
- pop3: Version up to 1.5.1
- struct: Version up to 1.2
- textutil: Version up to 0.4
- uri: Version up to 1.1
-
-2002-01-18 Andreas Kupries
-
- * Makefile.in (dist): Fixed bug #495976.
-
-2002-01-17 Pat Thoyts
-
- * crc module: added sum manual page
- * base64 module: added uuencode manual page
-
-2002-01-17 Andreas Kupries
-
- * examples/csv/csvdiff: New example for csv module. FR #485717.
-
- * mime: Fixed bug #499242.
-
-2002-01-16 Andreas Kupries
-
- * mime: Implemented FR #503336
- * ftp: Fixed bug #503471.
- * nntp: Fixed bug #502250
-
-2002-01-16 Pat Thoyts
-
- * base64 module: added uuencode package
- * crc module: added sum and cksum packages.
-
-2002-01-11 Pat Thoyts
-
- * mkInstallScripts.tcl:
- * Makefile.in: Added crc and smtpd modules to the installation files.
-
-2002-01-11 Kevin Kenny
-
- * mkInstallScripts.tcl: Changed the installation process for
- Windows to avoid the unimplemented [file permissions] in favor of
- [file attributes].
-
-2002-01-11 Kevin Kenny
-
- * New module: calendar.
-
-2002-01-11 Pat Thoyts
-
- * New module: crc. From patch #501339
-
-2002-01-11 Andreas Kupries
-
- * Makefile.in (install-doc): Fixed bug #500655. Using the code
- from the tcl "Makefile.in" as template equivalent code for
- tcllib was created and added to the file "Makefile.in". The
- modified makefile now includes the contents of "man.macros" into
- every installed manpage.
-
- * html: Applied patch #484117.
-
-2001-12-14 Andreas Kupries
-
- * New module: doctools. FR #492234.
-
-2001-12-13 Andreas Kupries
-
- * texturil: Applied patch #492156.
-
-2001-12-11 Andreas Kupries
-
- * pop3: Bugfix for item #490151.
-
- * textutil: Bugfix for item #476988.
-
-2001-12-10 Andreas Kupries
-
- * textutil: Update from William, 'evalcmd' callback.
-
-2001-12-06 Andreas Kupries
-
- * fileutil: Bugfix for item #486572.
-
-2001-11-28 Reinhard Max
-
- * split.tcl: Speed improvement.
-
-2001-11-23 Andreas Kupries
-
- * struct.matrix: Implemented FR #481022.
-
-2001-11-19 Andreas Kupries
-
- * irc: Added IRC example to examples section. Patch #481479.
-
- * struct/graph: Applied patch #483125
-
- * smtpd: Example consolidation: Moved the smtpd example to
- 'examples' directory.
-
- * ftp: Implemented FR #481161.
-
- * ftpd: Added example ftp server used for testing the
- functionality of FR #481161.
-
-2001-11-17 Pat Thoyts
-
- * smtpd: New module.
-
-2001-11-16 Andreas Kupries
-
- * csv: Applied patch #482570.
-
- * comm: Fixed bug #480227.
-
- * ftp, uri: Implemented FR #476804.
-
- * ftp: Applied patch #428053.
-
-2001-11-12 Andreas Kupries
-
- * irc: New module. Internet protocol handling. Internet Relay Chat
- (IRC). Author David N. Welton .
-
- * examples/nntp: Moved example applications out of the nntp module
- into the example space.
-
- * examples/ftpd: Moved example applications out of the ftpd module
- into the example space.
-
- * examples/ftp: Moved example applications out of the ftp module
- into the example space.
-
- * csv: Implemented FR #481023.
-
- * textutil: Added 'expander' code by William H. Duquette
- . Added option -strictlength to
- adjust. Code by Dan Kuchler .
-
-2001-11-09 Joe English
-
- * comm: Replaced nroff macro trickery in comm.n manpage.
-
-2001-11-07 Andreas Kupries
-
- * mime: Fixed bug #479174.
-
- * mkInstallScripts.tcl: Added code to install tclIndex files.
-
- * Makefile.in (install-libraries, dist): Added commands to copy
- 'tclIndex' files into installation and distribution. This fixes
- the remainder of #475846.
- (dist): Fixed error in generation of tar/zip files too.
-
-2001-11-07 Andreas Kupries
-
- * examples/ftp/ftpvalid: New example, using ftp and uri
- modules. Validation of ftp urls.
-
- * fileutil: Accepted Patch #477805.
- * ftp: Accepted Patch #478478.
-
-2001-11-07 Reinhard Max
-
- * control: added implementation for a 'do ... while/until' loop.
-
-2001-11-04 Andreas Kupries
-
- * ftp: Fixed bug #476729.
-
-2001-11-01 Andreas Kupries
-
- * mime: Fixed bugs #477088, #472009.
-
-2001-10-21 Andreas Kupries
-
- * uri: Accepted patch #470211.
-
-2001-10-20 Andreas Kupries
-
- * ncgi: Fixed bug #464560.
- * ftp: Fixed bug #466746.
-
-2001-10-17 Andreas Kupries
-
- * ------------------ Tcllib 1.1 released ------------------
-
- * tcllib moved to version 1.1
-
- * cmdline: Version up to 1.1.1
- * ftp: Version up to 2.2.1
- * html: Version up to 1.1.1
- * md5: Version up to 1.4.1
- * mime/smtp: Version up to 1.3
- * ncgi: Version up to 1.2
- * pop3: Version up to 1.5
- * report: Version up to 0.2
- * sha1: Version up to 1.0.1
- * struct: Version up to 1.1.1
- * textutil: Version up to 0.3
-
-2001-10-14 Jeff Hobbs
-
- * csv.tcl: moved to v0.2
-
-2001-09-24 Joe English
-
- * modules/ftpd/ftpd.tcl: fix improperly-formatted multi-line
- replies. See SF tracker ID #424797
-
-2001-08-24 Andreas Kupries
-
- * Makefile.in (check): Added target to report modules without
- testsuites and/or manpages.
-
-2001-08-22 Andreas Kupries
-
- * examples/nntp: Added new example application 'postnews'. This is
- an example how to use the 'nntp'-client library provided by
- tcllib.
-
- * Makefile.in (MODULES): Added package 'comm'.
-
-2001-08-21 Don Porter
-
- * Makefile.in (MODULES): Added package 'control'.
-
-2001-08-20 Andreas Kupries
-
- * Makefile.in (mandir, libdir): Applied patch [447141] by Reinhard
- Max to virtualize mandir and libdir
- via ${INSTALL_ROOT}.
-
- * all.tcl: Added ::tcltest::getErrorMessage in preparation of
- fixing [440051], [440049] and [440046] reported by Larry Virden
- .
-
-2001-07-17 Andreas Kupries
-
- * Bumped version to 1.0
-
-2001-07-10 Andreas Kupries
-
- * Frink 2.2 run, fixed dubious code.
-
-2001-07-06 Andreas Kupries
-
- * Fixed #438748, corrections of various misspellings in manpages
- accross all modules.
-
-2001-06-21 Andreas Kupries
-
- * Ran frink and procheck over all modules and fixed the reported
- problems. As far as they actually were problems.
-
-2001-06-21 Andreas Kupries
-
- * Makefile.in (MODULES): Added module 'sha1'. This is another
- message digest like 'md5'.
-
-2001-05-01 Andreas Kupries
-
- * Makefile.in (MODULES): Added module 'report'.
-
- * all.tcl: Added code to propagate "::tcltest::testDirectory" into
- the slave actually doing the tests. This tripped some of the
- tests for the new CSV module as they use some external files and
- were thus unable to find them correctly without this setting.
-
- * Makefile.in (MODULES): Added module 'csv'.
-
- * Added directory 'examples' for future sample applications of
- tcllib and some example applications too.
-
-2001-04-24 Andreas Kupries
-
- * Makefile.in: Added module 'md5'.
-
-2001-03-26 Andreas Kupries
-
- * Makefile.in (install-libraries): [Bug #404917]
- Added 'smtp' explictly to the list of modules for the full
- package index. It is part of the 'mime' directory and thus not
- automatically found / part of the list.
-
-2001-03-26 Andreas Kupries
-
- * Makefile.in: Added module 'htmlparse'.
-
-2001-03-21 Andreas Kupries
-
- * Makefile.in: Added module 'log'.
-
-2001-03-20 Andreas Kupries
-
- * all.tcl: [Bug #410100, Patch #410105]
- Squashed a subtle bug with package management for the
- tests. Changes: all.tcl now adds the module path to the
- auto_path (the tested modules did it themselves before) and also
- moved the setting of the auto_path in the slave before the first
- 'package require'. Why ? Assume the old code, an installed
- fileutil 1.0 and a new fileutil 1.1 under development. The
- initialization of the tests scans the package directories and
- finds fileutil 1.0. The module then adds itself to the auto_path
- and then requires fileutil (without version). Now fileutil 1.0
- is found by the pkg management, it is acceptable according to
- the rules of require and thus used. The new version is not
- considered at all, as changing the auto_path does *not* enforce
- a rescan of package directories. It is possible to solve the
- problem by having the modules require themselves and request a
- specific version (1.1 in this case). But this would mean that in
- each module we have (at least) one more file containing the
- version number (all test files!) and we have to maintain this
- for every module. The change here however solves the problem
- without touching the modules at all.
-
-2000-11-02 Brent Welch
-
- * configure.in: Bumped version number to 0.8
-
-2000-11-01 Dan Kuchler
-
- * Makefile.in: Added javascript package to tcllib.
-
-2000-10-27 Dan Kuchler
-
- * Makefile.in: Added ftpd package to tcllib.
-
-2000-10-04 Brent Welch
-
- * Makefile.in: Nuked stats in favor of counter.
-
-2000-09-19 Brent Welch
-
- * Makefile.in:
- Added the stats module.
- * configure.in:
- Increased version number to 0.7
- * modules/stats/stats.tcl:
- * modules/stats/stats.n:
- * modules/stats/stats.test:
- * modules/stats/pkgIndex.tcl:
- Initial version of the stats package.
-
-2000-08-23 Brent Welch
-
- * Makefile.in: fixed typo
-
-2000-08-22 Brent Welch
-
- * configure.in: Bumped patchlevel to 0.6.1
- * Makefile.in: Ignore errors when installing documentation,
- which only partly exists. You'll still see the error messages
- but it doesn't stop the install.
- Applied tcllib-0-6-1 tag
-
-2000-07-19 Brent Welch
-
- * configure.in: Bumped patchlevel to 0.6
- applied tcllib-0-6 tag
-
-2000-06-15 Dan Kuchler
-
- * Makefile.in: Added nntp client package.
- * modules/nntp: Added nntp client package to tcllib.
-
-2000-06-13 Eric Melski
-
- * Makefile.in: Added uri package.
- * modules/uri: Added uri package from Steve Ball, Andreas Kupries.
-
-2000-06-09 Brent Welch
-
- * configure.in: Bumped patchlevel to 0.5
- applied tcllib-0-5 tag
-
-2000-06-02 Eric Melski
-
- * Makefile.in: Added ftp package.
- * modules/ftp: Added ftp package from Steffen Traeger to tcllib.
-
-2000-04-28 Sandeep Tamhankar
-
- * mkInstallScripts.tcl: Fixed a bug in the UNIX shell script where
- it was checking if TCLINSTALL was non-null, but it was using ==,
- which isn't legal in /bin/sh. I found this out the hard way while
- trying to install tcllib0.4 in the default location
- (/usr/local/lib/tcllib0.4) and because of this bug, it ended up
- installing in /lib/tcllib0.4.
-
-2000-04-26 Brent Welch
-
- * configure.in: Bumped patchlevel to 0.4
- * Makefile.in: Fixed dist target to deal with missing manual
- pages and test files.
- * mkInstallScripts.tcl: Made install directory a parameter to
- the unix install.sh script
-
-2000-04-25 Eric Melski
-
- * Makefile.in: Tweaked dist target to include README and
- license.terms in distributions.
-
-2000-04-17 Brent Welch
-
- * modules/html: Added html generation module
-
-2000-04-10 Brent Welch
-
- * Makefile.in: restored ncgi module
-
-2000-04-07 Eric Melski
-
- * configure:
- * configure.in: Upped version to 0.3.
-
-2000-03-29 Eric Melski
-
- * mkIndex.tcl: Added missing "== -1" to [lsearch] for package dir
- in generated pkgIndex.tcl.
-
-2000-03-28 Eric Melski
-
- * Makefile.in: Added $(srcdir)/ prefix to mkIndex.tcl call in the
- install-libraries target, so that it would find the mkIndex.tcl
- script when run outside of the source tree. Same for man.macros
- in the install-doc target, so it would find the file.
-
-2000-03-27 Eric Melski
-
- * Makefile.in: Added dist target for building distribution.
-
- * configure.in: Removed mkIndex.tcl from AC_OUTPUT call.
-
- * mkInstallScripts.tcl: First cut at script for autogenerating
- simple INSTALL.BAT and install.sh files for tcllib distributions.
-
- * mkIndex.tcl:
- * mkIndex.tcl.in: Replace mkIndex.tcl.in with mkIndex.tcl, which
- now takes more args to specify values.
-
-2000-03-09 Eric Melski
-
- * Makefile.in: Added ncgi module, commented out until tests are done.
-
-2000-03-09 Eric Melski
-
- * Makefile.in: Updated test target to call out to all.tcl.
-
- * all.tcl: First checkin of all.tcl, the magic that hides behind
- "make test".
-
-2000-03-08 Eric Melski
-
- * Makefile.in: Commented out cgi module until it's ready for use.
- Added checks for bogus module names in install-libraries, but
- they're not foolproof.
-
-2000-03-07 Brent Welch
-
- * modules/cgi: Preliminary version of a CGI module. Still needs
- some cookie functions, test suite, and docs...
-
-2000-03-07 Eric Melski
-
- * modules/math: math library
-
- * Makefile.in: added math library to list of modules
-
-2000-03-07 Scott Stanton
-
- * configure.in:
- * configure:
- * aclocal.m4:
- * Makefile.in: Changed to use shared config subdirectory. Also
- fixed problem on Windows builds where it would fail to identify
- the tclsh executable to use. Simplified configure.in to minimum
- number of macros.
-
-2000-03-06 Eric Melski
-
- * man.macros: Moved from individual modules to toplevel tcllib
- dir, so that it is not repeated hundreds of times.
-
- * Makefile.in:
- * mkIndex.tcl.in: Added version number to installed tcllib dir.
-
- * license.terms: Adapted license from Tcl.
-
- * README: Added more information about file layout in module dirs.
-
-2000-03-06 Scott Redman
-
- * Makefile.in: added pop3 module.
-
-2000-03-02 Eric Melski
-
- * mkIndex.tcl.in: Instead of probing install dir for modules,
- changed to take module list on command line, so that users can
- change what goes into the pkgIndex.tcl from the Makefile.
-
- * Makefile.in: additional work on module list and pkgIndex.tcl
- generation. Now changing the module list changes what is
- installed and what is put in the pkgIndex.tcl.
-
-2000-03-02 Eric Melski
-
- * Makefile.in: Work on install-libraries, install-doc; removed
- references to compiled bits.
-
- * mkIndex.tcl.in: Tweaked the generated pkgIndex.tcl to only
- append the dirname if it doesn't already exist in the auto_path,
- and to use \[file dirname \[info script\]\] instead of [pwd].
-
- * configure:
- * configure.in: Removed checks for compiler, and all stuff related
- to compiling/linking (this is a tcl only extension).
-
- * tcl.m4: new tcl.m4 from sample extension.
-
-2000-03-01 Eric Melski
-
- * Makefile.in: Added fileutil, cmdline, mime, base64 modules.
-
-2000-02-24 Eric Melski
-
- * Makefile.in, et al: Preliminary Makefile and configure script, and
- supporting files
DELETED INSTALL.txt
Index: INSTALL.txt
==================================================================
--- INSTALL.txt
+++ /dev/null
@@ -1,77 +0,0 @@
-How to install Tcllib
-=====================
-
-Introduction
-------------
-
-The tcllib distribution, whether a snapshot directly from CVS, or
-officially released, offers a single method for installing tcllib,
-based on Tcl itself.
-
-This is based on the assumption that for tcllib to be of use Tcl has
-to be present, and therefore can be used.
-
-This single method however can be used in a variety of ways.
-
-0 For an unwrapped (= directory) distribution or CVS snapshot
-
- a. either call the application 'installer.tcl' directly,
- b or use
-
- % configure ; make install
-
- The latter is provided for people which are used to
- this method and more comfortable with it. In end this
- boils down into a call of 'installer.tcl' too.
-
-1. A starpack distribution (window-only) is a self-extracting
- installer which internally uses the aforementioned installer.
-
-2. A starkit distribution is very much like a starpack, but
- required an external interpreyter to run. This can be any tcl
- interpreter which has all the packages to support starkits
- (tclvfs, memchan, trf).
-
-3. A distribution in a tarball has to be unpacked first, then any
- of the methods described in (0) can be used.
-
-
-Usage of the installer
-----------------------
-
-The installer selects automatically either a gui based mode, or a
-command line based mode. If the package Tk is present and can be
-loaded, then the GUI mode is entered, else the system falls back to
-the command line.
-
-Note that it is possible to specify options on the command line even
-if the installer ultimatively selects a gui mode. In that case the
-hardwired defaults and the options determine the data presented to the
-user for editing.
-
-Command line help can be asked for by using the option -help when
-running the installer (3) or the distribution itself in the case of
-(1) or (2).
-
-The installer will select a number of defaults for the locations of
-packages, examples, and documentation, and also the format of the
-documentation. The user can overide these defaults in the GUI, or by
-specifying additional options.
-
-The defaults depend on the platform detected (unix/windows) and the
-executable used to run the installer. In the case of a starpack
-distribution (1) this means that _no defaults_ are possible for the
-various locations as the executable is part of the distribution and
-has no knowledge of its environment.
-
-In all other cases the intepreter executable is outside of the
-distribution, which means that its location can be used to determine
-sensible defaults.
-
-Notes
------
-
-The installer will overwrite an existing installation of tcllib 1.4
-without asking back after the initial confirmation is given. And if
-the user chooses the same directory as for tcllib 1.3 the installer
-will overwrite that too.
DELETED Makefile.in
Index: Makefile.in
==================================================================
--- Makefile.in
+++ /dev/null
@@ -1,110 +0,0 @@
-# Makefile.in --
-#
-# This file is a Makefile for the tcllib standard tcl library. If this
-# is "Makefile.in" then it is a template for a Makefile; to generate
-# the actual Makefile, run "./configure", which is a configuration script
-# generated by the "autoconf" program (constructs like "@foo@" will get
-# replaced in the actual Makefile.
-#
-# Copyright (c) 1999-2000 Ajuba Solutions
-# Copyright (c) 2001 ActiveState Tool Corp.
-#
-# See the file "license.terms" for information on usage and redistribution
-# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# RCS: @(#) $Id: Makefile.in,v 1.90 2003/04/18 02:57:46 andreas_kupries Exp $
-
-#========================================================================
-# Nothing of the variables below this line need to be changed. Please
-# check the TARGETS section below to make sure the make targets are
-# correct.
-#========================================================================
-
-SHELL = @SHELL@
-
-srcdir = @srcdir@
-top_srcdir = @top_srcdir@
-prefix = @prefix@
-exec_prefix = @exec_prefix@
-libdir = @libdir@
-mandir = @mandir@
-
-DESTDIR =
-pkglibdir = $(libdir)/@PACKAGE@@VERSION@
-top_builddir = .
-
-PACKAGE = @PACKAGE@
-VERSION = @VERSION@
-CYGPATH = @CYGPATH@
-
-TCLSH_PROG = @TCLSH_PROG@
-
-CONFIG_CLEAN_FILES =
-
-#========================================================================
-# Start of user-definable TARGETS section
-#========================================================================
-
-all:
-install: install-libraries install-doc
-doc: html-doc nroff-doc
-
-install-libraries:
- $(TCLSH_PROG) `$(CYGPATH) $(srcdir)/installer.tcl` \
- -pkg-path $(DESTDIR)$(pkglibdir) \
- -no-examples -no-html -no-nroff \
- -no-wait -no-gui
-
-install-doc:
- $(TCLSH_PROG) `$(CYGPATH) $(srcdir)/installer.tcl` \
- -nroff-path $(DESTDIR)$(mandir)/mann \
- -no-examples -no-pkgs -no-html \
- -no-wait -no-gui
-
-test:
- $(TCLSH_PROG) `$(CYGPATH) $(srcdir)/sak.tcl` test
-
-depend:
-dist:
- $(TCLSH_PROG) `$(CYGPATH) $(srcdir)/sak.tcl` gendist
-
-clean:
- rm -rf doc *-doc
-
-distclean: clean
- -rm -f Makefile $(CONFIG_CLEAN_FILES)
- -rm -f config.cache config.log stamp-h stamp-h[0-9]*
- -rm -f config.status
-
-Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
- cd $(top_builddir) \
- && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-uninstall-binaries:
-
-
-html-doc:
- $(TCLSH_PROG) `$(CYGPATH) $(srcdir)/sak.tcl` html
-nroff-doc:
- $(TCLSH_PROG) `$(CYGPATH) $(srcdir)/sak.tcl` nroff
-tmml-doc:
- $(TCLSH_PROG) `$(CYGPATH) $(srcdir)/sak.tcl` tmml
-wiki-doc:
- $(TCLSH_PROG) `$(CYGPATH) $(srcdir)/sak.tcl` wiki
-latex-doc:
- $(TCLSH_PROG) `$(CYGPATH) $(srcdir)/sak.tcl` ps
-list-doc:
- $(TCLSH_PROG) `$(CYGPATH) $(srcdir)/sak.tcl` list
-
-check:
- $(TCLSH_PROG) `$(CYGPATH) $(srcdir)/sak.tcl` validate
-
-sak-help:
- $(TCLSH_PROG) `$(CYGPATH) $(srcdir)/sak.tcl` help
-
-
-.PHONY: all binaries clean depend distclean doc install installdirs libraries test
-
-# Tell versions [3.59,3.63) of GNU make to not export all variables.
-# Otherwise a system limit (for SysV at least) may be exceeded.
-.NOEXPORT:
DELETED README
Index: README
==================================================================
--- README
+++ /dev/null
@@ -1,75 +0,0 @@
-RCS: @(#) $Id: README,v 1.6 2003/04/17 22:54:04 andreas_kupries Exp $
-
-Welcome to the tcllib, the Tcl Standard Library. This package is
-intended to be a collection of Tcl packages that provide utility
-functions useful to a large collection of Tcl programmers.
-
-The home web site for this code is http://tcllib.sourceforge.net/ .
-At this web site, you will find mailing lists, web forums, databases
-for bug reports and feature requests, the CVS repository (browsable on
-the web, or read-only accessible via CVS ), and more.
-
-The structure of the tcllib source hierarchy is:
-
-tcllib
- +- modules
- +-
- +-
- +- ...
-
-
-The install hierarchy is:
-
-.../lib/tcllib
- +-
- +-
- +- ...
-
-There are some base requirements that a module must meet before it
-will be added to tcllib:
-
-* the module must be a proper Tcl package
-* the module must use a namespace for its commands and variables
-* the name of the package must be the same as the name of the
- namespace
-* the module must reside in a subdirectory of the modules directory in
- the source hierarchy, and that subdirectory must have the same name
- as the package and namespace
-* the module must be released under the BSD License, the terms of
- which can be found in the toplevel tcllib source directory in the file
- license.terms
-* the module should have both documentation ([*]) and a test suite
- (in the form of a group of *.test files in the module directory).
-
- [*] Possible forms: doctools, TMML/XML, nroff (man), or HTML.
- The first format is the most prefered as it can be processed with
- tools provided by tcllib itself (See module doctools). The first
- two are prefered in general as they are semantic markup and thus
- easier to convert into other formats.
-
-* the module must have either documentation or a test suite. It can
- not have neither.
-* the module should adhere to Tcl coding standards
-
-When adding a module to tcllib, be sure to add it to the Makefile.in
-so it will be installed. Add a line like:
-
-MYNEWMODULE=mynewmodule
-
-to the list of modules at the top of the Makefile.in, and then add
-$(MYNEWMODULE) to the definition of the MODULES variable. This will
-allow users to choose which modules to install by commenting or
-uncommenting lines in the Makefile.
-
-Each module source directory should have no subdirectories (other than
-the CVS directory), and should contain the following files:
-
-* source code *.tcl
-* package index pkgIndex.tcl
-* tests *.test
-* documentation *.man, *.n, *.xml
-
-If you do not follow this directory structure, the tcllib Makefile
-will fail to locate the files from the new module.
-
-
DELETED STATUS
Index: STATUS
==================================================================
--- STATUS
+++ /dev/null
@@ -1,23 +0,0 @@
-tcllib STATUS:
-$Id: STATUS,v 1.2 2002/12/17 01:47:26 davidw Exp $
-
-Release:
--------
-
-Next release?
-
-To be done before release?
-
-Open Issues:
------------
-
-Problems outlined here (bgerror):
-https://sourceforge.net/mailarchive/forum.php?thread_id=1288113&forum_id=6718
-
- Bugs/feature requests need filing.
-
- Several solutions offered - we need to pick one.
-
-"Feature requests" for packages doing their own output.
-
-Feature requests for packages using too much regexp/regsub.
DELETED aclocal.m4
Index: aclocal.m4
==================================================================
--- aclocal.m4
+++ /dev/null
@@ -1,84 +0,0 @@
-# tcl.m4 --
-#
-# This file provides a set of autoconf macros to help TEA-enable
-# a Tcl extension.
-#
-# Copyright (c) 1999-2000 Ajuba Solutions.
-# All rights reserved.
-#
-# See the file "license.terms" for information on usage and redistribution
-# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-
-#------------------------------------------------------------------------
-# SC_SIMPLE_EXEEXT
-# Select the executable extension based on the host type. This
-# is a lightweight replacement for AC_EXEEXT that doesn't require
-# a compiler.
-#
-# Arguments
-# none
-#
-# Results
-# Subst's the following values:
-# EXEEXT
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_SIMPLE_EXEEXT, [
- AC_MSG_CHECKING(executable extension based on host type)
-
- case "`uname -s`" in
- *win32* | *WIN32* | *CYGWIN_NT* |*CYGWIN_98*|*CYGWIN_95*)
- EXEEXT=".exe"
- ;;
- *)
- EXEEXT=""
- ;;
- esac
-
- AC_MSG_RESULT(${EXEEXT})
- AC_SUBST(EXEEXT)
-])
-
-#------------------------------------------------------------------------
-# SC_PROG_TCLSH
-# Locate a tclsh shell in the following directories:
-# ${exec_prefix}/bin
-# ${prefix}/bin
-# ${TCL_BIN_DIR}
-# ${TCL_BIN_DIR}/../bin
-# ${PATH}
-#
-# Arguments
-# none
-#
-# Results
-# Subst's the following values:
-# TCLSH_PROG
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_PROG_TCLSH, [
- AC_MSG_CHECKING([for tclsh])
-
- AC_CACHE_VAL(ac_cv_path_tclsh, [
- search_path=`echo ${exec_prefix}/bin:${prefix}/bin:${TCL_BIN_DIR}:${TCL_BIN_DIR}/../bin:${PATH} | sed -e 's/:/ /g'`
- for dir in $search_path ; do
- for j in `ls -r $dir/tclsh[[8-9]]*${EXEEXT} 2> /dev/null` \
- `ls -r $dir/tclsh*${EXEEXT} 2> /dev/null` ; do
- if test x"$ac_cv_path_tclsh" = x ; then
- if test -f "$j" ; then
- ac_cv_path_tclsh=$j
- break
- fi
- fi
- done
- done
- ])
-
- if test -f "$ac_cv_path_tclsh" ; then
- TCLSH_PROG=$ac_cv_path_tclsh
- AC_MSG_RESULT($TCLSH_PROG)
- else
- AC_MSG_ERROR(No tclsh found in PATH: $search_path)
- fi
- AC_SUBST(TCLSH_PROG)
-])
DELETED all.tcl
Index: all.tcl
==================================================================
--- all.tcl
+++ /dev/null
@@ -1,192 +0,0 @@
-# all.tcl --
-#
-# This file contains a top-level script to run all of the Tcl
-# tests. Execute it by invoking "tclsh all.test" in this directory.
-#
-# To test a subset of the modules, invoke it by 'tclsh all.test -modules ""'
-#
-# Copyright (c) 1998-2000 by Ajuba Solutions.
-# All rights reserved.
-#
-# RCS: @(#) $Id: all.tcl,v 1.12 2003/03/29 02:01:23 patthoyts Exp $
-
-set old_auto_path $auto_path
-
-if {[lsearch [namespace children] ::tcltest] == -1} {
- namespace eval ::tcltest {}
- proc ::tcltest::processCmdLineArgsAddFlagsHook {} {
- return [list -modules]
- }
- proc ::tcltest::processCmdLineArgsHook {argv} {
- array set foo $argv
- catch {set ::modules $foo(-modules)}
- }
- proc ::tcltest::cleanupTestsHook {{c {}}} {
- if { [string equal $c ""] } {
- return
- }
- # Get total/pass/skip/fail counts
- array set foo [$c eval {array get ::tcltest::numTests}]
- foreach index [list "Total" "Passed" "Skipped" "Failed"] {
- incr ::tcltest::numTests($index) $foo($index)
- }
- incr ::tcltest::numTestFiles
-
- # Append the list of failFiles if necessary
- set f [$c eval {
- set ff $::tcltest::failFiles
- if {($::tcltest::currentFailure) && \
- ([lsearch -exact $ff $testFileName] == -1)} {
- set res [file join $::tcllibModule $testFileName]
- } else {
- set res ""
- }
- set res
- }] ; # {}
- if { ![string equal $f ""] } {
- lappend ::tcltest::failFiles $f
- }
-
- # Get the "skipped because" information
- unset foo
- array set foo [$c eval {array get ::tcltest::skippedBecause}]
- foreach constraint [array names foo] {
- if { ![info exists ::tcltest::skippedBecause($constraint)] } {
- set ::tcltest::skippedBecause($constraint) $foo($constraint)
- } else {
- incr ::tcltest::skippedBecause($constraint) $foo($constraint)
- }
- }
-
- # Clean out the state in the slave
- $c eval {
- foreach index [list "Total" "Passed" "Skipped" "Failed"] {
- set ::tcltest::numTests($index) 0
- }
- set ::tcltest::failFiles {}
- foreach constraint [array names ::tcltest::skippedBecause] {
- unset ::tcltest::skippedBecause($constraint)
- }
- }
- }
-
- package require tcltest
- namespace import ::tcltest::*
-}
-
-set ::tcltest::testSingleFile false
-set ::tcltest::testsDirectory [file dirname [info script]]
-set root $::tcltest::testsDirectory
-
-# We need to ensure that the testsDirectory is absolute
-::tcltest::normalizePath ::tcltest::testsDirectory
-
-puts stdout "tcllib tests"
-puts stdout "Tests running in working dir: $::tcltest::testsDirectory"
-if {[llength $::tcltest::skip] > 0} {
- puts stdout "Skipping tests that match: $::tcltest::skip"
-}
-if {[llength $::tcltest::match] > 0} {
- puts stdout "Only running tests that match: $::tcltest::match"
-}
-
-if {[llength $::tcltest::skipFiles] > 0} {
- puts stdout "Skipping test files that match: $::tcltest::skipFiles"
-}
-if {[llength $::tcltest::matchFiles] > 0} {
- puts stdout "Only sourcing test files that match: $::tcltest::matchFiles"
-}
-
-set timeCmd {clock format [clock seconds]}
-puts stdout "Tests began at [eval $timeCmd]"
-
-
-set auto_path $old_auto_path
-set auto_path [linsert $auto_path 0 [file join $root modules]]
-set old_apath $auto_path
-
-##
-## Take default action if the modules are not specified
-##
-
-if {![info exists modules]} then {
- foreach module [glob [file join $root modules]/*/*.test] {
- set tmp([lindex [file split $module] end-1]) 1
- }
- set modules [array names tmp]
- unset tmp
-}
-
-foreach module $modules {
- set ::tcltest::testsDirectory [file join $root modules $module]
-
- if { ![file isdirectory $::tcltest::testsDirectory] } {
- puts stdout "unknown module $module"
- }
-
- set auto_path $old_apath
- set auto_path [linsert $auto_path 0 $::tcltest::testsDirectory]
-
- # foreach module, make a slave interp and source that module's tests into
- # the slave. This isolates the test suites from one another.
- puts stdout "Module:\t[file tail $module]"
- set c [interp create]
- interp alias $c pSet {} set
- # import the auto_path from the parent interp, so "package require" works
- $c eval {
- set ::argv0 [pSet ::argv0]
- set ::tcllibModule [pSet module]
- set auto_path [pSet auto_path]
- package require tcltest
- namespace import ::tcltest::*
- set ::tcltest::testSingleFile false
- set ::tcltest::testsDirectory [pSet ::tcltest::testsDirectory]
- #set ::tcltest::verbose ps
-
- # Add a function to construct a proper error message for
- # 'wrong#args' situations. The format of the messages changed
- # for 8.4
-
- proc ::tcltest::getErrorMessage {functionName argList missingIndex} {
- # if oldstyle errors:
- if { [info tclversion] < 8.4 } {
- set msg "no value given for parameter "
- append msg "\"[lindex $argList $missingIndex]\" to "
- append msg "\"$functionName\""
- } else {
- set msg "wrong # args: should be \"$functionName $argList\""
- }
- return $msg
- }
-
- proc ::tcltest::tooManyMessage {functionName argList} {
- # if oldstyle errors:
- if { [info tclversion] < 8.4 } {
- set msg "called \"$functionName\" with too many arguments"
- } else {
- set msg "wrong # args: should be \"$functionName $argList\""
- }
- return $msg
- }
- }
- interp alias $c ::tcltest::cleanupTestsHook {} \
- ::tcltest::cleanupTestsHook $c
- # source each of the specified tests
- foreach file [lsort [::tcltest::getMatchingFiles]] {
- set tail [file tail $file]
- puts stdout [string map [list "$root/" ""] $file]
- $c eval {
- if {[catch {source [pSet file]} msg]} {
- puts stdout $errorInfo
- }
- }
- }
- interp delete $c
- puts stdout ""
-}
-
-# cleanup
-puts stdout "\nTests ended at [eval $timeCmd]"
-::tcltest::cleanupTests 1
-# FRINK: nocheck
-return
DELETED config/ChangeLog
Index: config/ChangeLog
==================================================================
--- config/ChangeLog
+++ /dev/null
@@ -1,36 +0,0 @@
-2001-03-15 Karl Lehenbauer
-
- * installFile.tcl: Added updating of the modification time of
- the target file whether we overwrote it or decided that it
- hadn't changed. This was necessary for us to be able to
- determine whether or not a module install touched the file.
-
-2001-03-08 Karl Lehenbauer
-
- * installFile.tcl: Added support for converting new-style (1.1+)
- Cygnus drive paths to Tcl-style.
-
-2001-01-15
-
- * tcl.m4: Added FreeBSD clause.
-
-2001-01-03
-
- * tcl.m4: Fixed typo in SC_LIB_SPEC where it is checking
- for exec-prefix.
-
-2000-12-01
-
- * tcl.m4: Concatenated most of the Ajuba acsite.m4 file
- so we don't need to modify the autoconf installation.
- * config.guess:
- * config.sub:
- * installFile.tcl:
- Added files from the itcl config subdirectory,
- which should go away.
-
-2000-7-29
-
- * Fixed the use of TCL_SRC_DIR and TK_SRC_DIR within TCL_PRIVATE_INCLUDES
- and TK_PRIVATE_INCLUDES to match their recent change from $(srcdir)
- to $(srcdir)/..
DELETED config/config.guess
Index: config/config.guess
==================================================================
--- config/config.guess
+++ /dev/null
@@ -1,483 +0,0 @@
-#!/bin/sh
-# Attempt to guess a canonical system name.
-# Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc.
-#
-# This file is free software; you can redistribute it and/or modify it
-# under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-#
-# As a special exception to the GNU General Public License, if you
-# distribute this file as part of a program that contains a
-# configuration script generated by Autoconf, you may include it under
-# the same distribution terms that you use for the rest of that program.
-
-# Written by Per Bothner .
-# The master version of this file is at the FSF in /home/gd/gnu/lib.
-#
-# This script attempts to guess a canonical system name similar to
-# config.sub. If it succeeds, it prints the system name on stdout, and
-# exits with 0. Otherwise, it exits with 1.
-#
-# The plan is that this can be called by configure scripts if you
-# don't specify an explicit system type (host/target name).
-#
-# Only a few systems have been added to this list; please add others
-# (but try to keep the structure clean).
-#
-
-# This is needed to find uname on a Pyramid OSx when run in the BSD universe.
-# (ghazi@noc.rutgers.edu 8/24/94.)
-if (test -f /.attbin/uname) >/dev/null 2>&1 ; then
- PATH=$PATH:/.attbin ; export PATH
-fi
-
-UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown
-UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown
-UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown
-UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
-
-trap 'rm -f dummy.c dummy.o dummy; exit 1' 1 2 15
-
-# Note: order is significant - the case branches are not exclusive.
-
-case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
- alpha:OSF1:V*:*)
- # After 1.2, OSF1 uses "V1.3" for uname -r.
- echo alpha-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^V//'`
- exit 0 ;;
- alpha:OSF1:*:*)
- # 1.2 uses "1.2" for uname -r.
- echo alpha-dec-osf${UNAME_RELEASE}
- exit 0 ;;
- arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
- echo arm-acorn-riscix${UNAME_RELEASE}
- exit 0;;
- Pyramid*:OSx*:*:*)
- if test "`(/bin/universe) 2>/dev/null`" = att ; then
- echo pyramid-pyramid-sysv3
- else
- echo pyramid-pyramid-bsd
- fi
- exit 0 ;;
- i86pc:SunOS:5.*:*)
- echo i486-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
- exit 0 ;;
- sun4*:SunOS:5.*:*)
- echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
- exit 0 ;;
- sun4*:SunOS:6*:*)
- # According to config.sub, this is the proper way to canonicalize
- # SunOS6. Hard to guess exactly what SunOS6 will be like, but
- # it's likely to be more like Solaris than SunOS4.
- echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
- exit 0 ;;
- sun4*:SunOS:*:*)
- # Japanese Language versions have a version number like `4.1.3-JL'.
- echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'`
- exit 0 ;;
- sun3*:SunOS:*:*)
- echo m68k-sun-sunos${UNAME_RELEASE}
- exit 0 ;;
- tp_s2*:SunOS:*:*)
- # Tadpole Sparcbook 2 running a modified 4.1.3
- echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'`
- exit 0 ;;
- RISC*:ULTRIX:*:*)
- echo mips-dec-ultrix${UNAME_RELEASE}
- exit 0 ;;
- VAX*:ULTRIX*:*:*)
- echo vax-dec-ultrix${UNAME_RELEASE}
- exit 0 ;;
- mips:*:5*:RISCos)
- echo mips-mips-riscos${UNAME_RELEASE}
- exit 0 ;;
- m88k:CX/UX:7*:*)
- echo m88k-harris-cxux7
- exit 0 ;;
- m88k:*:4*:R4*)
- echo m88k-motorola-sysv4
- exit 0 ;;
- m88k:*:3*:R3*)
- echo m88k-motorola-sysv3
- exit 0 ;;
- AViiON:dgux:*:*)
- if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx \
- -o ${TARGET_BINARY_INTERFACE}x = x ] ; then
- echo m88k-dg-dgux${UNAME_RELEASE}
- else
- echo m88k-dg-dguxbcs${UNAME_RELEASE}
- fi
- exit 0 ;;
- M88*:DolphinOS:*:*) # DolphinOS (SVR3)
- echo m88k-dolphin-sysv3
- exit 0 ;;
- M88*:*:R3*:*)
- # Delta 88k system running SVR3
- echo m88k-motorola-sysv3
- exit 0 ;;
- XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3)
- echo m88k-tektronix-sysv3
- exit 0 ;;
- Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD)
- echo m68k-tektronix-bsd
- exit 0 ;;
- *:IRIX:*:*)
- echo mips-sgi-irix${UNAME_RELEASE}
- exit 0 ;;
- i[34]86:AIX:*:*)
- echo i386-ibm-aix
- exit 0 ;;
- *:AIX:2:3)
- if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then
- sed 's/^ //' << EOF >dummy.c
- #include
-
- main()
- {
- if (!__power_pc())
- exit(1);
- puts("powerpc-ibm-aix3.2.5");
- exit(0);
- }
-EOF
- ${CC-cc} dummy.c -o dummy && ./dummy && rm dummy.c dummy && exit 0
- rm -f dummy.c dummy
- echo rs6000-ibm-aix3.2.5
- elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then
- echo rs6000-ibm-aix3.2.4
- else
- echo rs6000-ibm-aix3.2
- fi
- exit 0 ;;
- *:AIX:*:4)
- if /usr/sbin/lsattr -EHl proc0 | grep POWER >/dev/null 2>&1; then
- IBM_ARCH=rs6000
- else
- IBM_ARCH=powerpc
- fi
- if grep bos410 /usr/include/stdio.h >/dev/null 2>&1; then
- IBM_REV=4.1
- elif grep bos411 /usr/include/stdio.h >/dev/null 2>&1; then
- IBM_REV=4.1.1
- else
- IBM_REV=4.${UNAME_RELEASE}
- fi
- echo ${IBM_ARCH}-ibm-aix${IBM_REV}
- exit 0 ;;
- *:AIX:*:*)
- echo rs6000-ibm-aix
- exit 0 ;;
- *:BOSX:*:*)
- echo rs6000-bull-bosx
- exit 0 ;;
- DPX/2?00:B.O.S.:*:*)
- echo m68k-bull-sysv3
- exit 0 ;;
- 9000/[34]??:4.3bsd:1.*:*)
- echo m68k-hp-bsd
- exit 0 ;;
- hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*)
- echo m68k-hp-bsd4.4
- exit 0 ;;
- 9000/[3478]??:HP-UX:*:*)
- case "${UNAME_MACHINE}" in
- 9000/31? ) HP_ARCH=m68000 ;;
- 9000/[34]?? ) HP_ARCH=m68k ;;
- 9000/7?? | 9000/8?7 ) HP_ARCH=hppa1.1 ;;
- 9000/8?? ) HP_ARCH=hppa1.0 ;;
- esac
- HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
- echo ${HP_ARCH}-hp-hpux${HPUX_REV}
- exit 0 ;;
- 3050*:HI-UX:*:*)
- sed 's/^ //' << EOF >dummy.c
- #include
- int
- main ()
- {
- long cpu = sysconf (_SC_CPU_VERSION);
- /* The order matters, because CPU_IS_HP_MC68K erroneously returns
- true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct
- results, however. */
- if (CPU_IS_PA_RISC (cpu))
- {
- switch (cpu)
- {
- case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break;
- case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break;
- case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break;
- default: puts ("hppa-hitachi-hiuxwe2"); break;
- }
- }
- else if (CPU_IS_HP_MC68K (cpu))
- puts ("m68k-hitachi-hiuxwe2");
- else puts ("unknown-hitachi-hiuxwe2");
- exit (0);
- }
-EOF
- ${CC-cc} dummy.c -o dummy && ./dummy && rm dummy.c dummy && exit 0
- rm -f dummy.c dummy
- echo unknown-hitachi-hiuxwe2
- exit 0 ;;
- 9000/7??:4.3bsd:*:* | 9000/8?7:4.3bsd:*:* )
- echo hppa1.1-hp-bsd
- exit 0 ;;
- 9000/8??:4.3bsd:*:*)
- echo hppa1.0-hp-bsd
- exit 0 ;;
- hp7??:OSF1:*:* | hp8?7:OSF1:*:* )
- echo hppa1.1-hp-osf
- exit 0 ;;
- hp8??:OSF1:*:*)
- echo hppa1.0-hp-osf
- exit 0 ;;
- C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*)
- echo c1-convex-bsd
- exit 0 ;;
- C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*)
- if getsysinfo -f scalar_acc
- then echo c32-convex-bsd
- else echo c2-convex-bsd
- fi
- exit 0 ;;
- C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*)
- echo c34-convex-bsd
- exit 0 ;;
- C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*)
- echo c38-convex-bsd
- exit 0 ;;
- C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*)
- echo c4-convex-bsd
- exit 0 ;;
- CRAY*X-MP:UNICOS:*:*)
- echo xmp-cray-unicos
- exit 0 ;;
- CRAY*Y-MP:UNICOS:*:*)
- echo ymp-cray-unicos
- exit 0 ;;
- CRAY-2:UNICOS:*:*)
- echo cray2-cray-unicos
- exit 0 ;;
- hp3[0-9][05]:NetBSD:*:*)
- echo m68k-hp-netbsd${UNAME_RELEASE}
- exit 0 ;;
- i[34]86:BSD/386:*:*)
- echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
- exit 0 ;;
- i[34]86:BSD/OS:*:*)
- echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
- exit 0 ;;
- *:FreeBSD:*:*)
- echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
- exit 0 ;;
- *:NetBSD:*:*)
- echo ${UNAME_MACHINE}-unknown-netbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'`
- exit 0 ;;
- *:GNU:*:*)
- echo `echo ${UNAME_MACHINE}|sed -e 's,/.*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
- exit 0 ;;
- *:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux
- exit 0 ;;
-# ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. earlier versions
-# are messed up and put the nodename in both sysname and nodename.
- i[34]86:DYNIX/ptx:4*:*)
- echo i386-sequent-sysv4
- exit 0 ;;
- i[34]86:*:4.*:* | i[34]86:SYSTEM_V:4.*:*)
- if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
- echo ${UNAME_MACHINE}-univel-sysv${UNAME_RELEASE}
- else
- echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}
- fi
- exit 0 ;;
- i[34]86:*:3.2:*)
- if /bin/uname -X 2>/dev/null >/dev/null ; then
- UNAME_REL=`(/bin/uname -X|egrep Release|sed -e 's/.*= //')`
- (/bin/uname -X|egrep i80486 >/dev/null) && UNAME_MACHINE=i486
- echo ${UNAME_MACHINE}-unknown-sco$UNAME_REL
- elif test -f /usr/options/cb.name; then
- UNAME_REL=`sed -n 's/.*Version //p' /dev/null 2>&1 ; then
- echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4
- else # Add other i860-SVR4 vendors below as they are discovered.
- echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4
- fi
- exit 0 ;;
- mini*:CTIX:SYS*5:*)
- # "miniframe"
- echo m68010-convergent-sysv
- exit 0 ;;
- M680[234]0:*:R3V[567]*:*)
- test -r /sysV68 && echo 'm68k-motorola-sysv' && exit 0 ;;
- 3[34]??:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0)
- uname -p 2>/dev/null | grep 86 >/dev/null \
- && echo i486-ncr-sysv4.3 && exit 0 ;;
- 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
- uname -p 2>/dev/null | grep 86 >/dev/null \
- && echo i486-ncr-sysv4 && exit 0 ;;
- m680[234]0:LynxOS:2.2*:*)
- echo m68k-lynx-lynxos${UNAME_RELEASE}
- exit 0 ;;
- PowerPC:LynxOS:2.2*:*)
- echo powerpc-lynx-lynxos${UNAME_RELEASE}
- exit 0 ;;
- mc68030:UNIX_System_V:4.*:*)
- echo m68k-atari-sysv4
- exit 0 ;;
- i[34]86:LynxOS:2.2*:*)
- echo i386-lynx-lynxos${UNAME_RELEASE}
- exit 0 ;;
- TSUNAMI:LynxOS:2.2*:*)
- echo sparc-lynx-lynxos${UNAME_RELEASE}
- exit 0 ;;
- rs6000:LynxOS:2.2*:*)
- echo rs6000-lynx-lynxos${UNAME_RELEASE}
- exit 0 ;;
- RM*:SINIX-*:*:*)
- echo mips-sni-sysv4
- exit 0 ;;
- *:SINIX-*:*:*)
- if uname -p 2>/dev/null >/dev/null ; then
- UNAME_MACHINE=`(uname -p) 2>/dev/null`
- echo ${UNAME_MACHINE}-sni-sysv4
- else
- echo ns32k-sni-sysv
- fi
- exit 0 ;;
-esac
-
-#echo '(No uname command or uname output not recognized.)' 1>&2
-#echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2
-
-cat >dummy.c </dev/null`;
- printf ("%s-next-nextstep%s\n", __ARCHITECTURE__, version==2 ? "2" : "3");
- exit (0);
-#endif
-
-#if defined (MULTIMAX) || defined (n16)
-#if defined (UMAXV)
- printf ("ns32k-encore-sysv\n"); exit (0);
-#else
-#if defined (CMU)
- printf ("ns32k-encore-mach\n"); exit (0);
-#else
- printf ("ns32k-encore-bsd\n"); exit (0);
-#endif
-#endif
-#endif
-
-#if defined (__386BSD__)
- printf ("i386-unknown-bsd\n"); exit (0);
-#endif
-
-#if defined (sequent)
-#if defined (i386)
- printf ("i386-sequent-dynix\n"); exit (0);
-#endif
-#if defined (ns32000)
- printf ("ns32k-sequent-dynix\n"); exit (0);
-#endif
-#endif
-
-#if defined (_SEQUENT_)
- printf ("i386-sequent-ptx\n"); exit (0);
-#endif
-
-#if defined (vax)
-#if !defined (ultrix)
- printf ("vax-dec-bsd\n"); exit (0);
-#else
- printf ("vax-dec-ultrix\n"); exit (0);
-#endif
-#endif
-
-#if defined (alliant) && defined (i860)
- printf ("i860-alliant-bsd\n"); exit (0);
-#endif
-
- exit (1);
-}
-EOF
-
-${CC-cc} dummy.c -o dummy 2>/dev/null && ./dummy && rm dummy.c dummy && exit 0
-rm -f dummy.c dummy
-
-# Apollos put the system type in the environment.
-
-test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit 0; }
-
-# Convex versions that predate uname can use getsysinfo(1)
-
-if [ -x /usr/convex/getsysinfo ]
-then
- case `getsysinfo -f cpu_type` in
- c1*)
- echo c1-convex-bsd
- exit 0 ;;
- c2*)
- if getsysinfo -f scalar_acc
- then echo c32-convex-bsd
- else echo c2-convex-bsd
- fi
- exit 0 ;;
- c34*)
- echo c34-convex-bsd
- exit 0 ;;
- c38*)
- echo c38-convex-bsd
- exit 0 ;;
- c4*)
- echo c4-convex-bsd
- exit 0 ;;
- esac
-fi
-
-#echo '(Unable to guess system type)' 1>&2
-
-exit 1
DELETED config/config.sub
Index: config/config.sub
==================================================================
--- config/config.sub
+++ /dev/null
@@ -1,793 +0,0 @@
-#!/bin/sh
-# Configuration validation subroutine script, version 1.1.
-# Copyright (C) 1991, 1992, 1993, 1994 Free Software Foundation, Inc.
-# This file is (in principle) common to ALL GNU software.
-# The presence of a machine in this file suggests that SOME GNU software
-# can handle that machine. It does not imply ALL GNU software can.
-#
-# This file is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-
-# As a special exception to the GNU General Public License, if you
-# distribute this file as part of a program that contains a
-# configuration script generated by Autoconf, you may include it under
-# the same distribution terms that you use for the rest of that program.
-
-# Configuration subroutine to validate and canonicalize a configuration type.
-# Supply the specified configuration type as an argument.
-# If it is invalid, we print an error message on stderr and exit with code 1.
-# Otherwise, we print the canonical config type on stdout and succeed.
-
-# This file is supposed to be the same for all GNU packages
-# and recognize all the CPU types, system types and aliases
-# that are meaningful with *any* GNU software.
-# Each package is responsible for reporting which valid configurations
-# it does not support. The user should be able to distinguish
-# a failure to support a valid configuration from a meaningless
-# configuration.
-
-# The goal of this file is to map all the various variations of a given
-# machine specification into a single specification in the form:
-# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM
-# It is wrong to echo any other type of specification.
-
-# First pass through any local machine types.
-case $1 in
- *local*)
- echo $1
- exit 0
- ;;
- *)
- ;;
-esac
-
-# Separate what the user gave into CPU-COMPANY and OS (if any).
-basic_machine=`echo $1 | sed 's/-[^-]*$//'`
-if [ $basic_machine != $1 ]
-then os=`echo $1 | sed 's/.*-/-/'`
-else os=; fi
-
-### Let's recognize common machines as not being operating systems so
-### that things like config.sub decstation-3100 work. We also
-### recognize some manufacturers as not being operating systems, so we
-### can provide default operating systems below.
-case $os in
- -sun*os*)
- # Prevent following clause from handling this invalid input.
- ;;
- -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \
- -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \
- -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \
- -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\
- -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \
- -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp )
- os=
- basic_machine=$1
- ;;
- -hiux*)
- os=-hiuxwe2
- ;;
- -sco4)
- os=-sco3.2v4
- basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
- ;;
- -sco3.2.[4-9]*)
- os=`echo $os | sed -e 's/sco3.2./sco3.2v/'`
- basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
- ;;
- -sco3.2v[4-9]*)
- # Don't forget version if it is 3.2v4 or newer.
- basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
- ;;
- -sco*)
- os=-sco3.2v2
- basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
- ;;
- -isc)
- os=-isc2.2
- basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
- ;;
- -clix*)
- basic_machine=clipper-intergraph
- ;;
- -isc*)
- basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
- ;;
- -lynx)
- os=-lynxos
- ;;
- -ptx*)
- basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'`
- ;;
- -windowsnt*)
- os=`echo $os | sed -e 's/windowsnt/winnt/'`
- ;;
-esac
-
-# Decode aliases for certain CPU-COMPANY combinations.
-case $basic_machine in
- # Recognize the basic CPU types without company name.
- # Some are omitted here because they have special meanings below.
- tahoe | i[345]86 | i860 | m68k | m68000 | m88k | ns32k | arm | pyramid \
- | tron | a29k | 580 | i960 | h8300 | hppa1.0 | hppa1.1 \
- | alpha | we32k | ns16k | clipper | sparclite | i370 | sh \
- | powerpc | sparc64 | 1750a | dsp16xx | mips64 | mipsel \
- | pdp11 | mips64el | mips64orion | mips64orionel )
- basic_machine=$basic_machine-unknown
- ;;
- # Object if more than one company name word.
- *-*-*)
- echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
- exit 1
- ;;
- # Recognize the basic CPU types with company name.
- vax-* | tahoe-* | i[345]86-* | i860-* | m68k-* | m68000-* | m88k-* \
- | sparc-* | ns32k-* | fx80-* | arm-* | c[123]* \
- | mips-* | pyramid-* | tron-* | a29k-* | romp-* | rs6000-* \
- | none-* | 580-* | cray2-* | h8300-* | i960-* | xmp-* | ymp-* \
- | hppa1.0-* | hppa1.1-* | alpha-* | we32k-* | cydra-* | ns16k-* \
- | pn-* | np1-* | xps100-* | clipper-* | orion-* | sparclite-* \
- | pdp11-* | sh-* | powerpc-* | sparc64-* | mips64-* | mipsel-* \
- | mips64el-* | mips64orion-* | mips64orionel-* )
- ;;
- # Recognize the various machine names and aliases which stand
- # for a CPU type and a company and sometimes even an OS.
- 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc)
- basic_machine=m68000-att
- ;;
- 3b*)
- basic_machine=we32k-att
- ;;
- alliant | fx80)
- basic_machine=fx80-alliant
- ;;
- altos | altos3068)
- basic_machine=m68k-altos
- ;;
- am29k)
- basic_machine=a29k-none
- os=-bsd
- ;;
- amdahl)
- basic_machine=580-amdahl
- os=-sysv
- ;;
- amiga | amiga-*)
- basic_machine=m68k-cbm
- ;;
- amigados)
- basic_machine=m68k-cbm
- os=-amigados
- ;;
- amigaunix | amix)
- basic_machine=m68k-cbm
- os=-sysv4
- ;;
- apollo68)
- basic_machine=m68k-apollo
- os=-sysv
- ;;
- balance)
- basic_machine=ns32k-sequent
- os=-dynix
- ;;
- convex-c1)
- basic_machine=c1-convex
- os=-bsd
- ;;
- convex-c2)
- basic_machine=c2-convex
- os=-bsd
- ;;
- convex-c32)
- basic_machine=c32-convex
- os=-bsd
- ;;
- convex-c34)
- basic_machine=c34-convex
- os=-bsd
- ;;
- convex-c38)
- basic_machine=c38-convex
- os=-bsd
- ;;
- cray | ymp)
- basic_machine=ymp-cray
- os=-unicos
- ;;
- cray2)
- basic_machine=cray2-cray
- os=-unicos
- ;;
- crds | unos)
- basic_machine=m68k-crds
- ;;
- da30 | da30-*)
- basic_machine=m68k-da30
- ;;
- decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn)
- basic_machine=mips-dec
- ;;
- delta | 3300 | motorola-3300 | motorola-delta \
- | 3300-motorola | delta-motorola)
- basic_machine=m68k-motorola
- ;;
- delta88)
- basic_machine=m88k-motorola
- os=-sysv3
- ;;
- dpx20 | dpx20-*)
- basic_machine=rs6000-bull
- os=-bosx
- ;;
- dpx2* | dpx2*-bull)
- basic_machine=m68k-bull
- os=-sysv3
- ;;
- ebmon29k)
- basic_machine=a29k-amd
- os=-ebmon
- ;;
- elxsi)
- basic_machine=elxsi-elxsi
- os=-bsd
- ;;
- encore | umax | mmax)
- basic_machine=ns32k-encore
- ;;
- fx2800)
- basic_machine=i860-alliant
- ;;
- genix)
- basic_machine=ns32k-ns
- ;;
- gmicro)
- basic_machine=tron-gmicro
- os=-sysv
- ;;
- h3050r* | hiux*)
- basic_machine=hppa1.1-hitachi
- os=-hiuxwe2
- ;;
- h8300hms)
- basic_machine=h8300-hitachi
- os=-hms
- ;;
- harris)
- basic_machine=m88k-harris
- os=-sysv3
- ;;
- hp300-*)
- basic_machine=m68k-hp
- ;;
- hp300bsd)
- basic_machine=m68k-hp
- os=-bsd
- ;;
- hp300hpux)
- basic_machine=m68k-hp
- os=-hpux
- ;;
- hp9k2[0-9][0-9] | hp9k31[0-9])
- basic_machine=m68000-hp
- ;;
- hp9k3[2-9][0-9])
- basic_machine=m68k-hp
- ;;
- hp9k7[0-9][0-9] | hp7[0-9][0-9] | hp9k8[0-9]7 | hp8[0-9]7)
- basic_machine=hppa1.1-hp
- ;;
- hp9k8[0-9][0-9] | hp8[0-9][0-9])
- basic_machine=hppa1.0-hp
- ;;
- i370-ibm* | ibm*)
- basic_machine=i370-ibm
- os=-mvs
- ;;
-# I'm not sure what "Sysv32" means. Should this be sysv3.2?
- i[345]86v32)
- basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'`
- os=-sysv32
- ;;
- i[345]86v4*)
- basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'`
- os=-sysv4
- ;;
- i[345]86v)
- basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'`
- os=-sysv
- ;;
- i[345]86sol2)
- basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'`
- os=-solaris2
- ;;
- iris | iris4d)
- basic_machine=mips-sgi
- case $os in
- -irix*)
- ;;
- *)
- os=-irix4
- ;;
- esac
- ;;
- isi68 | isi)
- basic_machine=m68k-isi
- os=-sysv
- ;;
- m88k-omron*)
- basic_machine=m88k-omron
- ;;
- magnum | m3230)
- basic_machine=mips-mips
- os=-sysv
- ;;
- merlin)
- basic_machine=ns32k-utek
- os=-sysv
- ;;
- miniframe)
- basic_machine=m68000-convergent
- ;;
- mips3*-*)
- basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`
- ;;
- mips3*)
- basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown
- ;;
- ncr3000)
- basic_machine=i486-ncr
- os=-sysv4
- ;;
- news | news700 | news800 | news900)
- basic_machine=m68k-sony
- os=-newsos
- ;;
- news1000)
- basic_machine=m68030-sony
- os=-newsos
- ;;
- news-3600 | risc-news)
- basic_machine=mips-sony
- os=-newsos
- ;;
- next | m*-next )
- basic_machine=m68k-next
- case $os in
- -nextstep* )
- ;;
- -ns2*)
- os=-nextstep2
- ;;
- *)
- os=-nextstep3
- ;;
- esac
- ;;
- nh3000)
- basic_machine=m68k-harris
- os=-cxux
- ;;
- nh[45]000)
- basic_machine=m88k-harris
- os=-cxux
- ;;
- nindy960)
- basic_machine=i960-intel
- os=-nindy
- ;;
- np1)
- basic_machine=np1-gould
- ;;
- pa-hitachi)
- basic_machine=hppa1.1-hitachi
- os=-hiuxwe2
- ;;
- paragon)
- basic_machine=i860-intel
- os=-osf
- ;;
- pbd)
- basic_machine=sparc-tti
- ;;
- pbb)
- basic_machine=m68k-tti
- ;;
- pc532 | pc532-*)
- basic_machine=ns32k-pc532
- ;;
- pentium-*)
- # We will change tis to say i586 once there has been
- # time for various packages to start to recognize that.
- basic_machine=i486-`echo $basic_machine | sed 's/^[^-]*-//'`
- ;;
- pn)
- basic_machine=pn-gould
- ;;
- ps2)
- basic_machine=i386-ibm
- ;;
- rtpc | rtpc-*)
- basic_machine=romp-ibm
- ;;
- sequent)
- basic_machine=i386-sequent
- ;;
- sh)
- basic_machine=sh-hitachi
- os=-hms
- ;;
- sps7)
- basic_machine=m68k-bull
- os=-sysv2
- ;;
- spur)
- basic_machine=spur-unknown
- ;;
- sun2)
- basic_machine=m68000-sun
- ;;
- sun2os3)
- basic_machine=m68000-sun
- os=-sunos3
- ;;
- sun2os4)
- basic_machine=m68000-sun
- os=-sunos4
- ;;
- sun3os3)
- basic_machine=m68k-sun
- os=-sunos3
- ;;
- sun3os4)
- basic_machine=m68k-sun
- os=-sunos4
- ;;
- sun4os3)
- basic_machine=sparc-sun
- os=-sunos3
- ;;
- sun4os4)
- basic_machine=sparc-sun
- os=-sunos4
- ;;
- sun3 | sun3-*)
- basic_machine=m68k-sun
- ;;
- sun4)
- basic_machine=sparc-sun
- ;;
- sun386 | sun386i | roadrunner)
- basic_machine=i386-sun
- ;;
- symmetry)
- basic_machine=i386-sequent
- os=-dynix
- ;;
- tower | tower-32)
- basic_machine=m68k-ncr
- ;;
- ultra3)
- basic_machine=a29k-nyu
- os=-sym1
- ;;
- vaxv)
- basic_machine=vax-dec
- os=-sysv
- ;;
- vms)
- basic_machine=vax-dec
- os=-vms
- ;;
- vxworks960)
- basic_machine=i960-wrs
- os=-vxworks
- ;;
- vxworks68)
- basic_machine=m68k-wrs
- os=-vxworks
- ;;
- xmp)
- basic_machine=xmp-cray
- os=-unicos
- ;;
- xps | xps100)
- basic_machine=xps100-honeywell
- ;;
- none)
- basic_machine=none-none
- os=-none
- ;;
-
-# Here we handle the default manufacturer of certain CPU types. It is in
-# some cases the only manufacturer, in others, it is the most popular.
- mips)
- basic_machine=mips-mips
- ;;
- romp)
- basic_machine=romp-ibm
- ;;
- rs6000)
- basic_machine=rs6000-ibm
- ;;
- vax)
- basic_machine=vax-dec
- ;;
- pdp11)
- basic_machine=pdp11-dec
- ;;
- we32k)
- basic_machine=we32k-att
- ;;
- sparc)
- basic_machine=sparc-sun
- ;;
- cydra)
- basic_machine=cydra-cydrome
- ;;
- orion)
- basic_machine=orion-highlevel
- ;;
- orion105)
- basic_machine=clipper-highlevel
- ;;
- *)
- echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
- exit 1
- ;;
-esac
-
-# Here we canonicalize certain aliases for manufacturers.
-case $basic_machine in
- *-digital*)
- basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'`
- ;;
- *-commodore*)
- basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'`
- ;;
- *)
- ;;
-esac
-
-# Decode manufacturer-specific aliases for certain operating systems.
-
-if [ x"$os" != x"" ]
-then
-case $os in
- # -solaris* is a basic system type, with this one exception.
- -solaris1 | -solaris1.*)
- os=`echo $os | sed -e 's|solaris1|sunos4|'`
- ;;
- -solaris)
- os=-solaris2
- ;;
- -gnu/linux*)
- os=`echo $os | sed -e 's|gnu/linux|linux|'`
- ;;
- # First accept the basic system types.
- # The portable systems comes first.
- # Each alternative must end in a *, to match a version number.
- # -sysv* is not here because it comes later, after sysvr4.
- -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \
- | -vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[345]* \
- | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \
- | -amigados* | -msdos* | -newsos* | -unicos* | -aos* \
- | -nindy* | -vxworks* | -ebmon* | -hms* | -mvs* | -clix* \
- | -riscos* | -linux* | -uniplus* | -iris* | -rtu* | -xenix* \
- | -hiux* | -386bsd* | -netbsd* | -freebsd* | -riscix* \
- | -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* \
- | -ptx* | -coff* | -winnt*)
- ;;
- -sunos5*)
- os=`echo $os | sed -e 's|sunos5|solaris2|'`
- ;;
- -sunos6*)
- os=`echo $os | sed -e 's|sunos6|solaris3|'`
- ;;
- -osfrose*)
- os=-osfrose
- ;;
- -osf*)
- os=-osf
- ;;
- -utek*)
- os=-bsd
- ;;
- -dynix*)
- os=-bsd
- ;;
- -acis*)
- os=-aos
- ;;
- -ctix* | -uts*)
- os=-sysv
- ;;
- -triton*)
- os=-sysv3
- ;;
- -oss*)
- os=-sysv3
- ;;
- -svr4)
- os=-sysv4
- ;;
- -svr3)
- os=-sysv3
- ;;
- -sysvr4)
- os=-sysv4
- ;;
- # This must come after -sysvr4.
- -sysv*)
- ;;
- -xenix)
- os=-xenix
- ;;
- -none)
- ;;
- *)
- # Get rid of the `-' at the beginning of $os.
- os=`echo $os | sed 's/[^-]*-//'`
- echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2
- exit 1
- ;;
-esac
-else
-
-# Here we handle the default operating systems that come with various machines.
-# The value should be what the vendor currently ships out the door with their
-# machine or put another way, the most popular os provided with the machine.
-
-# Note that if you're going to try to match "-MANUFACTURER" here (say,
-# "-sun"), then you have to tell the case statement up towards the top
-# that MANUFACTURER isn't an operating system. Otherwise, code above
-# will signal an error saying that MANUFACTURER isn't an operating
-# system, and we'll never get to this point.
-
-case $basic_machine in
- *-acorn)
- os=-riscix1.2
- ;;
- pdp11-*)
- os=-none
- ;;
- *-dec | vax-*)
- os=-ultrix4.2
- ;;
- i386-sun)
- os=-sunos4.0.2
- ;;
- m68000-sun)
- os=-sunos3
- # This also exists in the configure program, but was not the
- # default.
- # os=-sunos4
- ;;
- *-tti) # must be before sparc entry or we get the wrong os.
- os=-sysv3
- ;;
- sparc-* | *-sun)
- os=-sunos4.1.1
- ;;
- *-ibm)
- os=-aix
- ;;
- *-hp)
- os=-hpux
- ;;
- *-hitachi)
- os=-hiux
- ;;
- i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent)
- os=-sysv
- ;;
- *-cbm)
- os=-amigados
- ;;
- *-dg)
- os=-dgux
- ;;
- *-dolphin)
- os=-sysv3
- ;;
- m68k-ccur)
- os=-rtu
- ;;
- m88k-omron*)
- os=-luna
- ;;
- *-sequent)
- os=-ptx
- ;;
- *-crds)
- os=-unos
- ;;
- *-ns)
- os=-genix
- ;;
- i370-*)
- os=-mvs
- ;;
- *-next)
- os=-nextstep3
- ;;
- *-gould)
- os=-sysv
- ;;
- *-highlevel)
- os=-bsd
- ;;
- *-encore)
- os=-bsd
- ;;
- *-sgi)
- os=-irix
- ;;
- *-masscomp)
- os=-rtu
- ;;
- *)
- os=-none
- ;;
-esac
-fi
-
-# Here we handle the case where we know the os, and the CPU type, but not the
-# manufacturer. We pick the logical manufacturer.
-vendor=unknown
-case $basic_machine in
- *-unknown)
- case $os in
- -riscix*)
- vendor=acorn
- ;;
- -sunos*)
- vendor=sun
- ;;
- -lynxos*)
- vendor=lynx
- ;;
- -aix*)
- vendor=ibm
- ;;
- -hpux*)
- vendor=hp
- ;;
- -hiux*)
- vendor=hitachi
- ;;
- -unos*)
- vendor=crds
- ;;
- -dgux*)
- vendor=dg
- ;;
- -luna*)
- vendor=omron
- ;;
- -genix*)
- vendor=ns
- ;;
- -mvs*)
- vendor=ibm
- ;;
- -ptx*)
- vendor=sequent
- ;;
- esac
- basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"`
- ;;
-esac
-
-echo $basic_machine$os
DELETED config/install-sh
Index: config/install-sh
==================================================================
--- config/install-sh
+++ /dev/null
@@ -1,119 +0,0 @@
-#!/bin/sh
-
-#
-# install - install a program, script, or datafile
-# This comes from X11R5; it is not part of GNU.
-#
-# $XConsortium: install.sh,v 1.2 89/12/18 14:47:22 jim Exp $
-#
-# This script is compatible with the BSD install script, but was written
-# from scratch.
-#
-
-
-# set DOITPROG to echo to test this script
-
-# Don't use :- since 4.3BSD and earlier shells don't like it.
-doit="${DOITPROG-}"
-
-
-# put in absolute paths if you don't have them in your path; or use env. vars.
-
-mvprog="${MVPROG-mv}"
-cpprog="${CPPROG-cp}"
-chmodprog="${CHMODPROG-chmod}"
-chownprog="${CHOWNPROG-chown}"
-chgrpprog="${CHGRPPROG-chgrp}"
-stripprog="${STRIPPROG-strip}"
-rmprog="${RMPROG-rm}"
-
-instcmd="$mvprog"
-chmodcmd=""
-chowncmd=""
-chgrpcmd=""
-stripcmd=""
-rmcmd="$rmprog -f"
-mvcmd="$mvprog"
-src=""
-dst=""
-
-while [ x"$1" != x ]; do
- case $1 in
- -c) instcmd="$cpprog"
- shift
- continue;;
-
- -m) chmodcmd="$chmodprog $2"
- shift
- shift
- continue;;
-
- -o) chowncmd="$chownprog $2"
- shift
- shift
- continue;;
-
- -g) chgrpcmd="$chgrpprog $2"
- shift
- shift
- continue;;
-
- -s) stripcmd="$stripprog"
- shift
- continue;;
-
- *) if [ x"$src" = x ]
- then
- src=$1
- else
- dst=$1
- fi
- shift
- continue;;
- esac
-done
-
-if [ x"$src" = x ]
-then
- echo "install: no input file specified"
- exit 1
-fi
-
-if [ x"$dst" = x ]
-then
- echo "install: no destination specified"
- exit 1
-fi
-
-
-# If destination is a directory, append the input filename; if your system
-# does not like double slashes in filenames, you may need to add some logic
-
-if [ -d $dst ]
-then
- dst="$dst"/`basename $src`
-fi
-
-# Make a temp file name in the proper directory.
-
-dstdir=`dirname $dst`
-dsttmp=$dstdir/#inst.$$#
-
-# Move or copy the file name to the temp name
-
-$doit $instcmd $src $dsttmp
-
-# and set any options; do chmod last to preserve setuid bits
-
-if [ x"$chowncmd" != x ]; then $doit $chowncmd $dsttmp; fi
-if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dsttmp; fi
-if [ x"$stripcmd" != x ]; then $doit $stripcmd $dsttmp; fi
-if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dsttmp; fi
-
-# Now rename the file to the real destination.
-
-$doit $rmcmd $dst
-$doit $mvcmd $dsttmp $dst
-
-
-exit 0
DELETED config/installFile.tcl
Index: config/installFile.tcl
==================================================================
--- config/installFile.tcl
+++ /dev/null
@@ -1,131 +0,0 @@
-#!/bin/sh
-#
-# installFile.tcl - a Tcl version of install-sh
-# that copies a file and preserves its permission bits.
-# This also optimizes out installation of existing files
-# that have the same size and time stamp as the source.
-#
-# \
-exec tclsh8.3 "$0" ${1+"$@"}
-
-set doCopy 0 ;# Rename files instead of copy
-set doStrip 0 ;# Strip the symbols from installed copy
-set verbose 0
-set src ""
-set dst ""
-
-# Process command line arguments, compatible with install-sh
-
-for {set i 0} {$i < $argc} {incr i} {
- set arg [lindex $argv $i]
- switch -- $arg {
- -c {
- set doCopy 1
- }
- -m {
- incr i
- # Assume UNIX standard "644", etc, so force Tcl to think octal
- set permissions 0[lindex $argv $i]
- }
- -o {
- incr i
- set owner [lindex $argv $i]
- }
- -g {
- incr i
- set group [lindex $argv $i]
- }
- -s {
- set doStrip 1
- }
- -v {
- set verbose 1
- }
- default {
- set src $arg
- incr i
- set dst [lindex $argv $i]
- break
- }
- }
-}
-if {[string length $src] == 0} {
- puts stderr "$argv0: no input file specified"
- exit 1
-}
-if {[string length $dst] == 0} {
- puts stderr "$argv0: no destination file specified"
- exit 1
-}
-
-# Compatibility with CYGNUS-style pathnames
-regsub {^/(cygdrive)?/(.)/(.*)} $src {\2:/\3} src
-regsub {^/(cygdrive)?/(.)/(.*)} $dst {\2:/\3} dst
-
-if {$verbose && $doStrip} {
- puts stderr "Ignoring -s (strip) option for $dst"
-}
-if {[file isdirectory $dst]} {
- set dst [file join $dst [file tail $src]]
-}
-
-# Temporary file name
-
-set dsttmp [file join [file dirname $dst] #inst.[pid]#]
-
-# Optimize out install if the file already exists
-
-set actions ""
-if {[file exists $dst] &&
- ([file mtime $src] == [file mtime $dst]) &&
- ([file size $src] == [file size $dst])} {
-
- # Looks like the same file, so don't bother to copy.
- # Set dsttmp in case we still need to tweak mode, group, etc.
-
- set dsttmp $dst
- lappend actions "already installed"
-} else {
- if {"[file type $src]" == "link"} {
- # Perfom a true copy.
- set in [open $src r]
- set out [open $dsttmp w]
- fcopy $in $out
- close $in
- close $out
- } else {
- file copy -force $src $dsttmp
- }
- lappend actions copied
-}
-
-# update the modification time of the target file
-file mtime $dsttmp [clock seconds]
-
-# At this point "$dsttmp" is installed, but might not have the
-# right permissions and may need to be renamed.
-
-
-foreach attrName {owner group permissions} {
- upvar 0 $attrName attr
-
- if {[info exists attr]} {
- if {![catch {file attributes $dsttmp -$attrName} dstattr]} {
-
- # This system supports "$attrName" kind of attributes
-
- if {($attr != $dstattr)} {
- file attributes $dsttmp -$attrName $attr
- lappend actions "set $attrName to $attr"
- }
- }
- }
-}
-
-if {[string compare $dst $dsttmp] != 0} {
- file rename -force $dsttmp $dst
-}
-if {$verbose} {
- puts stderr "$dst: [join $actions ", "]"
-}
-exit 0
DELETED config/mkinstalldirs
Index: config/mkinstalldirs
==================================================================
--- config/mkinstalldirs
+++ /dev/null
@@ -1,40 +0,0 @@
-#! /bin/sh
-# mkinstalldirs --- make directory hierarchy
-# Author: Noah Friedman
-# Created: 1993-05-16
-# Public domain
-
-# $Id: mkinstalldirs,v 1.1 2002/12/05 20:22:57 andreas_kupries Exp $
-
-errstatus=0
-
-for file
-do
- set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'`
- shift
-
- pathcomp=
- for d
- do
- pathcomp="$pathcomp$d"
- case "$pathcomp" in
- -* ) pathcomp=./$pathcomp ;;
- esac
-
- if test ! -d "$pathcomp"; then
- echo "mkdir $pathcomp"
-
- mkdir "$pathcomp" || lasterr=$?
-
- if test ! -d "$pathcomp"; then
- errstatus=$lasterr
- fi
- fi
-
- pathcomp="$pathcomp/"
- done
-done
-
-exit $errstatus
-
-# mkinstalldirs ends here
DELETED config/tcl.m4
Index: config/tcl.m4
==================================================================
--- config/tcl.m4
+++ /dev/null
@@ -1,2709 +0,0 @@
-# tcl.m4 --
-#
-# This file provides a set of autoconf macros to help TEA-enable
-# a Tcl extension.
-#
-# Copyright (c) 1999-2000 Ajuba Solutions.
-#
-# See the file "license.terms" for information on usage and redistribution
-# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-
-#------------------------------------------------------------------------
-# SC_PATH_TCLCONFIG --
-#
-# Locate the tclConfig.sh file and perform a sanity check on
-# the Tcl compile flags
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --with-tcl=...
-#
-# Defines the following vars:
-# TCL_BIN_DIR Full path to the directory containing
-# the tclConfig.sh file
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_PATH_TCLCONFIG, [
- #
- # Ok, lets find the tcl configuration
- # First, look for one uninstalled.
- # the alternative search directory is invoked by --with-tcl
- #
-
- if test x"${no_tcl}" = x ; then
- # we reset no_tcl in case something fails here
- no_tcl=true
- AC_ARG_WITH(tcl, [ --with-tcl directory containing tcl configuration (tclConfig.sh)], with_tclconfig=${withval})
- AC_MSG_CHECKING([for Tcl configuration])
- AC_CACHE_VAL(ac_cv_c_tclconfig,[
-
- # First check to see if --with-tcl was specified.
- if test x"${with_tclconfig}" != x ; then
- if test -f "${with_tclconfig}/tclConfig.sh" ; then
- ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
- else
- AC_MSG_ERROR([${with_tclconfig} directory doesn't contain tclConfig.sh])
- fi
- fi
-
- # then check for a private Tcl installation
- if test x"${ac_cv_c_tclconfig}" = x ; then
- for i in \
- ../tcl \
- `ls -dr ../tcl[[8-9]].[[0-9]]* 2>/dev/null` \
- ../../tcl \
- `ls -dr ../../tcl[[8-9]].[[0-9]]* 2>/dev/null` \
- ../../../tcl \
- `ls -dr ../../../tcl[[8-9]].[[0-9]]* 2>/dev/null` ; do
- if test -f "$i/unix/tclConfig.sh" ; then
- ac_cv_c_tclconfig=`(cd $i/unix; pwd)`
- break
- fi
- done
- fi
-
- # check in a few common install locations
- if test x"${ac_cv_c_tclconfig}" = x ; then
- for i in `ls -d ${prefix}/lib 2>/dev/null` \
- `ls -d /usr/lib 2>/dev/null` \
- `ls -d /usr/local/lib 2>/dev/null` ; do
- if test -f "$i/tclConfig.sh" ; then
- ac_cv_c_tclconfig=`(cd $i; pwd)`
- break
- fi
- done
- fi
-
- # check in a few other private locations
- if test x"${ac_cv_c_tclconfig}" = x ; then
- for i in \
- ${srcdir}/../tcl \
- `ls -dr ${srcdir}/../tcl[[8-9]].[[0-9]]* 2>/dev/null` ; do
- if test -f "$i/unix/tclConfig.sh" ; then
- ac_cv_c_tclconfig=`(cd $i/unix; pwd)`
- break
- fi
- done
- fi
- ])
-
- if test x"${ac_cv_c_tclconfig}" = x ; then
- TCL_BIN_DIR="# no Tcl configs found"
- AC_MSG_WARN(Can't find Tcl configuration definitions)
- exit 0
- else
- no_tcl=
- TCL_BIN_DIR=${ac_cv_c_tclconfig}
- AC_MSG_RESULT(found $TCL_BIN_DIR/tclConfig.sh)
- fi
- fi
-])
-
-#------------------------------------------------------------------------
-# SC_PATH_TKCONFIG --
-#
-# Locate the tkConfig.sh file
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --with-tk=...
-#
-# Defines the following vars:
-# TK_BIN_DIR Full path to the directory containing
-# the tkConfig.sh file
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_PATH_TKCONFIG, [
- #
- # Ok, lets find the tk configuration
- # First, look for one uninstalled.
- # the alternative search directory is invoked by --with-tk
- #
-
- if test x"${no_tk}" = x ; then
- # we reset no_tk in case something fails here
- no_tk=true
- AC_ARG_WITH(tk, [ --with-tk directory containing tk configuration (tkConfig.sh)], with_tkconfig=${withval})
- AC_MSG_CHECKING([for Tk configuration])
- AC_CACHE_VAL(ac_cv_c_tkconfig,[
-
- # First check to see if --with-tkconfig was specified.
- if test x"${with_tkconfig}" != x ; then
- if test -f "${with_tkconfig}/tkConfig.sh" ; then
- ac_cv_c_tkconfig=`(cd ${with_tkconfig}; pwd)`
- else
- AC_MSG_ERROR([${with_tkconfig} directory doesn't contain tkConfig.sh])
- fi
- fi
-
- # then check for a private Tk library
- if test x"${ac_cv_c_tkconfig}" = x ; then
- for i in \
- ../tk \
- `ls -dr ../tk[[8-9]].[[0-9]]* 2>/dev/null` \
- ../../tk \
- `ls -dr ../../tk[[8-9]].[[0-9]]* 2>/dev/null` \
- ../../../tk \
- `ls -dr ../../../tk[[8-9]].[[0-9]]* 2>/dev/null` ; do
- if test -f "$i/unix/tkConfig.sh" ; then
- ac_cv_c_tkconfig=`(cd $i/unix; pwd)`
- break
- fi
- done
- fi
- # check in a few common install locations
- if test x"${ac_cv_c_tkconfig}" = x ; then
- for i in `ls -d ${prefix}/lib 2>/dev/null` \
- `ls -d /usr/lib 2>/dev/null` \
- `ls -d /usr/local/lib 2>/dev/null` ; do
- if test -f "$i/tkConfig.sh" ; then
- ac_cv_c_tkconfig=`(cd $i; pwd)`
- break
- fi
- done
- fi
- # check in a few other private locations
- if test x"${ac_cv_c_tkconfig}" = x ; then
- for i in \
- ${srcdir}/../tk \
- `ls -dr ${srcdir}/../tk[[8-9]].[[0-9]]* 2>/dev/null` ; do
- if test -f "$i/unix/tkConfig.sh" ; then
- ac_cv_c_tkconfig=`(cd $i/unix; pwd)`
- break
- fi
- done
- fi
- ])
- if test x"${ac_cv_c_tkconfig}" = x ; then
- TK_BIN_DIR="# no Tk configs found"
- AC_MSG_WARN(Can't find Tk configuration definitions)
- exit 0
- else
- no_tk=
- TK_BIN_DIR=${ac_cv_c_tkconfig}
- AC_MSG_RESULT(found $TK_BIN_DIR/tkConfig.sh)
- fi
- fi
-
-])
-
-#------------------------------------------------------------------------
-# SC_LOAD_TCLCONFIG --
-#
-# Load the tclConfig.sh file
-#
-# Arguments:
-#
-# Requires the following vars to be set:
-# TCL_BIN_DIR
-#
-# Results:
-#
-# Subst the following vars:
-# TCL_BIN_DIR
-# TCL_SRC_DIR
-# TCL_LIB_FILE
-#
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_LOAD_TCLCONFIG, [
- AC_MSG_CHECKING([for existence of $TCL_BIN_DIR/tclConfig.sh])
-
- if test -f "$TCL_BIN_DIR/tclConfig.sh" ; then
- AC_MSG_RESULT([loading])
- . $TCL_BIN_DIR/tclConfig.sh
- else
- AC_MSG_RESULT([file not found])
- fi
-
- #
- # The eval is required to do the TCL_DBGX substitution in the
- # TCL_LIB_FILE variable
- #
-
- eval TCL_LIB_FILE=${TCL_LIB_FILE}
- eval TCL_LIB_FLAG=${TCL_LIB_FLAG}
-
- AC_SUBST(TCL_DBGX)
- AC_SUBST(TCL_BIN_DIR)
- AC_SUBST(TCL_SRC_DIR)
- AC_SUBST(TCL_LIB_FILE)
- AC_SUBST(TCL_LIBS)
- AC_SUBST(TCL_DEFS)
- AC_SUBST(TCL_SHLIB_LD_LIBS)
- AC_SUBST(TCL_EXTRA_CFLAGS)
- AC_SUBST(TCL_LD_FLAGS)
- AC_SUBST(TCL_LIB_FILE)
- AC_SUBST(TCL_STUB_LIB_FILE)
- AC_SUBST(TCL_LIB_SPEC)
- AC_SUBST(TCL_BUILD_LIB_SPEC)
- AC_SUBST(TCL_STUB_LIB_SPEC)
- AC_SUBST(TCL_BUILD_STUB_LIB_SPEC)
-])
-
-#------------------------------------------------------------------------
-# SC_LOAD_TKCONFIG --
-#
-# Load the tkConfig.sh file
-#
-# Arguments:
-#
-# Requires the following vars to be set:
-# TK_BIN_DIR
-#
-# Results:
-#
-# Sets the following vars that should be in tkConfig.sh:
-# TK_BIN_DIR
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_LOAD_TKCONFIG, [
- AC_MSG_CHECKING([for existence of $TK_BIN_DIR/tkConfig.sh])
-
- if test -f "$TK_BIN_DIR/tkConfig.sh" ; then
- AC_MSG_RESULT([loading])
- . $TK_BIN_DIR/tkConfig.sh
- else
- AC_MSG_RESULT([could not find $TK_BIN_DIR/tkConfig.sh])
- fi
-
- AC_SUBST(TK_BIN_DIR)
- AC_SUBST(TK_SRC_DIR)
- AC_SUBST(TK_LIB_FILE)
- AC_SUBST(TK_XINCLUDES)
-])
-
-#------------------------------------------------------------------------
-# SC_ENABLE_GCC --
-#
-# Allows the use of GCC if available
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --enable-gcc
-#
-# Sets the following vars:
-# CC Command to use for the compiler
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_ENABLE_GCC, [
- AC_ARG_ENABLE(gcc, [ --enable-gcc allow use of gcc if available [--disable-gcc]],
- [ok=$enableval], [ok=no])
- if test "$ok" = "yes"; then
- CC=gcc
- else
- case "`uname -s`" in
- *win32* | *WIN32* | *CYGWIN_NT* | *CYGWIN_98* | *CYGWIN_95*)
- CC=cl
- ;;
- *)
- CC=${CC-cc}
- ;;
- esac
- fi
- AC_PROG_CC
-])
-
-#------------------------------------------------------------------------
-# SC_ENABLE_SHARED --
-#
-# Allows the building of shared libraries
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --enable-shared=yes|no
-#
-# Defines the following vars:
-# STATIC_BUILD Used for building import/export libraries
-# on Windows.
-#
-# Sets the following vars:
-# SHARED_BUILD Value of 1 or 0
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_ENABLE_SHARED, [
- AC_MSG_CHECKING([how to build libraries])
- AC_ARG_ENABLE(shared,
- [ --enable-shared build and link with shared libraries [--enable-shared]],
- [tcl_ok=$enableval], [tcl_ok=yes])
-
- if test "${enable_shared+set}" = set; then
- enableval="$enable_shared"
- tcl_ok=$enableval
- else
- tcl_ok=yes
- fi
-
- if test "$tcl_ok" = "yes" ; then
- AC_MSG_RESULT([shared])
- SHARED_BUILD=1
- else
- AC_MSG_RESULT([static])
- SHARED_BUILD=0
- AC_DEFINE(STATIC_BUILD)
- fi
-])
-
-#------------------------------------------------------------------------
-# SC_ENABLE_THREADS --
-#
-# Specify if thread support should be enabled
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --enable-threads
-#
-# Sets the following vars:
-# THREADS_LIBS Thread library(s)
-#
-# Defines the following vars:
-# TCL_THREADS
-# _REENTRANT
-#
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_ENABLE_THREADS, [
- AC_MSG_CHECKING(for building with threads)
- AC_ARG_ENABLE(threads, [ --enable-threads build with threads],
- [tcl_ok=$enableval], [tcl_ok=no])
-
- if test "$tcl_ok" = "yes"; then
- TCL_THREADS=1
- AC_DEFINE(TCL_THREADS)
- AC_DEFINE(_REENTRANT)
-
- case "`uname -s`" in
- *win32* | *WIN32* | *CYGWIN_NT* | *CYGWIN_98* | *CYGWIN_95*)
- AC_MSG_RESULT(yes)
- ;;
- *)
- AC_CHECK_LIB(pthread,pthread_mutex_init,tcl_ok=yes,tcl_ok=no)
- if test "$tcl_ok" = "yes"; then
- # The space is needed
- THREADS_LIBS=" -lpthread"
- AC_MSG_RESULT(yes)
- else
- TCL_THREADS=0
- AC_MSG_RESULT(no)
- AC_MSG_WARN("Don t know how to find pthread lib on your system - you must disable thread support or edit the LIBS in the Makefile...")
- fi
- ;;
- esac
- else
- TCL_THREADS=0
- AC_MSG_RESULT(no (default))
- fi
-
-])
-
-#------------------------------------------------------------------------
-# SC_ENABLE_SYMBOLS --
-#
-# Specify if debugging symbols should be used
-#
-# Arguments:
-# none
-#
-# Requires the following vars to be set:
-# CFLAGS_DEBUG
-# CFLAGS_OPTIMIZE
-# LDFLAGS_DEBUG
-# LDFLAGS_OPTIMIZE
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --enable-symbols
-#
-# Defines the following vars:
-# CFLAGS_DEFAULT Sets to CFLAGS_DEBUG if true
-# Sets to CFLAGS_OPTIMIZE if false
-# LDFLAGS_DEFAULT Sets to LDFLAGS_DEBUG if true
-# Sets to LDFLAGS_OPTIMIZE if false
-# DBGX Debug library extension
-#
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_ENABLE_SYMBOLS, [
- case "`uname -s`" in
- *win32* | *WIN32* | *CYGWIN_NT* | *CYGWIN_98* | *CYGWIN_95*)
- tcl_dbgx=d
- ;;
- *)
- tcl_dbgx=g
- ;;
- esac
-
- AC_MSG_CHECKING([for build with symbols])
- AC_ARG_ENABLE(symbols, [ --enable-symbols build with debugging symbols [--disable-symbols]], [tcl_ok=$enableval], [tcl_ok=no])
- if test "$tcl_ok" = "yes"; then
- CFLAGS_DEFAULT="${CFLAGS_DEBUG}"
- LDFLAGS_DEFAULT="${LDFLAGS_DEBUG}"
- DBGX=${tcl_dbgx}
- TCL_DBGX=${tcl_dbgx}
- AC_MSG_RESULT([yes])
- else
- CFLAGS_DEFAULT="${CFLAGS_OPTIMIZE}"
- LDFLAGS_DEFAULT="${LDFLAGS_OPTIMIZE}"
- DBGX=""
- TCL_DBGX=""
- AC_MSG_RESULT([no])
- fi
-
- AC_SUBST(TCL_DBGX)
- AC_SUBST(CFLAGS_DEFAULT)
- AC_SUBST(LDFLAGS_DEFAULT)
-])
-
-#--------------------------------------------------------------------
-# SC_CONFIG_CFLAGS
-#
-# Try to determine the proper flags to pass to the compiler
-# for building shared libraries and other such nonsense.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Defines the following vars:
-#
-# DL_OBJS - Name of the object file that implements dynamic
-# loading for Tcl on this system.
-# DL_LIBS - Library file(s) to include in tclsh and other base
-# applications in order for the "load" command to work.
-# LDFLAGS - Flags to pass to the compiler when linking object
-# files into an executable application binary such
-# as tclsh.
-# LD_SEARCH_FLAGS-Flags to pass to ld, such as "-R /usr/local/tcl/lib",
-# that tell the run-time dynamic linker where to look
-# for shared libraries such as libtcl.so. Depends on
-# the variable LIB_RUNTIME_DIR in the Makefile.
-# MAKE_LIB - Command to execute to build the Tcl library;
-# differs depending on whether or not Tcl is being
-# compiled as a shared library.
-# SHLIB_CFLAGS - Flags to pass to cc when compiling the components
-# of a shared library (may request position-independent
-# code, among other things).
-# SHLIB_LD - Base command to use for combining object files
-# into a shared library.
-# SHLIB_LD_LIBS - Dependent libraries for the linker to scan when
-# creating shared libraries. This symbol typically
-# goes at the end of the "ld" commands that build
-# shared libraries. The value of the symbol is
-# "${LIBS}" if all of the dependent libraries should
-# be specified when creating a shared library. If
-# dependent libraries should not be specified (as on
-# SunOS 4.x, where they cause the link to fail, or in
-# general if Tcl and Tk aren't themselves shared
-# libraries), then this symbol has an empty string
-# as its value.
-# SHLIB_SUFFIX - Suffix to use for the names of dynamically loadable
-# extensions. An empty string means we don't know how
-# to use shared libraries on this platform.
-# TCL_LIB_FILE - Name of the file that contains the Tcl library, such
-# as libtcl7.8.so or libtcl7.8.a.
-# TCL_LIB_SUFFIX -Specifies everything that comes after the "libtcl"
-# in the shared library name, using the $VERSION variable
-# to put the version in the right place. This is used
-# by platforms that need non-standard library names.
-# Examples: ${VERSION}.so.1.1 on NetBSD, since it needs
-# to have a version after the .so, and ${VERSION}.a
-# on AIX, since the Tcl shared library needs to have
-# a .a extension whereas shared objects for loadable
-# extensions have a .so extension. Defaults to
-# ${VERSION}${SHLIB_SUFFIX}.
-# TCL_NEEDS_EXP_FILE -
-# 1 means that an export file is needed to link to a
-# shared library.
-# TCL_EXP_FILE - The name of the installed export / import file which
-# should be used to link to the Tcl shared library.
-# Empty if Tcl is unshared.
-# TCL_BUILD_EXP_FILE -
-# The name of the built export / import file which
-# should be used to link to the Tcl shared library.
-# Empty if Tcl is unshared.
-# CFLAGS_DEBUG -
-# Flags used when running the compiler in debug mode
-# CFLAGS_OPTIMIZE -
-# Flags used when running the compiler in optimize mode
-#
-# EXTRA_CFLAGS
-#
-# Subst's the following vars:
-# DL_LIBS
-# CFLAGS_DEBUG
-# CFLAGS_OPTIMIZE
-#--------------------------------------------------------------------
-
-AC_DEFUN(SC_CONFIG_CFLAGS, [
-
- # Step 0: Enable 64 bit support?
-
- AC_MSG_CHECKING([if 64bit support is enabled])
- AC_ARG_ENABLE(64bit,[ --enable-64bit enable 64bit support],,enableval="no")
-
- if test "$enableval" = "yes"; then
- AC_MSG_RESULT(Will compile with 64bit support)
- do64bit=yes
- else
- do64bit=no
- fi
- AC_MSG_RESULT($do64bit)
-
- # Step 1: set the variable "system" to hold the name and version number
- # for the system. This can usually be done via the "uname" command, but
- # there are a few systems, like Next, where this doesn't work.
-
- AC_MSG_CHECKING([system version (for dynamic loading)])
- if test -f /usr/lib/NextStep/software_version; then
- system=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version`
- else
- system=`uname -s`-`uname -r`
- if test "$?" -ne 0 ; then
- AC_MSG_RESULT([unknown (can't find uname command)])
- system=unknown
- else
- # Special check for weird MP-RAS system (uname returns weird
- # results, and the version is kept in special file).
-
- if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then
- system=MP-RAS-`awk '{print $3}' /etc/.relid'`
- fi
- if test "`uname -s`" = "AIX" ; then
- system=AIX-`uname -v`.`uname -r`
- fi
- AC_MSG_RESULT($system)
- fi
- fi
-
- # Step 2: check for existence of -ldl library. This is needed because
- # Linux can use either -ldl or -ldld for dynamic loading.
-
- AC_CHECK_LIB(dl, dlopen, have_dl=yes, have_dl=no)
-
- # Step 3: set configuration options based on system name and version.
-
- do64bit_ok=no
- fullSrcDir=`cd $srcdir; pwd`
- EXTRA_CFLAGS=""
- TCL_EXPORT_FILE_SUFFIX=""
- UNSHARED_LIB_SUFFIX=""
- TCL_TRIM_DOTS='`echo ${VERSION} | tr -d .`'
- ECHO_VERSION='`echo ${VERSION}`'
- TCL_LIB_VERSIONS_OK=ok
- CFLAGS_DEBUG=-g
- CFLAGS_OPTIMIZE=-O
- TCL_NEEDS_EXP_FILE=0
- TCL_BUILD_EXP_FILE=""
- TCL_EXP_FILE=""
- STLIB_LD="ar cr"
- case $system in
- AIX-5.*)
- if test "${TCL_THREADS}" = "1" -a "$using_gcc" = "no" ; then
- # AIX requires the _r compiler when gcc isn't being used
- if test "${CC}" != "cc_r" ; then
- CC=${CC}_r
- fi
- AC_MSG_RESULT(Using $CC for compiling with threads)
- fi
- # AIX-5 uses ELF style dynamic libraries
- SHLIB_CFLAGS=""
- SHLIB_LD="/usr/ccs/bin/ld -G -z text"
-
- # Note: need the LIBS below, otherwise Tk won't find Tcl's
- # symbols when dynamically loaded into tclsh.
-
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- # AIX-5 has dl* in libc.so
- DL_LIBS=""
- LDFLAGS=""
- if test "$using_gcc" = "yes" ; then
- LD_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
- else
- LD_SEARCH_FLAGS='-R${LIB_RUNTIME_DIR}'
- fi
-
- if test "$do64bit" = "yes" ; then
- if test "$using_gcc" = "no" ; then
- do64bit_ok=yes
- EXTRA_CFLAGS="-q64"
- LDFLAGS="-q64"
- else
- AC_MSG_WARN("64bit mode not supported with GCC on $system")
- fi
- fi
- ;;
- AIX-*)
- if test "${TCL_THREADS}" = "1" -a "$using_gcc" = "no" ; then
- # AIX requires the _r compiler when gcc isn't being used
- if test "${CC}" != "cc_r" ; then
- CC=${CC}_r
- fi
- AC_MSG_RESULT(Using $CC for compiling with threads)
- fi
- SHLIB_CFLAGS=""
- SHLIB_LD="$fullSrcDir/ldAix /bin/ld -bhalt:4 -bM:SRE -bE:lib.exp -H512 -T512 -bnoentry"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
- TCL_NEEDS_EXP_FILE=1
- TCL_EXPORT_FILE_SUFFIX='${VERSION}\$\{DBGX\}.exp'
-
- # AIX v<=4.1 has some different flags than 4.2+
- if test "$system" = "AIX-4.1" -o "`uname -v`" -lt "4" ; then
- LIBOBJS="$LIBOBJS tclLoadAix.o"
- DL_LIBS="-lld"
- fi
-
- # On AIX <=v4 systems, libbsd.a has to be linked in to support
- # non-blocking file IO. This library has to be linked in after
- # the MATH_LIBS or it breaks the pow() function. The way to
- # insure proper sequencing, is to add it to the tail of MATH_LIBS.
- # This library also supplies gettimeofday.
- #
- # AIX does not have a timezone field in struct tm. When the AIX
- # bsd library is used, the timezone global and the gettimeofday
- # methods are to be avoided for timezone deduction instead, we
- # deduce the timezone by comparing the localtime result on a
- # known GMT value.
-
- AC_CHECK_LIB(bsd, gettimeofday, libbsd=yes, libbsd=no)
- if test $libbsd = yes; then
- MATH_LIBS="$MATH_LIBS -lbsd"
- AC_DEFINE(USE_DELTA_FOR_TZ)
- fi
- ;;
- BSD/OS-2.1*|BSD/OS-3*)
- SHLIB_CFLAGS=""
- SHLIB_LD="shlicc -r"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- BSD/OS-4.*)
- SHLIB_CFLAGS="-export-dynamic -fPIC"
- SHLIB_LD="cc -shared"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS="-export-dynamic"
- LD_SEARCH_FLAGS=""
- ;;
- *win32*|*WIN32*|CYGWIN_NT*|cygwin_nt*|*CYGWIN_98*|*CYGWIN_95*)
- CFLAGS_DEBUG="-nologo -Z7 -Od -WX ${runtime}d"
- CFLAGS_OPTIMIZE="-nologo -Oti -Gs -GD ${runtime}"
- LDFLAGS_CONSOLE="-subsystem:console"
- LDFLAGS_WINDOW="-subsystem:windows"
- LDFLAGS_DEBUG="-debug:full -debugtype:cv"
- LDFLAGS_OPTIMIZE="-release"
- EXTRA_CFLAGS="-YX"
- PATHTYPE=-w
- STLIB_LD="lib -nologo"
- SHLIB_LD="link -dll -nologo -incremental:no"
- SHLIB_LD_LIBS="user32.lib advapi32.lib"
- RC="rc"
- ;;
- dgux*)
- SHLIB_CFLAGS="-K PIC"
- SHLIB_LD="cc -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- HP-UX-*.08.*|HP-UX-*.09.*|HP-UX-*.10.*|HP-UX-*.11.*)
- SHLIB_SUFFIX=".sl"
- AC_CHECK_LIB(dld, shl_load, tcl_ok=yes, tcl_ok=no)
- if test "$tcl_ok" = yes; then
- SHLIB_CFLAGS="+z"
- SHLIB_LD="ld -b"
- SHLIB_LD_LIBS=""
- DL_OBJS="tclLoadShl.o"
- DL_LIBS="-ldld"
- LDFLAGS="-Wl,-E"
- LD_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.'
- fi
- ;;
- IRIX-4.*)
- SHLIB_CFLAGS="-G 0"
- SHLIB_SUFFIX=".a"
- SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0"
- SHLIB_LD_LIBS='${LIBS}'
- DL_OBJS="tclLoadAout.o"
- DL_LIBS=""
- LDFLAGS="-Wl,-D,08000000"
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
- SHARED_LIB_SUFFIX='${VERSION}\$\{DBGX\}.a'
- ;;
- IRIX-5.*)
- SHLIB_CFLAGS=""
- SHLIB_LD="ld -shared -rdata_shared"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
- EXTRA_CFLAGS=""
- LDFLAGS=""
- ;;
- IRIX-6.*|IRIX64-6.5*)
- SHLIB_CFLAGS=""
- SHLIB_LD="ld -n32 -shared -rdata_shared"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
- if test "$using_gcc" = "yes" ; then
- EXTRA_CFLAGS="-mabi=n32"
- LDFLAGS="-mabi=n32"
- else
- case $system in
- IRIX-6.3)
- # Use to build 6.2 compatible binaries on 6.3.
- EXTRA_CFLAGS="-n32 -D_OLD_TERMIOS"
- ;;
- *)
- EXTRA_CFLAGS="-n32"
- ;;
- esac
- LDFLAGS="-n32"
- fi
- ;;
- IRIX64-6.*)
- SHLIB_CFLAGS=""
- SHLIB_LD="ld -32 -shared -rdata_shared"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
- ;;
- Linux*)
- SHLIB_CFLAGS="-fPIC"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
-
- # egcs-2.91.66 on Redhat Linux 6.0 generates lots of warnings
- # when you inline the string and math operations. Turn this off to
- # get rid of the warnings.
-
- CFLAGS_OPTIMIZE="${CFLAGS_OPTIMIZE} -D__NO_STRING_INLINES -D__NO_MATH_INLINES"
-
- if test "$have_dl" = yes; then
- SHLIB_LD="${CC} -shared"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS="-rdynamic"
- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
- else
- AC_CHECK_HEADER(dld.h, [
- SHLIB_LD="ld -shared"
- DL_OBJS="tclLoadDld.o"
- DL_LIBS="-ldld"
- LDFLAGS=""
- LD_SEARCH_FLAGS=""])
- fi
- if test "`uname -m`" = "alpha" ; then
- EXTRA_CFLAGS="-mieee"
- fi
- ;;
- MP-RAS-02*)
- SHLIB_CFLAGS="-K PIC"
- SHLIB_LD="cc -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- MP-RAS-*)
- SHLIB_CFLAGS="-K PIC"
- SHLIB_LD="cc -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS="-Wl,-Bexport"
- LD_SEARCH_FLAGS=""
- ;;
- NetBSD-*|FreeBSD-[[12]].*|OpenBSD-*)
- # Not available on all versions: check for include file.
- AC_CHECK_HEADER(dlfcn.h, [
- SHLIB_CFLAGS="-fpic"
- SHLIB_LD="ld -Bshareable -x"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0'
- ], [
- SHLIB_CFLAGS=""
- SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".a"
- DL_OBJS="tclLoadAout.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
- ])
-
- # FreeBSD doesn't handle version numbers with dots.
-
- UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
- TCL_LIB_VERSIONS_OK=nodots
- ;;
- FreeBSD-*)
- # FreeBSD 3.* and greater have ELF.
- SHLIB_CFLAGS="-fpic"
- SHLIB_LD="ld -Bshareable -x"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- NEXTSTEP-*)
- SHLIB_CFLAGS=""
- SHLIB_LD="cc -nostdlib -r"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadNext.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- OS/390-*)
- CFLAGS_OPTIMIZE="" # Optimizer is buggy
- AC_DEFINE(_OE_SOCKETS) # needed in sys/socket.h
- ;;
- OSF1-1.0|OSF1-1.1|OSF1-1.2)
- # OSF/1 1.[012] from OSF, and derivatives, including Paragon OSF/1
- SHLIB_CFLAGS=""
- # Hack: make package name same as library name
- SHLIB_LD='ld -R -export $@:'
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadOSF.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- OSF1-1.*)
- # OSF/1 1.3 from OSF using ELF, and derivatives, including AD2
- SHLIB_CFLAGS="-fpic"
- SHLIB_LD="ld -shared"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- OSF1-V*)
- # Digital OSF/1
- SHLIB_CFLAGS=""
- SHLIB_LD='ld -shared -expect_unresolved "*"'
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
- ;;
- RISCos-*)
- SHLIB_CFLAGS="-G 0"
- SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".a"
- DL_OBJS="tclLoadAout.o"
- DL_LIBS=""
- LDFLAGS="-Wl,-D,08000000"
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
- ;;
- SCO_SV-3.2*)
- # Note, dlopen is available only on SCO 3.2.5 and greater. However,
- # this test works, since "uname -s" was non-standard in 3.2.4 and
- # below.
- SHLIB_CFLAGS="-Kpic -belf"
- SHLIB_LD="ld -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LDFLAGS="-belf -Wl,-Bexport"
- LD_SEARCH_FLAGS=""
- ;;
- SINIX*5.4*)
- SHLIB_CFLAGS="-K PIC"
- SHLIB_LD="cc -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- SunOS-4*)
- SHLIB_CFLAGS="-PIC"
- SHLIB_LD="ld"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
-
- # SunOS can't handle version numbers with dots in them in library
- # specs, like -ltcl7.5, so use -ltcl75 instead. Also, it
- # requires an extra version number at the end of .so file names.
- # So, the library has to have a name like libtcl75.so.1.0
-
- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0'
- UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
- TCL_LIB_VERSIONS_OK=nodots
- ;;
- SunOS-5.[[0-6]]*)
- SHLIB_CFLAGS="-KPIC"
- SHLIB_LD="/usr/ccs/bin/ld -G -z text"
-
- # Note: need the LIBS below, otherwise Tk won't find Tcl's
- # symbols when dynamically loaded into tclsh.
-
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- LD_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
- ;;
- SunOS-5*)
- SHLIB_CFLAGS="-KPIC"
- SHLIB_LD="/usr/ccs/bin/ld -G -z text"
- LDFLAGS=""
-
- do64bit_ok=no
- if test "$do64bit" = "yes" ; then
- arch=`isainfo`
- if test "$arch" = "sparcv9 sparc" ; then
- if test "$CC" != "gcc" -a `$CC -v 2>&1 | grep -c gcc` = "0" ; then
- do64bit_ok=yes
- EXTRA_CFLAGS="-xarch=v9"
- LDFLAGS="-xarch=v9"
- else
- AC_MSG_WARN("64bit mode not supported using GCC on $system")
- fi
- else
- AC_MSG_WARN("64bit mode only supported sparcv9 system")
- fi
- fi
-
- # Note: need the LIBS below, otherwise Tk won't find Tcl's
- # symbols when dynamically loaded into tclsh.
-
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- if test "$CC" = "gcc" -o `$CC -v 2>&1 | grep -c gcc` != "0" ; then
- LD_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
- else
- LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
- fi
- ;;
- ULTRIX-4.*)
- SHLIB_CFLAGS="-G 0"
- SHLIB_SUFFIX=".a"
- SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0"
- SHLIB_LD_LIBS='${LIBS}'
- DL_OBJS="tclLoadAout.o"
- DL_LIBS=""
- LDFLAGS="-Wl,-D,08000000"
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
- ;;
- UNIX_SV* | UnixWare-5*)
- SHLIB_CFLAGS="-KPIC"
- SHLIB_LD="cc -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- # Some UNIX_SV* systems (unixware 1.1.2 for example) have linkers
- # that don't grok the -Bexport option. Test that it does.
- hold_ldflags=$LDFLAGS
- AC_MSG_CHECKING(for ld accepts -Bexport flag)
- LDFLAGS="${LDFLAGS} -Wl,-Bexport"
- AC_TRY_LINK(, [int i;], found=yes, found=no)
- LDFLAGS=$hold_ldflags
- AC_MSG_RESULT($found)
- if test $found = yes; then
- LDFLAGS="-Wl,-Bexport"
- else
- LDFLAGS=""
- fi
- LD_SEARCH_FLAGS=""
- ;;
- esac
-
- if test "$do64bit" = "yes" -a "$do64bit_ok" = "no" ; then
- AC_MSG_WARN("64bit support being disabled -- not supported on this platform")
- fi
-
- # Step 4: If pseudo-static linking is in use (see K. B. Kenny, "Dynamic
- # Loading for Tcl -- What Became of It?". Proc. 2nd Tcl/Tk Workshop,
- # New Orleans, LA, Computerized Processes Unlimited, 1994), then we need
- # to determine which of several header files defines the a.out file
- # format (a.out.h, sys/exec.h, or sys/exec_aout.h). At present, we
- # support only a file format that is more or less version-7-compatible.
- # In particular,
- # - a.out files must begin with `struct exec'.
- # - the N_TXTOFF on the `struct exec' must compute the seek address
- # of the text segment
- # - The `struct exec' must contain a_magic, a_text, a_data, a_bss
- # and a_entry fields.
- # The following compilation should succeed if and only if either sys/exec.h
- # or a.out.h is usable for the purpose.
- #
- # Note that the modified COFF format used on MIPS Ultrix 4.x is usable; the
- # `struct exec' includes a second header that contains information that
- # duplicates the v7 fields that are needed.
-
- if test "x$DL_OBJS" = "xtclLoadAout.o" ; then
- AC_MSG_CHECKING(sys/exec.h)
- AC_TRY_COMPILE([#include ],[
- struct exec foo;
- unsigned long seek;
- int flag;
-#if defined(__mips) || defined(mips)
- seek = N_TXTOFF (foo.ex_f, foo.ex_o);
-#else
- seek = N_TXTOFF (foo);
-#endif
- flag = (foo.a_magic == OMAGIC);
- return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry;
- ], tcl_ok=usable, tcl_ok=unusable)
- AC_MSG_RESULT($tcl_ok)
- if test $tcl_ok = usable; then
- AC_DEFINE(USE_SYS_EXEC_H)
- else
- AC_MSG_CHECKING(a.out.h)
- AC_TRY_COMPILE([#include ],[
- struct exec foo;
- unsigned long seek;
- int flag;
-#if defined(__mips) || defined(mips)
- seek = N_TXTOFF (foo.ex_f, foo.ex_o);
-#else
- seek = N_TXTOFF (foo);
-#endif
- flag = (foo.a_magic == OMAGIC);
- return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry;
- ], tcl_ok=usable, tcl_ok=unusable)
- AC_MSG_RESULT($tcl_ok)
- if test $tcl_ok = usable; then
- AC_DEFINE(USE_A_OUT_H)
- else
- AC_MSG_CHECKING(sys/exec_aout.h)
- AC_TRY_COMPILE([#include ],[
- struct exec foo;
- unsigned long seek;
- int flag;
-#if defined(__mips) || defined(mips)
- seek = N_TXTOFF (foo.ex_f, foo.ex_o);
-#else
- seek = N_TXTOFF (foo);
-#endif
- flag = (foo.a_midmag == OMAGIC);
- return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry;
- ], tcl_ok=usable, tcl_ok=unusable)
- AC_MSG_RESULT($tcl_ok)
- if test $tcl_ok = usable; then
- AC_DEFINE(USE_SYS_EXEC_AOUT_H)
- else
- DL_OBJS=""
- fi
- fi
- fi
- fi
-
- # Step 5: disable dynamic loading if requested via a command-line switch.
-
- AC_ARG_ENABLE(load, [ --disable-load disallow dynamic loading and "load" command],
- [tcl_ok=$enableval], [tcl_ok=yes])
- if test "$tcl_ok" = "no"; then
- DL_OBJS=""
- fi
-
- if test "x$DL_OBJS" != "x" ; then
- BUILD_DLTEST="\$(DLTEST_TARGETS)"
- else
- echo "Can't figure out how to do dynamic loading or shared libraries"
- echo "on this system."
- SHLIB_CFLAGS=""
- SHLIB_LD=""
- SHLIB_SUFFIX=""
- DL_OBJS="tclLoadNone.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- BUILD_DLTEST=""
- fi
-
- # If we're running gcc, then change the C flags for compiling shared
- # libraries to the right flags for gcc, instead of those for the
- # standard manufacturer compiler.
-
- if test "$DL_OBJS" != "tclLoadNone.o" ; then
- if test "$CC" = "gcc" -o `$CC -v 2>&1 | grep -c gcc` != "0" ; then
- case $system in
- AIX-*)
- ;;
- BSD/OS*)
- ;;
- IRIX*)
- ;;
- NetBSD-*|FreeBSD-*|OpenBSD-*)
- ;;
- RISCos-*)
- ;;
- ULTRIX-4.*)
- ;;
- *)
- SHLIB_CFLAGS="-fPIC"
- ;;
- esac
- fi
- fi
-
- if test "$SHARED_LIB_SUFFIX" = "" ; then
- SHARED_LIB_SUFFIX='${VERSION}\$\{DBGX\}${SHLIB_SUFFIX}'
- fi
- if test "$UNSHARED_LIB_SUFFIX" = "" ; then
- UNSHARED_LIB_SUFFIX='${VERSION}\$\{DBGX\}.a'
- fi
-
- AC_SUBST(STLIB_LD)
- AC_SUBST(SHLIB_LD)
- AC_SUBST(SHLIB_CFLAGS)
- AC_SUBST(SHLIB_LDFLAGS)
- AC_SUBST(DL_LIBS)
- AC_SUBST(CFLAGS_DEBUG)
- AC_SUBST(CFLAGS_OPTIMIZE)
- AC_SUBST(LDFLAGS_DEBUG)
- AC_SUBST(LDFLAGS_OPTIMIZE)
-])
-
-#--------------------------------------------------------------------
-# SC_SERIAL_PORT
-#
-# Determine which interface to use to talk to the serial port.
-# Note that #include lines must begin in leftmost column for
-# some compilers to recognize them as preprocessor directives.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Defines only one of the following vars:
-# USE_TERMIOS
-# USE_TERMIO
-# USE_SGTTY
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN(SC_SERIAL_PORT, [
- AC_MSG_CHECKING([termios vs. termio vs. sgtty])
-
- AC_TRY_RUN([
-#include
-
-main()
-{
- struct termios t;
- if (tcgetattr(0, &t) == 0) {
- cfsetospeed(&t, 0);
- t.c_cflag |= PARENB | PARODD | CSIZE | CSTOPB;
- return 0;
- }
- return 1;
-}], tk_ok=termios, tk_ok=no, tk_ok=no)
-
- if test $tk_ok = termios; then
- AC_DEFINE(USE_TERMIOS)
- else
- AC_TRY_RUN([
-#include
-
-main()
-{
- struct termio t;
- if (ioctl(0, TCGETA, &t) == 0) {
- t.c_cflag |= CBAUD | PARENB | PARODD | CSIZE | CSTOPB;
- return 0;
- }
- return 1;
- }], tk_ok=termio, tk_ok=no, tk_ok=no)
-
- if test $tk_ok = termio; then
- AC_DEFINE(USE_TERMIO)
- else
- AC_TRY_RUN([
-#include
-
-main()
-{
- struct sgttyb t;
- if (ioctl(0, TIOCGETP, &t) == 0) {
- t.sg_ospeed = 0;
- t.sg_flags |= ODDP | EVENP | RAW;
- return 0;
- }
- return 1;
-}], tk_ok=sgtty, tk_ok=none, tk_ok=none)
-
- if test $tk_ok = sgtty; then
- AC_DEFINE(USE_SGTTY)
- else
- AC_TRY_RUN([
-#include
-#include
-
-main()
-{
- struct termios t;
- if (tcgetattr(0, &t) == 0
- || errno == ENOTTY || errno == ENXIO || errno == EINVAL) {
- cfsetospeed(&t, 0);
- t.c_cflag |= PARENB | PARODD | CSIZE | CSTOPB;
- return 0;
- }
- return 1;
-}], tk_ok=termios, tk_ok=no, tk_ok=no)
-
- if test $tk_ok = termios; then
- AC_DEFINE(USE_TERMIOS)
- else
- AC_TRY_RUN([
-#include
-#include
-
-main()
-{
- struct termio t;
- if (ioctl(0, TCGETA, &t) == 0
- || errno == ENOTTY || errno == ENXIO || errno == EINVAL) {
- t.c_cflag |= CBAUD | PARENB | PARODD | CSIZE | CSTOPB;
- return 0;
- }
- return 1;
- }], tk_ok=termio, tk_ok=no, tk_ok=no)
-
- if test $tk_ok = termio; then
- AC_DEFINE(USE_TERMIO)
- else
- AC_TRY_RUN([
-#include
-#include
-
-main()
-{
- struct sgttyb t;
- if (ioctl(0, TIOCGETP, &t) == 0
- || errno == ENOTTY || errno == ENXIO || errno == EINVAL) {
- t.sg_ospeed = 0;
- t.sg_flags |= ODDP | EVENP | RAW;
- return 0;
- }
- return 1;
-}], tk_ok=sgtty, tk_ok=none, tk_ok=none)
-
- if test $tk_ok = sgtty; then
- AC_DEFINE(USE_SGTTY)
- fi
- fi
- fi
- fi
- fi
- fi
- AC_MSG_RESULT($tk_ok)
-])
-
-#--------------------------------------------------------------------
-# SC_MISSING_POSIX_HEADERS
-#
-# Supply substitutes for missing POSIX header files. Special
-# notes:
-# - stdlib.h doesn't define strtol, strtoul, or
-# strtod insome versions of SunOS
-# - some versions of string.h don't declare procedures such
-# as strstr
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Defines some of the following vars:
-# NO_DIRENT_H
-# NO_ERRNO_H
-# NO_VALUES_H
-# NO_LIMITS_H
-# NO_STDLIB_H
-# NO_STRING_H
-# NO_SYS_WAIT_H
-# NO_DLFCN_H
-# HAVE_UNISTD_H
-# HAVE_SYS_PARAM_H
-#
-# HAVE_STRING_H ?
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN(SC_MISSING_POSIX_HEADERS, [
-
- AC_MSG_CHECKING(dirent.h)
- AC_TRY_LINK([#include
-#include ], [
-#ifndef _POSIX_SOURCE
-# ifdef __Lynx__
- /*
- * Generate compilation error to make the test fail: Lynx headers
- * are only valid if really in the POSIX environment.
- */
-
- missing_procedure();
-# endif
-#endif
-DIR *d;
-struct dirent *entryPtr;
-char *p;
-d = opendir("foobar");
-entryPtr = readdir(d);
-p = entryPtr->d_name;
-closedir(d);
-], tcl_ok=yes, tcl_ok=no)
-
- if test $tcl_ok = no; then
- AC_DEFINE(NO_DIRENT_H)
- fi
-
- AC_MSG_RESULT($tcl_ok)
- AC_CHECK_HEADER(errno.h, , AC_DEFINE(NO_ERRNO_H))
- AC_CHECK_HEADER(float.h, , AC_DEFINE(NO_FLOAT_H))
- AC_CHECK_HEADER(values.h, , AC_DEFINE(NO_VALUES_H))
- AC_CHECK_HEADER(limits.h, , AC_DEFINE(NO_LIMITS_H))
- AC_CHECK_HEADER(stdlib.h, tcl_ok=1, tcl_ok=0)
- AC_EGREP_HEADER(strtol, stdlib.h, , tcl_ok=0)
- AC_EGREP_HEADER(strtoul, stdlib.h, , tcl_ok=0)
- AC_EGREP_HEADER(strtod, stdlib.h, , tcl_ok=0)
- if test $tcl_ok = 0; then
- AC_DEFINE(NO_STDLIB_H)
- fi
- AC_CHECK_HEADER(string.h, tcl_ok=1, tcl_ok=0)
- AC_EGREP_HEADER(strstr, string.h, , tcl_ok=0)
- AC_EGREP_HEADER(strerror, string.h, , tcl_ok=0)
-
- # See also memmove check below for a place where NO_STRING_H can be
- # set and why.
-
- if test $tcl_ok = 0; then
- AC_DEFINE(NO_STRING_H)
- fi
-
- AC_CHECK_HEADER(sys/wait.h, , AC_DEFINE(NO_SYS_WAIT_H))
- AC_CHECK_HEADER(dlfcn.h, , AC_DEFINE(NO_DLFCN_H))
-
- # OS/390 lacks sys/param.h (and doesn't need it, by chance).
-
- AC_HAVE_HEADERS(unistd.h sys/param.h)
-
-])
-
-#--------------------------------------------------------------------
-# SC_PATH_X
-#
-# Locate the X11 header files and the X11 library archive. Try
-# the ac_path_x macro first, but if it doesn't find the X stuff
-# (e.g. because there's no xmkmf program) then check through
-# a list of possible directories. Under some conditions the
-# autoconf macro will return an include directory that contains
-# no include files, so double-check its result just to be safe.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Sets the the following vars:
-# XINCLUDES
-# XLIBSW
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN(SC_PATH_X, [
- AC_PATH_X
- not_really_there=""
- if test "$no_x" = ""; then
- if test "$x_includes" = ""; then
- AC_TRY_CPP([#include ], , not_really_there="yes")
- else
- if test ! -r $x_includes/X11/Intrinsic.h; then
- not_really_there="yes"
- fi
- fi
- fi
- if test "$no_x" = "yes" -o "$not_really_there" = "yes"; then
- AC_MSG_CHECKING(for X11 header files)
- XINCLUDES="# no special path needed"
- AC_TRY_CPP([#include ], , XINCLUDES="nope")
- if test "$XINCLUDES" = nope; then
- dirs="/usr/unsupported/include /usr/local/include /usr/X386/include /usr/X11R6/include /usr/X11R5/include /usr/include/X11R5 /usr/include/X11R4 /usr/openwin/include /usr/X11/include /usr/sww/include"
- for i in $dirs ; do
- if test -r $i/X11/Intrinsic.h; then
- AC_MSG_RESULT($i)
- XINCLUDES=" -I$i"
- break
- fi
- done
- fi
- else
- if test "$x_includes" != ""; then
- XINCLUDES=-I$x_includes
- else
- XINCLUDES="# no special path needed"
- fi
- fi
- if test "$XINCLUDES" = nope; then
- AC_MSG_RESULT(couldn't find any!)
- XINCLUDES="# no include files found"
- fi
-
- if test "$no_x" = yes; then
- AC_MSG_CHECKING(for X11 libraries)
- XLIBSW=nope
- dirs="/usr/unsupported/lib /usr/local/lib /usr/X386/lib /usr/X11R6/lib /usr/X11R5/lib /usr/lib/X11R5 /usr/lib/X11R4 /usr/openwin/lib /usr/X11/lib /usr/sww/X11/lib"
- for i in $dirs ; do
- if test -r $i/libX11.a -o -r $i/libX11.so -o -r $i/libX11.sl; then
- AC_MSG_RESULT($i)
- XLIBSW="-L$i -lX11"
- x_libraries="$i"
- break
- fi
- done
- else
- if test "$x_libraries" = ""; then
- XLIBSW=-lX11
- else
- XLIBSW="-L$x_libraries -lX11"
- fi
- fi
- if test "$XLIBSW" = nope ; then
- AC_CHECK_LIB(Xwindow, XCreateWindow, XLIBSW=-lXwindow)
- fi
- if test "$XLIBSW" = nope ; then
- AC_MSG_RESULT(couldn't find any! Using -lX11.)
- XLIBSW=-lX11
- fi
-])
-#--------------------------------------------------------------------
-# SC_BLOCKING_STYLE
-#
-# The statements below check for systems where POSIX-style
-# non-blocking I/O (O_NONBLOCK) doesn't work or is unimplemented.
-# On these systems (mostly older ones), use the old BSD-style
-# FIONBIO approach instead.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Defines some of the following vars:
-# HAVE_SYS_IOCTL_H
-# HAVE_SYS_FILIO_H
-# USE_FIONBIO
-# O_NONBLOCK
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN(SC_BLOCKING_STYLE, [
- AC_CHECK_HEADERS(sys/ioctl.h)
- AC_CHECK_HEADERS(sys/filio.h)
- AC_MSG_CHECKING([FIONBIO vs. O_NONBLOCK for nonblocking I/O])
- if test -f /usr/lib/NextStep/software_version; then
- system=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version`
- else
- system=`uname -s`-`uname -r`
- if test "$?" -ne 0 ; then
- system=unknown
- else
- # Special check for weird MP-RAS system (uname returns weird
- # results, and the version is kept in special file).
-
- if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then
- system=MP-RAS-`awk '{print $3}' /etc/.relid'`
- fi
- if test "`uname -s`" = "AIX" ; then
- system=AIX-`uname -v`.`uname -r`
- fi
- fi
- fi
- case $system in
- # There used to be code here to use FIONBIO under AIX. However, it
- # was reported that FIONBIO doesn't work under AIX 3.2.5. Since
- # using O_NONBLOCK seems fine under AIX 4.*, I removed the FIONBIO
- # code (JO, 5/31/97).
-
- OSF*)
- AC_DEFINE(USE_FIONBIO)
- AC_MSG_RESULT(FIONBIO)
- ;;
- SunOS-4*)
- AC_DEFINE(USE_FIONBIO)
- AC_MSG_RESULT(FIONBIO)
- ;;
- ULTRIX-4.*)
- AC_DEFINE(USE_FIONBIO)
- AC_MSG_RESULT(FIONBIO)
- ;;
- *)
- AC_MSG_RESULT(O_NONBLOCK)
- ;;
- esac
-])
-
-#--------------------------------------------------------------------
-# SC_HAVE_VFORK
-#
-# Check to see whether the system provides a vfork kernel call.
-# If not, then use fork instead. Also, check for a problem with
-# vforks and signals that can cause core dumps if a vforked child
-# resets a signal handler. If the problem exists, then use fork
-# instead of vfork.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Defines some of the following vars:
-# vfork (=fork)
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN(SC_HAVE_VFORK, [
- AC_TYPE_SIGNAL()
- AC_CHECK_FUNC(vfork, tcl_ok=1, tcl_ok=0)
- if test "$tcl_ok" = 1; then
- AC_MSG_CHECKING([vfork/signal bug]);
- AC_TRY_RUN([
-#include
-#include
-#include
-int gotSignal = 0;
-sigProc(sig)
- int sig;
-{
- gotSignal = 1;
-}
-main()
-{
- int pid, sts;
- (void) signal(SIGCHLD, sigProc);
- pid = vfork();
- if (pid < 0) {
- exit(1);
- } else if (pid == 0) {
- (void) signal(SIGCHLD, SIG_DFL);
- _exit(0);
- } else {
- (void) wait(&sts);
- }
- exit((gotSignal) ? 0 : 1);
-}], tcl_ok=1, tcl_ok=0, tcl_ok=0)
-
- if test "$tcl_ok" = 1; then
- AC_MSG_RESULT(ok)
- else
- AC_MSG_RESULT([buggy, using fork instead])
- fi
- fi
- rm -f core
- if test "$tcl_ok" = 0; then
- AC_DEFINE(vfork, fork)
- fi
-])
-
-#--------------------------------------------------------------------
-# SC_TIME_HANLDER
-#
-# Checks how the system deals with time.h, what time structures
-# are used on the system, and what fields the structures have.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Defines some of the following vars:
-# USE_DELTA_FOR_TZ
-# HAVE_TM_GMTOFF
-# HAVE_TM_TZADJ
-# HAVE_TIMEZONE_VAR
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN(SC_TIME_HANDLER, [
- AC_CHECK_HEADERS(sys/time.h)
- AC_HEADER_TIME
- AC_STRUCT_TIMEZONE
-
- AC_MSG_CHECKING([tm_tzadj in struct tm])
- AC_TRY_COMPILE([#include ], [struct tm tm; tm.tm_tzadj;],
- [AC_DEFINE(HAVE_TM_TZADJ)
- AC_MSG_RESULT(yes)],
- AC_MSG_RESULT(no))
-
- AC_MSG_CHECKING([tm_gmtoff in struct tm])
- AC_TRY_COMPILE([#include ], [struct tm tm; tm.tm_gmtoff;],
- [AC_DEFINE(HAVE_TM_GMTOFF)
- AC_MSG_RESULT(yes)],
- AC_MSG_RESULT(no))
-
- #
- # Its important to include time.h in this check, as some systems
- # (like convex) have timezone functions, etc.
- #
- have_timezone=no
- AC_MSG_CHECKING([long timezone variable])
- AC_TRY_COMPILE([#include ],
- [extern long timezone;
- timezone += 1;
- exit (0);],
- [have_timezone=yes
- AC_DEFINE(HAVE_TIMEZONE_VAR)
- AC_MSG_RESULT(yes)],
- AC_MSG_RESULT(no))
-
- #
- # On some systems (eg IRIX 6.2), timezone is a time_t and not a long.
- #
- if test "$have_timezone" = no; then
- AC_MSG_CHECKING([time_t timezone variable])
- AC_TRY_COMPILE([#include ],
- [extern time_t timezone;
- timezone += 1;
- exit (0);],
- [AC_DEFINE(HAVE_TIMEZONE_VAR)
- AC_MSG_RESULT(yes)],
- AC_MSG_RESULT(no))
- fi
-
- #
- # AIX does not have a timezone field in struct tm. When the AIX bsd
- # library is used, the timezone global and the gettimeofday methods are
- # to be avoided for timezone deduction instead, we deduce the timezone
- # by comparing the localtime result on a known GMT value.
- #
-
- if test "`uname -s`" = "AIX" ; then
- AC_CHECK_LIB(bsd, gettimeofday, libbsd=yes)
- if test $libbsd = yes; then
- AC_DEFINE(USE_DELTA_FOR_TZ)
- fi
- fi
-])
-
-#--------------------------------------------------------------------
-# SC_BUGGY_STRTOD
-#
-# Under Solaris 2.4, strtod returns the wrong value for the
-# terminating character under some conditions. Check for this
-# and if the problem exists use a substitute procedure
-# "fixstrtod" (provided by Tcl) that corrects the error.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Might defines some of the following vars:
-# strtod (=fixstrtod)
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN(SC_BUGGY_STRTOD, [
- AC_CHECK_FUNC(strtod, tcl_strtod=1, tcl_strtod=0)
- if test "$tcl_strtod" = 1; then
- AC_MSG_CHECKING([for Solaris2.4/Tru64 strtod bugs])
- AC_TRY_RUN([
- extern double strtod();
- int main()
- {
- char *string = "NaN", *spaceString = " ";
- char *term;
- double value;
- value = strtod(string, &term);
- if ((term != string) && (term[-1] == 0)) {
- exit(1);
- }
- value = strtod(spaceString, &term);
- if (term == (spaceString+1)) {
- exit(1);
- }
- exit(0);
- }], tcl_ok=1, tcl_ok=0, tcl_ok=0)
- if test "$tcl_ok" = 1; then
- AC_MSG_RESULT(ok)
- else
- AC_MSG_RESULT(buggy)
- LIBOBJS="$LIBOBJS fixstrtod.o"
- AC_DEFINE(strtod, fixstrtod)
- fi
- fi
-])
-
-#--------------------------------------------------------------------
-# SC_TCL_LINK_LIBS
-#
-# Search for the libraries needed to link the Tcl shell.
-# Things like the math library (-lm) and socket stuff (-lsocket vs.
-# -lnsl) are dealt with here.
-#
-# Arguments:
-# Requires the following vars to be set in the Makefile:
-# DL_LIBS
-# LIBS
-# MATH_LIBS
-#
-# Results:
-#
-# Subst's the following var:
-# TCL_LIBS
-# MATH_LIBS
-#
-# Might append to the following vars:
-# LIBS
-#
-# Might define the following vars:
-# HAVE_NET_ERRNO_H
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN(SC_TCL_LINK_LIBS, [
- #--------------------------------------------------------------------
- # On a few very rare systems, all of the libm.a stuff is
- # already in libc.a. Set compiler flags accordingly.
- # Also, Linux requires the "ieee" library for math to work
- # right (and it must appear before "-lm").
- #--------------------------------------------------------------------
-
- AC_CHECK_FUNC(sin, MATH_LIBS="", MATH_LIBS="-lm")
- AC_CHECK_LIB(ieee, main, [MATH_LIBS="-lieee $MATH_LIBS"])
-
- #--------------------------------------------------------------------
- # On AIX systems, libbsd.a has to be linked in to support
- # non-blocking file IO. This library has to be linked in after
- # the MATH_LIBS or it breaks the pow() function. The way to
- # insure proper sequencing, is to add it to the tail of MATH_LIBS.
- # This library also supplies gettimeofday.
- #--------------------------------------------------------------------
-
- libbsd=no
- if test "`uname -s`" = "AIX" ; then
- AC_CHECK_LIB(bsd, gettimeofday, libbsd=yes)
- if test $libbsd = yes; then
- MATH_LIBS="$MATH_LIBS -lbsd"
- fi
- fi
-
-
- #--------------------------------------------------------------------
- # Interactive UNIX requires -linet instead of -lsocket, plus it
- # needs net/errno.h to define the socket-related error codes.
- #--------------------------------------------------------------------
-
- AC_CHECK_LIB(inet, main, [LIBS="$LIBS -linet"])
- AC_CHECK_HEADER(net/errno.h, AC_DEFINE(HAVE_NET_ERRNO_H))
-
- #--------------------------------------------------------------------
- # Check for the existence of the -lsocket and -lnsl libraries.
- # The order here is important, so that they end up in the right
- # order in the command line generated by make. Here are some
- # special considerations:
- # 1. Use "connect" and "accept" to check for -lsocket, and
- # "gethostbyname" to check for -lnsl.
- # 2. Use each function name only once: can't redo a check because
- # autoconf caches the results of the last check and won't redo it.
- # 3. Use -lnsl and -lsocket only if they supply procedures that
- # aren't already present in the normal libraries. This is because
- # IRIX 5.2 has libraries, but they aren't needed and they're
- # bogus: they goof up name resolution if used.
- # 4. On some SVR4 systems, can't use -lsocket without -lnsl too.
- # To get around this problem, check for both libraries together
- # if -lsocket doesn't work by itself.
- #--------------------------------------------------------------------
-
- tcl_checkBoth=0
- AC_CHECK_FUNC(connect, tcl_checkSocket=0, tcl_checkSocket=1)
- if test "$tcl_checkSocket" = 1; then
- AC_CHECK_LIB(socket, main, LIBS="$LIBS -lsocket", tcl_checkBoth=1)
- fi
- if test "$tcl_checkBoth" = 1; then
- tk_oldLibs=$LIBS
- LIBS="$LIBS -lsocket -lnsl"
- AC_CHECK_FUNC(accept, tcl_checkNsl=0, [LIBS=$tk_oldLibs])
- fi
- AC_CHECK_FUNC(gethostbyname, , AC_CHECK_LIB(nsl, main,
- [LIBS="$LIBS -lnsl"]))
-
- # Don't perform the eval of the libraries here because DL_LIBS
- # won't be set until we call SC_CONFIG_CFLAGS
-
- TCL_LIBS='${DL_LIBS} ${LIBS} ${MATH_LIBS}'
- AC_SUBST(TCL_LIBS)
- AC_SUBST(MATH_LIBS)
-])
-
-#------------------------------------------------------------------------
-# SC_MAKE_LIB --
-#
-# Generate a line that can be used to build a shared/unshared library
-# in a platform independent manner.
-#
-# Arguments:
-# none
-#
-# Requires:
-#
-# Results:
-#
-# Defines the following vars:
-# MAKE_LIB Makefile rule for building a library
-# MAKE_SHARED_LIB Makefile rule for building a shared library
-# MAKE_UNSHARED_LIB Makefile rule for building a static
-# library
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_MAKE_LIB, [
- case "`uname -s`" in
- *win32* | *WIN32* | *CYGWIN_NT* |*CYGWIN_98*|*CYGWIN_95*)
- if test "${CC-cc}" = "cl"; then
- MAKE_STATIC_LIB="\${STLIB_LD} -out:\[$]@ \$(${PACKAGE}_LIB_OBJECTS) "
- MAKE_SHARED_LIB="\${SHLIB_LD} \${SHLIB_LDFLAGS} \${SHLIB_LD_LIBS} \$(LDFLAGS) -out:\[$]@ \$(${PACKAGE}_LIB_OBJECTS) "
- fi
- ;;
- *)
- MAKE_STATIC_LIB="\${STLIB_LD} \[$]@ \$(${PACKAGE}_LIB_OBJECTS)"
- MAKE_SHARED_LIB="\${SHLIB_LD} -o \[$]@ \$(${PACKAGE}_LIB_OBJECTS) \${SHLIB_LDFLAGS} \${SHLIB_LD_LIBS}"
- ;;
- esac
-
- if test "${SHARED_BUILD}" = "1" ; then
- MAKE_LIB=${MAKE_SHARED_LIB}
- else
- MAKE_LIB=${MAKE_STATIC_LIB}
- fi
-
- AC_SUBST(MAKE_LIB)
- AC_SUBST(MAKE_SHARED_LIB)
- AC_SUBST(MAKE_STATIC_LIB)
-])
-
-#------------------------------------------------------------------------
-# SC_LIB_SPEC --
-#
-# Compute the name of an existing object library located in libdir
-# from the given base name and produce the appropriate linker flags.
-#
-# Arguments:
-# basename The base name of the library without version
-# numbers, extensions, or "lib" prefixes.
-# extra_dir Extra directory in which to search for the
-# library. This location is used first, then
-# $prefix/$exec-prefix, then some defaults.
-#
-# Requires:
-# CYGPATH command used to generate native style paths
-#
-# Results:
-#
-# Defines the following vars:
-# ${basename}_LIB_NAME The computed library name.
-# ${basename}_LIB_SPEC The computed linker flags.
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_LIB_SPEC, [
- AC_MSG_CHECKING(for $1 library)
-
- # Look in exec-prefix and prefix for the library. If neither of
- # these were specified, look in libdir. It doesn't matter if libdir
- # wasn't specified since a search in the unspecified directory will
- # fail (NONE/lib)
-
- if test x"${exec_prefix}" != x"NONE" ; then
- sc_lib_name_dir="${exec_prefix}/lib"
- elif test x"${prefix}" != x"NONE" ; then
- sc_lib_name_dir="${prefix}/lib"
- else
- eval "sc_lib_name_dir=${libdir}"
- fi
-
- if test x"$2" != x ; then
- sc_extra_lib_dir=$2
- else
- sc_extra_lib_dir=NONE
- fi
-
- for i in \
- `ls -dr ${sc_extra_lib_dir}/$1[[0-9]]*.lib 2>/dev/null ` \
- `ls -dr ${sc_extra_lib_dir}/$1.lib 2>/dev/null ` \
- `ls -dr ${sc_extra_lib_dir}/lib$1[[0-9]]* 2>/dev/null ` \
- `ls -dr ${sc_extra_lib_dir}/lib$1.* 2>/dev/null ` \
- `ls -dr ${sc_lib_name_dir}/$1[[0-9]]*.lib 2>/dev/null ` \
- `ls -dr ${sc_lib_name_dir}/$1.lib 2>/dev/null ` \
- `ls -dr ${sc_lib_name_dir}/lib$1[[0-9]]* 2>/dev/null ` \
- `ls -dr ${sc_lib_name_dir}/lib$1.* 2>/dev/null ` \
- `ls -dr /usr/lib/$1[[0-9]]*.lib 2>/dev/null ` \
- `ls -dr /usr/lib/$1.lib 2>/dev/null ` \
- `ls -dr /usr/lib/lib$1[[0-9]]* 2>/dev/null ` \
- `ls -dr /usr/lib/lib$1.* 2>/dev/null ` \
- `ls -dr /usr/local/lib/$1[[0-9]]*.lib 2>/dev/null ` \
- `ls -dr /usr/local/lib/$1.lib 2>/dev/null ` \
- `ls -dr /usr/local/lib/lib$1[[0-9]]* 2>/dev/null ` \
- `ls -dr /usr/local/lib/lib$1.* 2>/dev/null ` ; do
- if test -f "$i" ; then
-
- sc_lib_name_dir=`dirname $i`
- $1_LIB_NAME=`basename $i`
- $1_LIB_PATH_NAME=$i
- break
- fi
- done
-
- case "`uname -s`" in
- *win32* | *WIN32* | *CYGWIN_NT* |*CYGWIN_98*|*CYGWIN_95*)
- $1_LIB_SPEC=\"`${CYGPATH} ${$1_LIB_PATH_NAME}`\"
- ;;
- *)
- # Strip off the leading "lib" and trailing ".a" or ".so"
-
- sc_lib_name_lib=`echo ${$1_LIB_NAME}|sed -e 's/^lib//' -e 's/\.[[^.]]*$//' -e 's/\.so.*//'`
- $1_LIB_SPEC="-L${sc_lib_name_dir} -l${sc_lib_name_lib}"
- ;;
- esac
-
- if test "x${$1_LIB_NAME}" = x ; then
- AC_MSG_ERROR(not found)
- else
- AC_MSG_RESULT(${$1_LIB_SPEC})
- fi
-])
-
-#------------------------------------------------------------------------
-# SC_PRIVATE_TCL_HEADERS --
-#
-# Locate the private Tcl include files
-#
-# Arguments:
-#
-# Requires:
-# TCL_SRC_DIR Assumes that SC_LOAD_TCLCONFIG has
-# already been called.
-#
-# Results:
-#
-# Substs the following vars:
-# TCL_TOP_DIR_NATIVE
-# TCL_GENERIC_DIR_NATIVE
-# TCL_UNIX_DIR_NATIVE
-# TCL_WIN_DIR_NATIVE
-# TCL_BMAP_DIR_NATIVE
-# TCL_TOOL_DIR_NATIVE
-# TCL_PLATFORM_DIR_NATIVE
-# TCL_BIN_DIR_NATIVE
-# TCL_INCLUDES
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_PRIVATE_TCL_HEADERS, [
- AC_MSG_CHECKING(for Tcl private include files)
-
- case "`uname -s`" in
- *win32* | *WIN32* | *CYGWIN_NT* |*CYGWIN_98*|*CYGWIN_95*)
- TCL_TOP_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}`\"
- TCL_GENERIC_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/generic`\"
- TCL_UNIX_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/unix`\"
- TCL_WIN_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/win`\"
- TCL_BMAP_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/bitmaps`\"
- TCL_TOOL_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/tools`\"
- TCL_COMPAT_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/compat`\"
- TCL_PLATFORM_DIR_NATIVE=${TCL_WIN_DIR_NATIVE}
- ;;
- *)
- TCL_TOP_DIR_NATIVE='$(TCL_SRC_DIR)'
- TCL_GENERIC_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/generic'
- TCL_UNIX_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/unix'
- TCL_WIN_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/win'
- TCL_BMAP_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/bitmaps'
- TCL_TOOL_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/tools'
- TCL_COMPAT_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/compat'
- TCL_PLATFORM_DIR_NATIVE=${TCL_UNIX_DIR_NATIVE}
- ;;
- esac
-
- AC_SUBST(TCL_TOP_DIR_NATIVE)
- AC_SUBST(TCL_GENERIC_DIR_NATIVE)
- AC_SUBST(TCL_UNIX_DIR_NATIVE)
- AC_SUBST(TCL_WIN_DIR_NATIVE)
- AC_SUBST(TCL_BMAP_DIR_NATIVE)
- AC_SUBST(TCL_TOOL_DIR_NATIVE)
- AC_SUBST(TCL_PLATFORM_DIR_NATIVE)
-
- TCL_INCLUDES="-I${TCL_GENERIC_DIR_NATIVE} -I${TCL_PLATFORM_DIR_NATIVE}"
- AC_SUBST(TCL_INCLUDES)
- AC_MSG_RESULT(Using srcdir found in tclConfig.sh)
-])
-
-#------------------------------------------------------------------------
-# SC_PUBLIC_TCL_HEADERS --
-#
-# Locate the installed public Tcl header files
-#
-# Arguments:
-# None.
-#
-# Requires:
-# CYGPATH must be set
-#
-# Results:
-#
-# Adds a --with-tclinclude switch to configure.
-# Result is cached.
-#
-# Substs the following vars:
-# TCL_INCLUDES
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_PUBLIC_TCL_HEADERS, [
- AC_MSG_CHECKING(for Tcl public headers)
-
- AC_ARG_WITH(tclinclude, [ --with-tclinclude directory containing the public Tcl header files.], with_tclinclude=${withval})
-
- if test x"${with_tclinclude}" != x ; then
- if test -f "${with_tclinclude}/tcl.h" ; then
- ac_cv_c_tclh=${with_tclinclude}
- else
- AC_MSG_ERROR([${with_tclinclude} directory does not contain Tcl public header file tcl.h])
- fi
- else
- AC_CACHE_VAL(ac_cv_c_tclh, [
- # Use the value from --with-tclinclude, if it was given
-
- if test x"${with_tclinclude}" != x ; then
- ac_cv_c_tclh=${with_tclinclude}
- else
- # Check in the includedir, if --prefix was specified
-
- eval "temp_includedir=${includedir}"
- for i in \
- `ls -d ${TCL_PREFIX}/include 2>/dev/null` \
- `ls -d ${temp_includedir} 2>/dev/null` \
- `ls -d ${TCL_BIN_DIR}/../include 2>/dev/null` \
- /usr/local/include /usr/include ; do
- if test -f "$i/tcl.h" ; then
- ac_cv_c_tclh=$i
- break
- fi
- done
- fi
- ])
- fi
-
- # Print a message based on how we determined the include path
-
- if test x"${ac_cv_c_tclh}" = x ; then
- AC_MSG_ERROR(tcl.h not found. Please specify its location with --with-tclinclude)
- else
- AC_MSG_RESULT(${ac_cv_c_tclh})
- fi
-
- # Convert to a native path and substitute into the output files.
-
- INCLUDE_DIR_NATIVE=`${CYGPATH} ${ac_cv_c_tclh}`
-
- TCL_INCLUDES=-I\"${INCLUDE_DIR_NATIVE}\"
-
- AC_SUBST(TCL_INCLUDES)
-])
-
-#------------------------------------------------------------------------
-# SC_PRIVATE_TK_HEADERS --
-#
-# Locate the private Tk include files
-#
-# Arguments:
-#
-# Requires:
-# TK_SRC_DIR Assumes that SC_LOAD_TKCONFIG has
-# already been called.
-#
-# Results:
-#
-# Substs the following vars:
-# TK_INCLUDES
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_PRIVATE_TK_HEADERS, [
- AC_MSG_CHECKING(for Tk private include files)
-
- case "`uname -s`" in
- *win32* | *WIN32* | *CYGWIN_NT* |*CYGWIN_98*|*CYGWIN_95*)
- TK_TOP_DIR_NATIVE=\"`${CYGPATH} ${TK_SRC_DIR}`\"
- TK_UNIX_DIR_NATIVE=\"`${CYGPATH} ${TK_SRC_DIR}/unix`\"
- TK_WIN_DIR_NATIVE=\"`${CYGPATH} ${TK_SRC_DIR}/win`\"
- TK_GENERIC_DIR_NATIVE=\"`${CYGPATH} ${TK_SRC_DIR}/generic`\"
- TK_XLIB_DIR_NATIVE=\"`${CYGPATH} ${TK_SRC_DIR}/xlib`\"
- TK_PLATFORM_DIR_NATIVE=${TK_WIN_DIR_NATIVE}
-
- TK_INCLUDES="-I${TK_GENERIC_DIR_NATIVE} -I${TK_PLATFORM_DIR_NATIVE} -I${TK_XLIB_DIR_NATIVE}"
- ;;
- *)
- TK_TOP_DIR_NATIVE='$(TK_SRC_DIR)'
- TK_GENERIC_DIR_NATIVE='$(TK_TOP_DIR_NATIVE)/generic'
- TK_UNIX_DIR_NATIVE='$(TK_TOP_DIR_NATIVE)/unix'
- TK_WIN_DIR_NATIVE='$(TK_TOP_DIR_NATIVE)/win'
- TK_PLATFORM_DIR_NATIVE=${TK_UNIX_DIR_NATIVE}
-
- TK_INCLUDES="-I${TK_GENERIC_DIR_NATIVE} -I${TK_PLATFORM_DIR_NATIVE}"
- ;;
- esac
-
- AC_SUBST(TK_TOP_DIR_NATIVE)
- AC_SUBST(TK_UNIX_DIR_NATIVE)
- AC_SUBST(TK_WIN_DIR_NATIVE)
- AC_SUBST(TK_GENERIC_DIR_NATIVE)
- AC_SUBST(TK_XLIB_DIR_NATIVE)
- AC_SUBST(TK_PLATFORM_DIR_NATIVE)
-
- AC_SUBST(TK_INCLUDES)
- AC_MSG_RESULT(Using srcdir found in tkConfig.sh)
-])
-
-#------------------------------------------------------------------------
-# SC_PUBLIC_TK_HEADERS --
-#
-# Locate the installed public Tk header files
-#
-# Arguments:
-# None.
-#
-# Requires:
-# CYGPATH must be set
-#
-# Results:
-#
-# Adds a --with-tkinclude switch to configure.
-# Result is cached.
-#
-# Substs the following vars:
-# TK_INCLUDES
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_PUBLIC_TK_HEADERS, [
- AC_MSG_CHECKING(for Tk public headers)
-
- AC_ARG_WITH(tkinclude, [ --with-tkinclude directory containing the public Tk header files.], with_tkinclude=${withval})
-
- if test x"${with_tkinclude}" != x ; then
- if test -f "${with_tkinclude}/tk.h" ; then
- ac_cv_c_tkh=${with_tkinclude}
- else
- AC_MSG_ERROR([${with_tkinclude} directory does not contain Tk public header file tk.h])
- fi
- else
- AC_CACHE_VAL(ac_cv_c_tkh, [
- # Use the value from --with-tkinclude, if it was given
-
- if test x"${with_tkinclude}" != x ; then
- ac_cv_c_tkh=${with_tkinclude}
- else
- # Check in the includedir, if --prefix was specified
-
- eval "temp_includedir=${includedir}"
- for i in \
- `ls -d ${TCL_PREFIX}/include 2>/dev/null` \
- `ls -d ${temp_includedir} 2>/dev/null` \
- `ls -d ${TCL_BIN_DIR}/../include 2>/dev/null` \
- /usr/local/include /usr/include ; do
- if test -f "$i/tk.h" ; then
- ac_cv_c_tkh=$i
- break
- fi
- done
- fi
- ])
- fi
-
- # Print a message based on how we determined the include path
-
- if test x"${ac_cv_c_tkh}" = x ; then
- AC_MSG_ERROR(tk.h not found. Please specify its location with --with-tkinclude)
- else
- AC_MSG_RESULT(${ac_cv_c_tkh})
- fi
-
- # Convert to a native path and substitute into the output files.
-
- INCLUDE_DIR_NATIVE=`${CYGPATH} ${ac_cv_c_tkh}`
-
- TK_INCLUDES=-I\"${INCLUDE_DIR_NATIVE}\"
-
- AC_SUBST(TK_INCLUDES)
-])
-
-#------------------------------------------------------------------------
-# SC_SIMPLE_EXEEXT
-# Select the executable extension based on the host type. This
-# is a lightweight replacement for AC_EXEEXT that doesn't require
-# a compiler.
-#
-# Arguments
-# none
-#
-# Results
-# Subst's the following values:
-# EXEEXT
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_SIMPLE_EXEEXT, [
- AC_MSG_CHECKING(executable extension based on host type)
-
- case "`uname -s`" in
- *win32* | *WIN32* | *CYGWIN_NT* |*CYGWIN_98*|*CYGWIN_95*)
- EXEEXT=".exe"
- ;;
- *)
- EXEEXT=""
- ;;
- esac
-
- AC_MSG_RESULT(${EXEEXT})
- AC_SUBST(EXEEXT)
-])
-
-#------------------------------------------------------------------------
-# SC_PROG_TCLSH
-# Locate a tclsh shell in the following directories:
-# ${exec_prefix}/bin
-# ${prefix}/bin
-# ${TCL_BIN_DIR}
-# ${TCL_BIN_DIR}/../bin
-# ${PATH}
-#
-# Arguments
-# none
-#
-# Results
-# Subst's the following values:
-# TCLSH_PROG
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_PROG_TCLSH, [
- AC_MSG_CHECKING([for tclsh])
-
- AC_CACHE_VAL(ac_cv_path_tclsh, [
- search_path=`echo ${exec_prefix}/bin:${prefix}/bin:${TCL_BIN_DIR}:${TCL_BIN_DIR}/../bin:${PATH} | sed -e 's/:/ /g'`
- for dir in $search_path ; do
- for j in `ls -r $dir/tclsh[[8-9]]*${EXEEXT} 2> /dev/null` \
- `ls -r $dir/tclsh*${EXEEXT} 2> /dev/null` ; do
- if test x"$ac_cv_path_tclsh" = x ; then
- if test -f "$j" ; then
- ac_cv_path_tclsh=$j
- break
- fi
- fi
- done
- done
- ])
-
- if test -f "$ac_cv_path_tclsh" ; then
- TCLSH_PROG=$ac_cv_path_tclsh
- AC_MSG_RESULT($TCLSH_PROG)
- else
- AC_MSG_ERROR(No tclsh found in PATH: $search_path)
- fi
- AC_SUBST(TCLSH_PROG)
-])
-
-#------------------------------------------------------------------------
-# SC_PROG_WISH
-# Locate a wish shell in the following directories:
-# ${exec_prefix}/bin
-# ${prefix}/bin
-# ${TCL_BIN_DIR}
-# ${TCL_BIN_DIR}/../bin
-# ${PATH}
-#
-# Arguments
-# none
-#
-# Results
-# Subst's the following values:
-# WISH_PROG
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_PROG_WISH, [
- AC_MSG_CHECKING([for wish])
-
- AC_CACHE_VAL(ac_cv_path_wish, [
- search_path=`echo ${exec_prefix}/bin:${prefix}/bin:${TCL_BIN_DIR}:${TCL_BIN_DIR}/../bin:${PATH} | sed -e 's/:/ /g'`
- for dir in $search_path ; do
- for j in `ls -r $dir/wish[[8-9]]*${EXEEXT} 2> /dev/null` \
- `ls -r $dir/wish*${EXEEXT} 2> /dev/null` ; do
- if test x"$ac_cv_path_wish" = x ; then
- if test -f "$j" ; then
- ac_cv_path_wish=$j
- break
- fi
- fi
- done
- done
- ])
-
- if test -f "$ac_cv_path_wish" ; then
- WISH_PROG=$ac_cv_path_wish
- AC_MSG_RESULT($WISH_PROG)
- else
- AC_MSG_ERROR(No wish found in PATH: $search_path)
- fi
- AC_SUBST(WISH_PROG)
-])
-
-#------------------------------------------------------------------------
-# SC_SET_PLATFORM
-# Determine the common name of the platform we are using
-#
-# Arguments
-# none
-#
-# Results
-# Subst's the following values:
-# PLATFORM
-# CYGPATH
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_SET_PLATFORM, [
- AC_MSG_CHECKING(host platform)
-
- case "`uname -s`" in
- *win32* | *WIN32* | *CYGWIN_NT* | *CYGWIN_98* | *CYGWIN_95*)
- CYGPATH="cygpath -w"
- PLATFORM=win32-ix86
- ;;
- SunOS)
- CYGPATH=echo
- PLATFORM=solaris-sparc
- ;;
- Linux)
- CYGPATH=echo
- PLATFORM=linux-ix86
- ;;
- FreeBSD)
- CYGPATH=echo
- PLATFORM=freebsd-ix86
- ;;
- AIX)
- CYGPATH=echo
- PLATFORM=aix-risc
- ;;
- HP-UX)
- CYGPATH=echo
- PLATFORM=hpux-parisc
- ;;
- IRIX)
- CYGPATH=echo
- PLATFORM=irix-mips
- ;;
- *)
- CYGPATH=echo
- PLATFORM=UNSUPPORTED
- ;;
- esac
-
- if test x"${PLATFORM}" = x"UNSUPPORTED" ; then
- AC_MSG_ERROR(Can't figure out what platform you are using)
- else
- AC_MSG_RESULT(${PLATFORM})
- fi
-
- AC_SUBST(PLATFORM)
- AC_SUBST(CYGPATH)
-])
-
-#------------------------------------------------------------------------
-# SC_PATH_MODULE
-# Add a --with-foodir flag for locating sources for an external module
-# Search order:
-# --with-foodir configure switch value
-# cached configure value
-# $2 argument
-# ${srcdir}/modules/$1
-# ${srcdir}/../$1
-# ${srcdir}/../$1[0-9]*
-#
-# Arguments
-# $1 Name of module to locate
-# $2 Default directory where module can be found. If not specified,
-# the macro looks in some well-known locations. This argument
-# is mainly used for internal modules.
-#
-# Results
-# sets MODULE_DIR_$1 to point to the top level directory of
-# the module.
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_PATH_MODULE, [
-
- if test x"${CYGPATH}" = x ; then
- SC_SET_PLATFORM
- fi
-
- modsrcdir=$1
-
- AC_ARG_WITH($1dir, [ --with-$1dir directory containing sources for $1], with_module=${withval}, with_module="")
- AC_MSG_CHECKING([for $1dir])
-
- if test x"${with_module}" = x ; then
- AC_CACHE_VAL(ac_cv_module_$1dir,[
- if test x"${with_module}" != x ; then
- # Sanity check. Look for this module dir
- if test -d "${with_module}" ; then
- ac_cv_module_$1dir=`(cd ${with_module} ; pwd)`
- fi
- fi
-
-
- # If not found, look in a few standard places for this module.
- # Look in the default location (as specified by the argument(s)
- # to this macro) first
-
- if test x"$2" != x ; then
- for i in \
- `ls -dr $2 2>/dev/null` \
- `ls -dr ${srcdir}/$2 2>/dev/null` \
- `ls -dr ${srcdir}/../$2 2>/dev/null` \
- `ls -dr ${srcdir}/../$2[[0-9]]* 2>/dev/null` ; do
- if test -d $i ; then
- ac_cv_module_$1dir=`(cd $i; pwd)`
- break
- fi
- done
- fi
-
- # Make sure not to require a specific version number.
-
- if test x"${ac_cv_module_$1dir}" = x ; then
- for i in \
- `ls -dr ${srcdir}/modules/$modsrcdir 2>/dev/null` \
- `ls -dr ${srcdir}/../$modsrcdir 2>/dev/null` \
- `ls -dr ${srcdir}/../$modsrcdir[[0-9]]* 2>/dev/null` ; do
- if test -d $i ; then
- ac_cv_module_$1dir=`(cd $i; pwd)`
- break
- fi
- done
- fi
-
-
- ])
- else
- if test -d "${with_module}" ; then
- ac_cv_module_$1dir=`(cd ${with_module} ; pwd)`
- else
- AC_MSG_ERROR("Directory ${with_module} does not exist!")
- fi
- fi
-
- if test x"${ac_cv_module_$1dir}" = x ; then
- AC_MSG_WARN(MISSING. Use --with-$1dir to specify location of $1 or make sure you have checked out the sources from cvs.)
- MISSING_MODULE_LIST="${MISSING_MODULE_LIST} $1"
- MODULE_LIST="${MODULE_LIST} $1"
- else
- # Strip off any trailing \ from the path
- MODULE_DIR_$1=`${CYGPATH} ${ac_cv_module_$1dir} | sed -e 's%\\\\$%%'`
- AC_MSG_RESULT(${MODULE_DIR_$1})
- AC_SUBST(MODULE_DIR_$1)
- if test x"$1" != x"${PACKAGE}" ; then
- MODULE_LIST="${MODULE_LIST} $1"
- fi
- fi
-])
-
-#------------------------------------------------------------------------
-# SC_PATH_TOOLS
-# Add a --with-toolsdir flag for locating sources for an external module
-#
-# Arguments
-# none
-#
-# Results
-# sets MODULE_DIR_tools to point to the top level directory of
-# the module.
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_PATH_TOOLS, [
- AC_ARG_WITH(toolsdir, [ --with-toolsdir directory containing sources for tools], with_module=${withval}, with_module="")
- AC_MSG_CHECKING([for toolsdir])
-
- if test x"${with_module}" = x ; then
- AC_CACHE_VAL(ac_cv_module_toolsdir,[
- if test x"${with_module}" != x ; then
- # Sanity check. Look for configure.in in this module dir
- if test -d "${with_module}" ; then
- ac_cv_module_toolsdir=`(cd ${with_module} ; pwd)`
- fi
- fi
-
-
-
- # If not found, look in a few standard places for this module.
- # Make sure not to require a specific version number.
-
- if test x"${ac_cv_module_toolsdir}" = x ; then
- for i in \
- `ls -dr /tools/1.[[1-5]] 2>/dev/null` \
- `ls -dr /tools/TclPro1.[[1-5]] 2>/dev/null` \
- `ls -dr //t/tools/1.[[1-5]] 2>/dev/null` \
- `ls -dr //t/tools/TclPro1.[[1-5]] 2>/dev/null` \
- `ls -dr //pop/tools/1.[[1-5]] 2>/dev/null` \
- `ls -dr //pop/tools/TclPro1.[[1-5]] 2>/dev/null` ; do
- if test -d $i ; then
- ac_cv_module_toolsdir=`(cd $i; pwd)`
- break
- fi
- done
- fi
-
-
- ])
- else
- if test -d "${with_module}" ; then
- ac_cv_module_toolsdir=`(cd ${with_module} ; pwd)`
- else
- AC_MSG_WARN(Directory ${with_module} does not exist!)
- fi
- fi
-
- if test x"${ac_cv_module_toolsdir}" = x ; then
- AC_MSG_WARN(No tools directory - pressing forward with bogus value.)
- MODULE_DIR_tools=no_tools_dir
- AC_SUBST(MODULE_DIR_tools)
-# AC_MSG_ERROR("Use --with-toolsdir to specify location of tools")
-# exit 1
- else
- MODULE_DIR_tools=${ac_cv_module_toolsdir}
- AC_MSG_RESULT(${ac_cv_module_toolsdir})
- AC_SUBST(MODULE_DIR_tools)
- fi
-])
-
-#------------------------------------------------------------------------
-# SC_PATH_PROTOOLS
-# Path to a valid Tclpro installation. You must call SC_ SET_PLATFORM
-# before calling this macro.
-#
-# Arguments
-# none
-#
-# Results
-# Subst's the following values:
-# PROTOOLSDIR
-#------------------------------------------------------------------------
-
-AC_DEFUN(SC_PATH_PROTOOLS, [
- if test x"${PLATFORM}" = x ; then
- SC_SET_PLATFORM
- fi
-
- AC_ARG_WITH(protools, [ --with-protools directory containing the Tclpro installation], protools_dir=${withval})
-
- AC_MSG_CHECKING(for protclsh in a TclPro installation)
-
- if test x"${protools_dir}" != x ; then
- # Look for protclsh
-
- for i in `ls -r ${protools_dir}/${PLATFORM}/bin/protclsh* 2>/dev/null` ; do
- if test -f $i ; then
- PROTCLSH=$i
- break
- fi
- done
- else
- for i in `ls -dr /tools/TclPro1.[[3-4]] 2>/dev/null` \
- `ls -dr //t/tools/TclPro1.[[3-4]] 2>/dev/null ` ; do
-
- # Look for protclsh
-
- for j in `ls $i/${PLATFORM}/bin/protclsh* 2>/dev/null` ; do
- if test -f $j ; then
- PROTCLSH=$j
- break
- fi
- done
-
- if test x"${PROTCLSH}" != x ; then
- protools_dir=$i
- break
- fi
- done
- fi
-
- if test x"${PROTCLSH}" = x ; then
- AC_MSG_WARN(Could not locate a TclPro installation containing protclsh. Use --with-protoolsdir to specify a valid TclPro installation.)
- protools_dir=BOGUS_protools_dir
- else
- AC_MSG_RESULT("found ${PROTCLSH}")
- fi
-
- PROTOOLSDIR=${protools_dir}
- AC_SUBST(PROTOOLSDIR)
-])
DELETED configure
Index: configure
==================================================================
--- configure
+++ /dev/null
@@ -1,854 +0,0 @@
-#! /bin/sh
-
-# Guess values for system-dependent variables and create Makefiles.
-# Generated automatically using autoconf version 2.13
-# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
-#
-# This configure script is free software; the Free Software Foundation
-# gives unlimited permission to copy, distribute and modify it.
-
-# Defaults:
-ac_help=
-ac_default_prefix=/usr/local
-# Any additions from configure.in:
-
-# Initialize some variables set by options.
-# The variables have the same names as the options, with
-# dashes changed to underlines.
-build=NONE
-cache_file=./config.cache
-exec_prefix=NONE
-host=NONE
-no_create=
-nonopt=NONE
-no_recursion=
-prefix=NONE
-program_prefix=NONE
-program_suffix=NONE
-program_transform_name=s,x,x,
-silent=
-site=
-srcdir=
-target=NONE
-verbose=
-x_includes=NONE
-x_libraries=NONE
-bindir='${exec_prefix}/bin'
-sbindir='${exec_prefix}/sbin'
-libexecdir='${exec_prefix}/libexec'
-datadir='${prefix}/share'
-sysconfdir='${prefix}/etc'
-sharedstatedir='${prefix}/com'
-localstatedir='${prefix}/var'
-libdir='${exec_prefix}/lib'
-includedir='${prefix}/include'
-oldincludedir='/usr/include'
-infodir='${prefix}/info'
-mandir='${prefix}/man'
-
-# Initialize some other variables.
-subdirs=
-MFLAGS= MAKEFLAGS=
-SHELL=${CONFIG_SHELL-/bin/sh}
-# Maximum number of lines to put in a shell here document.
-ac_max_here_lines=12
-
-ac_prev=
-for ac_option
-do
-
- # If the previous option needs an argument, assign it.
- if test -n "$ac_prev"; then
- eval "$ac_prev=\$ac_option"
- ac_prev=
- continue
- fi
-
- case "$ac_option" in
- -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
- *) ac_optarg= ;;
- esac
-
- # Accept the important Cygnus configure options, so we can diagnose typos.
-
- case "$ac_option" in
-
- -bindir | --bindir | --bindi | --bind | --bin | --bi)
- ac_prev=bindir ;;
- -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
- bindir="$ac_optarg" ;;
-
- -build | --build | --buil | --bui | --bu)
- ac_prev=build ;;
- -build=* | --build=* | --buil=* | --bui=* | --bu=*)
- build="$ac_optarg" ;;
-
- -cache-file | --cache-file | --cache-fil | --cache-fi \
- | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
- ac_prev=cache_file ;;
- -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
- | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
- cache_file="$ac_optarg" ;;
-
- -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
- ac_prev=datadir ;;
- -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
- | --da=*)
- datadir="$ac_optarg" ;;
-
- -disable-* | --disable-*)
- ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
- # Reject names that are not valid shell variable names.
- if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
- { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
- fi
- ac_feature=`echo $ac_feature| sed 's/-/_/g'`
- eval "enable_${ac_feature}=no" ;;
-
- -enable-* | --enable-*)
- ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
- # Reject names that are not valid shell variable names.
- if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
- { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
- fi
- ac_feature=`echo $ac_feature| sed 's/-/_/g'`
- case "$ac_option" in
- *=*) ;;
- *) ac_optarg=yes ;;
- esac
- eval "enable_${ac_feature}='$ac_optarg'" ;;
-
- -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
- | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
- | --exec | --exe | --ex)
- ac_prev=exec_prefix ;;
- -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
- | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
- | --exec=* | --exe=* | --ex=*)
- exec_prefix="$ac_optarg" ;;
-
- -gas | --gas | --ga | --g)
- # Obsolete; use --with-gas.
- with_gas=yes ;;
-
- -help | --help | --hel | --he)
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat << EOF
-Usage: configure [options] [host]
-Options: [defaults in brackets after descriptions]
-Configuration:
- --cache-file=FILE cache test results in FILE
- --help print this message
- --no-create do not create output files
- --quiet, --silent do not print \`checking...' messages
- --version print the version of autoconf that created configure
-Directory and file names:
- --prefix=PREFIX install architecture-independent files in PREFIX
- [$ac_default_prefix]
- --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
- [same as prefix]
- --bindir=DIR user executables in DIR [EPREFIX/bin]
- --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
- --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
- --datadir=DIR read-only architecture-independent data in DIR
- [PREFIX/share]
- --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
- --sharedstatedir=DIR modifiable architecture-independent data in DIR
- [PREFIX/com]
- --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
- --libdir=DIR object code libraries in DIR [EPREFIX/lib]
- --includedir=DIR C header files in DIR [PREFIX/include]
- --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
- --infodir=DIR info documentation in DIR [PREFIX/info]
- --mandir=DIR man documentation in DIR [PREFIX/man]
- --srcdir=DIR find the sources in DIR [configure dir or ..]
- --program-prefix=PREFIX prepend PREFIX to installed program names
- --program-suffix=SUFFIX append SUFFIX to installed program names
- --program-transform-name=PROGRAM
- run sed PROGRAM on installed program names
-EOF
- cat << EOF
-Host type:
- --build=BUILD configure for building on BUILD [BUILD=HOST]
- --host=HOST configure for HOST [guessed]
- --target=TARGET configure for TARGET [TARGET=HOST]
-Features and packages:
- --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
- --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
- --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
- --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
- --x-includes=DIR X include files are in DIR
- --x-libraries=DIR X library files are in DIR
-EOF
- if test -n "$ac_help"; then
- echo "--enable and --with options recognized:$ac_help"
- fi
- exit 0 ;;
-
- -host | --host | --hos | --ho)
- ac_prev=host ;;
- -host=* | --host=* | --hos=* | --ho=*)
- host="$ac_optarg" ;;
-
- -includedir | --includedir | --includedi | --included | --include \
- | --includ | --inclu | --incl | --inc)
- ac_prev=includedir ;;
- -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
- | --includ=* | --inclu=* | --incl=* | --inc=*)
- includedir="$ac_optarg" ;;
-
- -infodir | --infodir | --infodi | --infod | --info | --inf)
- ac_prev=infodir ;;
- -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
- infodir="$ac_optarg" ;;
-
- -libdir | --libdir | --libdi | --libd)
- ac_prev=libdir ;;
- -libdir=* | --libdir=* | --libdi=* | --libd=*)
- libdir="$ac_optarg" ;;
-
- -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
- | --libexe | --libex | --libe)
- ac_prev=libexecdir ;;
- -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
- | --libexe=* | --libex=* | --libe=*)
- libexecdir="$ac_optarg" ;;
-
- -localstatedir | --localstatedir | --localstatedi | --localstated \
- | --localstate | --localstat | --localsta | --localst \
- | --locals | --local | --loca | --loc | --lo)
- ac_prev=localstatedir ;;
- -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
- | --localstate=* | --localstat=* | --localsta=* | --localst=* \
- | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
- localstatedir="$ac_optarg" ;;
-
- -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
- ac_prev=mandir ;;
- -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
- mandir="$ac_optarg" ;;
-
- -nfp | --nfp | --nf)
- # Obsolete; use --without-fp.
- with_fp=no ;;
-
- -no-create | --no-create | --no-creat | --no-crea | --no-cre \
- | --no-cr | --no-c)
- no_create=yes ;;
-
- -no-recursion | --no-recursion | --no-recursio | --no-recursi \
- | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
- no_recursion=yes ;;
-
- -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
- | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
- | --oldin | --oldi | --old | --ol | --o)
- ac_prev=oldincludedir ;;
- -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
- | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
- | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
- oldincludedir="$ac_optarg" ;;
-
- -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
- ac_prev=prefix ;;
- -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
- prefix="$ac_optarg" ;;
-
- -program-prefix | --program-prefix | --program-prefi | --program-pref \
- | --program-pre | --program-pr | --program-p)
- ac_prev=program_prefix ;;
- -program-prefix=* | --program-prefix=* | --program-prefi=* \
- | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
- program_prefix="$ac_optarg" ;;
-
- -program-suffix | --program-suffix | --program-suffi | --program-suff \
- | --program-suf | --program-su | --program-s)
- ac_prev=program_suffix ;;
- -program-suffix=* | --program-suffix=* | --program-suffi=* \
- | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
- program_suffix="$ac_optarg" ;;
-
- -program-transform-name | --program-transform-name \
- | --program-transform-nam | --program-transform-na \
- | --program-transform-n | --program-transform- \
- | --program-transform | --program-transfor \
- | --program-transfo | --program-transf \
- | --program-trans | --program-tran \
- | --progr-tra | --program-tr | --program-t)
- ac_prev=program_transform_name ;;
- -program-transform-name=* | --program-transform-name=* \
- | --program-transform-nam=* | --program-transform-na=* \
- | --program-transform-n=* | --program-transform-=* \
- | --program-transform=* | --program-transfor=* \
- | --program-transfo=* | --program-transf=* \
- | --program-trans=* | --program-tran=* \
- | --progr-tra=* | --program-tr=* | --program-t=*)
- program_transform_name="$ac_optarg" ;;
-
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- silent=yes ;;
-
- -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
- ac_prev=sbindir ;;
- -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
- | --sbi=* | --sb=*)
- sbindir="$ac_optarg" ;;
-
- -sharedstatedir | --sharedstatedir | --sharedstatedi \
- | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
- | --sharedst | --shareds | --shared | --share | --shar \
- | --sha | --sh)
- ac_prev=sharedstatedir ;;
- -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
- | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
- | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
- | --sha=* | --sh=*)
- sharedstatedir="$ac_optarg" ;;
-
- -site | --site | --sit)
- ac_prev=site ;;
- -site=* | --site=* | --sit=*)
- site="$ac_optarg" ;;
-
- -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
- ac_prev=srcdir ;;
- -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
- srcdir="$ac_optarg" ;;
-
- -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
- | --syscon | --sysco | --sysc | --sys | --sy)
- ac_prev=sysconfdir ;;
- -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
- | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
- sysconfdir="$ac_optarg" ;;
-
- -target | --target | --targe | --targ | --tar | --ta | --t)
- ac_prev=target ;;
- -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
- target="$ac_optarg" ;;
-
- -v | -verbose | --verbose | --verbos | --verbo | --verb)
- verbose=yes ;;
-
- -version | --version | --versio | --versi | --vers)
- echo "configure generated by autoconf version 2.13"
- exit 0 ;;
-
- -with-* | --with-*)
- ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
- # Reject names that are not valid shell variable names.
- if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
- { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
- fi
- ac_package=`echo $ac_package| sed 's/-/_/g'`
- case "$ac_option" in
- *=*) ;;
- *) ac_optarg=yes ;;
- esac
- eval "with_${ac_package}='$ac_optarg'" ;;
-
- -without-* | --without-*)
- ac_package=`echo $ac_option|sed -e 's/-*without-//'`
- # Reject names that are not valid shell variable names.
- if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
- { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
- fi
- ac_package=`echo $ac_package| sed 's/-/_/g'`
- eval "with_${ac_package}=no" ;;
-
- --x)
- # Obsolete; use --with-x.
- with_x=yes ;;
-
- -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
- | --x-incl | --x-inc | --x-in | --x-i)
- ac_prev=x_includes ;;
- -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
- | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
- x_includes="$ac_optarg" ;;
-
- -x-libraries | --x-libraries | --x-librarie | --x-librari \
- | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
- ac_prev=x_libraries ;;
- -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
- | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
- x_libraries="$ac_optarg" ;;
-
- -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
- ;;
-
- *)
- if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
- echo "configure: warning: $ac_option: invalid host type" 1>&2
- fi
- if test "x$nonopt" != xNONE; then
- { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
- fi
- nonopt="$ac_option"
- ;;
-
- esac
-done
-
-if test -n "$ac_prev"; then
- { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
-fi
-
-trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
-
-# File descriptor usage:
-# 0 standard input
-# 1 file creation
-# 2 errors and warnings
-# 3 some systems may open it to /dev/tty
-# 4 used on the Kubota Titan
-# 6 checking for... messages and results
-# 5 compiler messages saved in config.log
-if test "$silent" = yes; then
- exec 6>/dev/null
-else
- exec 6>&1
-fi
-exec 5>./config.log
-
-echo "\
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-" 1>&5
-
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Also quote any args containing shell metacharacters.
-ac_configure_args=
-for ac_arg
-do
- case "$ac_arg" in
- -no-create | --no-create | --no-creat | --no-crea | --no-cre \
- | --no-cr | --no-c) ;;
- -no-recursion | --no-recursion | --no-recursio | --no-recursi \
- | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
- *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
- ac_configure_args="$ac_configure_args '$ac_arg'" ;;
- *) ac_configure_args="$ac_configure_args $ac_arg" ;;
- esac
-done
-
-# NLS nuisances.
-# Only set these to C if already set. These must not be set unconditionally
-# because not all systems understand e.g. LANG=C (notably SCO).
-# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
-# Non-C LC_CTYPE values break the ctype check.
-if test "${LANG+set}" = set; then LANG=C; export LANG; fi
-if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
-if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
-if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -rf conftest* confdefs.h
-# AIX cpp loses on an empty file, so make sure it contains at least a newline.
-echo > confdefs.h
-
-# A filename unique to this package, relative to the directory that
-# configure is in, which we can look for to find out if srcdir is correct.
-ac_unique_file=ChangeLog
-
-# Find the source files, if location was not specified.
-if test -z "$srcdir"; then
- ac_srcdir_defaulted=yes
- # Try the directory containing this script, then its parent.
- ac_prog=$0
- ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
- test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
- srcdir=$ac_confdir
- if test ! -r $srcdir/$ac_unique_file; then
- srcdir=..
- fi
-else
- ac_srcdir_defaulted=no
-fi
-if test ! -r $srcdir/$ac_unique_file; then
- if test "$ac_srcdir_defaulted" = yes; then
- { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
- else
- { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
- fi
-fi
-srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
-
-# Prefer explicitly selected file to automatically selected ones.
-if test -z "$CONFIG_SITE"; then
- if test "x$prefix" != xNONE; then
- CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
- else
- CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
- fi
-fi
-for ac_site_file in $CONFIG_SITE; do
- if test -r "$ac_site_file"; then
- echo "loading site script $ac_site_file"
- . "$ac_site_file"
- fi
-done
-
-if test -r "$cache_file"; then
- echo "loading cache $cache_file"
- . $cache_file
-else
- echo "creating cache $cache_file"
- > $cache_file
-fi
-
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-ac_exeext=
-ac_objext=o
-if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
- # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
- if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
- ac_n= ac_c='
-' ac_t=' '
- else
- ac_n=-n ac_c= ac_t=
- fi
-else
- ac_n= ac_c='\c' ac_t=
-fi
-
-
-
-case "`uname -s`" in
- *win32* | *WIN32* | *CYGWIN_NT* | *CYGWIN_98* | *CYGWIN_95*)
- CYGPATH="cygpath -w"
- ;;
- *)
- CYGPATH=echo
- ;;
-esac
-
-
-
- echo $ac_n "checking executable extension based on host type""... $ac_c" 1>&6
-echo "configure:538: checking executable extension based on host type" >&5
-
- case "`uname -s`" in
- *win32* | *WIN32* | *CYGWIN_NT* |*CYGWIN_98*|*CYGWIN_95*)
- EXEEXT=".exe"
- ;;
- *)
- EXEEXT=""
- ;;
- esac
-
- echo "$ac_t""${EXEEXT}" 1>&6
-
-
-
- echo $ac_n "checking for tclsh""... $ac_c" 1>&6
-echo "configure:554: checking for tclsh" >&5
-
- if eval "test \"`echo '$''{'ac_cv_path_tclsh'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
-
- search_path=`echo ${exec_prefix}/bin:${prefix}/bin:${TCL_BIN_DIR}:${TCL_BIN_DIR}/../bin:${PATH} | sed -e 's/:/ /g'`
- for dir in $search_path ; do
- for j in `ls -r $dir/tclsh[8-9]*${EXEEXT} 2> /dev/null` \
- `ls -r $dir/tclsh*${EXEEXT} 2> /dev/null` ; do
- if test x"$ac_cv_path_tclsh" = x ; then
- if test -f "$j" ; then
- ac_cv_path_tclsh=$j
- break
- fi
- fi
- done
- done
-
-fi
-
-
- if test -f "$ac_cv_path_tclsh" ; then
- TCLSH_PROG=$ac_cv_path_tclsh
- echo "$ac_t""$TCLSH_PROG" 1>&6
- else
- { echo "configure: error: No tclsh found in PATH: $search_path" 1>&2; exit 1; }
- fi
-
-
-
-# ### ######### ###########################
-
-PACKAGE=`$TCLSH_PROG ${srcdir}/sak.tcl name`
-MAJOR_VERSION=`$TCLSH_PROG ${srcdir}/sak.tcl major`
-MINOR_VERSION=`$TCLSH_PROG ${srcdir}/sak.tcl minor`
-PATCHLEVEL=""
-
-VERSION=${MAJOR_VERSION}.${MINOR_VERSION}${PATCHLEVEL}
-NODOT_VERSION=${MAJOR_VERSION}${MINOR_VERSION}
-
-
-
-
-# ### ######### ###########################
-
-trap '' 1 2 15
-cat > confcache <<\EOF
-# This file is a shell script that caches the results of configure
-# tests run on this system so they can be shared between configure
-# scripts and configure runs. It is not useful on other systems.
-# If it contains results you don't want to keep, you may remove or edit it.
-#
-# By default, configure uses ./config.cache as the cache file,
-# creating it if it does not exist already. You can give configure
-# the --cache-file=FILE option to use a different cache file; that is
-# what configure does when it calls configure scripts in
-# subdirectories, so they share the cache.
-# Giving --cache-file=/dev/null disables caching, for debugging configure.
-# config.status only pays attention to the cache file if you give it the
-# --recheck option to rerun configure.
-#
-EOF
-# The following way of writing the cache mishandles newlines in values,
-# but we know of no workaround that is simple, portable, and efficient.
-# So, don't put newlines in cache variables' values.
-# Ultrix sh set writes to stderr and can't be redirected directly,
-# and sets the high bit in the cache file unless we assign to the vars.
-(set) 2>&1 |
- case `(ac_space=' '; set | grep ac_space) 2>&1` in
- *ac_space=\ *)
- # `set' does not quote correctly, so add quotes (double-quote substitution
- # turns \\\\ into \\, and sed turns \\ into \).
- sed -n \
- -e "s/'/'\\\\''/g" \
- -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
- ;;
- *)
- # `set' quotes correctly as required by POSIX, so do not add quotes.
- sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
- ;;
- esac >> confcache
-if cmp -s $cache_file confcache; then
- :
-else
- if test -w $cache_file; then
- echo "updating cache $cache_file"
- cat confcache > $cache_file
- else
- echo "not updating unwritable cache $cache_file"
- fi
-fi
-rm -f confcache
-
-trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
-
-test "x$prefix" = xNONE && prefix=$ac_default_prefix
-# Let make expand exec_prefix.
-test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-
-# Any assignment to VPATH causes Sun make to only execute
-# the first set of double-colon rules, so remove it if not needed.
-# If there is a colon in the path, we need to keep it.
-if test "x$srcdir" = x.; then
- ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
-fi
-
-trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
-
-# Transform confdefs.h into DEFS.
-# Protect against shell expansion while executing Makefile rules.
-# Protect against Makefile macro expansion.
-cat > conftest.defs <<\EOF
-s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
-s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g
-s%\[%\\&%g
-s%\]%\\&%g
-s%\$%$$%g
-EOF
-DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
-rm -f conftest.defs
-
-
-# Without the "./", some shells look in PATH for config.status.
-: ${CONFIG_STATUS=./config.status}
-
-echo creating $CONFIG_STATUS
-rm -f $CONFIG_STATUS
-cat > $CONFIG_STATUS </dev/null | sed 1q`:
-#
-# $0 $ac_configure_args
-#
-# Compiler output produced by configure, useful for debugging
-# configure, is in ./config.log if it exists.
-
-ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
-for ac_option
-do
- case "\$ac_option" in
- -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
- echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
- exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
- -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
- echo "$CONFIG_STATUS generated by autoconf version 2.13"
- exit 0 ;;
- -help | --help | --hel | --he | --h)
- echo "\$ac_cs_usage"; exit 0 ;;
- *) echo "\$ac_cs_usage"; exit 1 ;;
- esac
-done
-
-ac_given_srcdir=$srcdir
-
-trap 'rm -fr `echo "Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
-EOF
-cat >> $CONFIG_STATUS < conftest.subs <<\\CEOF
-$ac_vpsub
-$extrasub
-s%@SHELL@%$SHELL%g
-s%@CFLAGS@%$CFLAGS%g
-s%@CPPFLAGS@%$CPPFLAGS%g
-s%@CXXFLAGS@%$CXXFLAGS%g
-s%@FFLAGS@%$FFLAGS%g
-s%@DEFS@%$DEFS%g
-s%@LDFLAGS@%$LDFLAGS%g
-s%@LIBS@%$LIBS%g
-s%@exec_prefix@%$exec_prefix%g
-s%@prefix@%$prefix%g
-s%@program_transform_name@%$program_transform_name%g
-s%@bindir@%$bindir%g
-s%@sbindir@%$sbindir%g
-s%@libexecdir@%$libexecdir%g
-s%@datadir@%$datadir%g
-s%@sysconfdir@%$sysconfdir%g
-s%@sharedstatedir@%$sharedstatedir%g
-s%@localstatedir@%$localstatedir%g
-s%@libdir@%$libdir%g
-s%@includedir@%$includedir%g
-s%@oldincludedir@%$oldincludedir%g
-s%@infodir@%$infodir%g
-s%@mandir@%$mandir%g
-s%@CYGPATH@%$CYGPATH%g
-s%@EXEEXT@%$EXEEXT%g
-s%@TCLSH_PROG@%$TCLSH_PROG%g
-s%@PACKAGE@%$PACKAGE%g
-s%@VERSION@%$VERSION%g
-
-CEOF
-EOF
-
-cat >> $CONFIG_STATUS <<\EOF
-
-# Split the substitutions into bite-sized pieces for seds with
-# small command number limits, like on Digital OSF/1 and HP-UX.
-ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
-ac_file=1 # Number of current file.
-ac_beg=1 # First line for current file.
-ac_end=$ac_max_sed_cmds # Line after last line for current file.
-ac_more_lines=:
-ac_sed_cmds=""
-while $ac_more_lines; do
- if test $ac_beg -gt 1; then
- sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
- else
- sed "${ac_end}q" conftest.subs > conftest.s$ac_file
- fi
- if test ! -s conftest.s$ac_file; then
- ac_more_lines=false
- rm -f conftest.s$ac_file
- else
- if test -z "$ac_sed_cmds"; then
- ac_sed_cmds="sed -f conftest.s$ac_file"
- else
- ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
- fi
- ac_file=`expr $ac_file + 1`
- ac_beg=$ac_end
- ac_end=`expr $ac_end + $ac_max_sed_cmds`
- fi
-done
-if test -z "$ac_sed_cmds"; then
- ac_sed_cmds=cat
-fi
-EOF
-
-cat >> $CONFIG_STATUS <> $CONFIG_STATUS <<\EOF
-for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
- # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
- case "$ac_file" in
- *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
- ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- *) ac_file_in="${ac_file}.in" ;;
- esac
-
- # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
-
- # Remove last slash and all that follows it. Not all systems have dirname.
- ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
- if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
- # The file is in a subdirectory.
- test ! -d "$ac_dir" && mkdir "$ac_dir"
- ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
- # A "../" for each directory in $ac_dir_suffix.
- ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
- else
- ac_dir_suffix= ac_dots=
- fi
-
- case "$ac_given_srcdir" in
- .) srcdir=.
- if test -z "$ac_dots"; then top_srcdir=.
- else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
- /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
- *) # Relative path.
- srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
- top_srcdir="$ac_dots$ac_given_srcdir" ;;
- esac
-
-
- echo creating "$ac_file"
- rm -f "$ac_file"
- configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
- case "$ac_file" in
- *Makefile*) ac_comsub="1i\\
-# $configure_input" ;;
- *) ac_comsub= ;;
- esac
-
- ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
- sed -e "$ac_comsub
-s%@configure_input@%$configure_input%g
-s%@srcdir@%$srcdir%g
-s%@top_srcdir@%$top_srcdir%g
-" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
-fi; done
-rm -f conftest.s*
-
-EOF
-cat >> $CONFIG_STATUS <> $CONFIG_STATUS <<\EOF
-
-exit 0
-EOF
-chmod +x $CONFIG_STATUS
-rm -fr confdefs* $ac_clean_files
-test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
-
DELETED configure.in
Index: configure.in
==================================================================
--- configure.in
+++ /dev/null
@@ -1,31 +0,0 @@
-AC_INIT(ChangeLog)
-
-case "`uname -s`" in
- *win32* | *WIN32* | *CYGWIN_NT* | *CYGWIN_98* | *CYGWIN_95*)
- CYGPATH="cygpath -w"
- ;;
- *)
- CYGPATH=echo
- ;;
-esac
-AC_SUBST(CYGPATH)
-
-SC_SIMPLE_EXEEXT
-SC_PROG_TCLSH
-
-# ### ######### ###########################
-
-PACKAGE=`$TCLSH_PROG ${srcdir}/sak.tcl name`
-MAJOR_VERSION=`$TCLSH_PROG ${srcdir}/sak.tcl major`
-MINOR_VERSION=`$TCLSH_PROG ${srcdir}/sak.tcl minor`
-PATCHLEVEL=""
-
-VERSION=${MAJOR_VERSION}.${MINOR_VERSION}${PATCHLEVEL}
-NODOT_VERSION=${MAJOR_VERSION}${MINOR_VERSION}
-
-AC_SUBST(PACKAGE)
-AC_SUBST(VERSION)
-
-# ### ######### ###########################
-
-AC_OUTPUT([Makefile])
DELETED devdoc/cvs.branches.fig
Index: devdoc/cvs.branches.fig
==================================================================
--- devdoc/cvs.branches.fig
+++ /dev/null
@@ -1,32 +0,0 @@
-#FIG 3.2
-Landscape
-Center
-Inches
-Letter
-100.00
-Single
--2
-1200 2
-6 3000 2025 5400 2400
-4 0 12 50 0 0 14 0.0000 4 150 2385 3000 2175 Point releases are branched\001
-4 0 12 50 0 0 14 0.0000 4 150 1530 3000 2370 from RELEASES\001
--6
-6 2400 750 5700 1200
-4 0 1 50 0 0 14 0.0000 4 195 3225 2400 900 Developer performs internal releases,\001
-4 0 1 50 0 0 14 0.0000 4 195 3285 2400 1095 merging from HEAD into RELEASES\001
--6
-2 1 0 4 0 7 50 0 -1 0.000 0 0 7 1 0 2
- 2 1 4.00 240.00 480.00
- 300 600 5700 600
-2 1 0 2 1 7 50 0 -1 0.000 0 0 -1 1 0 2
- 2 1 2.00 120.00 240.00
- 2100 600 2400 1800
-2 1 0 5 12 7 50 0 -1 0.000 0 0 -1 1 0 3
- 2 1 5.00 300.00 600.00
- 2700 1800 3000 3000 5700 3000
-2 1 0 4 17 7 50 0 -1 0.000 0 0 7 1 0 3
- 2 1 4.00 240.00 480.00
- 1200 600 1500 1800 5700 1800
-4 0 0 50 0 0 14 0.0000 4 195 2835 3150 1575 Staging for release : RELEASES\001
-4 0 0 50 0 0 14 0.0000 4 195 1905 3900 300 Development : HEAD\001
-4 0 0 50 0 0 14 0.0000 4 150 930 4800 2700 Tcllib 1.2.0\001
DELETED devdoc/devguide.html
Index: devdoc/devguide.html
==================================================================
--- devdoc/devguide.html
+++ /dev/null
@@ -1,50 +0,0 @@
-
-
-
Guide for Tcllib developers.
-
-
-
-
CVS Repository
-
-
-
-
-
-
-The CVS repository for Tcllib contains two main branches, the HEAD for
-development, and RELEASES as the staging area for official
-releases. At RELEASES the minor branches containing the various
-official releases are anchored at.
-
-
-
All the branches are of interest to the developers for
- Tcllib. Ongoing development happens in HEAD, which can be
- unstable or may not work at all. Whenever a developer considers
- a piece of code, or module, he is responsible for as
- sufficiently stable she has to perform an internal release which
- merges this part from HEAD into RELEASES. Tools to help with
- this will be provided.
-
-
-
The branches for the official releases of tcllib are of interest to
- a developer because it is expected that fixes for important bugs
- not only go into the HEAD branch but also into the release
- branches for the release they were found in and all releases
- following that one. This is to allow the release manager to
- create patch releases of existing releases distribung important
- bugfixes as well.
-
-
-
Version numbers for modules are handled as described below. This
- way of handling them was chosen so that the modules in the
- development branch always uses version numbers different from
- the version numbers in the official releases made so far.
-
-
-
Whenever an internal release of a module FOO is done, the
- developer performing this internal release has to increment
- the version number of the module after the release was
- executed.
-
DELETED devdoc/dirlayout_install.txt
Index: devdoc/dirlayout_install.txt
==================================================================
--- devdoc/dirlayout_install.txt
+++ /dev/null
@@ -1,85 +0,0 @@
-Tcllib installation directory layout
-====================================
-
-This document describes the possible layouts for an installed tcllib,
-discusses their pro and contra and makes a choice for Tcllib 1.4. A
-roadmap of changes in the future is made available as appendix.
-
-[L1/D] Deep layout
-------------------
-
- This is the layout of Tcllib 1.3 (and versions before that).
-
- A single directory tcllib is created, and all
- subdirectories of the 'modules' subdirectory in the
- distribution is copied into it. This is restricted at large to
- *.tcl files, with exception made for some modules with special
- needs.
-
- Pro:
- Contra:
- Makes the handling of the various package indices,
- well, not difficult, but uncomfortable.
-
-
-[L2/Fa] Flat layout 1
----------------------
-
- A directory is created for each module of tcllib.
-
- Pro:
- Handling of package indices is easier than for L1/D, a
- toplevel index file with all its problems is not
- required anymore.
-
- Contra:
- Directories should be versioned to avoid conflicts
- between multiple releases. modules have no
- version. This can be faked for mdules containing one
- package, but not for the modules with more.
-
-
-[L2/Fb] Flat layout 2
----------------------
-
- A directory is created for each package in tcllib.
-
- Pro
- Handling of package indices is easy, one per package.
-
- Contra:
- Modules containing more than one package are difficult
- to handle. The system has to split them into the
- individual packages. This rendered very difficult
- because of shared package index files.
-
- This can be solved by moving tcllib (back) towards of
- one package per module. When that goal is reached
- L2/Fa and L2/Fb become the same, and the contra for
- L2/Fa vanishes too as an exact version number can be
- associated with each directory.
-
-Chosen layout for Tcllib 1.4
-----------------------------
-
- L1/D
-
- Despite the problems with package indices the contras against
- the flat structures are too strong at this point in
- time. Automatic solutions are not really possible, or require
- a very high effort.
-
-Roadmap
--------
- Change the module directories of tcllib to contain exactly one
- package per directory, with appropriate index (and meta data).
-
- This not only makes sense for easier handling of installation
- and package indices, but also in the geater context of
- wrapping code for deployment.
-
-
------------------------------------
-This document is in the public domain.
-
- Andreas Kupries
DELETED devdoc/indexing.txt
Index: devdoc/indexing.txt
==================================================================
--- devdoc/indexing.txt
+++ /dev/null
@@ -1,418 +0,0 @@
-Tcllib package indexing
-=======================
-
-This document describes the possibilities for using one or more
-pkgIndex.tcl files in an installation of tcllib to provide the
-information about all of its packages to a tcl interpreter, discusses
-their pro and contra and makes a choice for Tcllib 1.4. A roadmap of
-changes in the future is made available as appendix.
-
-Background under which to see the solutions:
-
- There are three level of groupings:
-
- - The tcllib project itself
- - Modules in the project (== subdirectory of 'modules')
- - Packages in a module.
-
- Each module currently contains one package index file.
-
- Some modules contain more than one package. They share the index.
-
- Most packages require specific versions of the Tcl
- interpreter. They perform the checks in their package index
- file and do not register if the pre-requisites are not
- fulfilled.
-
- Other checks are possible, but currently not in use.
-
-Note I:
- Whether a solutions is actually applicable depends on external
- factors, like the chosen directory layout of an installed
- tcllib.
-
-Note II:
- All solutions currently depend on the specific implementation
- of [tclPkgUnknown] coming with the basic core, simply by the
- fact that the files looked at are called 'pkgIndex.tcl'. This
- is therefore no contra argument against any specific solution,
- but against all. We ignore this as currently there is no
- better replacement in existence.
-
-Note III:
- We have to support Tcl before 8.3. as some packages in tcllib
- allow this.
-
-
-[i1/ng] No global package index
--------------------------------
-
- In this solution the module package indices are the only index
- files present in an installation.
-
- This solution is applicable if and only if one of the flat
- directory layouts (L2/Fa or L2/Fb) has been chosen.
-
- Pro:
- Simple. No need for complex management.
-
-
-[i2/ad] Global package index, auto_path extension, direct
----------------------------------------------------------
-
- A single global package index is present in the toplevel
- directory of the installation.
-
- This solution is applicable if and only if the deep directory
- layout (L2/D) has been chosen.
-
- The package index contains a series of statements extending
- the auto_path variable with all module directories. The list
- of names of the module directories is hardcoded. In other
- words, it is _not_ determined via [glob].
-
- Example:
- lappend auto_path [file join $dir md4]
- lappend auto_path [file join $dir md5]
- lappend auto_path [file join $dir sha1]
- ...
-
-
- Pro:
- [[0]] Compared to [i3/ag] this should be bit faster
- as glob'ing the directory tree of tcllib is
- avoided. This performance-boost is not a big
- pro according to the opinions below.
-
- [[1]] Relies on the module package index files for
- the actual registration of packages, thus
- automatically inherits the correct contraints
- on the registration of packages. No additional
- complexities.
-
- [[2]] Easier to generate than [i6/dr].
-
- Contra:
- [[3]] Hard coding the directory names implies that
- adding modules to the installed tcllib is not
- as easy as just creating a new directory for
- the module/package. The global index has to be
- updated too.
-
- Contra-Contra:
- <>
-
- <>
-
- [[4]] Extending the 'auto_path' list causes the
- package management of the tcl core to re-read
- the list and glob through all of them for new
- package indices. This has a high cost in terms
- of filesystem access, i.e. is an issue of
- performance.
-
- Contra-Contra:
- <>
-
- <>
-
-
- [[5]] This enables auto-loading in each module
- (according to any tclIndex file installed).
- This should not be done by the package
- indexer, but by the package itself. See
- control for an example.
-
- [[10]] Will not work with Tcl releases prior to
- 8.3.1. Only then was [tclPkgUnknown]
- "enhanced" to deal with changing ::auto_path
- values. If tcllib 1.4 wishes to continue
- supporting pre-8.3.1 Tcl, then this option has
- to be supplemented with a fallback.
-
-
-[i3/ag] Global package index, auto_path extension, glob
--------------------------------------------------------
-
- This is like [i2/ad], except that the list of sub directories
- is not hardcoded into the index, but determined through glob.
-
- Example:
- foreach subdir [glob -nocomplain -type d $dir/*] {
- lappend auto_path $subdir
- }
-
- Pro:
- Anti-[[3]]
- [[1]]
-
- Contra:
- All the contras of [i2/ad] and Anti-[[0]].
-
-
-[i4/sd] Global package index, sourcing module indices, direct
--------------------------------------------------------------
-
- A single global package index is present in the toplevel
- directory of the installation.
-
- This solution is applicable if and only if the deep directory
- layout (L2/D) has been chosen.
-
- The package index contains a series of statements source'ing
- the package index files of the modules in tcllib. The list
- of names of the module directories is hardcoded. In other
- words, it is _not_ determined via [glob].
-
- Example:
- set main $dir
- set dir [file join $main md4] ; source [file join $dir pkgIndex.tcl]
- set dir [file join $main md5] ; source [file join $dir pkgIndex.tcl]
- set dir [file join $main sha1] ; source [file join $dir pkgIndex.tcl]
- ...
-
- Pro:
- [[0]], but compared to [i5/sg].
- [[1]]
- [[2]]
- [[6]] In contrast to [i2/ad] and [i3/ag] repeated
- glob'bing for package index files is
- avoided. This cuts down on costly FS accesses.
- I.e. another perf. boost.
-
- Contra:
- [[3]]
-
-[i5/sg] Global package index, sourcing module indices, glob
------------------------------------------------------------
-
- This is like [i4/sd], except that the list of package indices
- to source is not hardcoded into the index, but determined
- through glob.
-
- Example:
- foreach subdir [glob -nocomplain -type d $dir/*] {
- set dir $subdir
- source [file join $dir pkgIndex.tcl]
- }
-
- Pro:
- Anti-[[3]]
- [[1]]
- [[2]]
-
- Contra:
- All the contras of [i2/sd], and Anti-[[0]]
-
-
-[i6/dr] Global package index, direct registration
--------------------------------------------------
-
- A single global package index is present in the toplevel
- directory of the installation.
-
- This solution is applicable if and only if the deep directory
- layout (L2/D) has been chosen.
-
- The package index contains a series of statements which
- directly register all the tcllib packages.
-
- Example:
- if {[constraint]} {return}
- package ifneeded md4 [list source [file join $dir md4 md4.tcl]]
- package ifneeded md5 [list source [file join $dir md4 md4.tcl]]
- package ifneeded sha1 [list source [file join $dir md4 md4.tcl]]
- ... more constraints ... package ifneeded
-
- Pro:
- [[7]] This is the fasted solution as the number of
- accesses to the filesystem is minimal.
-
- Contra:
- [[[3]]
- Anti-[[1]] Care has to be taken to ensure that
- the constraints the module indices
- place on the registration of packages
- are replicated in the global
- index. All other solutions simply used
- the module indices and thus got it
- right automatically. Now supporting
- code is required to detect such
- constraints and then to properly
- recreate them globally.
-
- = High complexity for the maintainer.
-
-[i7/ad] Global package index, auto_path extension, direct
----------------------------------------------------------
-
- A single global package index is present in the toplevel
- directory of the installation.
-
- This solution is applicable if and only if the deep directory
- layout (L2/D) has been chosen.
-
- The package index contains a single statement extending the
- auto_path variable with the tcllib main directory. The
- standard package management will then find all module sub
- directories and the package indices in them.
-
- Example:
- lappend auto_path $dir
-
- Pro:
- [[1]]
- [[8]] This is the easiest solution by far in terms
- of code to write, and complexities to solve
- (none).
-
- [[9]] <>
-
- <>
-
- Contra: [[4]]
- [[10]]
-
-
-[i8/pm] Global package index, pkg_mkIndex
------------------------------------------
-
-Just use [pkg_mkIndex modules */*.tcl] to generate the master index.
-
- Pro:
- Easy to do.
-
- Contra:
- Does not handle constraints in subordinate package
- indices, simply because they are actually ignored
- during processing.
-
- Adding code to handle constraints evolves this into
- [i6/dr].
-
- Note: The contra is hard enough IMHO to make this solution not
- applicable for 1.4, which does have constraints, and handling
- them wrong (not at all) is a bug.
-
-
-General discussion
-------------------
-
-Given that a deep directory layout was chosen [i1/ng] is not
-applicable and therefore dropped from the discussion.
-
-In the pro and contra arguments listed above three independent axes of
-reasoning emerged:
-
-a) Performance of the solution, with the number of accesses to
- filesystem the main factor determining it.
-
-b) Complexity/difficulty of the solution with regard to
- adding/updating packages.
-
-c) Complexity of generating the master index.
-
-Axis (b) has essentially been thrown out. Trying to modify the
-installation of tcllib itself is bad practice. Install new/updated
-packages separately. The version numbering takes care of the rest,
-i.e. usage of the new over the older version found in tcllib.
-
-With respect to axis (c), complexity of generation, [i7/ad] is the
-definite winner, with the other *d solutions close behind (all use
-fixed scripts, I7/ad wins on size). This is followed by the *g
-solutions as they require actual dynamic generation of code. And at
-the bottom of the ladder is [i6/dr] with its need for close inspection
-of the sub-ordinate indices to get everything right.
-
-Now axis (a), performance, [i6/dr] is most likely the winner as it
-causes only one index to be read and nothing else. This is followed by
-the all *d solutions, they read the subordinate indices, but do not
-need much globbing. The actual order in this group is difficult to
-determine. I guess that the auto_path extending methods are slower
-than the sourcing methods, and the adding of one directory faster than
-the adding of all, as the latter looks for much more subdirectories.
-The next group oare the *g solutions as they their own globbing too
-beyond that done by the package mgmt.
-
-Two final rankings
-
- (c), then (a) (a), then (c)
- ------------- -------------
- [i7/ad] [i6/dr]
- [i4/sd] [i4/sd]
- [i2/ad] [i7/ad]
- [i5/sg] [i2/ad]
- [i3/ag] [i5/sg]
- [i6/dr] [i3/ag]
- ------------- -------------
-
-[i4/sd] seems to be a good compromise solution between performance and
-complexity of generation, but [i7/ad] is not too bad either.
-
-[i4/sd] reminder:
- set main $dir
- set dir [file join $main md4] ; source [file join $dir pkgIndex.tcl]
- set dir [file join $main md5] ; source [file join $dir pkgIndex.tcl]
- set dir [file join $main sha1] ; source [file join $dir pkgIndex.tcl]
- ...
-
-[i7/ad] reminder:
- lappend auto_path $dir
-
-Other opinions:
-
- Don Porter prefers [i7/ad], and [i6/dr] as second choice. Also
- as [i7/ad] fallback for older Tcl before 8.3.1
-
- Joe English strictly opposes any solution modifying the
- auto_path, violoating his opinion that index scripts should
- have no side-effects beyond registering a package.
-
-
-Chosen solution for Tcllib 1.4
-------------------------------
-
-After comparing the code for the combination of [i7/ad] and [i6/dr] as
-submitted by Don Porter, and for [i4/sd] as submitted by myself
-(Andreas), and a small discussion on the Tcl'ers chat between Don and
-me we took [i4/sd] for the main body of the idnex, and the header of
-Don's code. Basically the chosen package index is a combination of
-[i7/id] and of [i4/sd] as fallback.
-
-This is still as easy to generate as [4/sd], the index is also only a
-bit more complex, and speed should be ok too.
-
-Don convinced me that while extending auto_path is definitely bad in
-the long-term it is still ok for the short-term and release 1.4.
-
-
-Roadmap
--------
-
-After Tcllib has been driven into the state of one package per module
-directory, and switched to a flat directory layout for its
-installation we switch to [i1/ng] for the indexing structure.
-
-
------------------------------------
-This document is in the public domain.
-
- Andreas Kupries
DELETED devdoc/installation.txt
Index: devdoc/installation.txt
==================================================================
--- devdoc/installation.txt
+++ /dev/null
@@ -1,85 +0,0 @@
-Tcllib installation directory layout
-====================================
-
-This document describes the possible layouts for an installed tcllib,
-discusses their pro and contra and makes a choice for Tcllib 1.4. A
-roadmap of changes in the future is made available as appendix.
-
-[L1/D] Deep layout
-------------------
-
- This is the layout of Tcllib 1.3 (and versions before that).
-
- A single directory tcllib is created, and all
- subdirectories of the 'modules' subdirectory in the
- distribution is copied into it. This is restricted at large to
- *.tcl files, with exception made for some modules with special
- needs.
-
- Pro:
- Contra:
- Makes the handling of the various package indices,
- well, not difficult, but uncomfortable.
-
-
-[L2/Fa] Flat layout 1
----------------------
-
- A directory is created for each module of tcllib.
-
- Pro:
- Handling of package indices is easier than for L1/D, a
- toplevel index file with all its problems is not
- required anymore.
-
- Contra:
- Directories should be versioned to avoid conflicts
- between multiple releases. modules have no
- version. This can be faked for mdules containing one
- package, but not for the modules with more.
-
-
-[L2/Fb] Flat layout 2
----------------------
-
- A directory is created for each package in tcllib.
-
- Pro
- Handling of package indices is easy, one per package.
-
- Contra:
- Modules containing more than one package are difficult
- to handle. The system has to split them into the
- individual packages. This rendered very difficult
- because of shared package index files.
-
- This can be solved by moving tcllib (back) towards of
- one package per module. When that goal is reached
- L2/Fa and L2/Fb become the same, and the contra for
- L2/Fa vanishes too as an exact version number can be
- associated with each directory.
-
-Chosen layout for Tcllib 1.4
-----------------------------
-
- L2/D
-
- Despite the problems with package indices the contras against
- the flat structures are too strong at this point in
- time. Automatic solutions are not really possible, or require
- a very high effort.
-
-Roadmap
--------
- Change the module directories of tcllib to contain exactly one
- package per directory, with appropriate index (and meta data).
-
- This not only makes sense for easier handling of installation
- and package indices, but also in the geater context of
- wrapping code for deployment.
-
-
------------------------------------
-This document is in the public domain.
-
- Andreas Kupries
DELETED devdoc/releaseguide.html
Index: devdoc/releaseguide.html
==================================================================
--- devdoc/releaseguide.html
+++ /dev/null
@@ -1,72 +0,0 @@
-
-
-
Guide to the creation of source releases for Tcllib
-
-
-
-
Recap
-
-
-
-
-
-The CVS repository for Tcllib contains two main branches,
- the HEAD for development, and RELEASES as the staging area for
- official releases.
-
-
-
Dependencies
-
-
-
Creation of a new official release
-
-
-
To create a new official release of Tcllib the release manager has
- to perform the steps described below:
-
-
-
-
-
Retrieve the sources at the current head
- from the CVS repository, using a command like
-
- CVSROOT=:pserver:anonymous@cvs.tcllib.sourceforge.net:/cvsroot/tcllib
- cvs -d${CVSROOT} co tcllib
-
- Vary this command according to taste as long as the overall
- meaning is not changed. Compression options and the like.
-
-
Tag these sources with a new branch tag for the new release of
- tcllib, like
-
- cvs -d${CVSROOT} rtag tcllib
-
-
-
Commit the changes, then update the working directory.
-
-
Use a tclsh to run the sak tool with the argument gendist, like
-
- tclsh /path/to/tcllib/sak.tcl gendist
-
-
-
This results in the creation of a tcllib-VERSION directory
-in the current working directory, and of two archives, .zip,
-and .tar.gz. A starkit will be created if sdx is present
-in the PATH. If additionally a file named tclkit is present in
-the current working directory a starpack will be created too, using
-this tclkit as the runtime.
-
-
-
Now follow the instructions in the Sourceforge site documentation
- for uploading the archives generated by the last
- step to
- ftp://upload.sourceforge.net/incoming, and
- follow the procedures for creating packages and
- releases at Sourceforge.
-
-
-
At last notify the relevant persons in other communities like
-Debian (See list of contacts) about the new release.
-
DELETED examples/README
Index: examples/README
==================================================================
--- examples/README
+++ /dev/null
@@ -1,2 +0,0 @@
-This directory contains example applications using the facilities of
-tcllib.
DELETED examples/csv/Bench.csv
Index: examples/csv/Bench.csv
==================================================================
--- examples/csv/Bench.csv
+++ /dev/null
@@ -1,254 +0,0 @@
-000,VERSIONS:,1:8.4a3,1:8.3.3,1:8.2.3,1:8.1.1,1:8.0.5,1:7.6p2,1:7.5p1
-001,CATCH return ok,11,6,7,4,5,28,17
-002,CATCH return error,70,64,275,54,204,146,33
-003,CATCH no catch used,10,6,7,13,4,24,9
-004,IF if true numeric,17,11,13,7,9,152,61
-005,IF elseif true numeric,20,15,16,20,11,299,292
-006,IF else true numeric,20,15,16,15,11,318,82
-007,IF if true num/num,17,12,281,22,9,329,174
-008,IF if false num/num,17,12,13,13,9,202,182
-009,IF if false al/num,27,20,20,29,17,467,121
-010,IF if true al/al,31,26,26,51,169,292,184
-011,IF if false al/al,31,25,25,51,60,217,243
-012,IF if true al,32,25,25,42,51,214,76
-013,IF elseif true al,47,39,338,89,156,358,154
-014,IF else true al,46,40,42,71,51,292,323
-015,SWITCH first true,63,42,103,58,73,391,241
-016,SWITCH second true,58,39,153,65,62,340,282
-017,SWITCH ninth true,67,44,238,73,112,391,284
-018,SWITCH default true,62,38,46,73,77,492,292
-019,DATA create in a list,4883,4083,15014,12925,7886,40180,29501
-020,DATA create in an array,5388,4916,19172,12827,16792,53723,40784
-021,DATA access in a list,4028,3546,15346,10386,7024,182889,175028
-022,DATA access in an array,3507,3223,14156,6966,7640,43232,39744
-023,EVAL cmd eval in list obj var,26,22,52,40,84,27,26
-024,EVAL cmd eval as list,24,21,49,88,144,22,52
-025,EVAL cmd eval as string,60,50,54,79,90,26,64
-026,EVAL cmd and mixed lists,3347,3546,32485,21937,13914,3017,2112
-027,EVAL list cmd and mixed lists,3403,3591,40366,19014,14703,2936,2259
-028,EVAL list cmd and pure lists,543,582,40115,21974,12611,2653,2245
-029,EXPR unbraced,153,167,502,23,331,313,365
-030,EXPR braced,29,25,29,53,92,505,386
-031,EXPR inline,31,30,40,68,59,321,177
-032,EXPR one operand,11,6,158,9,11,47,65
-033,EXPR ten operands,18,13,97,13,20,159,141
-034,EXPR fifty operands,48,43,45,71,85,708,430
-035,EXPR incr with incr,16,11,10,16,22,31,45
-036,EXPR incr with expr,11,7,9,11,13,73,74
-037,FCOPY std: 160010 bytes,10069,10242,46300,25104,26557
-038,FCOPY binary: 160010 bytes,9932,9892,41776,25211,
-039,FCOPY encoding: 160010 bytes,9818,9831,44598,25972,
-040,KLIST shuffle0 llength 1,144,127,554,271,367
-041,KLIST shuffle0 llength 10,457,413,1592,901,728
-042,KLIST shuffle0 llength 100,3986,3552,13565,8229,6484
-043,KLIST shuffle0 llength 1000,44083,41766,164223,92480,81157
-044,KLIST shuffle0 llength 10000,563245,533804,2073612,1214997,1161217
-045,KLIST shuffle1 llength 1,84,85,367,163,149
-046,KLIST shuffle1 llength 10,358,333,1371,718,634
-047,KLIST shuffle1 llength 100,6374,5238,12737,9243,8576
-048,KLIST shuffle1 llength 1000,1190696,1194146,1770024,1762135,1736049
-049,KLIST shuffle1a llength 1,110,100,94,172,150
-050,KLIST shuffle1a llength 10,474,368,404,768,910
-051,KLIST shuffle1a llength 100,4667,3625,3833,8986,9480
-052,KLIST shuffle1a llength 1000,47818,37340,39248,84798,95305
-053,KLIST shuffle1a llength 10000,474513,380522,408005,861405,1004602
-054,KLIST shuffle2 llength 1,104,99,108,196,229
-055,KLIST shuffle2 llength 10,440,375,481,938,1080
-056,KLIST shuffle2 llength 100,3762,3625,4250,8904,9803
-057,KLIST shuffle2 llength 1000,39573,37028,45651,95513,116933
-058,KLIST shuffle2 llength 10000,474558,433771,527055,1176566,1304458
-059,KLIST shuffle3 llength 1,104,98,102,217,170
-060,KLIST shuffle3 llength 10,380,335,376,786,832
-061,KLIST shuffle3 llength 100,3408,2883,3413,7161,7632
-062,KLIST shuffle3 llength 1000,38716,33237,37667,87353,82985
-063,KLIST shuffle3 llength 10000,945771,777699,844383,1789387,1732151
-064,KLIST shuffle4 llength 1,114,102,100,202,178
-065,KLIST shuffle4 llength 10,431,374,416,837,876
-066,KLIST shuffle4 llength 100,3871,3250,3758,8572,8278
-067,KLIST shuffle4 llength 1000,40201,32119,38186,82985,80450
-068,KLIST shuffle4 llength 10000,393369,330472,398724,874454,834612
-069,"STR/LIST length, obj shimmer",2390,2767,2333,905,28,2585,2638
-070,"LIST length, pure list",18,13,13,21,18,2023,1837
-071,STR length of a LIST,15,12,12,529,23,525,400
-072,"LIST exact search, first item",19,11,14,17,32,2303,1693
-073,"LIST exact search, middle item",69,25,27,46,38,1787,1944
-074,"LIST exact search, last item",132,48,50,90,111,2261,2009
-075,"LIST exact search, non-item",314,110,121,212,220,2099,2118
-076,"LIST sorted search, first item",23,12,12,16,29,1862,1610
-077,"LIST sorted search, middle item",24,26,26,42,40,1623,2252
-078,"LIST sorted search, last item",24,52,49,84,121,2145,1784
-079,"LIST sorted search, non-item",23,111,122,201,257,1999,2057
-080,"LIST exact search, untyped item",131,47,51,80,101,2166,2218
-081,"LIST exact search, typed item",128,48,49,77,111,2072,1872
-082,"LIST sorted search, typed item",19,46,50,93,104,1887,2221
-083,LIST sort,3299,3578,3293,6723,7021,10959,9644
-084,LIST typed sort,2739,2943,2660,4737,4651,28889,23969
-085,LIST remove first element,317,296,363,806,866,625,522
-086,LIST remove middle element,325,291,358,692,876,656,677
-087,LIST remove last element,318,293,360,689,879,754,675
-088,LIST replace first element,310,289,346,722,917,727,978
-089,LIST replace middle element,316,286,353,693,1045,1024,876
-090,LIST replace last element,316,283,346,963,832,1450,1243
-091,LIST replace first el with multiple,333,304,372,819,938,702,612
-092,LIST replace middle el with multiple,319,310,351,691,736,1088,1123
-093,LIST replace last el with multiple,319,282,347,813,740,1413,1313
-094,LIST replace range,294,282,343,744,866,1198,971
-095,LIST remove in mixed list,389,374,2195,833,999,829,617
-096,LIST replace in mixed list,377,352,2184,1054,925,756,592
-097,LIST index first element,18,10,13,16,25,451,375
-098,LIST index middle element,17,10,13,16,23,516,536
-099,LIST index last element,17,11,13,13,17,622,663
-100,LIST insert an item at start,291,298,366,775,805,729,563
-101,LIST insert an item at middle,269,266,370,684,667,978,630
-102,"LIST insert an item at ""end""",257,254,349,670,1013,1779,1200
-103,"LIST small, early range",23,19,16,42,35,500,383
-104,"LIST small, late range",23,18,16,28,38,618,685
-105,"LIST large, early range",37,29,24,54,108,511,697
-106,"LIST large, late range",40,30,21,81,131,567,551
-107,LIST append to list,409,401,396,917,1032,737,682
-108,LIST join list,1053,1072,1066,1818,1453,3672,3167
-109,"LOOP for, iterate list",6616,5198,5372,13766,9653,662376,583297
-110,"LOOP foreach, iterate list",1919,1845,1952,3750,3553,11561,12556
-111,LOOP for (to 1000),2566,2674,3065,4639,4867,66896,73851
-112,LOOP while (to 1000),2568,2942,3065,4551,4637,69891,80404
-113,"LOOP for, iterate string",6456,9440,9637,141594,14530,219770,199570
-114,"LOOP foreach, iterate string",2240,2249,3955,9099,8147,15468,13206
-115,MAP string 1 val,679,5931,6028,9096,(8.2+),(8.2+),(8.2+)
-116,MAP string 2 val,1562,6643,6877,12943,(8.2+),(8.2+),(8.2+)
-117,MAP string 3 val,1836,7673,7832,12825,(8.2+),(8.2+),(8.2+)
-118,MAP string 4 val,2510,8429,8622,17267,(8.2+),(8.2+),(8.2+)
-119,MAP string 1 val -nocase,3497,10259,10381,17685,(8.2+),(8.2+),(8.2+)
-120,MAP string 2 val -nocase,6218,14570,15024,27379,(8.2+),(8.2+),(8.2+)
-121,MAP string 3 val -nocase,8364,19344,18973,35569,(8.2+),(8.2+),(8.2+)
-122,MAP string 4 val -nocase,10135,21861,22132,39660,(8.2+),(8.2+),(8.2+)
-123,MAP regsub 1 val,3702,3954,4303,9663,1830,4430,3684
-124,MAP regsub 2 val,16066,16981,18176,41500,4184,9394,11576
-125,MAP regsub 3 val,21671,23258,24817,52315,6075,11441,12456
-126,MAP regsub 4 val,26657,29335,31350,67973,8659,15319,13884
-127,MAP regsub 1 val -nocase,3686,3913,4332,9463,2766,4729,4488
-128,MAP regsub 2 val -nocase,15821,17024,18134,40735,5881,9546,11911
-129,MAP regsub 3 val -nocase,20987,23228,24747,52639,8625,12501,14437
-130,MAP regsub 4 val -nocase,26227,29397,31314,66937,11664,14510,16818
-131,"MAP string, no match",926,7712,8028,14020,(8.2+),(8.2+),(8.2+)
-132,"MAP string -nocase, no match",6726,18725,18933,35683,(8.2+),(8.2+),(8.2+)
-133,"MAP regsub, no match",1149,2764,2830,6704,1843,3352,4823
-134,"MAP regsub -nocase, no match",1151,2785,2890,6609,3563,4499,5249
-135,MAP string short,37,41,39,116,(8.2+),(8.2+),(8.2+)
-136,MAP regsub short,164,180,193,308,154,244,432
-137,MTHD direct ns proc call,10,6,8,3,7
-138,MTHD imported ns proc call,11,6,7,5,7
-139,MTHD interp alias proc call,25,18,18,18,9
-140,MTHD indirect proc eval,36,29,61,56,72
-141,MTHD indirect proc eval #2,58,48,57,81,107
-142,MTHD array stored proc call,14,9,10,22,19
-143,MTHD switch method call,50,38,83,119,172
-144,MTHD ns lookup call,99,81,216,374,376
-145,MTHD inline call,5,3,3,2,2
-146,PROC explicit return,15,7,8,7,7,11,11
-147,PROC implicit return,11,6,7,4,11,16,15
-148,PROC explicit return (2),12,7,8,13,13,14,10
-149,PROC implicit return (2),10,6,7,10,18,21,24
-150,PROC explicit return (3),10,7,7,4,14,14,25
-151,PROC implicit return (3),10,6,7,3,12,10,18
-152,PROC heavily commented,10,5,6,12,5,629,753
-153,"PROC do-nothing, no args",8,5,28,38,4,5,2
-154,"PROC do-nothing, one arg",10,5,6,9,8,15,21
-155,PROC local links with global,1579,1569,1626,3586,4533,7955,11505
-156,PROC local links with upvar,1287,1166,1387,2806,2922,8371,10317
-157,PROC local links with variable,1195,1101,1334,2614,1050,9091,9212
-158,"READ 595K, gets",340064,299797,306109,819327,372526,978472,985676
-159,"READ 595K, read",77751,97698,97019,227338,2936958,3774669,3834017
-160,"READ 595K, read & size",77606,97909,97074,242255,124776,3696432,3704813
-161,"READ 3050b, gets",1869,1641,2052,4118,954,2074,2201
-162,"READ 3050b, read",522,494,494,789,748,503,415
-163,"READ 3050b, read & size",569,534,530,790,410,467,361
-164,"BREAD 595K, gets",350077,292326,304961,833500,365165,953379,979961
-165,"BREAD 595K, read",50105,50454,50018,228963,2952787,3640795,3741298
-166,"BREAD 595K, read & size",50303,50486,50140,246365,87019,3685978,3688120
-167,"BREAD 3050b, gets",2097,1777,1774,5220,1062,2208,2178
-168,"BREAD 3050b, read",340,347,334,1310,412,458,359
-169,"BREAD 3050b, read & size",396,389,369,1144,1230,390,495
-170,REGEXP literal regexp,39,37,38,42,31,26,26
-171,REGEXP var-based regexp,41,40,40,55,45,30,61
-172,REGEXP count all matches,137,139,530,1280,1332,2277,2776
-173,REGEXP extract all matches,169,177,616,1790,1129,3068,3620
-174,STARTUP time to launch tclsh,21138,20425,18293,85723,102877,70500,90323
-175,STR str [string compare],18,26,24,17,26,199,193
-176,STR str [string equal],18,25,23,68,38,160,198
-177,"STR str $a equal """"",17,26,24,81,52,670,410
-178,"STR str num == """"",19,14,24,36,52,338,419
-179,STR str $a eq $b,22,33,31,39,56,231,261
-180,STR str $a ne $b,23,31,30,85,47,226,265
-181,STR str $a eq $b (same obj),22,33,36,161,53,271,338
-182,STR str $a ne $b (same obj),21,33,30,28,57,203,235
-183,STR length (==4010),15,14,13,678,17,508,867
-184,STR index 0,26,19,19,487,30,522,614
-185,STR index 100,21,24,19,500,43,491,601
-186,STR index 500,21,18,19,483,42,489,493
-187,STR index2 0,21,19,19,494,27,485,583
-188,STR index2 100,20,19,19,470,26,557,459
-189,STR index2 500,21,19,19,484,40,764,468
-190,STR first (success),19,16,15,21,33,533,519
-191,STR first (failure),120,56,50,123,117,697,822
-192,STR first (total failure),109,42,28,54,57,545,631
-193,STR last (success),19,229,224,469,18,815,728
-194,STR last (failure),90,99,91,185,201,657,859
-195,STR last (total failure),82,90,83,135,151,584,1153
-196,"STR match, simple (success early)",17,14,13,25,33,503,489
-197,"STR match, simple (success late)",16,14,13,11,27,619,502
-198,"STR match, simple (failure)",17,15,13,26,36,421,680
-199,"STR match, simple (total failure)",16,18,13,17,30,456,378
-200,"STR match, complex (success early)",17,23,22,33,35,466,448
-201,"STR match, complex (success late)",145,1020,1040,2173,926,1529,1676
-202,"STR match, complex (failure)",122,1011,1010,1785,964,1357,1698
-203,"STR match, complex (total failure)",90,994,994,1844,1216,1725,1602
-204,"STR range, index 100..200 of 4010",26,21,21,716,25,589,609
-205,"STR replace, no replacement",79,270,264,570,166,1217,1315
-206,"STR replace, equal replacement",92,277,257,526,140,1560,1263
-207,"STR replace, longer replacement",95,270,265,551,103,1563,1309
-208,"STR repeat, abcdefghij * 10",19,22,22,21,199,997,963
-209,"STR repeat, abcdefghij * 100",39,72,74,120,1267,8488,9065
-210,"STR repeat, abcdefghij * 1000",245,565,557,798,12264,81587,86928
-211,"STR repeat, 4010 chars * 10",314,797,671,1971,1494,11891,7688
-212,"STR repeat, 4010 chars * 100",7347,18287,18194,47967,69328,105423,107290
-213,"STR reverse iter1, 100 chars",1285,1628,1425,4104,1871,8459,8704
-214,"STR reverse iter1, 100 uchars",1264,1768,1436,4448,1864,8250,9034
-215,"STR reverse iter2, 100 chars",808,1252,1168,3860,2099,8379,8292
-216,"STR reverse iter2, 100 uchars",807,1259,1096,4086,1602,9513,5431
-217,"STR reverse recur1, 100 chars",4092,4770,3998,8749,8470,20868,11271
-218,"STR reverse recur1, 100 uchars",4169,5467,4767,8794,9075,21634,13821
-219,"STR split, 4010 chars",2663,2138,8847,23626,18954,4372,3169
-220,"STR split, 12100 uchars",7207,6395,,,
-221,"STR split iter, 4010 chars",9349,9372,16664,39846,35962,52886,48521
-222,"STR split iter, 12100 uchars",28171,28299,,,
-223,STR append,100,82,71,108,164,1055,1145
-224,STR append (1KB + 1KB),65,55,49,96,79,236,290
-225,STR append (10KB + 1KB),186,193,196,474,75,215,213
-226,STR append (1MB + 2b * 1000),37786,70498,74635,178639,12391,82339,84345
-227,STR append (1MB + 1KB),29729,63374,61479,136891,68,215,335
-228,STR append (1MB + 1KB * 20),29635,64566,61865,127033,270,1551,1724
-229,STR append (1MB + 1KB * 1000),66605,94413,101998,177875,10955,78370,81930
-230,STR append (1MB + 1MB * 3),126103,153051,157370,282029,218,248,876
-231,STR append (1MB + 1MB * 5),157407,303871,315407,1051814,45,543,342
-232,STR append (1MB + (1b + 1K + 1b) * 100),33118,63834,69167,290360,2398,8930,9893
-233,STR info locals match,828,818,993,2025,1518,8071,9043
-234,TRACE no trace set,35,25,26,18,27,42,91
-235,TRACE read,35,26,26,16,59,128,113
-236,TRACE write,35,25,26,16,55,78,78
-237,TRACE unset,35,26,26,16,70,94,112
-238,TRACE all set (rwu),35,25,25,18,59,77,105
-239,UNSET var exists,14,8,9,8,16,27,37
-240,UNSET catch var exists,16,9,10,52,20,61,58
-241,UNSET catch var !exist,69,64,59,191,120,77,96
-242,UNSET info check var exists,19,14,13,69,27,80,78
-243,UNSET info check var !exist,16,11,11,6,17,73,64
-244,UNSET nocomplain var exists,14,9,10,35,20,52,56
-245,UNSET nocomplain var !exist,14,64,59,157,122,90,109
-246,VAR access locally set,14,8,10,18,20,106,67
-247,VAR access local proc arg,14,9,10,6,26,88,110
-248,VAR access global,34,25,26,101,61,82,121
-249,VAR access upvar,36,29,30,103,65,97,101
-250,VAR set scalar,10,6,7,4,11,35,74
-251,VAR set array element,18,12,14,9,33,59,35
-252,VAR 100 'set's in array,162,133,160,296,292,917,827
-253,VAR 'array set' of 100 elems,293,251,264,741,816,1063,993
DELETED examples/csv/Bench.html
Index: examples/csv/Bench.html
==================================================================
--- examples/csv/Bench.html
+++ /dev/null
@@ -1,258 +0,0 @@
-Core Benchmark Results
-
Core Benchmark Results
-
-
000
VERSIONS:
1:8.4a3
1:8.3.3
1:8.2.3
1:8.1.1
1:8.0.5
1:7.6p2
1:7.5p1
-
001
CATCH return ok
11
6
7
4
5
28
17
-
002
CATCH return error
70
64
275
54
204
146
33
-
003
CATCH no catch used
10
6
7
13
4
24
9
-
004
IF if true numeric
17
11
13
7
9
152
61
-
005
IF elseif true numeric
20
15
16
20
11
299
292
-
006
IF else true numeric
20
15
16
15
11
318
82
-
007
IF if true num/num
17
12
281
22
9
329
174
-
008
IF if false num/num
17
12
13
13
9
202
182
-
009
IF if false al/num
27
20
20
29
17
467
121
-
010
IF if true al/al
31
26
26
51
169
292
184
-
011
IF if false al/al
31
25
25
51
60
217
243
-
012
IF if true al
32
25
25
42
51
214
76
-
013
IF elseif true al
47
39
338
89
156
358
154
-
014
IF else true al
46
40
42
71
51
292
323
-
015
SWITCH first true
63
42
103
58
73
391
241
-
016
SWITCH second true
58
39
153
65
62
340
282
-
017
SWITCH ninth true
67
44
238
73
112
391
284
-
018
SWITCH default true
62
38
46
73
77
492
292
-
019
DATA create in a list
4883
4083
15014
12925
7886
40180
29501
-
020
DATA create in an array
5388
4916
19172
12827
16792
53723
40784
-
021
DATA access in a list
4028
3546
15346
10386
7024
182889
175028
-
022
DATA access in an array
3507
3223
14156
6966
7640
43232
39744
-
023
EVAL cmd eval in list obj var
26
22
52
40
84
27
26
-
024
EVAL cmd eval as list
24
21
49
88
144
22
52
-
025
EVAL cmd eval as string
60
50
54
79
90
26
64
-
026
EVAL cmd and mixed lists
3347
3546
32485
21937
13914
3017
2112
-
027
EVAL list cmd and mixed lists
3403
3591
40366
19014
14703
2936
2259
-
028
EVAL list cmd and pure lists
543
582
40115
21974
12611
2653
2245
-
029
EXPR unbraced
153
167
502
23
331
313
365
-
030
EXPR braced
29
25
29
53
92
505
386
-
031
EXPR inline
31
30
40
68
59
321
177
-
032
EXPR one operand
11
6
158
9
11
47
65
-
033
EXPR ten operands
18
13
97
13
20
159
141
-
034
EXPR fifty operands
48
43
45
71
85
708
430
-
035
EXPR incr with incr
16
11
10
16
22
31
45
-
036
EXPR incr with expr
11
7
9
11
13
73
74
-
037
FCOPY std: 160010 bytes
10069
10242
46300
25104
26557
-
038
FCOPY binary: 160010 bytes
9932
9892
41776
25211
-
039
FCOPY encoding: 160010 bytes
9818
9831
44598
25972
-
040
KLIST shuffle0 llength 1
144
127
554
271
367
-
041
KLIST shuffle0 llength 10
457
413
1592
901
728
-
042
KLIST shuffle0 llength 100
3986
3552
13565
8229
6484
-
043
KLIST shuffle0 llength 1000
44083
41766
164223
92480
81157
-
044
KLIST shuffle0 llength 10000
563245
533804
2073612
1214997
1161217
-
045
KLIST shuffle1 llength 1
84
85
367
163
149
-
046
KLIST shuffle1 llength 10
358
333
1371
718
634
-
047
KLIST shuffle1 llength 100
6374
5238
12737
9243
8576
-
048
KLIST shuffle1 llength 1000
1190696
1194146
1770024
1762135
1736049
-
049
KLIST shuffle1a llength 1
110
100
94
172
150
-
050
KLIST shuffle1a llength 10
474
368
404
768
910
-
051
KLIST shuffle1a llength 100
4667
3625
3833
8986
9480
-
052
KLIST shuffle1a llength 1000
47818
37340
39248
84798
95305
-
053
KLIST shuffle1a llength 10000
474513
380522
408005
861405
1004602
-
054
KLIST shuffle2 llength 1
104
99
108
196
229
-
055
KLIST shuffle2 llength 10
440
375
481
938
1080
-
056
KLIST shuffle2 llength 100
3762
3625
4250
8904
9803
-
057
KLIST shuffle2 llength 1000
39573
37028
45651
95513
116933
-
058
KLIST shuffle2 llength 10000
474558
433771
527055
1176566
1304458
-
059
KLIST shuffle3 llength 1
104
98
102
217
170
-
060
KLIST shuffle3 llength 10
380
335
376
786
832
-
061
KLIST shuffle3 llength 100
3408
2883
3413
7161
7632
-
062
KLIST shuffle3 llength 1000
38716
33237
37667
87353
82985
-
063
KLIST shuffle3 llength 10000
945771
777699
844383
1789387
1732151
-
064
KLIST shuffle4 llength 1
114
102
100
202
178
-
065
KLIST shuffle4 llength 10
431
374
416
837
876
-
066
KLIST shuffle4 llength 100
3871
3250
3758
8572
8278
-
067
KLIST shuffle4 llength 1000
40201
32119
38186
82985
80450
-
068
KLIST shuffle4 llength 10000
393369
330472
398724
874454
834612
-
069
STR/LIST length, obj shimmer
2390
2767
2333
905
28
2585
2638
-
070
LIST length, pure list
18
13
13
21
18
2023
1837
-
071
STR length of a LIST
15
12
12
529
23
525
400
-
072
LIST exact search, first item
19
11
14
17
32
2303
1693
-
073
LIST exact search, middle item
69
25
27
46
38
1787
1944
-
074
LIST exact search, last item
132
48
50
90
111
2261
2009
-
075
LIST exact search, non-item
314
110
121
212
220
2099
2118
-
076
LIST sorted search, first item
23
12
12
16
29
1862
1610
-
077
LIST sorted search, middle item
24
26
26
42
40
1623
2252
-
078
LIST sorted search, last item
24
52
49
84
121
2145
1784
-
079
LIST sorted search, non-item
23
111
122
201
257
1999
2057
-
080
LIST exact search, untyped item
131
47
51
80
101
2166
2218
-
081
LIST exact search, typed item
128
48
49
77
111
2072
1872
-
082
LIST sorted search, typed item
19
46
50
93
104
1887
2221
-
083
LIST sort
3299
3578
3293
6723
7021
10959
9644
-
084
LIST typed sort
2739
2943
2660
4737
4651
28889
23969
-
085
LIST remove first element
317
296
363
806
866
625
522
-
086
LIST remove middle element
325
291
358
692
876
656
677
-
087
LIST remove last element
318
293
360
689
879
754
675
-
088
LIST replace first element
310
289
346
722
917
727
978
-
089
LIST replace middle element
316
286
353
693
1045
1024
876
-
090
LIST replace last element
316
283
346
963
832
1450
1243
-
091
LIST replace first el with multiple
333
304
372
819
938
702
612
-
092
LIST replace middle el with multiple
319
310
351
691
736
1088
1123
-
093
LIST replace last el with multiple
319
282
347
813
740
1413
1313
-
094
LIST replace range
294
282
343
744
866
1198
971
-
095
LIST remove in mixed list
389
374
2195
833
999
829
617
-
096
LIST replace in mixed list
377
352
2184
1054
925
756
592
-
097
LIST index first element
18
10
13
16
25
451
375
-
098
LIST index middle element
17
10
13
16
23
516
536
-
099
LIST index last element
17
11
13
13
17
622
663
-
100
LIST insert an item at start
291
298
366
775
805
729
563
-
101
LIST insert an item at middle
269
266
370
684
667
978
630
-
102
LIST insert an item at "end"
257
254
349
670
1013
1779
1200
-
103
LIST small, early range
23
19
16
42
35
500
383
-
104
LIST small, late range
23
18
16
28
38
618
685
-
105
LIST large, early range
37
29
24
54
108
511
697
-
106
LIST large, late range
40
30
21
81
131
567
551
-
107
LIST append to list
409
401
396
917
1032
737
682
-
108
LIST join list
1053
1072
1066
1818
1453
3672
3167
-
109
LOOP for, iterate list
6616
5198
5372
13766
9653
662376
583297
-
110
LOOP foreach, iterate list
1919
1845
1952
3750
3553
11561
12556
-
111
LOOP for (to 1000)
2566
2674
3065
4639
4867
66896
73851
-
112
LOOP while (to 1000)
2568
2942
3065
4551
4637
69891
80404
-
113
LOOP for, iterate string
6456
9440
9637
141594
14530
219770
199570
-
114
LOOP foreach, iterate string
2240
2249
3955
9099
8147
15468
13206
-
115
MAP string 1 val
679
5931
6028
9096
(8.2+)
(8.2+)
(8.2+)
-
116
MAP string 2 val
1562
6643
6877
12943
(8.2+)
(8.2+)
(8.2+)
-
117
MAP string 3 val
1836
7673
7832
12825
(8.2+)
(8.2+)
(8.2+)
-
118
MAP string 4 val
2510
8429
8622
17267
(8.2+)
(8.2+)
(8.2+)
-
119
MAP string 1 val -nocase
3497
10259
10381
17685
(8.2+)
(8.2+)
(8.2+)
-
120
MAP string 2 val -nocase
6218
14570
15024
27379
(8.2+)
(8.2+)
(8.2+)
-
121
MAP string 3 val -nocase
8364
19344
18973
35569
(8.2+)
(8.2+)
(8.2+)
-
122
MAP string 4 val -nocase
10135
21861
22132
39660
(8.2+)
(8.2+)
(8.2+)
-
123
MAP regsub 1 val
3702
3954
4303
9663
1830
4430
3684
-
124
MAP regsub 2 val
16066
16981
18176
41500
4184
9394
11576
-
125
MAP regsub 3 val
21671
23258
24817
52315
6075
11441
12456
-
126
MAP regsub 4 val
26657
29335
31350
67973
8659
15319
13884
-
127
MAP regsub 1 val -nocase
3686
3913
4332
9463
2766
4729
4488
-
128
MAP regsub 2 val -nocase
15821
17024
18134
40735
5881
9546
11911
-
129
MAP regsub 3 val -nocase
20987
23228
24747
52639
8625
12501
14437
-
130
MAP regsub 4 val -nocase
26227
29397
31314
66937
11664
14510
16818
-
131
MAP string, no match
926
7712
8028
14020
(8.2+)
(8.2+)
(8.2+)
-
132
MAP string -nocase, no match
6726
18725
18933
35683
(8.2+)
(8.2+)
(8.2+)
-
133
MAP regsub, no match
1149
2764
2830
6704
1843
3352
4823
-
134
MAP regsub -nocase, no match
1151
2785
2890
6609
3563
4499
5249
-
135
MAP string short
37
41
39
116
(8.2+)
(8.2+)
(8.2+)
-
136
MAP regsub short
164
180
193
308
154
244
432
-
137
MTHD direct ns proc call
10
6
8
3
7
-
138
MTHD imported ns proc call
11
6
7
5
7
-
139
MTHD interp alias proc call
25
18
18
18
9
-
140
MTHD indirect proc eval
36
29
61
56
72
-
141
MTHD indirect proc eval #2
58
48
57
81
107
-
142
MTHD array stored proc call
14
9
10
22
19
-
143
MTHD switch method call
50
38
83
119
172
-
144
MTHD ns lookup call
99
81
216
374
376
-
145
MTHD inline call
5
3
3
2
2
-
146
PROC explicit return
15
7
8
7
7
11
11
-
147
PROC implicit return
11
6
7
4
11
16
15
-
148
PROC explicit return (2)
12
7
8
13
13
14
10
-
149
PROC implicit return (2)
10
6
7
10
18
21
24
-
150
PROC explicit return (3)
10
7
7
4
14
14
25
-
151
PROC implicit return (3)
10
6
7
3
12
10
18
-
152
PROC heavily commented
10
5
6
12
5
629
753
-
153
PROC do-nothing, no args
8
5
28
38
4
5
2
-
154
PROC do-nothing, one arg
10
5
6
9
8
15
21
-
155
PROC local links with global
1579
1569
1626
3586
4533
7955
11505
-
156
PROC local links with upvar
1287
1166
1387
2806
2922
8371
10317
-
157
PROC local links with variable
1195
1101
1334
2614
1050
9091
9212
-
158
READ 595K, gets
340064
299797
306109
819327
372526
978472
985676
-
159
READ 595K, read
77751
97698
97019
227338
2936958
3774669
3834017
-
160
READ 595K, read & size
77606
97909
97074
242255
124776
3696432
3704813
-
161
READ 3050b, gets
1869
1641
2052
4118
954
2074
2201
-
162
READ 3050b, read
522
494
494
789
748
503
415
-
163
READ 3050b, read & size
569
534
530
790
410
467
361
-
164
BREAD 595K, gets
350077
292326
304961
833500
365165
953379
979961
-
165
BREAD 595K, read
50105
50454
50018
228963
2952787
3640795
3741298
-
166
BREAD 595K, read & size
50303
50486
50140
246365
87019
3685978
3688120
-
167
BREAD 3050b, gets
2097
1777
1774
5220
1062
2208
2178
-
168
BREAD 3050b, read
340
347
334
1310
412
458
359
-
169
BREAD 3050b, read & size
396
389
369
1144
1230
390
495
-
170
REGEXP literal regexp
39
37
38
42
31
26
26
-
171
REGEXP var-based regexp
41
40
40
55
45
30
61
-
172
REGEXP count all matches
137
139
530
1280
1332
2277
2776
-
173
REGEXP extract all matches
169
177
616
1790
1129
3068
3620
-
174
STARTUP time to launch tclsh
21138
20425
18293
85723
102877
70500
90323
-
175
STR str [string compare]
18
26
24
17
26
199
193
-
176
STR str [string equal]
18
25
23
68
38
160
198
-
177
STR str $a equal ""
17
26
24
81
52
670
410
-
178
STR str num == ""
19
14
24
36
52
338
419
-
179
STR str $a eq $b
22
33
31
39
56
231
261
-
180
STR str $a ne $b
23
31
30
85
47
226
265
-
181
STR str $a eq $b (same obj)
22
33
36
161
53
271
338
-
182
STR str $a ne $b (same obj)
21
33
30
28
57
203
235
-
183
STR length (==4010)
15
14
13
678
17
508
867
-
184
STR index 0
26
19
19
487
30
522
614
-
185
STR index 100
21
24
19
500
43
491
601
-
186
STR index 500
21
18
19
483
42
489
493
-
187
STR index2 0
21
19
19
494
27
485
583
-
188
STR index2 100
20
19
19
470
26
557
459
-
189
STR index2 500
21
19
19
484
40
764
468
-
190
STR first (success)
19
16
15
21
33
533
519
-
191
STR first (failure)
120
56
50
123
117
697
822
-
192
STR first (total failure)
109
42
28
54
57
545
631
-
193
STR last (success)
19
229
224
469
18
815
728
-
194
STR last (failure)
90
99
91
185
201
657
859
-
195
STR last (total failure)
82
90
83
135
151
584
1153
-
196
STR match, simple (success early)
17
14
13
25
33
503
489
-
197
STR match, simple (success late)
16
14
13
11
27
619
502
-
198
STR match, simple (failure)
17
15
13
26
36
421
680
-
199
STR match, simple (total failure)
16
18
13
17
30
456
378
-
200
STR match, complex (success early)
17
23
22
33
35
466
448
-
201
STR match, complex (success late)
145
1020
1040
2173
926
1529
1676
-
202
STR match, complex (failure)
122
1011
1010
1785
964
1357
1698
-
203
STR match, complex (total failure)
90
994
994
1844
1216
1725
1602
-
204
STR range, index 100..200 of 4010
26
21
21
716
25
589
609
-
205
STR replace, no replacement
79
270
264
570
166
1217
1315
-
206
STR replace, equal replacement
92
277
257
526
140
1560
1263
-
207
STR replace, longer replacement
95
270
265
551
103
1563
1309
-
208
STR repeat, abcdefghij * 10
19
22
22
21
199
997
963
-
209
STR repeat, abcdefghij * 100
39
72
74
120
1267
8488
9065
-
210
STR repeat, abcdefghij * 1000
245
565
557
798
12264
81587
86928
-
211
STR repeat, 4010 chars * 10
314
797
671
1971
1494
11891
7688
-
212
STR repeat, 4010 chars * 100
7347
18287
18194
47967
69328
105423
107290
-
213
STR reverse iter1, 100 chars
1285
1628
1425
4104
1871
8459
8704
-
214
STR reverse iter1, 100 uchars
1264
1768
1436
4448
1864
8250
9034
-
215
STR reverse iter2, 100 chars
808
1252
1168
3860
2099
8379
8292
-
216
STR reverse iter2, 100 uchars
807
1259
1096
4086
1602
9513
5431
-
217
STR reverse recur1, 100 chars
4092
4770
3998
8749
8470
20868
11271
-
218
STR reverse recur1, 100 uchars
4169
5467
4767
8794
9075
21634
13821
-
219
STR split, 4010 chars
2663
2138
8847
23626
18954
4372
3169
-
220
STR split, 12100 uchars
7207
6395
-
221
STR split iter, 4010 chars
9349
9372
16664
39846
35962
52886
48521
-
222
STR split iter, 12100 uchars
28171
28299
-
223
STR append
100
82
71
108
164
1055
1145
-
224
STR append (1KB + 1KB)
65
55
49
96
79
236
290
-
225
STR append (10KB + 1KB)
186
193
196
474
75
215
213
-
226
STR append (1MB + 2b * 1000)
37786
70498
74635
178639
12391
82339
84345
-
227
STR append (1MB + 1KB)
29729
63374
61479
136891
68
215
335
-
228
STR append (1MB + 1KB * 20)
29635
64566
61865
127033
270
1551
1724
-
229
STR append (1MB + 1KB * 1000)
66605
94413
101998
177875
10955
78370
81930
-
230
STR append (1MB + 1MB * 3)
126103
153051
157370
282029
218
248
876
-
231
STR append (1MB + 1MB * 5)
157407
303871
315407
1051814
45
543
342
-
232
STR append (1MB + (1b + 1K + 1b) * 100)
33118
63834
69167
290360
2398
8930
9893
-
233
STR info locals match
828
818
993
2025
1518
8071
9043
-
234
TRACE no trace set
35
25
26
18
27
42
91
-
235
TRACE read
35
26
26
16
59
128
113
-
236
TRACE write
35
25
26
16
55
78
78
-
237
TRACE unset
35
26
26
16
70
94
112
-
238
TRACE all set (rwu)
35
25
25
18
59
77
105
-
239
UNSET var exists
14
8
9
8
16
27
37
-
240
UNSET catch var exists
16
9
10
52
20
61
58
-
241
UNSET catch var !exist
69
64
59
191
120
77
96
-
242
UNSET info check var exists
19
14
13
69
27
80
78
-
243
UNSET info check var !exist
16
11
11
6
17
73
64
-
244
UNSET nocomplain var exists
14
9
10
35
20
52
56
-
245
UNSET nocomplain var !exist
14
64
59
157
122
90
109
-
246
VAR access locally set
14
8
10
18
20
106
67
-
247
VAR access local proc arg
14
9
10
6
26
88
110
-
248
VAR access global
34
25
26
101
61
82
121
-
249
VAR access upvar
36
29
30
103
65
97
101
-
250
VAR set scalar
10
6
7
4
11
35
74
-
251
VAR set array element
18
12
14
9
33
59
35
-
252
VAR 100 'set's in array
162
133
160
296
292
917
827
-
253
VAR 'array set' of 100 elems
293
251
264
741
816
1063
993
-
DELETED examples/csv/Benchmark.75p2.csv
Index: examples/csv/Benchmark.75p2.csv
==================================================================
--- examples/csv/Benchmark.75p2.csv
+++ /dev/null
@@ -1,215 +0,0 @@
-000,VERSIONS:,1:7.5p1
-001,CATCH return ok,17
-002,CATCH return error,33
-003,CATCH no catch used,9
-004,IF if true numeric,61
-005,IF elseif true numeric,292
-006,IF else true numeric,82
-007,IF if true num/num,174
-008,IF if false num/num,182
-009,IF if false al/num,121
-010,IF if true al/al,184
-011,IF if false al/al,243
-012,IF if true al,76
-013,IF elseif true al,154
-014,IF else true al,323
-015,SWITCH first true,241
-016,SWITCH second true,282
-017,SWITCH ninth true,284
-018,SWITCH default true,292
-019,DATA create in a list,29501
-020,DATA create in an array,40784
-021,DATA access in a list,175028
-022,DATA access in an array,39744
-023,EVAL cmd eval in list obj var,26
-024,EVAL cmd eval as list,52
-025,EVAL cmd eval as string,64
-026,EVAL cmd and mixed lists,2112
-027,EVAL list cmd and mixed lists,2259
-028,EVAL list cmd and pure lists,2245
-029,EXPR unbraced,365
-030,EXPR braced,386
-031,EXPR inline,177
-032,EXPR one operand,65
-033,EXPR ten operands,141
-034,EXPR fifty operands,430
-035,EXPR incr with incr,45
-036,EXPR incr with expr,74
-037,FCOPY std: 160010 bytes,26979
-038,"STR/LIST length, obj shimmer",2638
-039,"LIST length, pure list",1837
-040,STR length of a LIST,400
-041,"LIST exact search, first item",1693
-042,"LIST exact search, middle item",1944
-043,"LIST exact search, last item",2009
-044,"LIST exact search, non-item",2118
-045,"LIST sorted search, first item",1610
-046,"LIST sorted search, middle item",2252
-047,"LIST sorted search, last item",1784
-048,"LIST sorted search, non-item",2057
-049,"LIST exact search, untyped item",2218
-050,"LIST exact search, typed item",1872
-051,"LIST sorted search, typed item",2221
-052,LIST sort,9644
-053,LIST typed sort,23969
-054,LIST remove first element,522
-055,LIST remove middle element,677
-056,LIST remove last element,675
-057,LIST replace first element,978
-058,LIST replace middle element,876
-059,LIST replace last element,1243
-060,LIST replace first el with multiple,612
-061,LIST replace middle el with multiple,1123
-062,LIST replace last el with multiple,1313
-063,LIST replace range,971
-064,LIST remove in mixed list,617
-065,LIST replace in mixed list,592
-066,LIST index first element,375
-067,LIST index middle element,536
-068,LIST index last element,663
-069,LIST insert an item at start,563
-070,LIST insert an item at middle,630
-071,"LIST insert an item at ""end""",1200
-072,"LIST small, early range",383
-073,"LIST small, late range",685
-074,"LIST large, early range",697
-075,"LIST large, late range",551
-076,LIST append to list,682
-077,LIST join list,3167
-078,"LOOP for, iterate list",583297
-079,"LOOP foreach, iterate list",12556
-080,LOOP for (to 1000),73851
-081,LOOP while (to 1000),80404
-082,"LOOP for, iterate string",199570
-083,"LOOP foreach, iterate string",13206
-084,MAP string 1 val,(8.2+)
-085,MAP string 2 val,(8.2+)
-086,MAP string 3 val,(8.2+)
-087,MAP string 4 val,(8.2+)
-088,MAP string 1 val -nocase,(8.2+)
-089,MAP string 2 val -nocase,(8.2+)
-090,MAP string 3 val -nocase,(8.2+)
-091,MAP string 4 val -nocase,(8.2+)
-092,MAP regsub 1 val,3684
-093,MAP regsub 2 val,11576
-094,MAP regsub 3 val,12456
-095,MAP regsub 4 val,13884
-096,MAP regsub 1 val -nocase,4488
-097,MAP regsub 2 val -nocase,11911
-098,MAP regsub 3 val -nocase,14437
-099,MAP regsub 4 val -nocase,16818
-100,"MAP string, no match",(8.2+)
-101,"MAP string -nocase, no match",(8.2+)
-102,"MAP regsub, no match",4823
-103,"MAP regsub -nocase, no match",5249
-104,MAP string short,(8.2+)
-105,MAP regsub short,432
-106,PROC explicit return,11
-107,PROC implicit return,15
-108,PROC explicit return (2),10
-109,PROC implicit return (2),24
-110,PROC explicit return (3),25
-111,PROC implicit return (3),18
-112,PROC heavily commented,753
-113,"PROC do-nothing, no args",2
-114,"PROC do-nothing, one arg",21
-115,PROC local links with global,11505
-116,PROC local links with upvar,10317
-117,PROC local links with variable,9212
-118,"READ 595K, gets",985676
-119,"READ 595K, read",3834017
-120,"READ 595K, read & size",3704813
-121,"READ 3050b, gets",2201
-122,"READ 3050b, read",415
-123,"READ 3050b, read & size",361
-124,"BREAD 595K, gets",979961
-125,"BREAD 595K, read",3741298
-126,"BREAD 595K, read & size",3688120
-127,"BREAD 3050b, gets",2178
-128,"BREAD 3050b, read",359
-129,"BREAD 3050b, read & size",495
-130,REGEXP literal regexp,26
-131,REGEXP var-based regexp,61
-132,REGEXP count all matches,2776
-133,REGEXP extract all matches,3620
-134,STARTUP time to launch tclsh,90323
-135,STR str [string compare],193
-136,STR str [string equal],198
-137,"STR str $a equal """"",410
-138,"STR str num == """"",419
-139,STR str $a eq $b,261
-140,STR str $a ne $b,265
-141,STR str $a eq $b (same obj),338
-142,STR str $a ne $b (same obj),235
-143,STR length (==4010),867
-144,STR index 0,614
-145,STR index 100,601
-146,STR index 500,493
-147,STR index2 0,583
-148,STR index2 100,459
-149,STR index2 500,468
-150,STR first (success),519
-151,STR first (failure),822
-152,STR first (total failure),631
-153,STR last (success),728
-154,STR last (failure),859
-155,STR last (total failure),1153
-156,"STR match, simple (success early)",489
-157,"STR match, simple (success late)",502
-158,"STR match, simple (failure)",680
-159,"STR match, simple (total failure)",378
-160,"STR match, complex (success early)",448
-161,"STR match, complex (success late)",1676
-162,"STR match, complex (failure)",1698
-163,"STR match, complex (total failure)",1602
-164,"STR range, index 100..200 of 4010",609
-165,"STR replace, no replacement",1315
-166,"STR replace, equal replacement",1263
-167,"STR replace, longer replacement",1309
-168,"STR repeat, abcdefghij * 10",963
-169,"STR repeat, abcdefghij * 100",9065
-170,"STR repeat, abcdefghij * 1000",86928
-171,"STR repeat, 4010 chars * 10",7688
-172,"STR repeat, 4010 chars * 100",107290
-173,"STR reverse iter1, 100 chars",8704
-174,"STR reverse iter1, 100 uchars",9034
-175,"STR reverse iter2, 100 chars",8292
-176,"STR reverse iter2, 100 uchars",5431
-177,"STR reverse recur1, 100 chars",11271
-178,"STR reverse recur1, 100 uchars",13821
-179,"STR split, 4010 chars",3169
-180,"STR split, 12000 uchars",9080
-181,"STR split iter, 4010 chars",48521
-182,"STR split iter, 12000 uchars",156287
-183,STR append,1145
-184,STR append (1KB + 1KB),290
-185,STR append (10KB + 1KB),213
-186,STR append (1MB + 2b * 1000),84345
-187,STR append (1MB + 1KB),335
-188,STR append (1MB + 1KB * 20),1724
-189,STR append (1MB + 1KB * 1000),81930
-190,STR append (1MB + 1MB * 3),876
-191,STR append (1MB + 1MB * 5),342
-192,STR append (1MB + (1b + 1K + 1b) * 100),9893
-193,STR info locals match,9043
-194,TRACE no trace set,91
-195,TRACE read,113
-196,TRACE write,78
-197,TRACE unset,112
-198,TRACE all set (rwu),105
-199,UNSET var exists,37
-200,UNSET catch var exists,58
-201,UNSET catch var !exist,96
-202,UNSET info check var exists,78
-203,UNSET info check var !exist,64
-204,UNSET nocomplain var exists,56
-205,UNSET nocomplain var !exist,109
-206,VAR access locally set,67
-207,VAR access local proc arg,110
-208,VAR access global,121
-209,VAR access upvar,101
-210,VAR set scalar,74
-211,VAR set array element,35
-212,VAR 100 'set's in array,827
-213,VAR 'array set' of 100 elems,993
-
DELETED examples/csv/Benchmark.76p2.csv
Index: examples/csv/Benchmark.76p2.csv
==================================================================
--- examples/csv/Benchmark.76p2.csv
+++ /dev/null
@@ -1,215 +0,0 @@
-000,VERSIONS:,1:7.6p2
-001,CATCH return ok,28
-002,CATCH return error,146
-003,CATCH no catch used,24
-004,IF if true numeric,152
-005,IF elseif true numeric,299
-006,IF else true numeric,318
-007,IF if true num/num,329
-008,IF if false num/num,202
-009,IF if false al/num,467
-010,IF if true al/al,292
-011,IF if false al/al,217
-012,IF if true al,214
-013,IF elseif true al,358
-014,IF else true al,292
-015,SWITCH first true,391
-016,SWITCH second true,340
-017,SWITCH ninth true,391
-018,SWITCH default true,492
-019,DATA create in a list,40180
-020,DATA create in an array,53723
-021,DATA access in a list,182889
-022,DATA access in an array,43232
-023,EVAL cmd eval in list obj var,27
-024,EVAL cmd eval as list,22
-025,EVAL cmd eval as string,26
-026,EVAL cmd and mixed lists,3017
-027,EVAL list cmd and mixed lists,2936
-028,EVAL list cmd and pure lists,2653
-029,EXPR unbraced,313
-030,EXPR braced,505
-031,EXPR inline,321
-032,EXPR one operand,47
-033,EXPR ten operands,159
-034,EXPR fifty operands,708
-035,EXPR incr with incr,31
-036,EXPR incr with expr,73
-037,FCOPY std: 160010 bytes,29538
-038,"STR/LIST length, obj shimmer",2585
-039,"LIST length, pure list",2023
-040,STR length of a LIST,525
-041,"LIST exact search, first item",2303
-042,"LIST exact search, middle item",1787
-043,"LIST exact search, last item",2261
-044,"LIST exact search, non-item",2099
-045,"LIST sorted search, first item",1862
-046,"LIST sorted search, middle item",1623
-047,"LIST sorted search, last item",2145
-048,"LIST sorted search, non-item",1999
-049,"LIST exact search, untyped item",2166
-050,"LIST exact search, typed item",2072
-051,"LIST sorted search, typed item",1887
-052,LIST sort,10959
-053,LIST typed sort,28889
-054,LIST remove first element,625
-055,LIST remove middle element,656
-056,LIST remove last element,754
-057,LIST replace first element,727
-058,LIST replace middle element,1024
-059,LIST replace last element,1450
-060,LIST replace first el with multiple,702
-061,LIST replace middle el with multiple,1088
-062,LIST replace last el with multiple,1413
-063,LIST replace range,1198
-064,LIST remove in mixed list,829
-065,LIST replace in mixed list,756
-066,LIST index first element,451
-067,LIST index middle element,516
-068,LIST index last element,622
-069,LIST insert an item at start,729
-070,LIST insert an item at middle,978
-071,"LIST insert an item at ""end""",1779
-072,"LIST small, early range",500
-073,"LIST small, late range",618
-074,"LIST large, early range",511
-075,"LIST large, late range",567
-076,LIST append to list,737
-077,LIST join list,3672
-078,"LOOP for, iterate list",662376
-079,"LOOP foreach, iterate list",11561
-080,LOOP for (to 1000),66896
-081,LOOP while (to 1000),69891
-082,"LOOP for, iterate string",219770
-083,"LOOP foreach, iterate string",15468
-084,MAP string 1 val,(8.2+)
-085,MAP string 2 val,(8.2+)
-086,MAP string 3 val,(8.2+)
-087,MAP string 4 val,(8.2+)
-088,MAP string 1 val -nocase,(8.2+)
-089,MAP string 2 val -nocase,(8.2+)
-090,MAP string 3 val -nocase,(8.2+)
-091,MAP string 4 val -nocase,(8.2+)
-092,MAP regsub 1 val,4430
-093,MAP regsub 2 val,9394
-094,MAP regsub 3 val,11441
-095,MAP regsub 4 val,15319
-096,MAP regsub 1 val -nocase,4729
-097,MAP regsub 2 val -nocase,9546
-098,MAP regsub 3 val -nocase,12501
-099,MAP regsub 4 val -nocase,14510
-100,"MAP string, no match",(8.2+)
-101,"MAP string -nocase, no match",(8.2+)
-102,"MAP regsub, no match",3352
-103,"MAP regsub -nocase, no match",4499
-104,MAP string short,(8.2+)
-105,MAP regsub short,244
-106,PROC explicit return,11
-107,PROC implicit return,16
-108,PROC explicit return (2),14
-109,PROC implicit return (2),21
-110,PROC explicit return (3),14
-111,PROC implicit return (3),10
-112,PROC heavily commented,629
-113,"PROC do-nothing, no args",5
-114,"PROC do-nothing, one arg",15
-115,PROC local links with global,7955
-116,PROC local links with upvar,8371
-117,PROC local links with variable,9091
-118,"READ 595K, gets",978472
-119,"READ 595K, read",3774669
-120,"READ 595K, read & size",3696432
-121,"READ 3050b, gets",2074
-122,"READ 3050b, read",503
-123,"READ 3050b, read & size",467
-124,"BREAD 595K, gets",953379
-125,"BREAD 595K, read",3640795
-126,"BREAD 595K, read & size",3685978
-127,"BREAD 3050b, gets",2208
-128,"BREAD 3050b, read",458
-129,"BREAD 3050b, read & size",390
-130,REGEXP literal regexp,26
-131,REGEXP var-based regexp,30
-132,REGEXP count all matches,2277
-133,REGEXP extract all matches,3068
-134,STARTUP time to launch tclsh,70500
-135,STR str [string compare],199
-136,STR str [string equal],160
-137,"STR str $a equal """"",670
-138,"STR str num == """"",338
-139,STR str $a eq $b,231
-140,STR str $a ne $b,226
-141,STR str $a eq $b (same obj),271
-142,STR str $a ne $b (same obj),203
-143,STR length (==4010),508
-144,STR index 0,522
-145,STR index 100,491
-146,STR index 500,489
-147,STR index2 0,485
-148,STR index2 100,557
-149,STR index2 500,764
-150,STR first (success),533
-151,STR first (failure),697
-152,STR first (total failure),545
-153,STR last (success),815
-154,STR last (failure),657
-155,STR last (total failure),584
-156,"STR match, simple (success early)",503
-157,"STR match, simple (success late)",619
-158,"STR match, simple (failure)",421
-159,"STR match, simple (total failure)",456
-160,"STR match, complex (success early)",466
-161,"STR match, complex (success late)",1529
-162,"STR match, complex (failure)",1357
-163,"STR match, complex (total failure)",1725
-164,"STR range, index 100..200 of 4010",589
-165,"STR replace, no replacement",1217
-166,"STR replace, equal replacement",1560
-167,"STR replace, longer replacement",1563
-168,"STR repeat, abcdefghij * 10",997
-169,"STR repeat, abcdefghij * 100",8488
-170,"STR repeat, abcdefghij * 1000",81587
-171,"STR repeat, 4010 chars * 10",11891
-172,"STR repeat, 4010 chars * 100",105423
-173,"STR reverse iter1, 100 chars",8459
-174,"STR reverse iter1, 100 uchars",8250
-175,"STR reverse iter2, 100 chars",8379
-176,"STR reverse iter2, 100 uchars",9513
-177,"STR reverse recur1, 100 chars",20868
-178,"STR reverse recur1, 100 uchars",21634
-179,"STR split, 4010 chars",4372
-180,"STR split, 12000 uchars",15202
-181,"STR split iter, 4010 chars",52886
-182,"STR split iter, 12000 uchars",162558
-183,STR append,1055
-184,STR append (1KB + 1KB),236
-185,STR append (10KB + 1KB),215
-186,STR append (1MB + 2b * 1000),82339
-187,STR append (1MB + 1KB),215
-188,STR append (1MB + 1KB * 20),1551
-189,STR append (1MB + 1KB * 1000),78370
-190,STR append (1MB + 1MB * 3),248
-191,STR append (1MB + 1MB * 5),543
-192,STR append (1MB + (1b + 1K + 1b) * 100),8930
-193,STR info locals match,8071
-194,TRACE no trace set,42
-195,TRACE read,128
-196,TRACE write,78
-197,TRACE unset,94
-198,TRACE all set (rwu),77
-199,UNSET var exists,27
-200,UNSET catch var exists,61
-201,UNSET catch var !exist,77
-202,UNSET info check var exists,80
-203,UNSET info check var !exist,73
-204,UNSET nocomplain var exists,52
-205,UNSET nocomplain var !exist,90
-206,VAR access locally set,106
-207,VAR access local proc arg,88
-208,VAR access global,82
-209,VAR access upvar,97
-210,VAR set scalar,35
-211,VAR set array element,59
-212,VAR 100 'set's in array,917
-213,VAR 'array set' of 100 elems,1063
-
DELETED examples/csv/Benchmark.805.csv
Index: examples/csv/Benchmark.805.csv
==================================================================
--- examples/csv/Benchmark.805.csv
+++ /dev/null
@@ -1,252 +0,0 @@
-000,VERSIONS:,1:8.0.5
-001,CATCH return ok,5
-002,CATCH return error,204
-003,CATCH no catch used,4
-004,IF if true numeric,9
-005,IF elseif true numeric,11
-006,IF else true numeric,11
-007,IF if true num/num,9
-008,IF if false num/num,9
-009,IF if false al/num,17
-010,IF if true al/al,169
-011,IF if false al/al,60
-012,IF if true al,51
-013,IF elseif true al,156
-014,IF else true al,51
-015,SWITCH first true,73
-016,SWITCH second true,62
-017,SWITCH ninth true,112
-018,SWITCH default true,77
-019,DATA create in a list,7886
-020,DATA create in an array,16792
-021,DATA access in a list,7024
-022,DATA access in an array,7640
-023,EVAL cmd eval in list obj var,84
-024,EVAL cmd eval as list,144
-025,EVAL cmd eval as string,90
-026,EVAL cmd and mixed lists,13914
-027,EVAL list cmd and mixed lists,14703
-028,EVAL list cmd and pure lists,12611
-029,EXPR unbraced,331
-030,EXPR braced,92
-031,EXPR inline,59
-032,EXPR one operand,11
-033,EXPR ten operands,20
-034,EXPR fifty operands,85
-035,EXPR incr with incr,22
-036,EXPR incr with expr,13
-037,FCOPY std: 160010 bytes,26557
-038,KLIST shuffle0 llength 1,367
-039,KLIST shuffle0 llength 10,728
-040,KLIST shuffle0 llength 100,6484
-041,KLIST shuffle0 llength 1000,81157
-042,KLIST shuffle0 llength 10000,1161217
-043,KLIST shuffle1 llength 1,149
-044,KLIST shuffle1 llength 10,634
-045,KLIST shuffle1 llength 100,8576
-046,KLIST shuffle1 llength 1000,1736049
-047,KLIST shuffle1a llength 1,150
-048,KLIST shuffle1a llength 10,910
-049,KLIST shuffle1a llength 100,9480
-050,KLIST shuffle1a llength 1000,95305
-051,KLIST shuffle1a llength 10000,1004602
-052,KLIST shuffle2 llength 1,229
-053,KLIST shuffle2 llength 10,1080
-054,KLIST shuffle2 llength 100,9803
-055,KLIST shuffle2 llength 1000,116933
-056,KLIST shuffle2 llength 10000,1304458
-057,KLIST shuffle3 llength 1,170
-058,KLIST shuffle3 llength 10,832
-059,KLIST shuffle3 llength 100,7632
-060,KLIST shuffle3 llength 1000,82985
-061,KLIST shuffle3 llength 10000,1732151
-062,KLIST shuffle4 llength 1,178
-063,KLIST shuffle4 llength 10,876
-064,KLIST shuffle4 llength 100,8278
-065,KLIST shuffle4 llength 1000,80450
-066,KLIST shuffle4 llength 10000,834612
-067,"STR/LIST length, obj shimmer",28
-068,"LIST length, pure list",18
-069,STR length of a LIST,23
-070,"LIST exact search, first item",32
-071,"LIST exact search, middle item",38
-072,"LIST exact search, last item",111
-073,"LIST exact search, non-item",220
-074,"LIST sorted search, first item",29
-075,"LIST sorted search, middle item",40
-076,"LIST sorted search, last item",121
-077,"LIST sorted search, non-item",257
-078,"LIST exact search, untyped item",101
-079,"LIST exact search, typed item",111
-080,"LIST sorted search, typed item",104
-081,LIST sort,7021
-082,LIST typed sort,4651
-083,LIST remove first element,866
-084,LIST remove middle element,876
-085,LIST remove last element,879
-086,LIST replace first element,917
-087,LIST replace middle element,1045
-088,LIST replace last element,832
-089,LIST replace first el with multiple,938
-090,LIST replace middle el with multiple,736
-091,LIST replace last el with multiple,740
-092,LIST replace range,866
-093,LIST remove in mixed list,999
-094,LIST replace in mixed list,925
-095,LIST index first element,25
-096,LIST index middle element,23
-097,LIST index last element,17
-098,LIST insert an item at start,805
-099,LIST insert an item at middle,667
-100,"LIST insert an item at ""end""",1013
-101,"LIST small, early range",35
-102,"LIST small, late range",38
-103,"LIST large, early range",108
-104,"LIST large, late range",131
-105,LIST append to list,1032
-106,LIST join list,1453
-107,"LOOP for, iterate list",9653
-108,"LOOP foreach, iterate list",3553
-109,LOOP for (to 1000),4867
-110,LOOP while (to 1000),4637
-111,"LOOP for, iterate string",14530
-112,"LOOP foreach, iterate string",8147
-113,MAP string 1 val,(8.2+)
-114,MAP string 2 val,(8.2+)
-115,MAP string 3 val,(8.2+)
-116,MAP string 4 val,(8.2+)
-117,MAP string 1 val -nocase,(8.2+)
-118,MAP string 2 val -nocase,(8.2+)
-119,MAP string 3 val -nocase,(8.2+)
-120,MAP string 4 val -nocase,(8.2+)
-121,MAP regsub 1 val,1830
-122,MAP regsub 2 val,4184
-123,MAP regsub 3 val,6075
-124,MAP regsub 4 val,8659
-125,MAP regsub 1 val -nocase,2766
-126,MAP regsub 2 val -nocase,5881
-127,MAP regsub 3 val -nocase,8625
-128,MAP regsub 4 val -nocase,11664
-129,"MAP string, no match",(8.2+)
-130,"MAP string -nocase, no match",(8.2+)
-131,"MAP regsub, no match",1843
-132,"MAP regsub -nocase, no match",3563
-133,MAP string short,(8.2+)
-134,MAP regsub short,154
-135,MTHD direct ns proc call,7
-136,MTHD imported ns proc call,7
-137,MTHD interp alias proc call,9
-138,MTHD indirect proc eval,72
-139,MTHD indirect proc eval #2,107
-140,MTHD array stored proc call,19
-141,MTHD switch method call,172
-142,MTHD ns lookup call,376
-143,MTHD inline call,2
-144,PROC explicit return,7
-145,PROC implicit return,11
-146,PROC explicit return (2),13
-147,PROC implicit return (2),18
-148,PROC explicit return (3),14
-149,PROC implicit return (3),12
-150,PROC heavily commented,5
-151,"PROC do-nothing, no args",4
-152,"PROC do-nothing, one arg",8
-153,PROC local links with global,4533
-154,PROC local links with upvar,2922
-155,PROC local links with variable,1050
-156,"READ 595K, gets",372526
-157,"READ 595K, read",2936958
-158,"READ 595K, read & size",124776
-159,"READ 3050b, gets",954
-160,"READ 3050b, read",748
-161,"READ 3050b, read & size",410
-162,"BREAD 595K, gets",365165
-163,"BREAD 595K, read",2952787
-164,"BREAD 595K, read & size",87019
-165,"BREAD 3050b, gets",1062
-166,"BREAD 3050b, read",412
-167,"BREAD 3050b, read & size",1230
-168,REGEXP literal regexp,31
-169,REGEXP var-based regexp,45
-170,REGEXP count all matches,1332
-171,REGEXP extract all matches,1129
-172,STARTUP time to launch tclsh,102877
-173,STR str [string compare],26
-174,STR str [string equal],38
-175,"STR str $a equal """"",52
-176,"STR str num == """"",52
-177,STR str $a eq $b,56
-178,STR str $a ne $b,47
-179,STR str $a eq $b (same obj),53
-180,STR str $a ne $b (same obj),57
-181,STR length (==4010),17
-182,STR index 0,30
-183,STR index 100,43
-184,STR index 500,42
-185,STR index2 0,27
-186,STR index2 100,26
-187,STR index2 500,40
-188,STR first (success),33
-189,STR first (failure),117
-190,STR first (total failure),57
-191,STR last (success),18
-192,STR last (failure),201
-193,STR last (total failure),151
-194,"STR match, simple (success early)",33
-195,"STR match, simple (success late)",27
-196,"STR match, simple (failure)",36
-197,"STR match, simple (total failure)",30
-198,"STR match, complex (success early)",35
-199,"STR match, complex (success late)",926
-200,"STR match, complex (failure)",964
-201,"STR match, complex (total failure)",1216
-202,"STR range, index 100..200 of 4010",25
-203,"STR replace, no replacement",166
-204,"STR replace, equal replacement",140
-205,"STR replace, longer replacement",103
-206,"STR repeat, abcdefghij * 10",199
-207,"STR repeat, abcdefghij * 100",1267
-208,"STR repeat, abcdefghij * 1000",12264
-209,"STR repeat, 4010 chars * 10",1494
-210,"STR repeat, 4010 chars * 100",69328
-211,"STR reverse iter1, 100 chars",1871
-212,"STR reverse iter1, 100 uchars",1864
-213,"STR reverse iter2, 100 chars",2099
-214,"STR reverse iter2, 100 uchars",1602
-215,"STR reverse recur1, 100 chars",8470
-216,"STR reverse recur1, 100 uchars",9075
-217,"STR split, 4010 chars",18954
-218,"STR split, 12000 uchars",60753
-219,"STR split iter, 4010 chars",35962
-220,"STR split iter, 12000 uchars",108683
-221,STR append,164
-222,STR append (1KB + 1KB),79
-223,STR append (10KB + 1KB),75
-224,STR append (1MB + 2b * 1000),12391
-225,STR append (1MB + 1KB),68
-226,STR append (1MB + 1KB * 20),270
-227,STR append (1MB + 1KB * 1000),10955
-228,STR append (1MB + 1MB * 3),218
-229,STR append (1MB + 1MB * 5),45
-230,STR append (1MB + (1b + 1K + 1b) * 100),2398
-231,STR info locals match,1518
-232,TRACE no trace set,27
-233,TRACE read,59
-234,TRACE write,55
-235,TRACE unset,70
-236,TRACE all set (rwu),59
-237,UNSET var exists,16
-238,UNSET catch var exists,20
-239,UNSET catch var !exist,120
-240,UNSET info check var exists,27
-241,UNSET info check var !exist,17
-242,UNSET nocomplain var exists,20
-243,UNSET nocomplain var !exist,122
-244,VAR access locally set,20
-245,VAR access local proc arg,26
-246,VAR access global,61
-247,VAR access upvar,65
-248,VAR set scalar,11
-249,VAR set array element,33
-250,VAR 100 'set's in array,292
-251,VAR 'array set' of 100 elems,816
DELETED examples/csv/Benchmark.811.csv
Index: examples/csv/Benchmark.811.csv
==================================================================
--- examples/csv/Benchmark.811.csv
+++ /dev/null
@@ -1,254 +0,0 @@
-000,VERSIONS:,1:8.1.1
-001,CATCH return ok,4
-002,CATCH return error,54
-003,CATCH no catch used,13
-004,IF if true numeric,7
-005,IF elseif true numeric,20
-006,IF else true numeric,15
-007,IF if true num/num,22
-008,IF if false num/num,13
-009,IF if false al/num,29
-010,IF if true al/al,51
-011,IF if false al/al,51
-012,IF if true al,42
-013,IF elseif true al,89
-014,IF else true al,71
-015,SWITCH first true,58
-016,SWITCH second true,65
-017,SWITCH ninth true,73
-018,SWITCH default true,73
-019,DATA create in a list,12925
-020,DATA create in an array,12827
-021,DATA access in a list,10386
-022,DATA access in an array,6966
-023,EVAL cmd eval in list obj var,40
-024,EVAL cmd eval as list,88
-025,EVAL cmd eval as string,79
-026,EVAL cmd and mixed lists,21937
-027,EVAL list cmd and mixed lists,19014
-028,EVAL list cmd and pure lists,21974
-029,EXPR unbraced,23
-030,EXPR braced,53
-031,EXPR inline,68
-032,EXPR one operand,9
-033,EXPR ten operands,13
-034,EXPR fifty operands,71
-035,EXPR incr with incr,16
-036,EXPR incr with expr,11
-037,FCOPY std: 160010 bytes,25104
-038,FCOPY binary: 160010 bytes,25211
-039,FCOPY encoding: 160010 bytes,25972
-040,KLIST shuffle0 llength 1,271
-041,KLIST shuffle0 llength 10,901
-042,KLIST shuffle0 llength 100,8229
-043,KLIST shuffle0 llength 1000,92480
-044,KLIST shuffle0 llength 10000,1214997
-045,KLIST shuffle1 llength 1,163
-046,KLIST shuffle1 llength 10,718
-047,KLIST shuffle1 llength 100,9243
-048,KLIST shuffle1 llength 1000,1762135
-049,KLIST shuffle1a llength 1,172
-050,KLIST shuffle1a llength 10,768
-051,KLIST shuffle1a llength 100,8986
-052,KLIST shuffle1a llength 1000,84798
-053,KLIST shuffle1a llength 10000,861405
-054,KLIST shuffle2 llength 1,196
-055,KLIST shuffle2 llength 10,938
-056,KLIST shuffle2 llength 100,8904
-057,KLIST shuffle2 llength 1000,95513
-058,KLIST shuffle2 llength 10000,1176566
-059,KLIST shuffle3 llength 1,217
-060,KLIST shuffle3 llength 10,786
-061,KLIST shuffle3 llength 100,7161
-062,KLIST shuffle3 llength 1000,87353
-063,KLIST shuffle3 llength 10000,1789387
-064,KLIST shuffle4 llength 1,202
-065,KLIST shuffle4 llength 10,837
-066,KLIST shuffle4 llength 100,8572
-067,KLIST shuffle4 llength 1000,82985
-068,KLIST shuffle4 llength 10000,874454
-069,"STR/LIST length, obj shimmer",905
-070,"LIST length, pure list",21
-071,STR length of a LIST,529
-072,"LIST exact search, first item",17
-073,"LIST exact search, middle item",46
-074,"LIST exact search, last item",90
-075,"LIST exact search, non-item",212
-076,"LIST sorted search, first item",16
-077,"LIST sorted search, middle item",42
-078,"LIST sorted search, last item",84
-079,"LIST sorted search, non-item",201
-080,"LIST exact search, untyped item",80
-081,"LIST exact search, typed item",77
-082,"LIST sorted search, typed item",93
-083,LIST sort,6723
-084,LIST typed sort,4737
-085,LIST remove first element,806
-086,LIST remove middle element,692
-087,LIST remove last element,689
-088,LIST replace first element,722
-089,LIST replace middle element,693
-090,LIST replace last element,963
-091,LIST replace first el with multiple,819
-092,LIST replace middle el with multiple,691
-093,LIST replace last el with multiple,813
-094,LIST replace range,744
-095,LIST remove in mixed list,833
-096,LIST replace in mixed list,1054
-097,LIST index first element,16
-098,LIST index middle element,16
-099,LIST index last element,13
-100,LIST insert an item at start,775
-101,LIST insert an item at middle,684
-102,"LIST insert an item at ""end""",670
-103,"LIST small, early range",42
-104,"LIST small, late range",28
-105,"LIST large, early range",54
-106,"LIST large, late range",81
-107,LIST append to list,917
-108,LIST join list,1818
-109,"LOOP for, iterate list",13766
-110,"LOOP foreach, iterate list",3750
-111,LOOP for (to 1000),4639
-112,LOOP while (to 1000),4551
-113,"LOOP for, iterate string",141594
-114,"LOOP foreach, iterate string",9099
-115,MAP string 1 val,9096
-116,MAP string 2 val,12943
-117,MAP string 3 val,12825
-118,MAP string 4 val,17267
-119,MAP string 1 val -nocase,17685
-120,MAP string 2 val -nocase,27379
-121,MAP string 3 val -nocase,35569
-122,MAP string 4 val -nocase,39660
-123,MAP regsub 1 val,9663
-124,MAP regsub 2 val,41500
-125,MAP regsub 3 val,52315
-126,MAP regsub 4 val,67973
-127,MAP regsub 1 val -nocase,9463
-128,MAP regsub 2 val -nocase,40735
-129,MAP regsub 3 val -nocase,52639
-130,MAP regsub 4 val -nocase,66937
-131,"MAP string, no match",14020
-132,"MAP string -nocase, no match",35683
-133,"MAP regsub, no match",6704
-134,"MAP regsub -nocase, no match",6609
-135,MAP string short,116
-136,MAP regsub short,308
-137,MTHD direct ns proc call,3
-138,MTHD imported ns proc call,5
-139,MTHD interp alias proc call,18
-140,MTHD indirect proc eval,56
-141,MTHD indirect proc eval #2,81
-142,MTHD array stored proc call,22
-143,MTHD switch method call,119
-144,MTHD ns lookup call,374
-145,MTHD inline call,2
-146,PROC explicit return,7
-147,PROC implicit return,4
-148,PROC explicit return (2),13
-149,PROC implicit return (2),10
-150,PROC explicit return (3),4
-151,PROC implicit return (3),3
-152,PROC heavily commented,12
-153,"PROC do-nothing, no args",38
-154,"PROC do-nothing, one arg",9
-155,PROC local links with global,3586
-156,PROC local links with upvar,2806
-157,PROC local links with variable,2614
-158,"READ 595K, gets",819327
-159,"READ 595K, read",227338
-160,"READ 595K, read & size",242255
-161,"READ 3050b, gets",4118
-162,"READ 3050b, read",789
-163,"READ 3050b, read & size",790
-164,"BREAD 595K, gets",833500
-165,"BREAD 595K, read",228963
-166,"BREAD 595K, read & size",246365
-167,"BREAD 3050b, gets",5220
-168,"BREAD 3050b, read",1310
-169,"BREAD 3050b, read & size",1144
-170,REGEXP literal regexp,42
-171,REGEXP var-based regexp,55
-172,REGEXP count all matches,1280
-173,REGEXP extract all matches,1790
-174,STARTUP time to launch tclsh,85723
-175,STR str [string compare],17
-176,STR str [string equal],68
-177,"STR str $a equal """"",81
-178,"STR str num == """"",36
-179,STR str $a eq $b,39
-180,STR str $a ne $b,85
-181,STR str $a eq $b (same obj),161
-182,STR str $a ne $b (same obj),28
-183,STR length (==4010),678
-184,STR index 0,487
-185,STR index 100,500
-186,STR index 500,483
-187,STR index2 0,494
-188,STR index2 100,470
-189,STR index2 500,484
-190,STR first (success),21
-191,STR first (failure),123
-192,STR first (total failure),54
-193,STR last (success),469
-194,STR last (failure),185
-195,STR last (total failure),135
-196,"STR match, simple (success early)",25
-197,"STR match, simple (success late)",11
-198,"STR match, simple (failure)",26
-199,"STR match, simple (total failure)",17
-200,"STR match, complex (success early)",33
-201,"STR match, complex (success late)",2173
-202,"STR match, complex (failure)",1785
-203,"STR match, complex (total failure)",1844
-204,"STR range, index 100..200 of 4010",716
-205,"STR replace, no replacement",570
-206,"STR replace, equal replacement",526
-207,"STR replace, longer replacement",551
-208,"STR repeat, abcdefghij * 10",21
-209,"STR repeat, abcdefghij * 100",120
-210,"STR repeat, abcdefghij * 1000",798
-211,"STR repeat, 4010 chars * 10",1971
-212,"STR repeat, 4010 chars * 100",47967
-213,"STR reverse iter1, 100 chars",4104
-214,"STR reverse iter1, 100 uchars",4448
-215,"STR reverse iter2, 100 chars",3860
-216,"STR reverse iter2, 100 uchars",4086
-217,"STR reverse recur1, 100 chars",8749
-218,"STR reverse recur1, 100 uchars",8794
-219,"STR split, 4010 chars",23626
-220,"STR split, 12000 uchars",74910
-221,"STR split iter, 4010 chars",39846
-222,"STR split iter, 12000 uchars",122753
-223,STR append,108
-224,STR append (1KB + 1KB),96
-225,STR append (10KB + 1KB),474
-226,STR append (1MB + 2b * 1000),178639
-227,STR append (1MB + 1KB),136891
-228,STR append (1MB + 1KB * 20),127033
-229,STR append (1MB + 1KB * 1000),177875
-230,STR append (1MB + 1MB * 3),282029
-231,STR append (1MB + 1MB * 5),1051814
-232,STR append (1MB + (1b + 1K + 1b) * 100),290360
-233,STR info locals match,2025
-234,TRACE no trace set,18
-235,TRACE read,16
-236,TRACE write,16
-237,TRACE unset,16
-238,TRACE all set (rwu),18
-239,UNSET var exists,8
-240,UNSET catch var exists,52
-241,UNSET catch var !exist,191
-242,UNSET info check var exists,69
-243,UNSET info check var !exist,6
-244,UNSET nocomplain var exists,35
-245,UNSET nocomplain var !exist,157
-246,VAR access locally set,18
-247,VAR access local proc arg,6
-248,VAR access global,101
-249,VAR access upvar,103
-250,VAR set scalar,4
-251,VAR set array element,9
-252,VAR 100 'set's in array,296
-253,VAR 'array set' of 100 elems,741
DELETED examples/csv/Benchmark.823.csv
Index: examples/csv/Benchmark.823.csv
==================================================================
--- examples/csv/Benchmark.823.csv
+++ /dev/null
@@ -1,254 +0,0 @@
-000,VERSIONS:,1:8.2.3
-001,CATCH return ok,7
-002,CATCH return error,275
-003,CATCH no catch used,7
-004,IF if true numeric,13
-005,IF elseif true numeric,16
-006,IF else true numeric,16
-007,IF if true num/num,281
-008,IF if false num/num,13
-009,IF if false al/num,20
-010,IF if true al/al,26
-011,IF if false al/al,25
-012,IF if true al,25
-013,IF elseif true al,338
-014,IF else true al,42
-015,SWITCH first true,103
-016,SWITCH second true,153
-017,SWITCH ninth true,238
-018,SWITCH default true,46
-019,DATA create in a list,15014
-020,DATA create in an array,19172
-021,DATA access in a list,15346
-022,DATA access in an array,14156
-023,EVAL cmd eval in list obj var,52
-024,EVAL cmd eval as list,49
-025,EVAL cmd eval as string,54
-026,EVAL cmd and mixed lists,32485
-027,EVAL list cmd and mixed lists,40366
-028,EVAL list cmd and pure lists,40115
-029,EXPR unbraced,502
-030,EXPR braced,29
-031,EXPR inline,40
-032,EXPR one operand,158
-033,EXPR ten operands,97
-034,EXPR fifty operands,45
-035,EXPR incr with incr,10
-036,EXPR incr with expr,9
-037,FCOPY std: 160010 bytes,46300
-038,FCOPY binary: 160010 bytes,41776
-039,FCOPY encoding: 160010 bytes,44598
-040,KLIST shuffle0 llength 1,554
-041,KLIST shuffle0 llength 10,1592
-042,KLIST shuffle0 llength 100,13565
-043,KLIST shuffle0 llength 1000,164223
-044,KLIST shuffle0 llength 10000,2073612
-045,KLIST shuffle1 llength 1,367
-046,KLIST shuffle1 llength 10,1371
-047,KLIST shuffle1 llength 100,12737
-048,KLIST shuffle1 llength 1000,1770024
-049,KLIST shuffle1a llength 1,94
-050,KLIST shuffle1a llength 10,404
-051,KLIST shuffle1a llength 100,3833
-052,KLIST shuffle1a llength 1000,39248
-053,KLIST shuffle1a llength 10000,408005
-054,KLIST shuffle2 llength 1,108
-055,KLIST shuffle2 llength 10,481
-056,KLIST shuffle2 llength 100,4250
-057,KLIST shuffle2 llength 1000,45651
-058,KLIST shuffle2 llength 10000,527055
-059,KLIST shuffle3 llength 1,102
-060,KLIST shuffle3 llength 10,376
-061,KLIST shuffle3 llength 100,3413
-062,KLIST shuffle3 llength 1000,37667
-063,KLIST shuffle3 llength 10000,844383
-064,KLIST shuffle4 llength 1,100
-065,KLIST shuffle4 llength 10,416
-066,KLIST shuffle4 llength 100,3758
-067,KLIST shuffle4 llength 1000,38186
-068,KLIST shuffle4 llength 10000,398724
-069,"STR/LIST length, obj shimmer",2333
-070,"LIST length, pure list",13
-071,STR length of a LIST,12
-072,"LIST exact search, first item",14
-073,"LIST exact search, middle item",27
-074,"LIST exact search, last item",50
-075,"LIST exact search, non-item",121
-076,"LIST sorted search, first item",12
-077,"LIST sorted search, middle item",26
-078,"LIST sorted search, last item",49
-079,"LIST sorted search, non-item",122
-080,"LIST exact search, untyped item",51
-081,"LIST exact search, typed item",49
-082,"LIST sorted search, typed item",50
-083,LIST sort,3293
-084,LIST typed sort,2660
-085,LIST remove first element,363
-086,LIST remove middle element,358
-087,LIST remove last element,360
-088,LIST replace first element,346
-089,LIST replace middle element,353
-090,LIST replace last element,346
-091,LIST replace first el with multiple,372
-092,LIST replace middle el with multiple,351
-093,LIST replace last el with multiple,347
-094,LIST replace range,343
-095,LIST remove in mixed list,2195
-096,LIST replace in mixed list,2184
-097,LIST index first element,13
-098,LIST index middle element,13
-099,LIST index last element,13
-100,LIST insert an item at start,366
-101,LIST insert an item at middle,370
-102,"LIST insert an item at ""end""",349
-103,"LIST small, early range",16
-104,"LIST small, late range",16
-105,"LIST large, early range",24
-106,"LIST large, late range",21
-107,LIST append to list,396
-108,LIST join list,1066
-109,"LOOP for, iterate list",5372
-110,"LOOP foreach, iterate list",1952
-111,LOOP for (to 1000),3065
-112,LOOP while (to 1000),3065
-113,"LOOP for, iterate string",9637
-114,"LOOP foreach, iterate string",3955
-115,MAP string 1 val,6028
-116,MAP string 2 val,6877
-117,MAP string 3 val,7832
-118,MAP string 4 val,8622
-119,MAP string 1 val -nocase,10381
-120,MAP string 2 val -nocase,15024
-121,MAP string 3 val -nocase,18973
-122,MAP string 4 val -nocase,22132
-123,MAP regsub 1 val,4303
-124,MAP regsub 2 val,18176
-125,MAP regsub 3 val,24817
-126,MAP regsub 4 val,31350
-127,MAP regsub 1 val -nocase,4332
-128,MAP regsub 2 val -nocase,18134
-129,MAP regsub 3 val -nocase,24747
-130,MAP regsub 4 val -nocase,31314
-131,"MAP string, no match",8028
-132,"MAP string -nocase, no match",18933
-133,"MAP regsub, no match",2830
-134,"MAP regsub -nocase, no match",2890
-135,MAP string short,39
-136,MAP regsub short,193
-137,MTHD direct ns proc call,8
-138,MTHD imported ns proc call,7
-139,MTHD interp alias proc call,18
-140,MTHD indirect proc eval,61
-141,MTHD indirect proc eval #2,57
-142,MTHD array stored proc call,10
-143,MTHD switch method call,83
-144,MTHD ns lookup call,216
-145,MTHD inline call,3
-146,PROC explicit return,8
-147,PROC implicit return,7
-148,PROC explicit return (2),8
-149,PROC implicit return (2),7
-150,PROC explicit return (3),7
-151,PROC implicit return (3),7
-152,PROC heavily commented,6
-153,"PROC do-nothing, no args",28
-154,"PROC do-nothing, one arg",6
-155,PROC local links with global,1626
-156,PROC local links with upvar,1387
-157,PROC local links with variable,1334
-158,"READ 595K, gets",306109
-159,"READ 595K, read",97019
-160,"READ 595K, read & size",97074
-161,"READ 3050b, gets",2052
-162,"READ 3050b, read",494
-163,"READ 3050b, read & size",530
-164,"BREAD 595K, gets",304961
-165,"BREAD 595K, read",50018
-166,"BREAD 595K, read & size",50140
-167,"BREAD 3050b, gets",1774
-168,"BREAD 3050b, read",334
-169,"BREAD 3050b, read & size",369
-170,REGEXP literal regexp,38
-171,REGEXP var-based regexp,40
-172,REGEXP count all matches,530
-173,REGEXP extract all matches,616
-174,STARTUP time to launch tclsh,18293
-175,STR str [string compare],24
-176,STR str [string equal],23
-177,"STR str $a equal """"",24
-178,"STR str num == """"",24
-179,STR str $a eq $b,31
-180,STR str $a ne $b,30
-181,STR str $a eq $b (same obj),36
-182,STR str $a ne $b (same obj),30
-183,STR length (==4010),13
-184,STR index 0,19
-185,STR index 100,19
-186,STR index 500,19
-187,STR index2 0,19
-188,STR index2 100,19
-189,STR index2 500,19
-190,STR first (success),15
-191,STR first (failure),50
-192,STR first (total failure),28
-193,STR last (success),224
-194,STR last (failure),91
-195,STR last (total failure),83
-196,"STR match, simple (success early)",13
-197,"STR match, simple (success late)",13
-198,"STR match, simple (failure)",13
-199,"STR match, simple (total failure)",13
-200,"STR match, complex (success early)",22
-201,"STR match, complex (success late)",1040
-202,"STR match, complex (failure)",1010
-203,"STR match, complex (total failure)",994
-204,"STR range, index 100..200 of 4010",21
-205,"STR replace, no replacement",264
-206,"STR replace, equal replacement",257
-207,"STR replace, longer replacement",265
-208,"STR repeat, abcdefghij * 10",22
-209,"STR repeat, abcdefghij * 100",74
-210,"STR repeat, abcdefghij * 1000",557
-211,"STR repeat, 4010 chars * 10",671
-212,"STR repeat, 4010 chars * 100",18194
-213,"STR reverse iter1, 100 chars",1425
-214,"STR reverse iter1, 100 uchars",1436
-215,"STR reverse iter2, 100 chars",1168
-216,"STR reverse iter2, 100 uchars",1096
-217,"STR reverse recur1, 100 chars",3998
-218,"STR reverse recur1, 100 uchars",4767
-219,"STR split, 4010 chars",8847
-220,"STR split, 12000 uchars",27293
-221,"STR split iter, 4010 chars",16664
-222,"STR split iter, 12000 uchars",52115
-223,STR append,71
-224,STR append (1KB + 1KB),49
-225,STR append (10KB + 1KB),196
-226,STR append (1MB + 2b * 1000),74635
-227,STR append (1MB + 1KB),61479
-228,STR append (1MB + 1KB * 20),61865
-229,STR append (1MB + 1KB * 1000),101998
-230,STR append (1MB + 1MB * 3),157370
-231,STR append (1MB + 1MB * 5),315407
-232,STR append (1MB + (1b + 1K + 1b) * 100),69167
-233,STR info locals match,993
-234,TRACE no trace set,26
-235,TRACE read,26
-236,TRACE write,26
-237,TRACE unset,26
-238,TRACE all set (rwu),25
-239,UNSET var exists,9
-240,UNSET catch var exists,10
-241,UNSET catch var !exist,59
-242,UNSET info check var exists,13
-243,UNSET info check var !exist,11
-244,UNSET nocomplain var exists,10
-245,UNSET nocomplain var !exist,59
-246,VAR access locally set,10
-247,VAR access local proc arg,10
-248,VAR access global,26
-249,VAR access upvar,30
-250,VAR set scalar,7
-251,VAR set array element,14
-252,VAR 100 'set's in array,160
-253,VAR 'array set' of 100 elems,264
DELETED examples/csv/Benchmark.833.csv
Index: examples/csv/Benchmark.833.csv
==================================================================
--- examples/csv/Benchmark.833.csv
+++ /dev/null
@@ -1,254 +0,0 @@
-000,VERSIONS:,1:8.3.3
-001,CATCH return ok,6
-002,CATCH return error,64
-003,CATCH no catch used,6
-004,IF if true numeric,11
-005,IF elseif true numeric,15
-006,IF else true numeric,15
-007,IF if true num/num,12
-008,IF if false num/num,12
-009,IF if false al/num,20
-010,IF if true al/al,26
-011,IF if false al/al,25
-012,IF if true al,25
-013,IF elseif true al,39
-014,IF else true al,40
-015,SWITCH first true,42
-016,SWITCH second true,39
-017,SWITCH ninth true,44
-018,SWITCH default true,38
-019,DATA create in a list,4083
-020,DATA create in an array,4916
-021,DATA access in a list,3546
-022,DATA access in an array,3223
-023,EVAL cmd eval in list obj var,22
-024,EVAL cmd eval as list,21
-025,EVAL cmd eval as string,50
-026,EVAL cmd and mixed lists,3546
-027,EVAL list cmd and mixed lists,3591
-028,EVAL list cmd and pure lists,582
-029,EXPR unbraced,167
-030,EXPR braced,25
-031,EXPR inline,30
-032,EXPR one operand,6
-033,EXPR ten operands,13
-034,EXPR fifty operands,43
-035,EXPR incr with incr,11
-036,EXPR incr with expr,7
-037,FCOPY std: 160010 bytes,10242
-038,FCOPY binary: 160010 bytes,9892
-039,FCOPY encoding: 160010 bytes,9831
-040,KLIST shuffle0 llength 1,127
-041,KLIST shuffle0 llength 10,413
-042,KLIST shuffle0 llength 100,3552
-043,KLIST shuffle0 llength 1000,41766
-044,KLIST shuffle0 llength 10000,533804
-045,KLIST shuffle1 llength 1,85
-046,KLIST shuffle1 llength 10,333
-047,KLIST shuffle1 llength 100,5238
-048,KLIST shuffle1 llength 1000,1194146
-049,KLIST shuffle1a llength 1,100
-050,KLIST shuffle1a llength 10,368
-051,KLIST shuffle1a llength 100,3625
-052,KLIST shuffle1a llength 1000,37340
-053,KLIST shuffle1a llength 10000,380522
-054,KLIST shuffle2 llength 1,99
-055,KLIST shuffle2 llength 10,375
-056,KLIST shuffle2 llength 100,3625
-057,KLIST shuffle2 llength 1000,37028
-058,KLIST shuffle2 llength 10000,433771
-059,KLIST shuffle3 llength 1,98
-060,KLIST shuffle3 llength 10,335
-061,KLIST shuffle3 llength 100,2883
-062,KLIST shuffle3 llength 1000,33237
-063,KLIST shuffle3 llength 10000,777699
-064,KLIST shuffle4 llength 1,102
-065,KLIST shuffle4 llength 10,374
-066,KLIST shuffle4 llength 100,3250
-067,KLIST shuffle4 llength 1000,32119
-068,KLIST shuffle4 llength 10000,330472
-069,"STR/LIST length, obj shimmer",2767
-070,"LIST length, pure list",13
-071,STR length of a LIST,12
-072,"LIST exact search, first item",11
-073,"LIST exact search, middle item",25
-074,"LIST exact search, last item",48
-075,"LIST exact search, non-item",110
-076,"LIST sorted search, first item",12
-077,"LIST sorted search, middle item",26
-078,"LIST sorted search, last item",52
-079,"LIST sorted search, non-item",111
-080,"LIST exact search, untyped item",47
-081,"LIST exact search, typed item",48
-082,"LIST sorted search, typed item",46
-083,LIST sort,3578
-084,LIST typed sort,2943
-085,LIST remove first element,296
-086,LIST remove middle element,291
-087,LIST remove last element,293
-088,LIST replace first element,289
-089,LIST replace middle element,286
-090,LIST replace last element,283
-091,LIST replace first el with multiple,304
-092,LIST replace middle el with multiple,310
-093,LIST replace last el with multiple,282
-094,LIST replace range,282
-095,LIST remove in mixed list,374
-096,LIST replace in mixed list,352
-097,LIST index first element,10
-098,LIST index middle element,10
-099,LIST index last element,11
-100,LIST insert an item at start,298
-101,LIST insert an item at middle,266
-102,"LIST insert an item at ""end""",254
-103,"LIST small, early range",19
-104,"LIST small, late range",18
-105,"LIST large, early range",29
-106,"LIST large, late range",30
-107,LIST append to list,401
-108,LIST join list,1072
-109,"LOOP for, iterate list",5198
-110,"LOOP foreach, iterate list",1845
-111,LOOP for (to 1000),2674
-112,LOOP while (to 1000),2942
-113,"LOOP for, iterate string",9440
-114,"LOOP foreach, iterate string",2249
-115,MAP string 1 val,5931
-116,MAP string 2 val,6643
-117,MAP string 3 val,7673
-118,MAP string 4 val,8429
-119,MAP string 1 val -nocase,10259
-120,MAP string 2 val -nocase,14570
-121,MAP string 3 val -nocase,19344
-122,MAP string 4 val -nocase,21861
-123,MAP regsub 1 val,3954
-124,MAP regsub 2 val,16981
-125,MAP regsub 3 val,23258
-126,MAP regsub 4 val,29335
-127,MAP regsub 1 val -nocase,3913
-128,MAP regsub 2 val -nocase,17024
-129,MAP regsub 3 val -nocase,23228
-130,MAP regsub 4 val -nocase,29397
-131,"MAP string, no match",7712
-132,"MAP string -nocase, no match",18725
-133,"MAP regsub, no match",2764
-134,"MAP regsub -nocase, no match",2785
-135,MAP string short,41
-136,MAP regsub short,180
-137,MTHD direct ns proc call,6
-138,MTHD imported ns proc call,6
-139,MTHD interp alias proc call,18
-140,MTHD indirect proc eval,29
-141,MTHD indirect proc eval #2,48
-142,MTHD array stored proc call,9
-143,MTHD switch method call,38
-144,MTHD ns lookup call,81
-145,MTHD inline call,3
-146,PROC explicit return,7
-147,PROC implicit return,6
-148,PROC explicit return (2),7
-149,PROC implicit return (2),6
-150,PROC explicit return (3),7
-151,PROC implicit return (3),6
-152,PROC heavily commented,5
-153,"PROC do-nothing, no args",5
-154,"PROC do-nothing, one arg",5
-155,PROC local links with global,1569
-156,PROC local links with upvar,1166
-157,PROC local links with variable,1101
-158,"READ 595K, gets",299797
-159,"READ 595K, read",97698
-160,"READ 595K, read & size",97909
-161,"READ 3050b, gets",1641
-162,"READ 3050b, read",494
-163,"READ 3050b, read & size",534
-164,"BREAD 595K, gets",292326
-165,"BREAD 595K, read",50454
-166,"BREAD 595K, read & size",50486
-167,"BREAD 3050b, gets",1777
-168,"BREAD 3050b, read",347
-169,"BREAD 3050b, read & size",389
-170,REGEXP literal regexp,37
-171,REGEXP var-based regexp,40
-172,REGEXP count all matches,139
-173,REGEXP extract all matches,177
-174,STARTUP time to launch tclsh,20425
-175,STR str [string compare],26
-176,STR str [string equal],25
-177,"STR str $a equal """"",26
-178,"STR str num == """"",14
-179,STR str $a eq $b,33
-180,STR str $a ne $b,31
-181,STR str $a eq $b (same obj),33
-182,STR str $a ne $b (same obj),33
-183,STR length (==4010),14
-184,STR index 0,19
-185,STR index 100,24
-186,STR index 500,18
-187,STR index2 0,19
-188,STR index2 100,19
-189,STR index2 500,19
-190,STR first (success),16
-191,STR first (failure),56
-192,STR first (total failure),42
-193,STR last (success),229
-194,STR last (failure),99
-195,STR last (total failure),90
-196,"STR match, simple (success early)",14
-197,"STR match, simple (success late)",14
-198,"STR match, simple (failure)",15
-199,"STR match, simple (total failure)",18
-200,"STR match, complex (success early)",23
-201,"STR match, complex (success late)",1020
-202,"STR match, complex (failure)",1011
-203,"STR match, complex (total failure)",994
-204,"STR range, index 100..200 of 4010",21
-205,"STR replace, no replacement",270
-206,"STR replace, equal replacement",277
-207,"STR replace, longer replacement",270
-208,"STR repeat, abcdefghij * 10",22
-209,"STR repeat, abcdefghij * 100",72
-210,"STR repeat, abcdefghij * 1000",565
-211,"STR repeat, 4010 chars * 10",797
-212,"STR repeat, 4010 chars * 100",18287
-213,"STR reverse iter1, 100 chars",1628
-214,"STR reverse iter1, 100 uchars",1768
-215,"STR reverse iter2, 100 chars",1252
-216,"STR reverse iter2, 100 uchars",1259
-217,"STR reverse recur1, 100 chars",4770
-218,"STR reverse recur1, 100 uchars",5467
-219,"STR split, 4010 chars",2138
-220,"STR split, 12100 uchars",6395
-221,"STR split iter, 4010 chars",9372
-222,"STR split iter, 12100 uchars",28299
-223,STR append,82
-224,STR append (1KB + 1KB),55
-225,STR append (10KB + 1KB),193
-226,STR append (1MB + 2b * 1000),70498
-227,STR append (1MB + 1KB),63374
-228,STR append (1MB + 1KB * 20),64566
-229,STR append (1MB + 1KB * 1000),94413
-230,STR append (1MB + 1MB * 3),153051
-231,STR append (1MB + 1MB * 5),303871
-232,STR append (1MB + (1b + 1K + 1b) * 100),63834
-233,STR info locals match,818
-234,TRACE no trace set,25
-235,TRACE read,26
-236,TRACE write,25
-237,TRACE unset,26
-238,TRACE all set (rwu),25
-239,UNSET var exists,8
-240,UNSET catch var exists,9
-241,UNSET catch var !exist,64
-242,UNSET info check var exists,14
-243,UNSET info check var !exist,11
-244,UNSET nocomplain var exists,9
-245,UNSET nocomplain var !exist,64
-246,VAR access locally set,8
-247,VAR access local proc arg,9
-248,VAR access global,25
-249,VAR access upvar,29
-250,VAR set scalar,6
-251,VAR set array element,12
-252,VAR 100 'set's in array,133
-253,VAR 'array set' of 100 elems,251
DELETED examples/csv/Benchmark.84a3.csv
Index: examples/csv/Benchmark.84a3.csv
==================================================================
--- examples/csv/Benchmark.84a3.csv
+++ /dev/null
@@ -1,254 +0,0 @@
-000,VERSIONS:,1:8.4a3
-001,CATCH return ok,11
-002,CATCH return error,70
-003,CATCH no catch used,10
-004,IF if true numeric,17
-005,IF elseif true numeric,20
-006,IF else true numeric,20
-007,IF if true num/num,17
-008,IF if false num/num,17
-009,IF if false al/num,27
-010,IF if true al/al,31
-011,IF if false al/al,31
-012,IF if true al,32
-013,IF elseif true al,47
-014,IF else true al,46
-015,SWITCH first true,63
-016,SWITCH second true,58
-017,SWITCH ninth true,67
-018,SWITCH default true,62
-019,DATA create in a list,4883
-020,DATA create in an array,5388
-021,DATA access in a list,4028
-022,DATA access in an array,3507
-023,EVAL cmd eval in list obj var,26
-024,EVAL cmd eval as list,24
-025,EVAL cmd eval as string,60
-026,EVAL cmd and mixed lists,3347
-027,EVAL list cmd and mixed lists,3403
-028,EVAL list cmd and pure lists,543
-029,EXPR unbraced,153
-030,EXPR braced,29
-031,EXPR inline,31
-032,EXPR one operand,11
-033,EXPR ten operands,18
-034,EXPR fifty operands,48
-035,EXPR incr with incr,16
-036,EXPR incr with expr,11
-037,FCOPY std: 160010 bytes,10069
-038,FCOPY binary: 160010 bytes,9932
-039,FCOPY encoding: 160010 bytes,9818
-040,KLIST shuffle0 llength 1,144
-041,KLIST shuffle0 llength 10,457
-042,KLIST shuffle0 llength 100,3986
-043,KLIST shuffle0 llength 1000,44083
-044,KLIST shuffle0 llength 10000,563245
-045,KLIST shuffle1 llength 1,84
-046,KLIST shuffle1 llength 10,358
-047,KLIST shuffle1 llength 100,6374
-048,KLIST shuffle1 llength 1000,1190696
-049,KLIST shuffle1a llength 1,110
-050,KLIST shuffle1a llength 10,474
-051,KLIST shuffle1a llength 100,4667
-052,KLIST shuffle1a llength 1000,47818
-053,KLIST shuffle1a llength 10000,474513
-054,KLIST shuffle2 llength 1,104
-055,KLIST shuffle2 llength 10,440
-056,KLIST shuffle2 llength 100,3762
-057,KLIST shuffle2 llength 1000,39573
-058,KLIST shuffle2 llength 10000,474558
-059,KLIST shuffle3 llength 1,104
-060,KLIST shuffle3 llength 10,380
-061,KLIST shuffle3 llength 100,3408
-062,KLIST shuffle3 llength 1000,38716
-063,KLIST shuffle3 llength 10000,945771
-064,KLIST shuffle4 llength 1,114
-065,KLIST shuffle4 llength 10,431
-066,KLIST shuffle4 llength 100,3871
-067,KLIST shuffle4 llength 1000,40201
-068,KLIST shuffle4 llength 10000,393369
-069,"STR/LIST length, obj shimmer",2390
-070,"LIST length, pure list",18
-071,STR length of a LIST,15
-072,"LIST exact search, first item",19
-073,"LIST exact search, middle item",69
-074,"LIST exact search, last item",132
-075,"LIST exact search, non-item",314
-076,"LIST sorted search, first item",23
-077,"LIST sorted search, middle item",24
-078,"LIST sorted search, last item",24
-079,"LIST sorted search, non-item",23
-080,"LIST exact search, untyped item",131
-081,"LIST exact search, typed item",128
-082,"LIST sorted search, typed item",19
-083,LIST sort,3299
-084,LIST typed sort,2739
-085,LIST remove first element,317
-086,LIST remove middle element,325
-087,LIST remove last element,318
-088,LIST replace first element,310
-089,LIST replace middle element,316
-090,LIST replace last element,316
-091,LIST replace first el with multiple,333
-092,LIST replace middle el with multiple,319
-093,LIST replace last el with multiple,319
-094,LIST replace range,294
-095,LIST remove in mixed list,389
-096,LIST replace in mixed list,377
-097,LIST index first element,18
-098,LIST index middle element,17
-099,LIST index last element,17
-100,LIST insert an item at start,291
-101,LIST insert an item at middle,269
-102,"LIST insert an item at ""end""",257
-103,"LIST small, early range",23
-104,"LIST small, late range",23
-105,"LIST large, early range",37
-106,"LIST large, late range",40
-107,LIST append to list,409
-108,LIST join list,1053
-109,"LOOP for, iterate list",6616
-110,"LOOP foreach, iterate list",1919
-111,LOOP for (to 1000),2566
-112,LOOP while (to 1000),2568
-113,"LOOP for, iterate string",6456
-114,"LOOP foreach, iterate string",2240
-115,MAP string 1 val,679
-116,MAP string 2 val,1562
-117,MAP string 3 val,1836
-118,MAP string 4 val,2510
-119,MAP string 1 val -nocase,3497
-120,MAP string 2 val -nocase,6218
-121,MAP string 3 val -nocase,8364
-122,MAP string 4 val -nocase,10135
-123,MAP regsub 1 val,3702
-124,MAP regsub 2 val,16066
-125,MAP regsub 3 val,21671
-126,MAP regsub 4 val,26657
-127,MAP regsub 1 val -nocase,3686
-128,MAP regsub 2 val -nocase,15821
-129,MAP regsub 3 val -nocase,20987
-130,MAP regsub 4 val -nocase,26227
-131,"MAP string, no match",926
-132,"MAP string -nocase, no match",6726
-133,"MAP regsub, no match",1149
-134,"MAP regsub -nocase, no match",1151
-135,MAP string short,37
-136,MAP regsub short,164
-137,MTHD direct ns proc call,10
-138,MTHD imported ns proc call,11
-139,MTHD interp alias proc call,25
-140,MTHD indirect proc eval,36
-141,MTHD indirect proc eval #2,58
-142,MTHD array stored proc call,14
-143,MTHD switch method call,50
-144,MTHD ns lookup call,99
-145,MTHD inline call,5
-146,PROC explicit return,15
-147,PROC implicit return,11
-148,PROC explicit return (2),12
-149,PROC implicit return (2),10
-150,PROC explicit return (3),10
-151,PROC implicit return (3),10
-152,PROC heavily commented,10
-153,"PROC do-nothing, no args",8
-154,"PROC do-nothing, one arg",10
-155,PROC local links with global,1579
-156,PROC local links with upvar,1287
-157,PROC local links with variable,1195
-158,"READ 595K, gets",340064
-159,"READ 595K, read",77751
-160,"READ 595K, read & size",77606
-161,"READ 3050b, gets",1869
-162,"READ 3050b, read",522
-163,"READ 3050b, read & size",569
-164,"BREAD 595K, gets",350077
-165,"BREAD 595K, read",50105
-166,"BREAD 595K, read & size",50303
-167,"BREAD 3050b, gets",2097
-168,"BREAD 3050b, read",340
-169,"BREAD 3050b, read & size",396
-170,REGEXP literal regexp,39
-171,REGEXP var-based regexp,41
-172,REGEXP count all matches,137
-173,REGEXP extract all matches,169
-174,STARTUP time to launch tclsh,21138
-175,STR str [string compare],18
-176,STR str [string equal],18
-177,"STR str $a equal """"",17
-178,"STR str num == """"",19
-179,STR str $a eq $b,22
-180,STR str $a ne $b,23
-181,STR str $a eq $b (same obj),22
-182,STR str $a ne $b (same obj),21
-183,STR length (==4010),15
-184,STR index 0,26
-185,STR index 100,21
-186,STR index 500,21
-187,STR index2 0,21
-188,STR index2 100,20
-189,STR index2 500,21
-190,STR first (success),19
-191,STR first (failure),120
-192,STR first (total failure),109
-193,STR last (success),19
-194,STR last (failure),90
-195,STR last (total failure),82
-196,"STR match, simple (success early)",17
-197,"STR match, simple (success late)",16
-198,"STR match, simple (failure)",17
-199,"STR match, simple (total failure)",16
-200,"STR match, complex (success early)",17
-201,"STR match, complex (success late)",145
-202,"STR match, complex (failure)",122
-203,"STR match, complex (total failure)",90
-204,"STR range, index 100..200 of 4010",26
-205,"STR replace, no replacement",79
-206,"STR replace, equal replacement",92
-207,"STR replace, longer replacement",95
-208,"STR repeat, abcdefghij * 10",19
-209,"STR repeat, abcdefghij * 100",39
-210,"STR repeat, abcdefghij * 1000",245
-211,"STR repeat, 4010 chars * 10",314
-212,"STR repeat, 4010 chars * 100",7347
-213,"STR reverse iter1, 100 chars",1285
-214,"STR reverse iter1, 100 uchars",1264
-215,"STR reverse iter2, 100 chars",808
-216,"STR reverse iter2, 100 uchars",807
-217,"STR reverse recur1, 100 chars",4092
-218,"STR reverse recur1, 100 uchars",4169
-219,"STR split, 4010 chars",2663
-220,"STR split, 12100 uchars",7207
-221,"STR split iter, 4010 chars",9349
-222,"STR split iter, 12100 uchars",28171
-223,STR append,100
-224,STR append (1KB + 1KB),65
-225,STR append (10KB + 1KB),186
-226,STR append (1MB + 2b * 1000),37786
-227,STR append (1MB + 1KB),29729
-228,STR append (1MB + 1KB * 20),29635
-229,STR append (1MB + 1KB * 1000),66605
-230,STR append (1MB + 1MB * 3),126103
-231,STR append (1MB + 1MB * 5),157407
-232,STR append (1MB + (1b + 1K + 1b) * 100),33118
-233,STR info locals match,828
-234,TRACE no trace set,35
-235,TRACE read,35
-236,TRACE write,35
-237,TRACE unset,35
-238,TRACE all set (rwu),35
-239,UNSET var exists,14
-240,UNSET catch var exists,16
-241,UNSET catch var !exist,69
-242,UNSET info check var exists,19
-243,UNSET info check var !exist,16
-244,UNSET nocomplain var exists,14
-245,UNSET nocomplain var !exist,14
-246,VAR access locally set,14
-247,VAR access local proc arg,14
-248,VAR access global,34
-249,VAR access upvar,36
-250,VAR set scalar,10
-251,VAR set array element,18
-252,VAR 100 'set's in array,162
-253,VAR 'array set' of 100 elems,293
DELETED examples/csv/README
Index: examples/csv/README
==================================================================
--- examples/csv/README
+++ /dev/null
@@ -1,85 +0,0 @@
-Here are some applications for handling and manipulating CSV files in
-various ways. Provided are:
-=======================================================================
-
-csv2html ?-sep sepchar? ?-title string? file...
-
- Reads CSV data from the files and returns it as a HTML table
- on stdout.
-
-=======================================================================
-
-csvsort ?-sep sepchar? ?-f? ?-n? ?-r? ?-skip cnt? column file.in|- file.out|-
-
- Like "sort", but for CSV files. Sorts after the specified
- column. Input and output are from and to a file or stdin
- and stdout (Any combination is possible).
-
- Options:
-
- -sep specifies the separator character used in the input file.
- Default is comma.
-
- -n If specified integer sorting is used.
- -f If specified floating point sorting is used.
- (-n and -f exclude each other. If both are used the
- last option decides the mode).
-
- -r If specified reverse sorting is used (largest first)
-
- -skip If specified that number of rows is skipped at the beginning,
- i.e. excluded from sorting. This is to allow sorting of
- CSV files with header lines.
-
-=======================================================================
-
-csvcut ?-sep sepchar? LIST file...
-
- Like "cut", but for CSV files. Print selected parts of CSV
- records from each FILE to standard output.
-
- LIST is a comma separated list of column specifications. The
- allowed forms are:
-
- N numeric specification of single column
- N-M range specification, both parts numberic,
- N < M required.
- -M See N-M, N defaults to 0.
- N- See N-M, M defaults to last column
-
- If there are no files or file = "-" read from stdin.
-
-=======================================================================
-
-csvuniq ?-sep sepchar? column file.in|- file.out|-
-
- Like "uniq", but for CSV files. Uniq's the specified column.
- Writes the first record it encounters for a value. Input and
- output are from and to a file or stdin and stdout (Any
- combination is possible).
-
- Options:
-
- -sep specifies the separator character used in the input file.
- Default is comma.
-
-=======================================================================
-
-csvjoin ?-sep sepchar? ?-outer? keycol1 file1.in keycol2 file2.in file.out|-
-
- Joins the two CSV inputtables using the specified columns as
- keys to compare and associate. The result will contain all
- columns from both files with the exception of the second key
- column (the result needs only one key column, the other is
- identical by definition and therefore superfluous).
-
- Options:
-
- -sep specifies the separator character used in the input file.
- Default is comma.
-
- -outer Flag, perform outer join. Means that if the key is
- missing in file2 a record is nevertheless written,
- extended with empty values.
-
-=======================================================================
DELETED examples/csv/bench_join
Index: examples/csv/bench_join
==================================================================
--- examples/csv/bench_join
+++ /dev/null
@@ -1,11 +0,0 @@
-
-./csvcut '1-' Benchmark.833.csv > tmp.csv ; ./csvjoin -outer 1 Benchmark.84a3.csv 0 tmp.csv tmp1.csv
-./csvcut '1-' Benchmark.823.csv > tmp.csv ; ./csvjoin -outer 1 tmp1.csv 0 tmp.csv tmp2.csv
-./csvcut '1-' Benchmark.811.csv > tmp.csv ; ./csvjoin -outer 1 tmp2.csv 0 tmp.csv tmp1.csv
-./csvcut '1-' Benchmark.805.csv > tmp.csv ; ./csvjoin -outer 1 tmp1.csv 0 tmp.csv tmp2.csv
-./csvcut '1-' Benchmark.76p2.csv > tmp.csv ; ./csvjoin -outer 1 tmp2.csv 0 tmp.csv tmp1.csv
-./csvcut '1-' Benchmark.75p2.csv > tmp.csv ; ./csvjoin -outer 1 tmp1.csv 0 tmp.csv Bench.csv
-
-rm -f tmp.csv tmp1.csv tmp2.csv
-
-./csv2html -title 'Core Benchmark Results' Bench.csv > Bench.html
DELETED examples/csv/csv2html
Index: examples/csv/csv2html
==================================================================
--- examples/csv/csv2html
+++ /dev/null
@@ -1,105 +0,0 @@
-#!/bin/sh
-# use -*- tcl -*- \
-exec tclsh "$0" "$@"
-# Generate HTML table from CSV data
-
-package require csv
-package require cmdline
-package require report
-package require struct
-
-# ----------------------------------------------------
-# csv2html ?-sep sepchar? file...
-#
-# Argument processing and checks.
-
-set sepChar ,
-set title "Title"
-set usage "Usage: $argv0 ?-sep sepchar? ?-title string? file..."
-
-while {[set ok [cmdline::getopt argv {sep.arg title.arg} opt val]] > 0} {
- #puts stderr "= $opt $val"
- switch -exact -- $opt {
- sep {set sepChar $val}
- title {set title $val}
- }
-}
-if {($ok < 0) || ([llength $argv] < 1)} {
- #puts stderr "A >>$ok<< >>[llength $argv]<<"
- puts stderr $usage
- exit -1
-}
-
-set files $argv
-
-if {[llength $files] == 0} {
- set files -
-}
-
-# ----------------------------------------------------
-# Actual processing, uses the following information from the
-# commandline:
-#
-# files - name of the files to read
-# indices - preprocessed indices
-# sepChar - separator character
-
-::report::defstyle html {} {
- set c [columns]
- set cl $c ; incr cl -1
- data set "
[split [string repeat " " $cl] ""]
"
- for {set col 0} {$col < $c} {incr col} {
- pad $col left "
"
- pad $col right "
"
- }
- return
-}
-
-set stdin 1
-set first 1
-
-struct::matrix::matrix m
-
-foreach f $files {
- if {![string compare $f -]} {
- if {!$stdin} {
- puts stderr "Cannot use - (stdin) more than once"
- exit -1
- }
- set in stdin
- set stdin 0
- } else {
- set in [open $f r]
- }
-
- if {$first} {
- set first 0
- if {[gets $in line] < 0} {
- continue
- }
- set data [::csv::split $line $sepChar]
-
- m add columns [llength $data]
- m add row $data
- }
-
- csv::read2matrix $in m $sepChar
-
- if {[string compare $f -]} {
- close $in
- }
-}
-
-# And writing the accumulated results
-
-report::report r [m columns] style html
-
-puts stdout "$title"
-puts stdout "
$title
"
-puts stdout "
"
-r printmatrix2channel m stdout
-#m format 2chan r stdout
-puts stdout "
"
-r destroy
-
-exit
DELETED examples/csv/csvcut
Index: examples/csv/csvcut
==================================================================
--- examples/csv/csvcut
+++ /dev/null
@@ -1,105 +0,0 @@
-#!/bin/sh
-# use -*- tcl -*- \
-exec tclsh "$0" "$@"
-# Cut and reorder fields in a CSV file.
-
-package require csv
-package require cmdline
-
-# ----------------------------------------------------
-# csvcut ?-sep sepchar? LIST file...
-#
-# Argument processing and checks.
-
-set sepChar ,
-set usage "Usage: $argv0 ?-sep sepchar? LIST file...\n\tLIST=idx,...\n\tidx in \{n, -m, n-, n-m\}"
-
-while {[set ok [cmdline::getopt argv {sep.arg} opt val]] > 0} {
- #puts stderr "= $opt $val"
- switch -exact -- $opt {
- sep {set sepChar $val}
- }
-}
-if {($ok < 0) || ([llength $argv] < 2)} {
- #puts stderr "A >>$ok<< >>[llength $argv]<<"
- puts stderr $usage
- exit -1
-}
-
-set indices [split [lindex $argv 0] ,]
-set files [lrange $argv 1 end]
-
-if {[llength $indices] == 0} {
- #puts stderr >>$indices<<
- #puts stderr B
- puts stderr $usage
- exit -1
-}
-
-set idx [list]
-foreach i $indices {
- if {[regexp -- {[0-9]+-[0-9]+} $i]} {
- foreach {f t} [split $i -] break
- lappend idx [list $f $t]
- } elseif {[regexp -- {[0-9]+-} $i]} {
- foreach {f t} [split $i -] break
- lappend idx [list $f end]
- } elseif {[regexp -- {-[0-9]+} $i]} {
- foreach {f t} [split $i -] break
- lappend idx [list 0 $t]
- } elseif {[regexp -- {[0-9]+} $i]} {
- lappend idx [list $i $i]
- } else {
- #puts stderr >>$idx<<
- #puts stderr C
- puts stderr $usage
- exit -1
- }
-}
-set indices $idx
-
-if {[llength $files] == 0} {
- set files -
-}
-
-# ----------------------------------------------------
-# Actual processing, uses the following information from the
-# commandline:
-#
-# files - name of the files to read
-# indices - preprocessed indices
-# sepChar - separator character
-
-set stdin 1
-foreach f $files {
- if {![string compare $f -]} {
- if {!$stdin} {
- puts stderr "Cannot use - (stdin) more than once"
- exit -1
- }
- set in stdin
- set stdin 0
- } else {
- set in [open $f r]
- }
-
- while {![eof $in]} {
- if {[gets $in line] < 0} {
- continue
- }
- set data [::csv::split $line $sepChar]
-
- set dataOut [list]
-
- foreach i $indices {
- foreach {f t} $i break
- eval lappend dataOut [lrange $data $f $t]
- }
- puts stdout [::csv::join $dataOut $sepChar]
- }
- if {[string compare $f -]} {
- close $in
- }
-}
-
-exit
DELETED examples/csv/csvdiff
Index: examples/csv/csvdiff
==================================================================
--- examples/csv/csvdiff
+++ /dev/null
@@ -1,163 +0,0 @@
-#!/bin/sh
-# use -*- tcl -*- \
-exec tclsh "$0" "$@"
-# Perform a diff on two CSV files.
-# The result is a CSV file
-
-package require csv
-package require cmdline
-
-# ----------------------------------------------------
-# csvdiff ?-sep sepchar? ?-key LIST? file1 file2
-#
-# Argument processing and checks.
-
-set sepChar ,
-set usage "Usage: $argv0 ?-n? ?-sep sepchar? ?-key LIST? file1 file2\n\tLIST=idx,...\n\tidx in \{n, -m, n-, n-m\}"
-set keySpec "0-"
-
-# lineout = boolean flag, indicates if linenumbers has to be written
-# as part of the output (1) or not (0). Defaults to 0.
-
-set lineout 0
-while {[set ok [cmdline::getopt argv {sep.arg key.arg n} opt val]] > 0} {
- #puts stderr "= $opt $val"
- switch -exact -- $opt {
- sep {set sepChar $val}
- key {set keySpec $val}
- n {set lineout 1}
- }
-}
-if {($ok < 0) || ([llength $argv] != 2)} {
- puts stderr $usage
- exit -1
-}
-
-foreach {fileA fileB} $argv break
-
-
-if {[llength $keySpec] == 0} {
- #puts stderr >>$keySpec<<
- #puts stderr B
- puts stderr $usage
- exit -1
-}
-
-set idx [list]
-foreach i $keySpec {
- if {[regexp -- {[0-9]+-[0-9]+} $i]} {
- foreach {f t} [split $i -] break
- lappend idx [list $f $t]
- } elseif {[regexp -- {[0-9]+-} $i]} {
- foreach {f t} [split $i -] break
- lappend idx [list $f end]
- } elseif {[regexp -- {-[0-9]+} $i]} {
- foreach {f t} [split $i -] break
- lappend idx [list 0 $t]
- } elseif {[regexp -- {[0-9]+} $i]} {
- lappend idx [list $i $i]
- } else {
- #puts stderr >>$idx<<
- #puts stderr C
- puts stderr $usage
- exit -1
- }
-}
-set keySpec $idx
-
-
-set inA [open $fileA r]
-set inB [open $fileB r]
-
-# ----------------------------------------------------
-# Actual processing, uses the following information from the
-# commandline:
-#
-# inA - channel for input A
-# inB - channel for input B
-# sepChar - separator character
-
-# We read file2 completely and then go through the records of
-# file1. For any record we don't find we write a "deleted" record. If
-# we find the matching record we remove it from the internal
-# storage. In a second sweep through the internal array we write
-# "added" records for the remaining data as that was not in file1 but
-# is in file2.
-
-proc keyof {data} {
- global keySpec
- set key [list]
- foreach i $keySpec {
- foreach {f t} $i break
- eval lappend key [lrange $data $f $t]
- }
- return $key
-}
-
-
-
-set order [list]
-array set map {}
-set linenum 0
-while {![eof $inB]} {
- if {[gets $inB line] < 0} {
- continue
- }
- incr linenum
- set data [::csv::split $line $sepChar]
- set key [keyof $data]
-
- if {[info exist map($key)]} {
- puts stderr "warning: $key occurs multiple times in $fileB (lines $linenum and $map($key))"
- }
- set map($key) $linenum
- lappend order $data
-}
-close $inB
-
-set linenum 0
-
-if {$lineout} {
- array set lmap {}
-}
-
-while {![eof $inA]} {
- if {[gets $inA line] < 0} {
- continue
- }
- incr linenum
- set data [::csv::split $line $sepChar]
- set key [keyof $data]
-
- if {$lineout} {set lmap($key) $linenum}
-
- if {[info exists map($key)]} {
- if {$map($key) < 0} {
- puts stderr "warning: $key occurs multiple times\
- in $fileA (lines $linenum and [expr {-$map($key)}]"
- } else {
- set map($key) [expr {-$linenum}]
- }
- continue
- }
-
- if {$lineout} {
- puts stdout [::csv::join [linsert $data 0 - $linenum] $sepChar]
- } else {
- puts stdout [::csv::join [linsert $data 0 -] $sepChar]
- }
-}
-close $inA
-
-foreach data $order {
- set key [keyof $data]
- if {$map($key) > 0} {
- if {$lineout} {
- puts stdout [::csv::join [linsert $data 0 + $lmap($key)] $sepChar]
- } else {
- puts stdout [::csv::join [linsert $data 0 +] $sepChar]
- }
- }
-}
-
-exit
DELETED examples/csv/csvjoin
Index: examples/csv/csvjoin
==================================================================
--- examples/csv/csvjoin
+++ /dev/null
@@ -1,122 +0,0 @@
-#!/bin/sh
-# use -*- tcl -*- \
-exec tclsh "$0" "$@"
-# Join two CSV files by key
-
-package require csv
-package require cmdline
-
-# ----------------------------------------------------
-# csvuniq ?-sep sepchar? keycol1 file1.in keycol2 file2.in file.out|-
-#
-# Argument processing and checks.
-
-set sepChar ,
-set outer 0
-
-set usage "Usage: $argv0 ?-sep sepchar? ?-outer? key1 file1.in key2 file2.in file.out|-"
-
-while {[set ok [cmdline::getopt argv {sep.arg outer} opt val]] > 0} {
- #puts stderr "= $opt $val"
- switch -exact -- $opt {
- sep {set sepChar $val}
- outer {set outer 1}
- }
-}
-if {($ok < 0) || ([llength $argv] != 5)} {
- puts stderr $usage
- exit -1
-}
-
-foreach {keyA inA keyB inB out} $argv break
-
-if {
- ![string is integer $keyA] ||
- ($keyA < 0) ||
- ![string is integer $keyB] ||
- ($keyB < 0) ||
- ![string compare $inA ""] ||
- ![string compare $inB ""] ||
- ![string compare $out ""]
-} {
- puts stderr $usage
- exit -1
-}
-
-if {![string compare $out -]} {
- set out stdout
-} else {
- set out [open $out w]
-}
-
-set inA [open $inA r]
-set inB [open $inB r]
-
-# ----------------------------------------------------
-# Actual processing, uses the following information from the
-# commandline:
-#
-# inA - channel for input A
-# inB - channel for input B
-# out - channel for output
-# sepChar - separator character
-# keyA - key column in A
-# keyB - key column in B
-
-# 1. Read input B completely into an array indexed by the contents of
-# the key column. Store only the non-key information of input
-# B. Note that B may contain several lines having the same key.
-#
-# 2. Read input A line by line and match its key information against
-# the array. If there is no match ignore the record, else join the
-# record with all records from the array and write the resulting
-# records into the output.
-
-set bwidth 0
-
-array set map {}
-while {![eof $inB]} {
- if {[gets $inB line] < 0} {
- continue
- }
-
- set data [::csv::split $line $sepChar]
- set key [lindex $data $keyB]
- set data [lreplace $data $keyB $keyB]
-
- if {[info exists map($key)]} {
- lappend map($key) $data
- } else {
- set map($key) [list $data]
- }
- set bwidth [llength $data]
-}
-close $inB
-
-while {![eof $inA]} {
- if {[gets $inA line] < 0} {
- continue
- }
- set data [::csv::split $line $sepChar]
- set key [lindex $data $keyA]
-
- if {[info exists map($key)]} {
- foreach record $map($key) {
- set res $data
- eval lappend res $record
- puts $out [::csv::join $res $sepChar]
- }
- } elseif {$outer} {
- # Nothing was found, but an outer join was requested too =>
- # append 'bwidth' empty cells to the data and write the new
- # record.
-
- for {set i 0} {$i < $bwidth} {incr i} {
- lappend data {}
- }
-
- puts $out [::csv::join $data $sepChar]
- }
-}
-
-exit ; # automatically closes the channels
DELETED examples/csv/csvsort
Index: examples/csv/csvsort
==================================================================
--- examples/csv/csvsort
+++ /dev/null
@@ -1,95 +0,0 @@
-#!/bin/sh
-# use -*- tcl -*- \
-exec tclsh "$0" "$@"
-# Sort CSV data by a column
-
-package require csv
-package require cmdline
-
-# ----------------------------------------------------
-# csvsort ?-sep sepchar? ?-f? ?-n? ?-r? ?-skip cnt? column file.in|- file.out|-
-#
-# Argument processing and checks.
-
-set sepChar ,
-set sortmode ascii
-set order increasing
-set reverse 0
-set skip 0
-
-set usage "Usage: $argv0 ?-sep sepchar? ?-f? ?-n? ?-r? ?-skip cnt? column file.in|- file.out|-"
-
-while {[set ok [cmdline::getopt argv {sep.arg f n r skip.arg} opt val]] > 0} {
- #puts stderr "= $opt $val"
- switch -exact -- $opt {
- sep {set sepChar $val}
- n {set sortmode integer}
- f {set sortmode real}
- r {set order decreasing}
- skip {set skip $val}
- }
-}
-if {($ok < 0) || ([llength $argv] != 3)} {
- puts stderr $usage
- exit -1
-}
-
-foreach {sortCol in out} $argv break
-
-if {
- ![string is integer $sortCol] ||
- ($sortCol < 0) ||
- ![string compare $in ""] ||
- ![string compare $out ""]
-} {
- puts stderr $usage
- exit -1
-}
-
-if {![string compare $in -]} {
- set in stdin
-} else {
- set in [open $in r]
-}
-if {![string compare $out -]} {
- set out stdout
-} else {
- set out [open $out w]
-}
-
-# ----------------------------------------------------
-# Actual processing, uses the following information from the
-# commandline:
-#
-# in - channel for input
-# out - channel for output
-# sepChar - separator character
-# sortCol - column to sort after
-# sortmode - Sort integer (1) or string (0)
-# reverse - Sort ascending (0) or descending (1)
-# skip - Skip that many lines at the beginning.
-
-set data [list]
-
-while {![eof $in]} {
- if {[gets $in line] < 0} {
- continue
- }
- if {$skip > 0} {
- puts $out $line
- incr skip -1
- continue
- }
- lappend data [::csv::split $line $sepChar]
-}
-
-#puts stderr $sortmode,$order
-
-set data [lsort -index $sortCol -$order -$sortmode $data]
-
-foreach item $data {
- puts $out [::csv::join $item $sepChar]
-}
-
-exit ; # automatically closes the channels
-
DELETED examples/csv/csvuniq
Index: examples/csv/csvuniq
==================================================================
--- examples/csv/csvuniq
+++ /dev/null
@@ -1,81 +0,0 @@
-#!/bin/sh
-# use -*- tcl -*- \
-exec tclsh "$0" "$@"
-# Make CSV data the specified column unique.
-
-package require csv
-package require cmdline
-
-# ----------------------------------------------------
-# csvuniq ?-sep sepchar? column file.in|- file.out|-
-#
-# Argument processing and checks.
-
-set sepChar ,
-
-set usage "Usage: $argv0 ?-sep sepchar? column file.in|- file.out|-"
-
-while {[set ok [cmdline::getopt argv {sep.arg} opt val]] > 0} {
- #puts stderr "= $opt $val"
- switch -exact -- $opt {
- sep {set sepChar $val}
- }
-}
-if {($ok < 0) || ([llength $argv] != 3)} {
- puts stderr $usage
- exit -1
-}
-
-foreach {uniCol in out} $argv break
-
-if {
- ![string is integer $uniCol] ||
- ($uniCol < 0) ||
- ![string compare $in ""] ||
- ![string compare $out ""]
-} {
- puts stderr $usage
- exit -1
-}
-
-if {![string compare $in -]} {
- set in stdin
-} else {
- set in [open $in r]
-}
-if {![string compare $out -]} {
- set out stdout
-} else {
- set out [open $out w]
-}
-
-# ----------------------------------------------------
-# Actual processing, uses the following information from the
-# commandline:
-#
-# in - channel for input
-# out - channel for output
-# sepChar - separator character
-# uniCol - column to make unique
-
-set last ""
-set first 1
-
-while {![eof $in]} {
- if {[gets $in line] < 0} {
- continue
- }
-
- set data [::csv::split $line $sepChar]
-
- if {$first} {
- set first 0
- set last [lindex $data $uniCol]
- puts $out [::csv::join $data $sepChar]
- } elseif {[string compare $last [lindex $data $uniCol]] != 0} {
- set last [lindex $data $uniCol]
- puts $out [::csv::join $data $sepChar]
- } ; # else {no change in column, ignore record}
-}
-
-exit ; # automatically closes the channels
DELETED examples/dns/tk_sample.tcl
Index: examples/dns/tk_sample.tcl
==================================================================
--- examples/dns/tk_sample.tcl
+++ /dev/null
@@ -1,88 +0,0 @@
-# tk-sample.tcl - Copyright (C) 2002 Pat Thoyts
-#
-# Derived from Neil Madden's browser sig :)
-#
-# Note that this doesn't work for sites using virtual hosting and is dubious for
-# multi-homed sites too. This is only to illustrate the resolver usage. What we
-# should be doing is connecting a socket to the resolved address and then requesting
-# the original URL. Useless if there is a proxy between you as well.
-#
-# $Id: tk_sample.tcl,v 1.1 2002/03/02 01:54:21 patthoyts Exp $
-
-package require Tkhtml
-package require http
-package require dns
-
-set Sample(URL) http://mini.net/tcl/976.html
-set Sample(nameserver) localhost
-
-# Description:
-# Construct a simple web browser interface.
-#
-proc gui {} {
- frame .f -bd 0 -relief flat
- label .f.l1 -text "Nameserver" -underline 0
- entry .f.e1 -textvariable ::Sample(nameserver)
- label .f.l2 -text "URL" -underline 0
- entry .f.e2 -textvariable ::Sample(URL)
- button .f.b -text Go -underline 0 -command {get $::Sample(URL)}
- button .f.x -text Exit -underline 1 -command {bye}
-
- scrollbar .v -orient v -command {.h yv}
- html .h -yscrollcommand {.v set}
-
- pack .f.l1 -side left -fill y
- pack .f.e1 -side left -fill both -expand 1
- pack .f.x -side right -fill y
- pack .f.b -side right -fill y
- pack .f.l2 -side left -fill y
- pack .f.e2 -side right -fill both -expand 1
-
- pack .f -side top -fill x
- pack .v -side right -fill y
- pack .h -fill both -expand 1
-
- bind .h.x <1> {eval get [.h href %x %y]}
-}
-
-proc bye {} {
- destroy .f .v .h
-}
-
-proc bgerror {args} {
-}
-
-# Description:
-# Rewrite the URL by looking up the domain name and replacing with the
-# IP address.
-#
-proc resolve {url} {
- global Sample
- if {![catch {array set URL [uri::split $url]} msg]} {
- set tok [dns::resolve $URL(host) -server $Sample(nameserver)]
- if {[dns::status $tok] == "ok"} {
- set URL(host) [dns::address $tok]
- set url [eval uri::join [array get URL]]
- }
- dns::cleanup $tok
- }
- log::log debug "resolved to $url"
- return $url
-}
-
-# Description:
-# Fetch an HTTP URL and display.
-#
-proc get {url} {
- global Sample
- set url [resolve $url]
- set Sample(URL) $url
- set tok [http::geturl $url -headers $::auth]
- .h clear
- .h parse [http::data $tok]
- http::cleanup $tok
- .h configure -base $url
-}
-
-gui
-get $::Sample(URL)
DELETED examples/doctools/doctools.idx
Index: examples/doctools/doctools.idx
==================================================================
--- examples/doctools/doctools.idx
+++ /dev/null
@@ -1,81 +0,0 @@
-[index_begin tcllib/doctools {Documentation tools}]
- [key HTML]
- [manpage didxengine {docidx engine}]
- [manpage didxformat {docidx format}]
- [manpage doctools {doctools package}]
- [manpage dtformat {doctools format}]
- [manpage dtformatter {doctools formatter}]
- [manpage dtocengine {doctoc engine}]
- [manpage dtocformat {doctoc format}]
- [manpage mpexpand mpexpand]
- [key TMML]
- [manpage didxengine {docidx engine}]
- [manpage didxformat {docidx format}]
- [manpage doctools {doctools package}]
- [manpage dtformat {doctools format}]
- [manpage dtformatter {doctools formatter}]
- [manpage dtocengine {doctoc engine}]
- [manpage dtocformat {doctoc format}]
- [manpage mpexpand mpexpand]
- [key conversion]
- [manpage didxengine {docidx engine}]
- [manpage didxformat {docidx format}]
- [manpage doctools {doctools package}]
- [manpage dtformat {doctools format}]
- [manpage dtformatter {doctools formatter}]
- [manpage dtocengine {doctoc engine}]
- [manpage dtocformat {doctoc format}]
- [manpage mpexpand mpexpand]
- [key documentation]
- [manpage doctools {doctools package}]
- [manpage dtformatter {doctools formatter}]
- [key index]
- [manpage didxengine {docidx engine}]
- [manpage didxformat {docidx format}]
- [manpage doctools {doctools package}]
- [manpage dtformat {doctools format}]
- [manpage dtocformat {doctoc format}]
- [key interface]
- [manpage didxengine {docidx engine}]
- [manpage dtformatter {doctools formatter}]
- [manpage dtocengine {doctoc engine}]
- [key manpage]
- [manpage didxengine {docidx engine}]
- [manpage didxformat {docidx format}]
- [manpage doctools {doctools package}]
- [manpage dtformat {doctools format}]
- [manpage dtformatter {doctools formatter}]
- [manpage dtocengine {doctoc engine}]
- [manpage dtocformat {doctoc format}]
- [manpage mpexpand mpexpand]
- [key markup]
- [manpage didxengine {docidx engine}]
- [manpage didxformat {docidx format}]
- [manpage doctools {doctools package}]
- [manpage dtformat {doctools format}]
- [manpage dtformatter {doctools formatter}]
- [manpage dtocengine {doctoc engine}]
- [manpage dtocformat {doctoc format}]
- [manpage mpexpand mpexpand]
- [key nroff]
- [manpage didxengine {docidx engine}]
- [manpage didxformat {docidx format}]
- [manpage doctools {doctools package}]
- [manpage dtformat {doctools format}]
- [manpage dtformatter {doctools formatter}]
- [manpage dtocengine {doctoc engine}]
- [manpage dtocformat {doctoc format}]
- [manpage mpexpand mpexpand]
- [key {table of contents}]
- [manpage didxformat {docidx format}]
- [manpage doctools {doctools package}]
- [manpage dtformat {doctools format}]
- [manpage dtocengine {doctoc engine}]
- [manpage dtocformat {doctoc format}]
- [key toc]
- [manpage didxformat {docidx format}]
- [manpage doctools {doctools package}]
- [manpage dtformat {doctools format}]
- [manpage dtocengine {doctoc engine}]
- [manpage dtocformat {doctoc format}]
-[index_end]
DELETED examples/doctools/doctools.toc
Index: examples/doctools/doctools.toc
==================================================================
--- examples/doctools/doctools.toc
+++ /dev/null
@@ -1,36 +0,0 @@
-[toc_begin tcllib/doctools {Documentation tools}]
-[division_start {Basic format}]
-[item dtformat dtformat {doctools format specification}]
-[item dtformatter dtformatter {doctools engine interface}]
-[item doctools doctools {Package to handle doctools input and engines}]
-[division_end]
-[division_start {Table of Contents}]
-[item dtocformat dtocformat {doctoc format specification}]
-[item dtocformatter dtocformatter {doctoc engine interface}]
-[item doctoc doctoc {Package to handle doctoc input and engines}]
-[division_end]
-[division_start {Indices}]
-[item dtidxformat dtidxformat {docindex format specification}]
-[item dtidxformatter dtidxformatter {docindex engine interface}]
-[item docindex docindex {Package to handle docindex input and engines}]
-[division_end]
-[division_start {Test}]
-[division_start {Test2}]
-[item dtidxformat dtidxformat {docindex format specification}]
-[division_end]
-[division_start {Test3}]
-[item dtidxformatter dtidxformatter {docindex engine interface}]
-[division_end]
-[division_end]
-[division_start {Test}]
-[division_start {Test2}]
-[item AAAAAAA AA AA]
-[division_end]
-[division_start {Test3}]
-[item BBBBBBB BB BB]
-[division_end]
-[division_end]
-[division_start {Test4}]
-[item CCCCCCC CC CC]
-[division_end]
-[toc_end]
DELETED examples/ftp/ChangeLog
Index: examples/ftp/ChangeLog
==================================================================
--- examples/ftp/ChangeLog
+++ /dev/null
@@ -1,4 +0,0 @@
-2002-02-14 Andreas Kupries
-
- * hpupdate.tcl: Frink run.
-
DELETED examples/ftp/README
Index: examples/ftp/README
==================================================================
--- examples/ftp/README
+++ /dev/null
@@ -1,61 +0,0 @@
-=======================
-ftp examples README
-=======================
-
-Example #1 - Directory Mirror (mirror.tcl)
------------------------------
-
-The script mirror.tcl is used to mirror a complete remote directory
-structure. It creates an exact copy of this structure on the locale
-machine. Three parameters needs to be modified to work properly,
-the hostname of the remote server, the username and the password
-for login.
-
-
-Example #2 - Software Update (newer.tcl)
-----------------------------
-
-The script newer.tcl is used to detect whether a new release of
-Brent Welch's phantastic tcl-httpd is present at scriptics ftp
-server. If ftp::Newer detects a newer file then it causes the
-upload process and sends me (as root) an email to inform about.
-The file name for the remote copy of tclhttpd may have changed,
-and the script needs a local copy of tclhttpd's source to do
-the comparison.
-
-Example #3 - Homepage Update (hpupdate.tcl)
-----------------------------
-
-Quite a few people must have to keep permanent updating their
-homepages on a ISP server. hpupdate.tcl is a tk-program for
-the interactive comparsion of the homepage directory on the local
-computer with the same directories on the remote homepage server.
-
-It is based on File Transfer Protocol. This process can be automated
-easily by hpupdate. It makes it quick and easy to keep the track of
-new/old or changed files.
-
-Brief overview:
-
- - FTP connection to remote server
- - Processing subdirectories
- - Display of summary used and selected disk space
- - Automatically all superfluous directories/files of remote
- homepage server will be deleted
- - Automatically all new/updated files will be uploaded
- - Tested under Linux, should also run without problems under
- Windows 95/NT and on Macintosh computers
-
-Example #4 - TkCon command line ftp client
-------------------------------------------
-
-Loading the ftp Library Package into Jeffrey Hobbs' TkCon rovides
-a simple ftp command line utility with command history. TkCon is a
-replacement for the standard console that comes with Tk. It must be
-started with the "package" option:
-
- tkcon -package ftp
-
-to load ftp automatically. TkCon is available at
-
- http://www.purl.org/net/hobbs/tcl/script/tkcon
DELETED examples/ftp/ftpdemo.tcl
Index: examples/ftp/ftpdemo.tcl
==================================================================
--- examples/ftp/ftpdemo.tcl
+++ /dev/null
@@ -1,860 +0,0 @@
-#!/bin/sh
-# the next line restarts using wish \
-exec wish8.3 "$0" "$@"
-#
-# - simple tcl/tk test script for FTP library package -
-#
-# Required: tcl/tk8.3
-#
-# Created: 07/97
-# Changed: 07/00
-# Version: 1.1
-#
-# Copyright (C) 1997,1998 Steffen Traeger
-# EMAIL: Steffen.Traeger@t-online.de
-# URL: http://home.t-online.de/home/Steffen.Traeger
-#
-# This program is free software; you can redistribute it and/or
-# modify it.
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-#
-########################################################################
-
-package require Tcl 8
-package require Tk
-package require ftp 2.0
-
-# set palette under X
-if { [string range [winfo server .] 0 0] == "X" } {
- option add *background LightGray
- tk_setPalette LightGray
- option add *Text.foreground black
- option add *Text.background [option get . selectBackground Listbox]
- option add *Listbox.background [option get . selectBackground Listbox]
- option add *Listbox.selectBackground [option get . insertBackground Listbox]
- option add *Listbox.selectForeground white
- option add *Entry.background [option get . selectBackground Listbox]
- option add *Entry.selectBackground [option get . insertBackground Listbox]
- option add *Entry.selectForeground white
- option add *borderWidth 2
-} else {
- option add *Checkbutton.borderWidth 0
- option add *Radiobutton.borderWidth 0
-
-}
-
-# main window
-wm title . "ftp Test"
-wm iconname . ftptest
-wm minsize . 1 1
-
-# split area
-frame .msg -bd 1 -relief raised
- pack .msg -in . -side top -fill both -expand 1
-frame .op -bd 1 -relief raised
- pack .op -in . -side top -fill x
-frame .but -bd 1 -relief raised
- pack .but -in . -side top -fill both -expand 1
-
-####################################################################
-# Frame 1
-#
-# Options
-frame .op.f -bd 3
- pack .op.f -in .op -side top -fill x
-
-### options
-frame .op.f.f1 -bd 3
- pack .op.f.f1 -in .op.f -side left -fill both
-label .op.f.f1.l -bd 2 -text "Server Options: " -relief flat -anchor w
- pack .op.f.f1.l -in .op.f.f1 -side top -fill x
-
-frame .op.f.f1.server -bd 2
- pack .op.f.f1.server -in .op.f.f1 -side top -fill x -padx 15
-label .op.f.f1.server.l -text "Host: " -width 10 -relief flat -anchor w
- pack .op.f.f1.server.l -in .op.f.f1.server -side left -fill x
-entry .op.f.f1.server.e -width 20
- pack .op.f.f1.server.e -in .op.f.f1.server -side left -fill x
-
-frame .op.f.f1.port -bd 2
- pack .op.f.f1.port -in .op.f.f1 -side top -fill x -padx 15
-label .op.f.f1.port.l -text "Port: " -width 10 -relief flat -anchor w
- pack .op.f.f1.port.l -in .op.f.f1.port -side left -fill x
-entry .op.f.f1.port.e -width 5
- pack .op.f.f1.port.e -in .op.f.f1.port -side left -fill x
-
-frame .op.f.f1.username -bd 2
- pack .op.f.f1.username -in .op.f.f1 -side top -fill x -padx 15
-label .op.f.f1.username.l -text "Username: " -width 10 -relief flat -anchor w
- pack .op.f.f1.username.l -in .op.f.f1.username -side left -fill x
-entry .op.f.f1.username.e -width 10
- pack .op.f.f1.username.e -in .op.f.f1.username -side left -fill x
-
-frame .op.f.f1.password -bd 2
- pack .op.f.f1.password -in .op.f.f1 -side top -fill x -padx 15
-label .op.f.f1.password.l -text "Password: " -width 10 -relief flat -anchor w
- pack .op.f.f1.password.l -in .op.f.f1.password -side left -fill x
-entry .op.f.f1.password.e -width 10 -show "*"
- pack .op.f.f1.password.e -in .op.f.f1.password -side left -fill x
-
-frame .op.f.f1.directory -bd 2
- pack .op.f.f1.directory -in .op.f.f1 -side top -fill x -padx 15
-label .op.f.f1.directory.l -text "Directory: " -width 10 -relief flat -anchor w
- pack .op.f.f1.directory.l -in .op.f.f1.directory -side left -fill x
-entry .op.f.f1.directory.e -width 20
- pack .op.f.f1.directory.e -in .op.f.f1.directory -side left -fill x
-
-# Separator
-frame .op.f.sep1 -bd 1 -relief sunken
- pack .op.f.sep1 -in .op.f -fill y -side left -pady 2 -padx 4
-frame .op.f.sep1.f -bd 1 -relief flat
- pack .op.f.sep1.f -in .op.f.sep1 -fill y -side left
-
-frame .op.f.f2 -bd 3
- pack .op.f.f2 -in .op.f -side left -fill both -ipadx 15
-### transfer mode
-label .op.f.f2.l2 -borderwidth 2 -anchor w -text "Transfer mode:"
- pack .op.f.f2.l2 -in .op.f.f2 -side top -fill x
-radiobutton .op.f.f2.active -anchor w -text "Active" -variable test(mode) -value "active"
- pack .op.f.f2.active -in .op.f.f2 -side top -fill x -padx 15
-radiobutton .op.f.f2.passive -anchor w -text "Passive" -variable test(mode) -value "passive"
- pack .op.f.f2.passive -in .op.f.f2 -side top -fill x -padx 15
-
-####################################################################
-# Frame 2
-#
-### debugging
-label .op.f.f2.l1 -borderwidth 2 -anchor w -text "Debugging:"
- pack .op.f.f2.l1 -in .op.f.f2 -side top -fill x
-checkbutton .op.f.f2.debug -anchor w -text "Debug" -variable ftp::DEBUG
- pack .op.f.f2.debug -in .op.f.f2 -side top -fill x -padx 15
-checkbutton .op.f.f2.verbose -anchor w -text "Verbose" -variable ftp::VERBOSE
- pack .op.f.f2.verbose -in .op.f.f2 -side top -fill x -padx 15
-
-#Iterations
-frame .op.f.f2.loops -bd 2
- pack .op.f.f2.loops -in .op.f.f2 -side top -fill x -pady 2
-label .op.f.f2.loops.l -borderwidth 2 -text "Iterations: " -relief flat -anchor w
- pack .op.f.f2.loops.l -in .op.f.f2.loops -side left -fill x
-entry .op.f.f2.loops.e -borderwidth 2 -width 5
- pack .op.f.f2.loops.e -in .op.f.f2.loops -side left -fill x
-
-# Separator
-frame .op.f.sep2 -bd 1 -relief sunken
- pack .op.f.sep2 -in .op.f -fill y -side left -pady 2 -padx 4
-frame .op.f.sep2.f -bd 1 -relief flat
- pack .op.f.sep2.f -in .op.f.sep2 -fill y -side left
-
-####################################################################
-# Frame 3
-#
-frame .op.f.f3 -bd 3
- pack .op.f.f3 -in .op.f -side left -fill both -expand 1 -ipadx 15
-
-label .op.f.f3.l1 -anchor w -width 10 -text "Variable trace:"
- pack .op.f.f3.l1 -in .op.f.f3 -side top -fill x
-
-frame .op.f.f3.v0 -bd 0
- pack .op.f.f3.v0 -in .op.f.f3 -side top -fill x -pady 2 -padx 15
-label .op.f.f3.v0.name -anchor w -text "iterations = "
- pack .op.f.f3.v0.name -in .op.f.f3.v0 -side left -fill x
-label .op.f.f3.v0.value -anchor w -textvariable test(loop)
- pack .op.f.f3.v0.value -in .op.f.f3.v0 -side top -fill x
-frame .op.f.f3.v1 -bd 0
- pack .op.f.f3.v1 -in .op.f.f3 -side top -fill x -pady 2 -padx 15
-label .op.f.f3.v1.name -anchor w -text "errors = "
- pack .op.f.f3.v1.name -in .op.f.f3.v1 -side left -fill x
-label .op.f.f3.v1.value -anchor w -textvariable test(errors)
- pack .op.f.f3.v1.value -in .op.f.f3.v1 -side top -fill x
-frame .op.f.f3.v2 -bd 0
- pack .op.f.f3.v2 -in .op.f.f3 -side top -fill x -pady 2 -padx 15
-label .op.f.f3.v2.name -anchor w -text "after queues = "
- pack .op.f.f3.v2.name -in .op.f.f3.v2 -side left -fill x
-label .op.f.f3.v2.value -anchor w -textvariable test(after)
- pack .op.f.f3.v2.value -in .op.f.f3.v2 -side top -fill x
-frame .op.f.f3.v4 -bd 0
- pack .op.f.f3.v4 -in .op.f.f3 -side top -fill x -pady 2 -padx 15
-label .op.f.f3.v4.name -anchor w -text "open channels:"
- pack .op.f.f3.v4.name -in .op.f.f3.v4 -side top -fill x
-label .op.f.f3.v4.value -anchor w -textvariable test(open)
- pack .op.f.f3.v4.value -in .op.f.f3.v4 -side top -fill x -padx 8
-
-#####################################################################################
-# Messages
-frame .msg.f -bd 3
- pack .msg.f -in .msg -side top -fill both -expand 1
-
-frame .msg.f.f1 -bd 2 -relief groove
- pack .msg.f.f1 -in .msg.f -side left -fill both -padx 2 -pady 2
-label .msg.f.f1.l -text "Test commands: " -relief flat -anchor w
- pack .msg.f.f1.l -in .msg.f.f1 -side top -fill x -padx 4 -pady 2
-
-### Test commands
-set idlist {}
-foreach {id text} { quote "System Info"\
- list "List" \
- nlist "NList" \
- dir "Cd, MkDir, RmDir" \
- afile "ASCII Put/Get" \
- bfile "Binary Put/Ret" \
- ren "Rename" \
- append "Append" \
- new "Newer" \
- reget "Reget" \
- notfound "file not found"} {
- checkbutton .msg.f.f1.$id -anchor w -text $text -variable test($id)
- pack .msg.f.f1.$id -in .msg.f.f1 -side top -fill x -padx 16
- set test($id) 1
- lappend idlist $id
-}
-button .msg.f.f1.plus -text "+ all" -command "foreach i {$idlist} {set test(\$i) 1}"
- pack .msg.f.f1.plus -in .msg.f.f1 -side left -fill x -padx 16 -pady 8
-button .msg.f.f1.minus -text "- all" -command "foreach i {$idlist} {set test(\$i) 0}"
- pack .msg.f.f1.minus -in .msg.f.f1 -side left -fill x -pady 8
-
-frame .msg.f.f2 -bd 2 -relief groove
- pack .msg.f.f2 -in .msg.f -side left -fill both -pady 2
-
-label .msg.f.f2.label -text "Messages:" -anchor w
- pack .msg.f.f2.label -in .msg.f.f2 -side top -fill x -padx 2
-scrollbar .msg.f.f2.yscroll -command ".msg.f.f2.text yview"
- pack .msg.f.f2.yscroll -in .msg.f.f2 -side right -fill y
-scrollbar .msg.f.f2.xscroll -relief sunken -orient horizontal -command ".msg.f.f2.text xview"
- pack .msg.f.f2.xscroll -in .msg.f.f2 -side bottom -fill x
-text .msg.f.f2.text -relief sunken -setgrid 1 -wrap none -height 20 -width 80 -bg white -fg black\
- -state disabled -xscrollcommand ".msg.f.f2.xscroll set" \
- -yscrollcommand ".msg.f.f2.yscroll set"
- pack .msg.f.f2.text -in .msg.f.f2 -side left -expand 1 -fill both
-.msg.f.f2.text tag configure error -foreground red
-.msg.f.f2.text tag configure data -foreground brown
-.msg.f.f2.text tag configure control -foreground blue
-.msg.f.f2.text tag configure header -foreground white -background black
-
-#####################################################################################
-# Buttons
-frame .but.f -bd 3
- pack .but.f -in .but -side top -fill both -expand 1
-
-frame .but.f.f1 -bd 3
- pack .but.f.f1 -in .but.f -side top -fill x -padx 15 -pady 6
-button .but.f.f1.start -text "Start Test" -width 12 -state normal -command "StartTest"
- pack .but.f.f1.start -side left -fill x -padx 15
-button .but.f.f1.stop -text "Stop Test" -width 12 -state disabled -command "StopTest"
- pack .but.f.f1.stop -side left -fill x -padx 15
-button .but.f.f1.close -text "Quit" -width 12 -state normal -command "destroy ."
- pack .but.f.f1.close -side right -fill x -padx 15
-button .but.f.f1.save -text "Save Options" -width 12 -state normal -command "SaveConfig"
- pack .but.f.f1.save -side right -fill x -padx 15
-
-################ procedures ####################################################################
-
-# overwrite default ftp display message procedure
-namespace eval ftp {
-proc DisplayMsg {s msg {state ""}} {
-global test
- .msg.f.f2.text configure -state normal
-
- # change state from "error" to "" for procedure test_9notfound
- if { ($state == "error") && [info exist test(proc)] && ($test(proc) == "test_99notfound") } {
- set state ""
- }
-
- switch -exact -- $state {
- data {.msg.f.f2.text insert end "$msg\n" data}
- control {.msg.f.f2.text insert end "$msg\n" control}
- error {.msg.f.f2.text insert end "$msg\n" error; incr test(errors)}
- header {.msg.f.f2.text insert end "$msg\n" header}
- default {.msg.f.f2.text insert end "$msg\n"}
- }
- .msg.f.f2.text configure -state disabled
- .msg.f.f2.text see end
- update idletasks
-}}
-
-# new tracing open command
-rename open ftpopen
-proc open {args} {
-global test
- set rc [eval ftpopen $args]
- if {[lsearch -exact $test(open) $rc] == "-1"} {
- lappend test(open) $rc
- }
-#puts "open: $test(open)"
- return $rc
-}
-
-# new tracing close command
-rename close ftpclose
-proc close {args} {
-global test
- set rc [eval ftpclose $args]
- set index [lsearch -exact $test(open) $args]
- if {$index != "-1"} {
- set test(open) [lreplace $test(open) $index $index]
- }
-#puts "close: $test(open)"
- return $rc
-}
-
-# new tracing socket command
-rename socket ftpsocket
-proc socket {args} {
-global test
- set rc [eval ftpsocket $args]
- if {[lsearch -exact $test(open) $rc] == "-1"} {
- lappend test(open) $rc
- }
-#puts "socket: $test(open)"
- return $rc
-}
-
-
-# new tracing InitDataConn command
-namespace eval ftp {
-rename InitDataConn ftpInitDataConn
-proc InitDataConn {args} {
-global test
- set rc [eval ftpInitDataConn $args]
- set s [lindex $args 0]
- if {[lsearch -exact $test(open) $s] == "-1"} {
- lappend test(open) $s
- }
-#puts "InitDataConn: $test(open)"
- return $rc
-}}
-
-# progress bar for put/get operations
-proc ProgressBar {state {bytes 0} {total {}} {filename {}}} {
-global progress
- set w .progress
- switch -exact -- $state {
- init {
- set progress(percent) "0%"
- set progress(total) $total
- set progress(left) 0
- toplevel $w -bd 0 -class Progressbar
- wm transient $w .
- wm title $w Progress
- wm iconname $w Progress
- wm resizable $w 0 0
- focus $w
-
- frame $w.frame -bd 4
- pack $w.frame -side top -fill both
- label $w.frame.label -text "Transfering $filename..." -relief flat -anchor w -bd 1
- pack $w.frame.label -in $w.frame -side top -fill x -padx 10 -pady 5
- frame $w.frame.bar -bd 1 -relief sunken -bg #ffffff
- pack $w.frame.bar -in $w.frame -side left -padx 10 -pady 5
- frame $w.frame.bar.dummy -bd 0 -width 250 -height 0
- pack $w.frame.bar.dummy -in $w.frame.bar -side top -fill x
- frame $w.frame.bar.pbar -bd 0 -width 0 -height 20
- pack $w.frame.bar.pbar -in $w.frame.bar -side left
- label $w.frame.proz -textvariable progress(percent) -width 5 -relief flat -anchor e -bd 1
- pack $w.frame.proz -in $w.frame -side right -padx 10 -pady 5
-
- wm withdraw $w
- update idletasks
- set x [expr {[winfo x .] + ([winfo width .] / 2) - ([winfo reqwidth $w] / 2)}]
- set y [expr {[winfo y .] + ([winfo height .] / 2) - ([winfo reqheight $w] / 2)}]
- wm geometry $w +$x+$y
- update idletasks
- wm deiconify $w
- update idletasks
- }
-
- update {
- if {![winfo exist $w]} {return}
- set cur_width 250
- catch {
- set progress(percent) "[expr {round($bytes) * 100 / $progress(total)}]%";
- set cur_width [expr {round($bytes * 250 / $progress(total))}]
- } msg
- $w.frame.bar.pbar configure -width $cur_width -bg #000080
- update idletasks
- }
-
- done {
- unset progress
- destroy $w
- update
- }
- default {
- error "Unknown state \"$state\""
- }
- }
-}
-
-#
-# 1.) list - returns a long list
-#
-proc test_10list {loop} {
-global test
-
- # check if enabled
- if {!$test(list)} {return}
-
- ftp::DisplayMsg $test(conn) "*** TEST $loop.1 (long directory listing) ***" header
- set remote_list [ftp::List $test(conn)]
- ftp::DisplayMsg $test(conn) "[llength $remote_list] directory lines!"
-}
-
-#
-# 2.) nlist - returns a sorted short list
-#
-proc test_20nlist {loop} {
-global test
-
- # check if enabled
- if {!$test(nlist)} {return}
-
- ftp::DisplayMsg $test(conn) "*** TEST $loop.2 (short directory listing) ***" header
- set remote_list [ftp::NList $test(conn)]
- ftp::DisplayMsg $test(conn) "[llength $remote_list] directory entries!"
-}
-
-
-#
-# 3.) directory commands (cd, mkdir, rmdir)
-# - creates a remote directory foo
-# - changes to this directory
-# - changes back to parent directory
-# - removes a remote directory foo
-#
-proc test_30dir {loop} {
-global test
-
- # check if enabled
- if {!$test(dir)} {return}
- ftp::DisplayMsg $test(conn) "*** TEST $loop.3 (directory commands cd,mkdir,rmdir) ***" header
- ftp::Pwd $test(conn)
- ftp::MkDir $test(conn) foo$test(pid)
- ftp::Cd $test(conn) foo$test(pid)
- ftp::Pwd $test(conn)
- ftp::Cd $test(conn) ..
- ftp::Pwd $test(conn)
- ftp::RmDir $test(conn) foo$test(pid)
-}
-
-#
-# 4.) ascii put/get and delete
-# - go to ascii mode
-# - store a file to remote site
-# - retrieve the same file from remote site
-# - delete a file on remote site
-# - compare the size of both files
-# (file sizes should be equal or only the "\r" difference
-# between DOS/WINDOWS <> UNIX
-#
-proc test_40afile {loop} {
-global test
-
- # check if enabled
- if {!$test(afile)} {return}
-
- ftp::DisplayMsg $test(conn) "*** TEST $loop.4 (put/get ascii files) ***" header
- set ascii_file ftpdemo.tcl
- set lsize [file size $ascii_file]
- ftp::Type $test(conn) ascii
- ftp::Put $test(conn) $ascii_file ignore$test(pid).tmp
-
- # FileSize only works proper in binary mode
- ftp::Type $test(conn) binary
- set rsize [ftp::FileSize $test(conn) ignore$test(pid).tmp]
- ftp::Type $test(conn) ascii
- ftp::Get $test(conn) ignore$test(pid).tmp
- ftp::Delete $test(conn) ignore$test(pid).tmp
-
- catch {
- ftp::DisplayMsg $test(conn) "Original File:\t$lsize bytes"
- ftp::DisplayMsg $test(conn) "Stored File:\t$rsize bytes"
- ftp::DisplayMsg $test(conn) "Retrieved File:\t[file size ignore$test(pid).tmp] bytes"
- file delete ignore$test(pid).tmp }
-
-}
-
-#
-# 5.) binary put/get
-# - switch to binary mode
-# - store a file to remote site
-# - retrieve the same file from remote site
-# - delete a file on remote site
-# - compare the size of both files
-#
-proc test_50bfile {loop} {
-global test tk_library
-
- # check if enabled
- if {!$test(bfile)} {return}
-
- ftp::DisplayMsg $test(conn) "*** TEST $loop.5 (put/get binary files) ***" header
- set bin_file $tk_library/demos/images/teapot.ppm
- set lsize [file size $bin_file]
- ftp::Type $test(conn) binary
-
- # Put with ProgressBar
- # - ProgressBar init ...
- # - ProgressBar update ... callback defined in ftp!
- # - ProgressBar done
- ProgressBar init 0 $lsize teapot.ppm
- ftp::Put $test(conn) $bin_file ignore$test(pid).tmp
- ProgressBar done
-
- # Put with ProgressBar
- set rsize [ftp::FileSize $test(conn) ignore$test(pid).tmp]
- ProgressBar init 0 $rsize ignore$test(pid).tmp
- ftp::Get $test(conn) ignore$test(pid).tmp
- ProgressBar done
-
- ftp::Delete $test(conn) ignore$test(pid).tmp
-
- catch {
- ftp::DisplayMsg $test(conn) "Original File:\t$lsize bytes"
- ftp::DisplayMsg $test(conn) "Stored File:\t$rsize bytes"
- ftp::DisplayMsg $test(conn) "Retrieved File:\t[file size ignore$test(pid).tmp] bytes"
- file delete ignore$test(pid).tmp
- }
-
-}
-
-#
-# 6.) rename
-# - stores a binary file on remote site and renames it
-#
-proc test_60ren {loop} {
-global test tk_library
-
- # check if enabled
- if {!$test(ren)} {return}
-
- ftp::DisplayMsg $test(conn) "*** TEST $loop.6 (renaming remote files) ***" header
- set bin_file $tk_library/demos/images/earth.gif
- ftp::Type $test(conn) binary
- ftp::Put $test(conn) $bin_file ignore$test(pid).tmp
- ftp::Rename $test(conn) ignore$test(pid).tmp renamed$test(pid).tmp
- ftp::Delete $test(conn) renamed$test(pid).tmp
-
-}
-#
-# 7.) append
-# - go to ascii mode
-# - store a ascii file to remote site
-# - appends ascci file on remote site and renames it
-# - delete a file on remote site
-# - compare the size of both files
-# remote file must have the double size
-# (file sizes should be equal or only the "\r" difference
-# between DOS/WINDOWS <> UNIX
-#
-proc test_70append {loop} {
-global test tk_library
-
- # check if enabled
- if {!$test(append)} {return}
-
- ftp::DisplayMsg $test(conn) "*** TEST $loop.7 (append ascii file) ***" header
- set ascii_file ftpdemo.tcl
- set lsize [file size $ascii_file]
- ftp::Type $test(conn) ascii
- ftp::Append $test(conn) $ascii_file ignore$test(pid).tmp
- ftp::Append $test(conn) $ascii_file ignore$test(pid).tmp
- ftp::Get $test(conn) ignore$test(pid).tmp
- ftp::Delete $test(conn) ignore$test(pid).tmp
-
- catch {
- ftp::DisplayMsg $test(conn) "Original File:\t$lsize bytes ( * 2 = [expr {$lsize * 2}])"
- ftp::DisplayMsg $test(conn) "Appended File:\t[file size ignore$test(pid).tmp] bytes"
- file delete ignore$test(pid).tmp }
-
-}
-
-#
-# 8.) newer
-# - create a local copy of a a file
-# - create a remote copy of a a file
-# - check date entries
-# - transfer only if the specifieid file is newer
-#
-proc test_80new {loop} {
-global test tk_library
-
- # check if enabled
- if {!$test(new)} {return}
-
- ftp::DisplayMsg $test(conn) "*** TEST $loop.8 (newer) ***" header
- set bin_file $tk_library/demos/images/earth.gif
- ftp::Type $test(conn) binary
-
- file copy $bin_file ignore$test(pid).tmp
- ftp::Put $test(conn) $bin_file ignore$test(pid).tmp
- set datestr "%m/%d/%Y, %H:%M"
-
- set out {}
- catch {
- append out "Local File:\t[clock format [file mtime ignore$test(pid).tmp] -format $datestr -gmt 1]" \n
- append out "Remote File:\t[clock format [ftp::ModTime $test(conn) ignore$test(pid).tmp] -format $datestr -gmt 1]" \n
- }
-
- ftp::Newer $test(conn) ignore$test(pid).tmp
-
- catch {
- append out "Local File:\t[clock format [file mtime ignore$test(pid).tmp] -format $datestr -gmt 1] (after ftp::Newer)"
- }
-
- ftp::Delete $test(conn) ignore$test(pid).tmp
- catch {file delete ignore$test(pid).tmp}
- ftp::DisplayMsg $test(conn) $out
-
-}
-
-#
-# 9.) reget - reget command
-# - store file to remote site
-# - write 6 bytes to local file
-# - test the reget at position 6
-#
-proc test_90reget {loop} {
-global test tk_library
-
- # check if enabled
- if {!$test(reget)} {return}
-
- ftp::DisplayMsg $test(conn) "*** TEST $loop.9 (reget command) ***" header
- set bin_file $tk_library/demos/images/earth.gif
- ftp::Type $test(conn) binary
- ftp::Put $test(conn) $bin_file ignore$test(pid).tmp
- set f [open ignore$test(pid).tmp w]
- puts -nonewline $f "123456"
- close $f
- ftp::Reget $test(conn) ignore$test(pid).tmp
- ftp::Delete $test(conn) ignore$test(pid).tmp
-
- catch {
- ftp::DisplayMsg $test(conn) "Original File:\t\t[file size $bin_file]"
- ftp::DisplayMsg $test(conn) "Transfered File:\t[file size ignore$test(pid).tmp]"
- file delete ignore$test(pid).tmp
- }
-}
-
-##
-# 10.) not existing file/directory
-# all command with a not existing file name as parameter
-# - nlist, filesize, modtime, delete, rename, cd, rmdir, put, get, reget, newer
-# - write 6 bytes to local file
-# - test the reget at position 6
-#
-proc test_99notfound {loop} {
-global test tk_library
-
- # check if enabled
- if {!$test(notfound)} {return}
-
- ftp::DisplayMsg $test(conn) "*** TEST $loop.10 (not existing file/directory) ***" header
- ftp::NList $test(conn) filenotfound
- ftp::FileSize $test(conn) filenotfound
- ftp::ModTime $test(conn) filenotfound
- ftp::Rename $test(conn) filenotfound filenotfound
- ftp::Delete $test(conn) filenotfound
- ftp::Cd $test(conn) filenotfound
- ftp::RmDir $test(conn) filenotfound
- ftp::Put $test(conn) filenotfound
- ftp::Get $test(conn) filenotfound
- ftp::Reget $test(conn) filenotfound
- ftp::Newer $test(conn) filenotfound
-}
-
-# save preferences
-proc SaveConfig {} {
-global cnf
-
- set cnf(server) [.op.f.f1.server.e get]
- set cnf(port) [.op.f.f1.port.e get]
- set cnf(username) [.op.f.f1.username.e get]
- set cnf(password) [.op.f.f1.password.e get]
- set cnf(directory) [.op.f.f1.directory.e get]
- set cnf(loops) [.op.f.f2.loops.e get]
- set cnf(debug) $ftp::DEBUG
- set cnf(verbose) $ftp::VERBOSE
-
- set f [open $cnf(configfile) w]
- puts $f [array get cnf]
- close $f
-}
-
-# load preferences
-proc LoadConfig {} {
-global cnf
-
- # Defaults
- set cnf(server) "xxx"
- set cnf(port) 21
- set cnf(username) "xxx"
- set cnf(password) "xxx"
- set cnf(directory) ""
- set cnf(loops) 1
- set cnf(debug) 0
- set cnf(verbose) 1
-
- if {[file exists $cnf(configfile)]} {
- set f [open $cnf(configfile) r]
- array set cnf [read $f]
- close $f
- }
-
- .op.f.f1.server.e delete 0 end
- .op.f.f1.server.e insert 0 $cnf(server)
- .op.f.f1.port.e delete 0 end
- .op.f.f1.port.e insert 0 $cnf(port)
- .op.f.f1.username.e delete 0 end
- .op.f.f1.username.e insert 0 $cnf(username)
- .op.f.f1.password.e delete 0 end
- .op.f.f1.password.e insert 0 $cnf(password)
- .op.f.f1.directory.e delete 0 end
- .op.f.f1.directory.e insert 0 $cnf(directory)
- .op.f.f2.loops.e delete 0 end
- .op.f.f2.loops.e insert 0 $cnf(loops)
- set ::ftp::DEBUG $cnf(debug)
- set ::ftp::VERBOSE $cnf(verbose)
-}
-
-# stop the test
-proc StopTest {} {
-global test
- set test(break) 1
-}
-
-# start the test
-proc StartTest {} {
-global test
-
- .but.f.f1.stop configure -state normal
- .but.f.f1.start configure -state disabled
-
- .msg.f.f2.text configure -state normal
- .msg.f.f2.text delete 1.0 end
- .msg.f.f2.text configure -state disabled -fg black
-
- set loops [.op.f.f2.loops.e get]
- set server [.op.f.f1.server.e get]
- set port [.op.f.f1.port.e get]
- set username [.op.f.f1.username.e get]
- set passwd [.op.f.f1.password.e get]
- set dir [.op.f.f1.directory.e get]
-
- # open a ftp server connection
- set test(errors) 0
- set test(open) {}
- set test(pid) [pid]
- set start_time [clock seconds]
- ftp::DisplayMsg "" "*** Test started at [clock format [clock seconds] -format %d.%m.%Y\ %H:%M:%S ] ..." header
- if {[set conn [ftp::Open $server $username $passwd -port $port -progress {ProgressBar update} -mode $test(mode) -blocksize 8196 -timeout 60]] >= 0} {
-
- if {$test(quote)} {
- ftp::DisplayMsg $conn [ftp::Quote $conn syst]
- ftp::DisplayMsg $conn [ftp::Quote $conn site umask 022]
- ftp::DisplayMsg $conn [ftp::Quote $conn help]
- }
-
-
- if { $dir != "" } {
- ftp::Cd $conn $dir
- }
-
- # begin test loop
- set test(break) 0
- set test(conn) $conn
- for {set test(loop) 1} {$test(loop) <= $loops} {incr test(loop)} {
- if {$test(break)} {break}
- foreach test(proc) [lsort [info proc test*]] {
- if {$test(break)} {break}
-
- # count entries in the after queues
- set test(after) [after info]
-
- # run procedure
- eval $test(proc) $test(loop)
- }
- }
- if {$test(break)} {
- ftp::DisplayMsg "... user break!" error
- } else {
- incr test(loop) -1
- }
-
- ftp::Close $conn
- set stop_time [clock seconds]
- set elapsed [expr {$stop_time - $start_time}]
- if { $elapsed == 0 } { set elapsed 1}
- ftp::DisplayMsg "" "************************* THE END *************************" header
- ftp::DisplayMsg "" "=> $loops iterations takes $elapsed seconds"
- ftp::DisplayMsg "" "=> $test(errors) error(s) occured"
- }
- .but.f.f1.stop configure -state disabled
- .but.f.f1.start configure -state normal
-}
-
-# Help
-proc Help {} {
- .msg.f.f2.text configure -state normal
- .msg.f.f2.text delete 1.0 end
- .msg.f.f2.text insert 1.0 " **** CONFIGURATION HELP *****
-
-Ftp_demo is the simple user interface to the ftp test program. It
-checks all ftp commands of the FTP library package against an
-existing FTP server. It requires some configuration entries specified
-in the form below.
-
-- Host ... Host FTP server on which the connection will be established
-- Username ... Users login name at host
-- Password ... Users password at host
-- Directory ... Starting directory when differs from root \"/\"
-- Iterations ... Count of interations for the test algorithm (default 1)
-
-The message window shows all responses from the remote server, as well
-as report on data transfer statistics and file sizes. Two switches
-toggles enhanced output:
-
-1. Debug...Enables debugging (return code, state, real FTP commands )
-2. Verbose ... Forces to show all responses from the FTP server
-
-Active or passive file transfer mode is selected in the upper frame.
-When ftpdemo uses the active mode it waits for the server to open
-a connection to transfer files or get file listings. In passive mode
-the server waits for ftpdemo to open a connection to transfer files
-or get file listings. Passive mode is normally a requirement when
-accessing sites via a firewall.
-
-Press \"Save Options\" to save these options in a configuration file.
-Options will be restored next time you start the ftpdemo program.
-Check marked test commands and start test by pressing \"Start test\"
-button. Any time the test program can be canceled by pressing the
-\"Stop test\" button.
-
-NOTE:
------
-THE FTP_DEMO PROGRAM IS A DEVELOPMENT AND DEBUGGING TOOL RATHER THAN
-A USEFUL FTP USER INTERFACE. FEEL FREE TO USE IT.
-
-
- ***"
- .msg.f.f2.text configure -state disabled -fg darkgreen
-}
-
-################ main ##########################################################################
-
-# default file transfer mode ... active
-set test(mode) active
-
-# Configuration file
-set cnf(configfile) "ftpdemo.cnf"
-LoadConfig
-
-Help
-
-
-
-
-
-
-
DELETED examples/ftp/ftpvalid
Index: examples/ftp/ftpvalid
==================================================================
--- examples/ftp/ftpvalid
+++ /dev/null
@@ -1,78 +0,0 @@
-#!/bin/sh
-# -*- tcl -*- \
-exec tclsh "$0" ${1+"$@"}
-# Author: [Larry W. Virden] [LV], modified Andreas Kupries [AK]
-# Version: 3
-# Validate the ftp: urls given on the command line.
-
-package require uri
-package require ftp
-
-# Should eventually add a command line argument to toggle verbose
-#set ftp::VERBOSE 1
-
-if {0} {
- proc ftp::DisplayMsg {s msg {state ""}} {
- upvar ::ftp::ftp$s ftp
- variable VERBOSE
-
- switch -exact -- $state {
- data {
- if { $VERBOSE } { puts $msg }
- }
- control {
- if { $VERBOSE } { puts $msg }
- }
- error {
- if { $VERBOSE } { puts "E: $msg" }
- #error "ERROR: $msg"
- }
- default {
- if { $VERBOSE } { puts $msg }
- }
- }
- return
- }
-}
-
-foreach arg $argv {
- array set current [uri::split $arg]
-
- # parray current
-
- if {[catch {
- set fdc [ftp::Open $current(host) anonymous enteryourname@here.com]
- } returncode]} {
- puts stderr [format "error 1: unable to open %s\n" $current(host)]
- continue
- }
- set ftp_dir [file dirname $current(path)]
- set ftp_file [file tail $current(path)]
-
- if {[catch {
- set result [ftp::Cd $fdc $ftp_dir] } returncode]
- } {
- puts stderr [format "error 2: unable to enter directory %s:%s\n" $current(host) $ftp_dir]
- continue
- }
-
- if { $result == 0 } {
- puts stderr [format "error 3: failure to enter %s:%s\n" $current(host) $ftp_dir]
- continue
- }
-
- if {[catch {
- set result [ftp::List $fdc "${ftp_file}*"] } returncode]
- } {
- puts stderr [format "error 4: no match for ${ftp_file}*\n" $current(host) $ftp_dir]
- continue
- }
- if { $result == {} } {
- puts stderr [format "error 5: no match for ${ftp_file}*\n" $current(host) $ftp_dir]
- continue
- }
-
- ftp::Close $fdc
-}
-
-exit
DELETED examples/ftp/hpupdate.tcl
Index: examples/ftp/hpupdate.tcl
==================================================================
--- examples/ftp/hpupdate.tcl
+++ /dev/null
@@ -1,1186 +0,0 @@
-#!/bin/sh
-# the next line restarts using wish \
-exec wish8.3 "$0" -- "$@"
-#
-# - homepage update program using FTP -
-#
-# Required: tcl/tk8.2
-#
-# Created: 12/96
-# Changed: 7/2000
-# Version: 2.0
-#
-# Copyright (C) 1998 Steffen Traeger
-# EMAIL: Steffen.Traeger@t-online.de
-# URL: http://home.t-online.de/home/Steffen.Traeger
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-#
-########################################################################
-
-# load required FTP package library
-package require ftp 2.0
-package require Tk
-if {![llength [info commands tkButtonInvoke]]} {
- ::tk::unsupported::ExposePrivateCommand tkButtonInvoke
-}
-
-# LED Colors
-set status(off) "#006666"
-set status(on) "#00ff00"
-set ftp(Mode) passive
-
-# set palette under X
-if { [string range [winfo server .] 0 0] == "X" } {
- set tk_strictMotif 1
- tk_setPalette LightGray
- option add *font {Helvetica 12}
- option add *Text.foreground black
- option add *Text.background white
- option add *Listbox.background white
- option add *Listbox.selectForeground white
- option add *Entry.background white
- option add *Entry.selectBackground black
- option add *Entry.selectForeground white
- option add *Scrollbar.width 12
-}
-
-# main window
-wm title . "hpupdate 2.0"
-wm iconname . hpupdate
-wm minsize . 1 1
-
-# Menue
-menu .menu -tearoff 0
-menu .menu.file -tearoff 0
-.menu add cascade -label "File" -menu .menu.file -underline 0
-.menu.file add command -label "Connect" -underline 0 -command {BusyCommand Connect} -accelerator Alt+C
-.menu.file add command -label "Disconnect" -underline 1 -state disabled -command {BusyCommand Disconnect} -accelerator Alt+I
-.menu.file add separator
-.menu.file add command -label "Exit" -underline 0 -command Quit -accelerator Alt+X
-
-#menu .menu.edit -tearoff 0
-#.menu add cascade -label "Bearbeiten" -menu .menu.edit -underline 0
-#.menu.edit add command -label "Alle Löschen" -underline 0 -state disabled -command {
-# .view.remote.list selection set 0 end; BusyCommand DeleteremoteFiles}
-#.menu.edit add command -label "Alle Übertragen" -underline 0 -state disabled -command Quit
-
-menu .menu.view -tearoff 0
-.menu add cascade -label "View" -menu .menu.view -underline 0
-.menu.view add command -label "Refresh" -underline 0 -command {BusyCommand Refresh} -accelerator Alt+R
-
-menu .menu.options -tearoff 0
-.menu add cascade -label "Options" -menu .menu.options -underline 0
-.menu.options add command -label "Preferences" -underline 0 -command {BusyCommand Config} -accelerator Alt+P
-
-menu .menu.help -tearoff 0
-.menu add cascade -label "Help" -menu .menu.help -underline 0
-.menu.help add command -label "Overview" -underline 0 -command {Help overview}
-.menu.help add command -label "Installation" -underline 0 -command {Help install}
-.menu.help add command -label "Usage" -underline 0 -command {Help usage}
-.menu.help add separator
-.menu.help add command -label "About" -underline 1 -command {Help about}
-
-. configure -menu .menu
-
-# View area
-frame .status -bd 1 -relief flat
- pack .status -in . -side bottom -fill x
-frame .view -bd 1 -relief flat
- pack .view -in . -side top -expand 1 -fill both
-
-# Status
-frame .status.head -bd 1 -relief sunken
- pack .status.head -in .status -side top -fill x
-label .status.head.label -textvariable status(header) -relief raised -anchor w -bd 1
- pack .status.head.label -in .status.head -side left -expand 1 -fill x -ipadx 2 -ipady 2
-
-# Connection status
-frame .view.conn -bd 1 -relief flat
- pack .view.conn -in .view -side top -fill both -padx 8
-frame .view.conn.led1 -bd 2 -relief raised -width 20 -height 10
- pack .view.conn.led1 -in .view.conn -side left -fill x -padx 3
-label .view.conn.lab1 -text "No Connection!" -relief flat -anchor w -bd 1 -font {Helvetica 8}
- pack .view.conn.lab1 -in .view.conn -side left -fill x -padx 3
-checkbutton .view.conn.check -text "syncronize scrollbars" -takefocus 0 -variable ftp(SyncScroll) \
- -command SyncScroll -relief flat -anchor w -bd 2 -font {Helvetica 12}
- pack .view.conn.check -in .view.conn -side right
-
-# Separator
-frame .view.line -bd 1 -height 2 -relief sunken
- pack .view.line -in .view -side top -fill x -padx 8 -pady 5
-
-# Dummy
-frame .view.dummy -bd 1 -height 5 -relief flat
- pack .view.dummy -in .view -side bottom -fill x -padx 8 -pady 5
-
-# Remote directory
-frame .view.remote -bd 1
- pack .view.remote -in .view -side right -expand 1 -fill both -padx 5
-frame .view.remote.status -bd 0
- pack .view.remote.status -in .view.remote -side top -fill x
-label .view.remote.status.label -text "Remote: " -anchor w -relief flat -font {Helvetica 12 italic}
- pack .view.remote.status.label -in .view.remote.status -side left
-label .view.remote.status.mark -text "" -anchor w -relief flat -font {Helvetica 10}
- pack .view.remote.status.mark -in .view.remote.status -side right
-label .view.remote.status.use -text "0K" -anchor w -relief flat -fg #0000ff
- pack .view.remote.status.use -in .view.remote.status -side left
-
-frame .view.remote.buttons -bd 1
- pack .view.remote.buttons -in .view.remote -side bottom -fill x
-button .view.remote.buttons.delete -text "Delete" -under 0 -state disabled -command {BusyCommand DeleteRemoteFiles}
- pack .view.remote.buttons.delete -in .view.remote.buttons -side top -pady 1m
-scrollbar .view.remote.yscroll -relief sunken -takefocus 0 -command ".view.remote.list yview"
- pack .view.remote.yscroll -in .view.remote -side right -fill y
-scrollbar .view.remote.xscroll -relief sunken -orient horizontal -takefocus 0 -command ".view.remote.list xview"
- pack .view.remote.xscroll -in .view.remote -side bottom -fill x
-listbox .view.remote.list -relief sunken -xscroll ".view.remote.xscroll set" -yscroll ".view.remote.yscroll set" \
- -width 40 -height 24 -font {Courier 12} \
- -exportselection 0 -selectmode multiple -takefocus 0 -selectbackground #ff0000
- pack .view.remote.list -in .view.remote -side left -expand 1 -fill both
-
-# Local directory
-frame .view.local -bd 1
- pack .view.local -in .view -side left -expand 1 -fill both -padx 5
-frame .view.local.status -bd 0
- pack .view.local.status -in .view.local -side top -fill x
-label .view.local.status.label -text "Local: " -anchor w -relief flat -font {Helvetica 12 italic}
- pack .view.local.status.label -in .view.local.status -side left
-label .view.local.status.mark -text "" -anchor w -relief flat -font {Helvetica 10}
- pack .view.local.status.mark -in .view.local.status -side right
-label .view.local.status.use -text "0K" -anchor w -relief flat -fg #0000ff
- pack .view.local.status.use -in .view.local.status -side left
-
-frame .view.local.buttons -bd 1
- pack .view.local.buttons -in .view.local -side bottom -fill x
-button .view.local.buttons.transfer -text "Upload->" -under 0 -state disabled -command UpdateRemoteFiles
- pack .view.local.buttons.transfer -in .view.local.buttons -side top -pady 1m
-scrollbar .view.local.yscroll -relief sunken -takefocus 0 -command ".view.local.list yview"
- pack .view.local.yscroll -in .view.local -side right -fill y
-scrollbar .view.local.xscroll -relief sunken -orient horizontal -takefocus 0 -command ".view.local.list xview"
- pack .view.local.xscroll -in .view.local -side bottom -fill x
-listbox .view.local.list -relief sunken -xscroll ".view.local.xscroll set" -yscroll ".view.local.yscroll set" \
- -width 40 -height 24 -font {Courier 12} \
- -exportselection 0 -selectmode multiple -takefocus 0 -selectbackground #000080
- pack .view.local.list -in .view.local -side left -expand 1 -fill both
-
-# Shows selected files
-bindtags .view.local.list {Listbox . all .view.local.list}
-bindtags .view.remote.list {Listbox . all .view.remote.list}
-bind .view.local.list {Showselected local}
-bind .view.remote.list {Showselected remote}
-
-# Acc. Keys
-bind . {BusyCommand Connect}
-bind . {BusyCommand Disconnect}
-bind . {BusyCommand Refresh}
-bind . {BusyCommand Config}
-bind . "tkButtonInvoke .view.local.buttons.transfer"
-bind . "tkButtonInvoke .view.remote.buttons.delete"
-bind . Quit
-
-proc SyncY {args} {
- eval .view.local.list yview $args
- eval .view.remote.list yview $args
-}
-
-proc SyncX {args} {
- eval .view.local.list xview $args
- eval .view.remote.list xview $args
-}
-
-# Syncron Scrollbars
-proc SyncScroll {} {
-global ftp
- if { $ftp(SyncScroll) == 1} {
- .view.local.yscroll configure -command SyncY
- .view.remote.yscroll configure -command SyncY
- .view.local.xscroll configure -command SyncX
- .view.remote.xscroll configure -command SyncX
- } else {
- .view.local.yscroll configure -command ".view.local.list yview"
- .view.remote.yscroll configure -command ".view.remote.list yview"
- .view.local.xscroll configure -command ".view.local.list xview"
- .view.remote.xscroll configure -command ".view.remote.list xview"
- }
-}
-
-# messages
-proc ftp::DisplayMsg {s msg {state normal}} {
-global status
-
- switch -- $state {
- data {return}
- control {return}
- normal {.status.head.label configure -fg black}
- error {.status.head.label configure -fg red}
- }
- set status(header) $msg
- update idletasks
-}
-
-################################################
-#
-# Procedures
-#
-################################################
-
-# hourglass
-proc BusyCommand {args} {
- set command $args
- set busy {.menu .view .status}
- set window_list {.menu .view .status}
- while {$window_list != ""} {
- set next {}
- foreach w $window_list {
- set class [winfo class $w]
- set cursor [lindex [$w config -cursor] 4]
- if {[winfo toplevel $w] == $w || $cursor != ""} {
- lappend busy [list $w $cursor]
- }
- set next [concat $next [winfo children $w]]
- }
- set window_list $next
- }
- foreach w $busy {
- catch { grab set [lindex $w 0]}
- catch {[lindex $w 0] config -cursor watch}
- }
- update idletasks
- set error [catch {uplevel eval [list $command]} g]
- foreach w $busy {
- catch {grab release [lindex $w 0]}
- catch {[lindex $w 0] config -cursor [lindex $w 1]}
- }
- if { !$error } {
- return $g
- } else {
- bgerror $g
- }
- return ""
-}
-
-# read recursive the remote directory tree
-proc GetRemoteTree {{dir ""}} {
-global ftp
-
- foreach i [ftp::List $ftp(conn) $dir] {
- set rc [scan $i "%s %s %s %s %s %s %s %s %s" perm l u g size d1 d2 d3 name]
- if {$rc == "9"} {
-
- if { ($name == ".") || ($name == "..") } {
- continue
- }
-
- set type [string range $perm 0 0]
- if { $dir != "" } {
- regsub {\./} [file join $dir $name] "" name
- }
- switch -- $type {
- d {
- lappend ftp(remoteDirList) $name
- lappend ftp(remoteFileList) "$name"
- lappend ftp(remoteSizeList) $size
- GetRemoteTree $name
- }
-
- - {
- lappend ftp(remoteFileList) "$name"
- lappend ftp(remoteSizeList) $size
- }
-
- default {
- lappend ftp(remoteFileList) "$name"
- lappend ftp(remoteSizeList) $size
- }
- }
- }
- }
-}
-
-# read remote directory
-proc ReadRemoteDir {} {
-global ftp opt
-
- # connected?
- if {(![info exists ftp(conn)]) ||
- (![info exists ftp::ftp${ftp(conn)}(State)])} {
- .view.remote.list delete 0 end
- return
- }
-
- focus .view.remote.list
- .view.remote.list delete 0 end
- .view.remote.list insert end "Working..."
- update idletasks
-
- set ftp(remoteDirList) {}
- set ftp(remoteFileList) {}
- set ftp(remoteSizeList) {}
- GetRemoteTree .
-
- foreach name $ftp(remoteFileList) {
- if { [string length $name] > $ftp(MaxLength) } {
- set ftp(MaxLength) [string length $name]
- }
- }
-
- set max_length $ftp(MaxLength)
- .view.remote.list delete 0 end
- update idletasks
- set index 0
- foreach i $ftp(remoteFileList) {
-
- set name $i
- set size [lindex $ftp(remoteSizeList) $index ]
- set entry [format "%-${max_length}s %8s" $name $size]
- .view.remote.list insert end $entry
-
- # If file doesn't exist on local location then mark it to delete
- set index [lsearch -regexp [.view.local.list get 0 end] "^$name "]
- if { $index == "-1" } {
- .view.remote.list selection set end end
- }
- incr index
-
- }
-
- ShowUsed remote
- Showselected remote
- ReadLocalDir
-}
-
-# shine a light
-proc Blink {mode} {
-global status
- switch -- $mode {
- on {
- .view.conn.led1 configure -bg $status(on)
- update idletasks
- }
- off {
- .view.conn.led1 configure -bg $status(off)
- update idletasks
- }
- }
-}
-
-# connect to ftp server
-proc Connect {} {
-global ftp opt
- ftp::DisplayMsg "" " ftp> Trying connect to ftp server..."
- Blink on
- if {[set ftp(conn) [ftp::Open $opt(Server) $opt(Username) $opt(Password) -progress {ProgressBar update} ]] == -1} {
- Blink off
- ShowStatus
- return
- }
-
- # remote homepage directory
- if {![ftp::Cd $ftp(conn) $opt(remoteDir)]} {
- tk_messageBox -parent . -title INFO -message "Directory $opt(remoteDir) on remote ftp server not found!" -type ok
- Disconnect
- return
- }
-
- ftp::DisplayMsg $ftp(conn) "Connected to ftp service on $opt(Server)!"
- ReadRemoteDir
- .view.local.buttons.transfer configure -state normal
- .view.remote.buttons.delete configure -state normal
- .menu.file entryconfigure 0 -state disabled
- .menu.file entryconfigure 1 -state normal
- ShowStatus
-}
-
-# Remove connection to file server
-proc Disconnect {} {
-global ftp
-
- # connected?
- if {([info exists ftp(conn)]) &&
- ([info exists ftp::ftp${ftp(conn)}(State)])} {
- ftp::Close $ftp(conn)
- ftp::DisplayMsg "" "Connection closed!"
- }
- if {[info exists ftp(conn)]} {
- unset ftp(conn)
- }
- set ftp(remoteSizeList) {}
- .view.remote.list delete 0 end
- .view.local.buttons.transfer configure -state disabled
- .view.remote.buttons.delete configure -state disabled
- .menu.file entryconfigure 0 -state normal
- .menu.file entryconfigure 1 -state disabled
- ShowStatus
- ShowUsed remote
- Showselected remote
-}
-
-# Display connection status
-proc ShowStatus {} {
-global status
- if {([info exists ftp(conn)]) &&
- ([info exists ftp::ftp${ftp(conn)}(State)])} {
- .view.conn.led1 configure -bg $status(on)
- .view.conn.lab1 configure -text "connected"
- update idletasks
- } else {
- .view.conn.led1 configure -bg $status(off)
- .view.conn.lab1 configure -text "not connected"
- update idletasks
- }
-}
-
-# display used directory size
-proc ShowUsed {mode} {
-global ftp
- set sum 0
- foreach i $ftp(${mode}SizeList) {
- incr sum $i
- }
-
-# if { $sum > [ expr {1024 * 1024}] } {
-# set color #ff0000
-# } else {
-# set color #0000ff
-# }
-
- set color #0000ff
- .view.$mode.status.use configure -text "[expr {round($sum / 1024.0)}] KB" -fg $color
- update idletasks
-}
-
-# display selected directory size
-proc Showselected {mode} {
-global ftp
- set sum 0
- set count 0
- if { ([info exists ftp(${mode}SizeList)]) && ([llength $ftp(${mode}SizeList)] != 0) } {
- foreach i [.view.$mode.list curselection] {
- incr sum [lindex $ftp(${mode}SizeList) $i]
- incr count
- }
- }
- .view.$mode.status.mark configure -text "[expr {round($sum / 1024.0)}] KB \[$count\]"
- update idletasks
-}
-
-
-# read recursive the local directory tree
-proc GetLocalTree {dir} {
-global ftp
- foreach i [lsort [glob -nocomplain $dir/* $dir/.*]] {
- regsub {\./} $i "" i
- if { ([file tail $i] != ".") && ([file tail $i] != "..") } {
-
- # exist check
- if {![file exists $i]} {
- continue
- }
-
- if {[file isdirectory $i]} {
- lappend ftp(localFileList) $i
- lappend ftp(localDirList) $i
- GetLocalTree $i
- } else {
- lappend ftp(localFileList) $i
- }
- }
- }
-}
-
-# read local directory
-proc ReadLocalDir {} {
-global opt ftp
-
- .view.local.list delete 0 end
- .view.local.list insert end "Working..."
- update
-
- # local homepage directory
- if {![file isdirectory $opt(localDir)]} {
- tk_messageBox -parent . -title INFO -message "Directory $opt(localDir) not found!" -type ok
- return
-
- }
-
- # read local homepage directory
- set ftp(localDirList) {}
- set ftp(localFileList) {}
- set ftp(localSizeList) {}
- cd $opt(localDir)
- GetLocalTree .
-
- foreach name $ftp(localFileList) {
- if { [string length $name] > $ftp(MaxLength) } {
- set ftp(MaxLength) [string length $name]
- }
- }
-
- set max_length $ftp(MaxLength)
- .view.local.list delete 0 end
- update idletask
- foreach i $ftp(localFileList) {
-
- set name $i
- set size [file size $name]
- set entry [format "%-${max_length}s %8s" $name $size]
- .view.local.list insert end $entry
- lappend ftp(localSizeList) $size
-
- # if updated then mark to upload
- if { [file mtime $name] > $opt(Timestamp) } {
- .view.local.list selection set end end
- }
-
- # if not exist at remote machine then mark to upload
- if {([info exists ftp(conn)]) &&
- ([info exists ftp::ftp${ftp(conn)}(State)])} {
- set index [lsearch -regexp [.view.remote.list get 0 end] "^$name "]
- if { $index == "-1" } {
- .view.local.list selection set end end
- }
- }
- }
-
- ShowUsed local
- Showselected local
-}
-
-# delete files on remote site
-proc DeleteRemoteFiles {} {
-global ftp
-
- # connected?
- if {(![info exists ftp(conn)]) ||
- (![info exists ftp::ftp${ftp(conn)}(State)])} {
- tk_messageBox -parent . -title INFO -message "No connection!" -type ok
- return
- }
- # nothing choosed
- if { [.view.remote.list curselection] == {} } {
- return
- }
- # ask user
- set count [llength [.view.remote.list curselection]]
- set rc [tk_messageBox -parent . -title DELETE -message "Do you really want to delete the $count selected file(s)?" -type yesno]
- if { $rc == "no" } {
- return
- }
-
- # delete selected files
- focus .view.remote.list
- foreach i [lsort -integer -decreasing [.view.remote.list curselection]] {
- set filename [lindex [.view.remote.list get $i] 0]
- .view.remote.list see $i
- .view.remote.list activate $i
- update idletasks
-
- # file or directory?
- set index [lsearch -exact $ftp(remoteDirList) $filename]
- if { $index == "-1" } {
- set command "ftp::Delete"
- } else {
- set command "ftp::RmDir"
- }
-
- if {[eval $command $ftp(conn) $filename]} {
- .view.remote.list selection clear $i
- update idletasks
- set ftp(remoteSizeList) [lreplace $ftp(remoteSizeList) $i $i 0]
- ShowUsed remote
- Showselected remote
- Showselected local
- } else {
- tk_messageBox -parent . -title ERROR -message \
- "Error deleting $filename!" -icon error -type ok
- continue
- }
- }
- BusyCommand Refresh
-}
-
-# Progress bar displayed in status line
-proc ProgressBar {state {bytes 0} {filename ""}} {
-global ftp
- set w .progress
- switch -- $state {
- init {
- set ftp(Filename) ""
- set ftp(ProgressProz) "0%"
- toplevel $w -bd 0 -class Progressbar
- wm transient $w .
- wm title $w Upload
- wm iconname $w Upload
- wm resizable $w 0 0
- focus $w
- grab $w
-
- frame $w.buttons
- pack $w.buttons -side bottom -fill x -pady 2m
- button $w.buttons.esc -text "Cancel" -command "set ftp(escaped) 1"
- pack $w.buttons.esc -in $w.buttons -side top
-
- frame $w.frame -bd 4
- pack $w.frame -side top -fill both
- label $w.frame.label -textvariable ftp(Filename) -relief flat -anchor w -bd 1 -font {Helvetica 12}
- pack $w.frame.label -in $w.frame -side top -fill x -padx 10 -pady 5
- frame $w.frame.line -bd 1 -height 2 -relief sunken
- pack $w.frame.line -in $w.frame -side bottom -fill x -padx 2 -pady 5
- frame $w.frame.bar -bd 1 -relief sunken -bg #ffffff
- pack $w.frame.bar -in $w.frame -side left -padx 10 -pady 5
- frame $w.frame.bar.dummy -bd 0 -width 200 -height 0
- pack $w.frame.bar.dummy -in $w.frame.bar -side top -fill x
- frame $w.frame.bar.pbar -bd 0 -width 0 -height 20
- pack $w.frame.bar.pbar -in $w.frame.bar -side left
- label $w.frame.proz -textvariable ftp(ProgressProz) -width 5 -relief flat -anchor e -bd 1 -font {Helvetica 12}
- pack $w.frame.proz -in $w.frame -side right -padx 10 -pady 5
-
- wm withdraw $w
- update idletasks
- set x [expr {[winfo x .] + ([winfo width .] / 3) - ([winfo reqwidth $w] / 2)}]
- set y [expr {[winfo y .] + ([winfo height .] / 3) - ([winfo reqheight $w] / 2)}]
- wm geometry $w +$x+$y
- wm deiconify $w
- update idletasks
- }
-
- reset {
- set ftp(Filename) "Uploading $filename...."
- set index [lsearch $ftp(localFileList) $filename]
- if { $index != "-1" } {
- set ftp(progress_sum) [lindex $ftp(localSizeList) $index]
- if { $ftp(progress_sum) == 0 } {
- set ftp(progress_sum) 1
- }
- } else {
- set ftp(progress_sum) 1
- }
- ProgressBar update
- update idletasks
- }
-
- update {
- if {![winfo exists $w]} {return}
- set ftp(ProgressProz) "[expr {round( $bytes * 100 / $ftp(progress_sum))}]%"
- set cur_width [expr {round($bytes * 200 / $ftp(progress_sum))}]
- $w.frame.bar.pbar configure -width $cur_width -bg #000080
- focus $w.buttons.esc
- update idletasks
- update
- }
-
- done {
- set ftp(Filename) "Upload successful!"
- $w.buttons.esc configure -text "OK" -command "destroy $w"
- update idletasks
- tkwait window $w
- }
-
- escape {
- destroy $w
- BusyCommand Refresh
- }
-
- error {
- destroy $w
- }
- }
-}
-
-# upload local files to remote site
-proc UpdateRemoteFiles {} {
-global ftp opt status
- # connected?
- if {(![info exists ftp(conn)]) ||
- (![info exists ftp::ftp${ftp(conn)}(State)]) } {
- tk_messageBox -parent . -title INFO -message "No connection!" -type ok
- return 0
- }
-
- # nothing selected
- if { [.view.local.list curselection] == {} } {
- return 0
- }
-
- # ask user
- set count [llength [.view.local.list curselection]]
- set rc [tk_messageBox -parent . -title UPLOAD -message "Do you really want to upload the $count selected file(s)?" -type yesno]
- if { $rc == "no" } {
- return 0
- }
-
- # create list of uploading files
- set upload_list {}
- foreach i [.view.local.list curselection] {
- lappend upload_list $i
- }
-
- # empty list?
- if { $upload_list == {} } {
- tk_messageBox -parent . -title INFO -type ok -message "Nothing selected for upload!!"
- return 0
- }
- focus .view.local.list
-
- # binary type for all files
- ftp::Type $ftp(conn) binary
-
- # upload files
- set ftp(escaped) 0
- ProgressBar init
- set ftp(ProgressCount) 0
- foreach i $upload_list {
- set filename [lindex [.view.local.list get $i] 0]
- .view.local.list see $i
- .view.local.list activate $i
- update idletasks
-
- # file or directory?
- set index [lsearch -exact $ftp(localDirList) $filename]
- if { $index == "-1" } {
- set command "ftp::Put"
- } else {
-
- # directory already exists
- if { [lsearch -exact $ftp(remoteDirList) $filename] != "-1" } {
- continue
- }
- set command "ftp::MkDir"
- }
-
- ProgressBar reset 0 $filename
- if {[eval $command $ftp(conn) $filename]} {
- incr ftp(ProgressCount)
- if {$ftp(escaped)} {
- ProgressBar escape
- return 1
- }
- .view.local.list selection clear $i
- } else {
- tk_messageBox -parent . -title ERROR -message "Error uploading $filename!" -icon error -type ok
- ProgressBar error
- continue
- }
- }
-
- ProgressBar done
-
- # new timestamp
- Touch $opt(TsFile)
- set opt(Timestamp) [file mtime $opt(TsFile)]
- Refresh
- set status(header) " last update: [clock format $opt(Timestamp) -format %d.%m.%Y\ %H:%M:%S\ Uhr -gmt 0]"
- return 0
-}
-
-# Refresh
-proc Refresh {} {
-global ftp
- set ftp(MaxLength) 0
- ReadLocalDir
- ReadRemoteDir
- ShowStatus
- update idletasks
-}
-
-
-if {[package vcompare [info tclversion] 8.4] >= 0} {
- proc Touch {filename} {
- file mtime $filename [clock seconds]
- }
-} else {
- # update timestamp
- proc Touch {filename} {
- set file [open $filename w]
- puts -nonewline $file ""
- close $file
- }
-}
-
-
-# quit hpupdate
-proc Quit {} {
-global ftp
- Disconnect
- destroy .
- exit 0
-}
-
-
-# save current configuration
-proc SaveConfig {} {
-global opt
- set file [open $opt(ConfigFile) w]
- puts $file [array get opt]
- close $file
-}
-
-# accept new configuraion
-proc AcceptConfig {w} {
-global opt ftp
-
- # get ftp server options
- set opt(Server) [$w.mask.server.entry get]
- set opt(Username) [$w.mask.user.entry get]
- set opt(Password) [$w.mask.passwd.entry get]
- set opt(remoteDir) [$w.mask.remote.entry get]
-
- # get local homepage direction
- set dir [$w.mask.local.entry get]
- if { ![file isdirectory $dir] } {
- tk_messageBox -parent . -title ERROR -message "Directory \"$dir\" not found!" -type ok
- return
- }
- set opt(localDir) [$w.mask.local.entry get]
- cd $opt(localDir)
-
- SaveConfig
- tk_messageBox -parent . -title INFO -message "Configuration applied and saved!" -type ok
- destroy $w
-}
-
-# ftp configuration
-proc Config {} {
-global opt
-
- # new window
- set w .config
-
- catch {destroy $w}
- toplevel $w -bd 0 -class Config
- wm transient $w .
- wm title $w "options"
- wm iconname $w "options"
- wm transient $w .
- wm minsize $w 10 10
-
- frame $w.mask -bd 1 -relief raised
- pack $w.mask -in $w -side top -expand 1 -fill both
- frame $w.control -bd 1 -relief raised
- pack $w.control -in $w -side bottom -fill x
-
- frame $w.mask.server -bd 1
- pack $w.mask.server -in $w.mask -side top -expand 1 -fill both -padx 3m -pady 3m
- label $w.mask.server.label -text "ftp server name:" -under 0 -anchor w
- pack $w.mask.server.label -in $w.mask.server -side top -fill x
- entry $w.mask.server.entry -width 40
- pack $w.mask.server.entry -in $w.mask.server -expand 1 -side left -fill x
-
- frame $w.mask.user -bd 1
- pack $w.mask.user -in $w.mask -side top -expand 1 -fill both -padx 3m -pady 3m
- label $w.mask.user.label -text "User:" -under 0 -anchor w
- pack $w.mask.user.label -in $w.mask.user -side top -fill x
- entry $w.mask.user.entry -width 40
- pack $w.mask.user.entry -in $w.mask.user -expand 1 -side left -fill x
-
- frame $w.mask.passwd -bd 1
- pack $w.mask.passwd -in $w.mask -side top -expand 1 -fill both -padx 3m -pady 3m
- label $w.mask.passwd.label -text "Password:" -under 0 -anchor w
- pack $w.mask.passwd.label -in $w.mask.passwd -side top -fill x
- entry $w.mask.passwd.entry -show "*" -width 40
- pack $w.mask.passwd.entry -in $w.mask.passwd -expand 1 -side left -fill x
-
- frame $w.mask.remote -bd 1
- pack $w.mask.remote -in $w.mask -side top -expand 1 -fill both -padx 3m -pady 3m
- label $w.mask.remote.label -text "Remote directory:" -under 0 -anchor w
- pack $w.mask.remote.label -in $w.mask.remote -side top -fill x
- entry $w.mask.remote.entry -width 40
- pack $w.mask.remote.entry -in $w.mask.remote -expand 1 -side left -fill x
-
- frame $w.mask.local -bd 1
- pack $w.mask.local -in $w.mask -side top -expand 1 -fill both -padx 3m -pady 3m
- label $w.mask.local.label -text "Local directory:" -under 0 -anchor w
- pack $w.mask.local.label -in $w.mask.local -side top -fill x
- entry $w.mask.local.entry -width 40
- pack $w.mask.local.entry -in $w.mask.local -expand 1 -side left -fill x
-
- button $w.control.accept -width 14 -text "Apply & Save" -under 0 -command "AcceptConfig $w"
- pack $w.control.accept -in $w.control -side left -expand 1 -padx 3m -pady 2m
- button $w.control.quit -width 14 -text "Cancel" -under 0 -command "destroy $w"
- pack $w.control.quit -in $w.control -side left -expand 1 -padx 3m -pady 2m
-
-
- # arrange window
- wm withdraw $w
- update idletasks
- set x [expr {[winfo x .] + ([winfo width .] / 3) - ([winfo reqwidth $w] / 2)}]
- set y [expr {[winfo y .] + ([winfo height .] / 3) - ([winfo reqheight $w] / 2)}]
- wm geometry $w +$x+$y
- wm deiconify $w
-
- $w.mask.server.entry delete 0 end
- $w.mask.server.entry insert 0 $opt(Server)
- $w.mask.user.entry delete 0 end
- $w.mask.user.entry insert 0 $opt(Username)
- $w.mask.passwd.entry delete 0 end
- $w.mask.passwd.entry insert 0 $opt(Password)
- $w.mask.local.entry delete 0 end
- $w.mask.local.entry insert 0 $opt(localDir)
- $w.mask.remote.entry delete 0 end
- $w.mask.remote.entry insert 0 $opt(remoteDir)
-
- bind $w "tkButtonInvoke $w.mask.check.debug"
- bind $w "tkButtonInvoke $w.mask.check.verbose"
- bind $w "focus $w.mask.server.entry"
- bind $w "focus $w.mask.remote.entry"
- bind $w "focus $w.mask.local.entry"
- bind $w "tkButtonInvoke $w.control.accept"
- bind $w "tkButtonInvoke $w.control.cancel"
-
- focus -force $w.mask.server.entry
- update idletasks
-}
-
-proc Usage {} {
- puts "\nusage hpupdate \[-h\] \[directory\]"
- puts " -h help"
- puts " directory local directory"
- puts " (default: current directory)\n"
- exit 0
-}
-
-# Help
-proc Help {mode} {
-
-set help(overview) {
-OVERVIEW
----------
-
-In order to simplify the transfer of the files of my homepage to the
-FTP server of my Internet Service Provider, I looked at the end of
-1996 for an useful tool. Linux offered only the
-abilities of the ftp command line utility. As fan of
-Tcl/Tk, my selection immediately fell on "expect", which was very suitable
-to automate interactive processes like FTP sessions. A little bit
-more Tcl source code and hpupdate 0.1 was finished, a script for
-automatic updating of my homepage files.
-
-At the beginning of 1997, I was more intensively occupied with the
-FTP protocol. At the same time I played with Tcl's socket command.
-Thus the FTP library package for Tcl7.6 was developed.
-This forms the basis for hpupdate.
-
-So far, the program runs under Linux with Tcl/Tk 8.0. I have once
-tested it on Windows 3.11 (with Win32s) and Windows 95 and it runs
-perfectly. Today I have no experiences with Windows NT and
-Macintosh. Perhaps somebody will be found who will test it in these
-environments. I would like to be informed of your experiences!
-Thank you!
-
- usage: hpupdate
-
- example: hpupdate /home/user/hp
-
- ***
-}
-
-set help(install) {
-INSTALLATION
-------------
-
-The great advantage of hpupdate is its platform independence
-because of using Tcl/Tk.
-
-If you do not have Tcl/Tk 8.0 installed already, at first you must
-install it. Get it from the known locations such as http://tcl.sf.net/
-and follow the installation instructions.
-
-If you have not already installed the ftp library package, you must
-install it. Get it from my homepage and follow the
-installation instructions.
-
-Start up hpupdate and change the preferred options in option menu.
-
-"ftp Server Name" - remote FTP server hostname
-"User" - valid username
-"Password" - valid password for user
-"Remote Directory" - remote root for homepage or empty (destination)
-"Local Directory" - local homepage directory (source)
-
-
- ***
-}
-
-set help(usage) {
-USAGE
------
-
-The hpupdate application is divided into 4 areas:
-
- 1.) menu
- 2.) local file list (source)
- 3.) remote file list (destination)
- 4.) status line
-
-1.) menu
-
- File / Connect
-Opens a connection with the FTP server.
-
- File / Disconnetc
-Closes an existing connection with the FTP server.
-
- File / Exit
-Quits hpupdate, the connection to the FTP server will be
-closed automatically.
-
- View / Refresh
-Reads new file data and refreshs it in the list.
-
- Options / Preferences
-Interface to saving your login, password, ftp server, etc.
-
- Help / * look there
-
-2.) local file list
-This list contains the file names and sizes from the local
-homepage directory. The file name, date and time-of-day
-of the files are compared with the time stamp of the remote files.
-When getting the filename for this list, the date/time entry of each file
-is read and compared with the timestamp of the last update.
-Files which have a date and/or time newer than the remote file's timestamp
-are detected as updated and marked for upload.
-It is also possible to mark/unmark the files manually per mouse click.
-The capacity of all files in the directory is displayed in blue.
-Besides this, the capacity of the marked files, as well as the count of files
-(in parentheses) are shown.
-
-By pressing the button "Upload", all selected files in the local
-homepage directory will be transfered to the remote FTP server.
-
-3.) remote file list
-The files at the FTP site appear in this list after connection with
-the FTP server. The remote files will be compared with the local files.
-Files which are not in the local list are detected as superfluous
-and marked for deletion.
-It is also possible to mark/unmark files manually per mouse click.
-The number of marked files is displayed in an extra frame.
-Additionally, the summary disk space is shown.
-The capacity of all files in the directory is displayed in blue.
-Besides this, the capacity of all marked files as well as the count
-(in parentheses) is shown.
-
-By pressing the button "Delete", all selected files in the remote homepage
-directory will be deleted.
-
-NOTE: Synchronize the scrolling of both lists by pressing the checkbutton
-"sychronize scrollbars ".
-
-4.) status line
-The status line shows when the last update of the remote system has taken place.
-This display is always updated after every file transfer.
-Internally, the file "hpupdate.ts" is provided with a new timestamp.
-After this moment, all modified local files are automatically detected
-with the next refresh and marked for upload.
-
-Error and status messages for the FTP connection are also displayed in
-the status line.
-
-EXTENSION:
-The green LED shows the connection status, a lighter green means an
-established connection.
-
- ***
-}
-
-set help(about) {
- - hpupdate
- homepage update program using FTP
-
- Required: Tcl/Tk8.0x
-
- Created: 12/96
- Changed: 04/2002
- Version: 2.1
-
- Copyright (C) 1997,1998, Steffen Traeger
- EMAIL: Steffen.Traeger@t-online.de
- URL: http://home.t-online.de/home/Steffen.Traeger
-}
-
- set w .help
- catch {destroy $w}
- toplevel $w -bd 0 -class Help
- wm transient $w .
- wm title $w "Help - $mode"
- wm iconname $w Hilfe
- wm minsize $w 10 10
- frame $w.buttons -bd 1 -relief flat
- pack $w.buttons -side bottom -fill x -pady 2m
- button $w.buttons.close -text "OK" -command "destroy $w"
- pack $w.buttons.close -side left -expand 1
- frame $w.ftp -bd 1 -relief flat
- pack $w.ftp -side top -expand 1 -fill both
- scrollbar $w.ftp.yscroll -command "$w.ftp.text yview"
- pack $w.ftp.yscroll -in $w.ftp -side right -fill y
- scrollbar $w.ftp.xscroll -relief sunken -orient horizontal -command "$w.ftp.text xview"
- pack $w.ftp.xscroll -in $w.ftp -side bottom -fill x
- text $w.ftp.text -relief sunken -setgrid 1 -wrap none -height 15 -width 60 -bg white -fg black\
- -state normal -xscrollcommand "$w.ftp.xscroll set" \
- -yscrollcommand "$w.ftp.yscroll set"
- pack $w.ftp.text -in $w.ftp -side left -expand 1 -fill both
- wm withdraw $w
- update idletasks
- set x [expr {[winfo x .] + ([winfo width .] / 3) - ([winfo reqwidth $w] / 2)}]
- set y [expr {[winfo y .] + ([winfo height .] / 3) - ([winfo reqheight $w] / 2)}]
- wm geometry $w +$x+$y
- wm deiconify $w
- $w.ftp.text insert 0.0 $help($mode)
- $w.ftp.text configure -state disabled
- update idletasks
-
-}
-##################### main ###################################################
-
-# determine working directory
-if { $argv != "" && $argv != "{}" } {
- if { [lindex $argv 0] == "-h" } {Usage}
- set dir [lindex $argv 0]
- if { [file exists $dir] && [file isdirectory $dir] } {
- set opt(localDir) $dir
- } else {
- puts "Directory \"$dir\" not found!"
- Usage
- }
-} else {
- set opt(localDir) [pwd]
-}
-
-# init defaults
-set opt(Server) ""
-set opt(Username) "anonymous"
-set opt(Password) ""
-set opt(remoteDir) "."
-set opt(ConfigFile) $env(HOME)/hpupdate.cnf
-set opt(TsFile) $env(HOME)/hpupdate.ts
-
-# load configuration file
-if { [file exists $opt(ConfigFile)] } {
- set file [open $opt(ConfigFile) r]
- array set opt [read $file]
- close $file
-}
-set ftp::DEBUG 0
-set ftp::VERBOSE 0
-
-# to compare older and newer files hpupdate creates
-# a new timesstamp on file "hpupdate.ts" after every update
-if { ![file exists $opt(TsFile)] } {Touch $opt(TsFile)}
-set opt(Timestamp) [file mtime $opt(TsFile)]
-set status(header) " last update: [clock format $opt(Timestamp) -format %d.%m.%Y\ %H:%M:%S\ Uhr -gmt 0]"
-
-BusyCommand Refresh
-
DELETED examples/ftp/mirror.tcl
Index: examples/ftp/mirror.tcl
==================================================================
--- examples/ftp/mirror.tcl
+++ /dev/null
@@ -1,40 +0,0 @@
-#!/bin/sh
-# the next line restarts using tclsh \
-exec tclsh8.3 "$0" -- "$@"
-
-package require ftp 2.0
-
-# user configuration
-set server noname
-set username anonymous
-set passwd xxxxxx
-
-# simple progress display
-proc ProgressBar {bytes} {
- puts -nonewline stdout "."; flush stdout
-}
-
-# recursive file transfer
-proc GetTree {conn {dir ""}} {
- catch {file mkdir $dir}
- foreach line [ftp::List $conn $dir] {
- set rc [scan $line "%s %s %s %s %s %s %s %s %s %s %s" \
- perm l u g size d1 d2 d3 name link linksource]
- if { ($name == ".") || ($name == "..") } {continue}
- set type [string range $perm 0 0]
- set name [file join $dir $name]
- switch -- $type {
- d {GetTree $name}
- l {catch {exec ln -s $linksource $name} msg}
- - {ftp::Get $conn $name}
- }
- }
-}
-
-# main
-if {[set conn [ftp::Open $server $username $passwd -progress ProgressBar]] != -1} {
- GetTree $conn
- ftp::Close $conn
- puts "OK!"
-}
-
DELETED examples/ftp/newer.tcl
Index: examples/ftp/newer.tcl
==================================================================
--- examples/ftp/newer.tcl
+++ /dev/null
@@ -1,13 +0,0 @@
-#!/bin/sh
-# the next line restarts using tclsh \
-exec tclsh8.3 "$0" -- "$@"
-
-package require ftp 2.0
-
-if { [set conn [ftp::Open ftp.scriptics.com anonymous xxxx]] != -1} {
- if {[ftp::Newer $conn /pub/tcl/httpd/tclhttpd.tar.gz /usr/local/src/tclhttpd.tgz]} {
- exec echo "New httpd arrived!" | mailx -s ANNOUNCE root
- }
- ftp::Close $conn
-}
-
DELETED examples/ftpd/ftpd
Index: examples/ftpd/ftpd
==================================================================
--- examples/ftpd/ftpd
+++ /dev/null
@@ -1,18 +0,0 @@
-#!/bin/sh
-# FTP daemon
-# \
-exec tclsh8.3 "$0" ${1+"$@"}
-
-if {[catch {package require ftpd}]} {
- set here [file dirname [info script]]
- source [file join .. $here ftpd.tcl]
-}
-
-proc bgerror {args} {
- global errorInfo
- puts stderr "bgerror: [join $args]"
- puts stderr $errorInfo
-}
-
-::ftpd::server
-vwait forever
DELETED examples/ftpd/ftpd.test
Index: examples/ftpd/ftpd.test
==================================================================
--- examples/ftpd/ftpd.test
+++ /dev/null
@@ -1,42 +0,0 @@
-#!/bin/sh
-# FTP daemon for testing the ftp client (modules/ftp).
-# -*- tcl -*- \
-exec tclsh8.3 "$0" ${1+"$@"}
-
-# This ftpd runs on port 7777, uses /tmp as root dir and does not do
-# any authentication at all. IOW, do not run this server for longer
-# periods of time or you create a security hole on your machine. This
-# server is strictly for short testing the implementation of the ftp
-# module over short periods of time.
-
-package require ftpd
-package require log
-
-proc bgerror {args} {
- global errorInfo
- puts stderr "bgerror: [join $args]"
- puts stderr $errorInfo
-}
-
-proc ftplog {level text} {
- if {[string equal $level note]} {set level notice}
- log::log $level $text
-}
-
-proc noauth {args} {
- return 1
-}
-
-proc fakefs {cmd path args} {
- # Use the standard unix fs, i.e. "::ftpd::fsFile::fs", but rewrite the incoming path
- # to stay in the /tmp directory.
-
- set path [file join / tmp [file tail $path]]
- eval [linsert $args 0 ::ftpd::fsFile::fs $cmd $path]
-}
-
-::ftpd::config -logCmd ftplog -authUsrCmd noauth -authFileCmd noauth -fsCmd fakefs
-set ::ftpd::port 7777 ; # Listen on user port
-
-::ftpd::server
-vwait forever
DELETED examples/ftpd/ftpd.unix
Index: examples/ftpd/ftpd.unix
==================================================================
--- examples/ftpd/ftpd.unix
+++ /dev/null
@@ -1,19 +0,0 @@
-#!/bin/sh
-# FTP daemon
-# \
-exec tclsh8.3 "$0" ${1+"$@"}
-
-if {[catch {package require ftpd}]} {
- set here [file dirname [info script]]
- source [file join .. $here ftpd.tcl]
-}
-
-proc bgerror {args} {
- global errorInfo
- puts stderr "bgerror: [join $args]"
- puts stderr $errorInfo
-}
-
-::ftpd::config -authUsrCmd ::ftpd::unixAuth
-::ftpd::server
-vwait forever
DELETED examples/irc/ChangeLog
Index: examples/irc/ChangeLog
==================================================================
--- examples/irc/ChangeLog
+++ /dev/null
@@ -1,5 +0,0 @@
-2003-01-30 David N. Welton
-
- * irc_example.tcl (client::connect): Added some more comments,
- change the startup features. Create ChangeLog.
-
DELETED examples/irc/irc_example.tcl
Index: examples/irc/irc_example.tcl
==================================================================
--- examples/irc/irc_example.tcl
+++ /dev/null
@@ -1,81 +0,0 @@
-#!/bin/sh
-# the next line restarts using tclsh \
- exec tclsh "$0" "$@"
-
-# irc example script, by David N. Welton
-# $Id: irc_example.tcl,v 1.4 2003/01/31 02:52:49 davidw Exp $
-
-# Pick up a nick from the command line, or default to TclIrc.
-
-if { [lindex $argv 0] != "" } {
- set nick [lindex $argv 0]
-} else {
- set nick TclIrc
-}
-
-# I include these so that it can find both the irc package and the
-# logger package that irc needs.
-
-set auto_path "[file join [file dirname [info script]] .. .. modules irc] $auto_path"
-set auto_path "[file join [file dirname [info script]] .. .. modules log] $auto_path"
-package require irc 0.3
-
-namespace eval client {
- variable channel \#tcl
-}
-
-proc client::connect { nick } {
- variable channel
- set cn [::irc::connection irc.freenode.net 6667]
- set ns [namespace qualifiers $cn]
-
- # Register an event for the PING command that comes from the
- # server.
- $cn registerevent PING {
- network send "PONG [msg]"
- set ::PING 1
- }
-
-
- $cn registerevent 376 {
- set ::PING 1
- }
-
- # Register a default action for commands from the server.
- $cn registerevent defaultcmd {
- puts "[action] [msg]"
- }
-
- # Register a default action for numeric events from the server.
- $cn registerevent defaultnumeric {
- puts "[action] XXX [target] XXX [msg]"
- }
-
- # Register a default action for events.
- $cn registerevent defaultevent {
- puts "[action] XXX [who] XXX [target] XXX [msg]"
- }
-
- # Register a default action for PRIVMSG (either public or to a
- # channel).
- $cn registerevent PRIVMSG {
- puts "[who] says to [target] [msg]"
- }
-
- $cn registerevent KICK {
- puts "[who] KICKed [target 1] from [target] : [msg]"
- }
-
- # Connect to the server.
- $cn connect
- $cn user $nick localhost "www.tcl.tk"
- $cn nick $nick
- $cn join $channel
-
- vwait ::PING
- $cn join $channel
-}
-
-# Start things in motion.
-client::connect $nick
-vwait forever
DELETED examples/mime/mbot/README.html
Index: examples/mime/mbot/README.html
==================================================================
--- examples/mime/mbot/README.html
+++ /dev/null
@@ -1,817 +0,0 @@
-The README file: The personal.tcl Mailbot
-
-
-
-
-
The personal.tcl mailbot implements a highly-specialized
-filter for personal messages.
-It MUST not be used by people who receive mailing list traffic in
-their personal mailboxes.
-
Guest lists are an effective mechanism for cutting back on
-excessive mail.
-
-
-
when the mailbot receives a message from you,
-it adds any recipients it finds to a permanent-guest list;
-
-
when the mailbot receives a message from someone on a guest list,
-it adds any recipients it finds to a temporary-guest list; but,
-
-
when the mailbot receives a message from someone not on any guest
-list,
-they get a rejection notice.
-
-
-Note that in order to promote someone to the permanent-guest list,
-you must send them a message (with a copy to yourself).
-In most cases,
-simply replying to the original message accomplishes this.
-Of course,
-if you don't want to promote someone to the permanent-guest list,
-simply remove that address (or your address) from the list of
-recipients in your reply.
-
-
Here are the fine points:
-
-
-
rejection notices contain a passphrase that may be used at most
-once to bypass the guest list mechanism
-(notices also contain the original message to minimize type-in
-by the uninvited);
-
-
a flip-flop is used to avoid mail loops; and,
-
-
messages originated by an administrative address (e.g.,
-"Postmaster") bypass the guest list mechanism
-(unless the message refers to a previously-rejected message,
-in which case it is supressed).
-
-
-
-
The rejection notice should be written carefully to minimize an
-extreme negative reaction on the part of the uninvited.
-Of course,
-by allowing a passphrase,
-this provides something of a CQ test for the uninvited --
-if someone can't pass the test...
-
The mailbot supports the following command line arguments:
-
-
-
-config configFile:
-
-specifies the name of the configuration file to use;
-
-
-debug boolean:
-
-enables debug output;
-
-
-file messageFile:
-
-specifies the name of the file containing the message;
-
-
-originator orginatorAddress:
-
-specifies the email-address of the originator of the message; and,
-
-
-user userName:
-
-specifies the user-identity of the recipient.
-
-
-Note that if "-user" is given,
-then the working directory is set to userName's home directory before
-configFile is sourced,
-and the umask is set defensively.
-
Given the default values,
-only "-user" need be specified.
-The reason is that if a message is being delivered to multiple local
-recipients,
-and if any of the ".forward" files are identical in content,
-then sendmail may not deliver the message to all of the local
-recipients.
-
-
A few other (sendmail related) tips:
-
-
-
If sendmail is configured with smrsh,
-you'll need to symlink personal.tcl into the
-/usr/libexec/sm.bin/ directory.
-
-
Make sure that tclsh8.0 is in the path specified on the third-line
-of personal.tcl.
-
The mailbot begins by parsing its arguments,
-sourcing configFile,
-and then examining the incoming message:
-
-
-
If auditInFile is set,
-a copy of the message is
-saved there.
-
-
If the message contains a previously-encountered "Message-ID",
-processing terminates.
-
-
If the message's originator can not be determined,
-a copy of the message is
-saved in the
-defaultMaildrop and
-processing terminates.
-
-
The originator's email-address is examined:
-
-
-
If the originator appears to be an
-automated administrative process,
-and if a previously rejected email-address is found in the message,
-processing terminates.
-
-
Otherwise,
-if the originator isn't the user,
-or a friend,
-or a permanent-access guest,
-or a temporary-access guest,
-and if noticeFile is set,
-then the message is rejected.
-
-
Otherwise,
-each recipient email-address in the message's header is added to a guest
-list.
-(If the originator is the user,
-the permanent-guest list is used instead of the temporary-guest
-list.)
-
The filename containing the textual notice sent when a message is
-rejected.
-Note that all occurrances of "%passPhrase%" within this file are
-replaced with an at-most-once passphrase allowing the originator to
-bypass the mailbot's filtering.
-Similarly,
-any occurrences of "%subject%" are replaced by the "Subject" of the
-incoming message.
-
If impersonalMail
-returns a non-empty string
-then the message is processed differently than the algorithm given in
-Actions.
-Specifically:
-
-
-
If the message contains a previously-encountered "Message-ID",
-processing terminates.
-
-
If the message's originator can not be determined,
-processing terminates.
-
-
The value returned by
-impersonalMail
-is the folder's name and is broken into one or more components
-seperated by dots (".").
-If there aren't at least two components,
-or if any of the components are empty
-(e.g., the folder is named "sys..announce"),
-then the message is bounced.
-
-
If mappingFile exists,
-that file is examined to see if an entry is present for the folder.
-If so,
-the message is processed according to the value present,
-one of:
-
-
-
"ignore":
-
the message is silently ignored;
-
-
"bounce":
-
the message is noisily bounced; or,
-
-
otherwise:
-
the message is resent to the address.
-
-
-Regardless,
-if an entry was present for the folder,
-then processing terminates.
-
-
The message is saved
-in a file whose name is constructed by replacing each dot (".") in the
-folder name with a directory seperator
-(e.g., if the folder is named "sys.announce",
-then the file is called "announce" underneath the directory "sys"
-underneath the directory identified by
-foldersDirectory.
-
-
Finally,
-the file identified by foldersFile
-is updated as necessary.
-
The file consulted by the mailbot to determine how to process
-"impersonal" messages.
-Each line of the file consists of a folder name and value,
-seperated by a colon (":").
-There are three reserved values: "bounce", "ignore", and "store".
-
If the message is deemed "impersonal",
-return the name of a corresponding private folder;
-otherwise,
-return the empty-string.
-
-
Many mail systems have a mechanism of passing additional
-information when performing final delivery using a program.
-With modern versions of sendmail,
-for example,
-if mail is sent to a local user named "user+detail",
-then,
-in the absense of an alias for either "user+detail" or "user+*",
-then the message is delivered to "user".
-The trick is to get sendmail to pass the "detail" part to the mailbot.
-
-
At present,
-sendmail passes this information only if procmail is your local
-mailer.
-Here's how I do it:
-
This makes available an environment variable called
-"SUFFIX" which has the "details" part.
-The drawback in this approach is that this information is lost if the
-message is re-queued for delivery
-(what's really needed is an addition to the .forward syntax to allow
-macros such as $h to be passed).
-
-
The corresponding impersonalMail procedure is defined as:
-
If an entry for the folder exists in the
-mappingFile,
-and if the value for that entry is "process",
-then this procedure is invoked to return a string indicating what
-action to take
-(cf., Impersonal Mail).
-
The original version of this mailbot was written by the author in 1994,
-implemented using the safe-tcl package
-(Borenstein and Rose, circa 1993).
-
DELETED examples/mime/mbot/README.txt
Index: examples/mime/mbot/README.txt
==================================================================
--- examples/mime/mbot/README.txt
+++ /dev/null
@@ -1,1008 +0,0 @@
-
-
-The README file M. Rose
- Dover Beach Consulting, Inc.
- February 2002
-
-
- The personal.tcl Mailbot
-
-
-Abstract
-
- The personal.tcl mailbot implements a highly-specialized filter for
- personal messages. It MUST not be used by people who receive mailing
- list traffic in their personal mailboxes.
-
-Table of Contents
-
- 1. SYNOPSIS . . . . . . . . . . . . . . . . . . . . . . . . . . 2
- 1.1 Requirements . . . . . . . . . . . . . . . . . . . . . . . . 2
- 1.2 Copyrights . . . . . . . . . . . . . . . . . . . . . . . . . 2
- 2. PHILOSOPHY . . . . . . . . . . . . . . . . . . . . . . . . . 3
- 2.1 Guest Lists . . . . . . . . . . . . . . . . . . . . . . . . 4
- 3. BEHAVIOR . . . . . . . . . . . . . . . . . . . . . . . . . . 5
- 3.1 Arguments . . . . . . . . . . . . . . . . . . . . . . . . . 5
- 3.2 Actions . . . . . . . . . . . . . . . . . . . . . . . . . . 6
- 3.3 The Configuration File . . . . . . . . . . . . . . . . . . . 7
- 3.3.1 Configuration Options . . . . . . . . . . . . . . . . . . . 7
- 3.3.2 Configurable Procedures . . . . . . . . . . . . . . . . . . 10
- References . . . . . . . . . . . . . . . . . . . . . . . . . 12
- Author's Address . . . . . . . . . . . . . . . . . . . . . . 12
- A. Impersonal Mail . . . . . . . . . . . . . . . . . . . . . . 13
- A.1 Configuration Options . . . . . . . . . . . . . . . . . . . 14
- A.1.1 foldersDirectory . . . . . . . . . . . . . . . . . . . . . . 14
- A.1.2 foldersFile . . . . . . . . . . . . . . . . . . . . . . . . 14
- A.1.3 announceMailboxes . . . . . . . . . . . . . . . . . . . . . 14
- A.1.4 mappingFile . . . . . . . . . . . . . . . . . . . . . . . . 14
- A.2 Configurable Procedures . . . . . . . . . . . . . . . . . . 15
- A.2.1 impersonalMail . . . . . . . . . . . . . . . . . . . . . . . 15
- A.2.2 processFolder . . . . . . . . . . . . . . . . . . . . . . . 16
- B. An Example configFile . . . . . . . . . . . . . . . . . . . 17
- C. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 18
-
-
-
-
-
-
-
-
-
-
-
-
-Rose [Page 1]
-
-README The personal.tcl Mailbot February 2002
-
-
-1. SYNOPSIS
-
- Create a configuration file (Section 3.3) and add this line to your
- ".forward" file:
-
- "| LIB/mbot-1.1/personal.tcl -config FILE -user USER"
-
- where "LIB" is where the Tcl library lives, "FILE" is the name of
- your configuration file, and "USER" is your username.
-
-1.1 Requirements
-
- This package requires:
-
- o Tcl version 8.3 [1] or later
-
- o tcl lib [2]
-
- o TclX version 8.0 [3] or later
-
-
-1.2 Copyrights
-
- (c) 1999-2002 Marshall T. Rose
-
- Hold harmless the author, and any lawful use is allowed.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-Rose [Page 2]
-
-README The personal.tcl Mailbot February 2002
-
-
-2. PHILOSOPHY
-
- The mailbot's philosophy is simple:
-
- o The mailbot receives all of your incoming personal mail.
-
- o You ALWAYS copy yourself on every message you send, so that the
- mailbot receives all of your outgoing personal mail.
-
- o The mailbot performs six tasks, all optional:
-
- * makes audit copies of your incoming and outgoing mail;
-
- * performs duplicate supression;
-
- * performs originator supression by rejecting messages from
- people who aren't your friends or on a guest list;
-
- * performs content supression by rejecting messages that contain
- attachments with extensions on your prohibited list;
-
- * sends a textual synopsis to your PDA; and,
-
- * sends a copy to your remote mailbox.
-
- Do NOT use the personal.tcl mailbot if you receive mailing list
- traffic in your personal mailbox. When sending mail to a mailing
- list, either:
-
- o use a "From" address that the personal.tcl mailbot will process as
- "impersonal" mail, (e.g., "hewes+ietf.general@example.com"); or,
-
- o set the "Reply-To" for the message to the mailing list.
-
- Consult Appendix A for information on how "impersonal" mail is
- identified and processed.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-Rose [Page 3]
-
-README The personal.tcl Mailbot February 2002
-
-
-2.1 Guest Lists
-
- Guest lists are an effective mechanism for cutting back on excessive
- mail.
-
- o when the mailbot receives a message from you, it adds any
- recipients it finds to a permanent-guest list;
-
- o when the mailbot receives a message from someone on a guest list,
- it adds any recipients it finds to a temporary-guest list; but,
-
- o when the mailbot receives a message from someone not on any guest
- list, they get a rejection notice.
-
- Note that in order to promote someone to the permanent-guest list,
- you must send them a message (with a copy to yourself). In most
- cases, simply replying to the original message accomplishes this. Of
- course, if you don't want to promote someone to the permanent-guest
- list, simply remove that address (or your address) from the list of
- recipients in your reply.
-
- Here are the fine points:
-
- o rejection notices contain a passphrase that may be used at most
- once to bypass the guest list mechanism (notices also contain the
- original message to minimize type-in by the uninvited);
-
- o a flip-flop is used to avoid mail loops; and,
-
- o messages originated by an administrative address (e.g.,
- "Postmaster") bypass the guest list mechanism (unless the message
- refers to a previously-rejected message, in which case it is
- supressed).
-
- The rejection notice should be written carefully to minimize an
- extreme negative reaction on the part of the uninvited. Of course,
- by allowing a passphrase, this provides something of a CQ test for
- the uninvited -- if someone can't pass the test...
-
-
-
-
-
-
-
-
-
-
-
-
-
-Rose [Page 4]
-
-README The personal.tcl Mailbot February 2002
-
-
-3. BEHAVIOR
-
-3.1 Arguments
-
- The mailbot supports the following command line arguments:
-
- -config configFile: specifies the name of the configuration file
- to use;
-
- -debug boolean: enables debug output;
-
- -file messageFile: specifies the name of the file containing the
- message;
-
- -originator orginatorAddress: specifies the email-address of the
- originator of the message; and,
-
- -user userName: specifies the user-identity of the recipient.
-
- Note that if "-user" is given, then the working directory is set to
- userName's home directory before configFile is sourced, and the umask
- is set defensively.
-
- The default values are:
-
- personal.tcl -config .personal-config.tcl \
- -debug 0 \
- -file - \
- -originator "derived from message"
-
- Given the default values, only "-user" need be specified. The reason
- is that if a message is being delivered to multiple local recipients,
- and if any of the ".forward" files are identical in content, then
- sendmail may not deliver the message to all of the local recipients.
-
- A few other (sendmail related) tips:
-
- o If sendmail is configured with smrsh, you'll need to symlink
- personal.tcl into the /usr/libexec/sm.bin/ directory.
-
- o Make sure that tclsh8.0 is in the path specified on the third-line
- of personal.tcl.
-
- o You should chmod your ".forward" file to 0600.
-
-
-
-
-
-
-
-Rose [Page 5]
-
-README The personal.tcl Mailbot February 2002
-
-
-3.2 Actions
-
- The mailbot begins by parsing its arguments, sourcing configFile, and
- then examining the incoming message:
-
- 1. If auditInFile (Section 3.3.1.3) is set, a copy of the message is
- saved (Section 3.3.2.4) there.
-
- 2. If the message contains a previously-encountered "Message-ID",
- processing terminates.
-
- 3. If the message's originator can not be determined, a copy of the
- message is saved (Section 3.3.2.4) in the defaultMaildrop
- (Section 3.3.1.2) and processing terminates.
-
- 4. The originator's email-address is examined:
-
- 1. If the originator appears to be an automated administrative
- process (Section 3.3.2.1), and if a previously rejected
- email-address is found in the message, processing terminates.
-
- 2. Otherwise, if the originator isn't the user (Section
- 3.3.2.3), or a friend (Section 3.3.2.2), or a permanent-
- access guest, or a temporary-access guest, and if noticeFile
- (Section 3.3.1.10) is set, then the message is rejected.
-
- 3. Otherwise, each recipient email-address in the message's
- header is added to a guest list. (If the originator is the
- user (Section 3.3.2.3), the permanent-guest list is used
- instead of the temporary-guest list.)
-
- 5. If the originator is the the user (Section 3.3.2.3), then:
-
- 1. If auditOutFile (Section 3.3.1.4) is set, saved (Section
- 3.3.2.4) there.
-
- 2. Regardless, processing terminates.
-
- 6. If pdaMailboxes (Section 3.3.1.11) is set, and if any plaintext
- is contained in the message, then the plaintext is sent to those
- email-addresses.
-
- 7. If remoteMailboxes (Section 3.3.1.12) is set, and if the message
- is successful resent to those email-addresses, then processing
- terminates.
-
- 8. A copy of the message is saved (Section 3.3.2.4) in the
- defaultMaildrop (Section 3.3.1.2) and processing terminates.
-
-
-
-Rose [Page 6]
-
-README The personal.tcl Mailbot February 2002
-
-
-3.3 The Configuration File
-
- There are two kinds of information that may be defined in configFile:
- configuration options (Section 3.3.1) and configurable procedures
- (Section 3.3.2).
-
- Here's a simple example of a configFile for a user named "example":
-
- set options(dataDirectory) .personal
- set options(defaultMaildrop) /var/mail/example
- set options(logFile) [file join .personal personal.log]
- set options(noticeFile) [file join .personal notice.txt]
-
-
-3.3.1 Configuration Options
-
- configFile must define dataDirectory (Section 3.3.1.1) and
- defaultMaildrop (Section 3.3.1.2). All other configuration options
- are optional.
-
-3.3.1.1 dataDirectory
-
- The directory where the mailbot keeps its databases. The
- subdirectories are:
-
- badaddrs: the directory of rejected email-addresses
-
- inaddrs: the directory of originator email-addresses
-
- msgids: the directory of Message-IDs
-
- outaddrs: the permanent-guest list
-
- phrases: the directory of at-most-once passphrases
-
- tmpaddrs: the temporary-guest list
-
- If you want to remove someone from a guest list, simply go to that
- directory and delete the corresponding file.
-
-3.3.1.2 defaultMaildrop
-
- The filename where messages are saved (Section 3.3.2.4) for later
- viewing by your user agent.
-
-3.3.1.3 auditInFile
-
- The filename where messages are saved (Section 3.3.2.4) for audit
-
-
-
-Rose [Page 7]
-
-README The personal.tcl Mailbot February 2002
-
-
- purposes.
-
-3.3.1.4 auditOutFile
-
- The filename where your outgoing messages are saved (Section 3.3.2.4)
- for audit purposes.
-
-3.3.1.5 dropNames
-
- A list of filename extensions for attachments that automatically
- cause the message to be rejected.
-
-3.3.1.6 friendlyDomains
-
- A list used by friendP (Section 3.3.2.2) giving the domain names
- where your friends live.
-
-3.3.1.7 friendlyfire
-
- If present and true, then someone sending a message both to you and
- someone you've previously sent mail to, is considered a friend.
-
-3.3.1.8 logFile
-
- The filename where the mailbot logs (Section 3.3.2.8) its actions.
-
-3.3.1.9 myMailbox
-
- Your preferred email-address with commentary text, e.g.,
-
- Arlington Hewes
-
-
-3.3.1.10 noticeFile
-
- The filename containing the textual notice sent when a message is
- rejected. Note that all occurrances of "%passPhrase%" within this
- file are replaced with an at-most-once passphrase allowing the
- originator to bypass the mailbot's filtering. Similarly, any
- occurrences of "%subject%" are replaced by the "Subject" of the
- incoming message.
-
-3.3.1.11 pdaMailboxes
-
- The email-addresses where a textual synopsis of the incoming message
- is sent.
-
-
-
-
-
-Rose [Page 8]
-
-README The personal.tcl Mailbot February 2002
-
-
-3.3.1.12 remoteMailboxes
-
- The email-addresses where a copy of the incoming message is resent.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-Rose [Page 9]
-
-README The personal.tcl Mailbot February 2002
-
-
-3.3.2 Configurable Procedures
-
- All of these procedures are defined in personal.tcl. You may
- override any of them in configFile.
-
-3.3.2.1 adminP
-
- proc adminP {local domain}
-
- Returns "1" if the email-address is an automated administrative
- process.
-
-3.3.2.2 friendP
-
- proc friendP {local domain}
-
- Returns "1" if the email-address is from a friendly domain (Section
- 3.3.1.6) or sub-domain.
-
-3.3.2.3 ownerP
-
- proc ownerP {local domain}
-
- Returns "1" if the email-address refers to the user (as determined by
- looking at myMailbox (Section 3.3.1.9), pdaMailboxes (Section
- 3.3.1.11), and remoteMailboxes (Section 3.3.1.12).
-
-3.3.2.4 saveMessage
-
- proc saveMessage {inF {outF ""}}
-
- Saves a copy of the message contained in the file inF. If the
- destination file, outF, isn't specified, it defaults to the
- defaultMaildrop (Section 3.3.1.2).
-
-3.3.2.5 findPhrase
-
- proc findPhrase {subject}
-
- Returns "1" if a previously-allocated passphrase is present in the
- subject. If so, the passphrase is forgotten.
-
-3.3.2.6 makePhrase
-
- proc makePhrase {}
-
- Returns an at-most-once passphrase for use with a rejection notice.
-
-
-
-
-Rose [Page 10]
-
-README The personal.tcl Mailbot February 2002
-
-
-3.3.2.7 pruneDir
-
- proc pruneDir {dir type}
-
- Removes old entries from one of the mailbot's databases (Section
- 3.3.1.1). The second parameter is one of "addr", "msgid", or
- "phrase".
-
-3.3.2.8 tclLog
-
- proc tclLog {message}
-
- Writes a message to the logFile (Section 3.3.1.8).
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-Rose [Page 11]
-
-README The personal.tcl Mailbot February 2002
-
-
-References
-
- [1]
-
- [2]
-
- [3]
-
-
-Author's Address
-
- Marshall T. Rose
- Dover Beach Consulting, Inc.
- POB 255268
- Sacramento, CA 95865-5268
- US
-
- Phone: +1 916 483 8878
- Fax: +1 916 483 8848
- EMail: mrose@dbc.mtview.ca.us
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-Rose [Page 12]
-
-README The personal.tcl Mailbot February 2002
-
-
-Appendix A. Impersonal Mail
-
- If impersonalMail (Appendix A.2.1) returns a non-empty string then
- the message is processed differently than the algorithm given in
- Section 3.2. Specifically:
-
- 1. If the message contains a previously-encountered "Message-ID",
- processing terminates.
-
- 2. If the message's originator can not be determined, processing
- terminates.
-
- 3. The value returned by impersonalMail (Appendix A.2.1) is the
- folder's name and is broken into one or more components seperated
- by dots ("."). If there aren't at least two components, or if
- any of the components are empty (e.g., the folder is named
- "sys..announce"), then the message is bounced.
-
- 4. If mappingFile (Appendix A.1.4) exists, that file is examined to
- see if an entry is present for the folder. If so, the message is
- processed according to the value present, one of:
-
- "ignore": the message is silently ignored;
-
- "bounce": the message is noisily bounced; or,
-
- otherwise: the message is resent to the address.
-
- Regardless, if an entry was present for the folder, then
- processing terminates.
-
- 5. The message is saved (Section 3.3.2.4) in a file whose name is
- constructed by replacing each dot (".") in the folder name with a
- directory seperator (e.g., if the folder is named "sys.announce",
- then the file is called "announce" underneath the directory "sys"
- underneath the directory identified by foldersDirectory (Appendix
- A.1.1).
-
- 6. Finally, the file identified by foldersFile (Appendix A.1.2) is
- updated as necessary.
-
-
-
-
-
-
-
-
-
-
-
-Rose [Page 13]
-
-README The personal.tcl Mailbot February 2002
-
-
-A.1 Configuration Options
-
- If "impersonal" mail is received, then foldersFile (Appendix A.1.2)
- and foldersDirectory (Appendix A.1.1) must exist.
-
-A.1.1 foldersDirectory
-
- The directory where the mailbot keeps private folders.
-
-A.1.2 foldersFile
-
- This file contains one line for each private folder.
-
-A.1.3 announceMailboxes
-
- The email-addresses where an announcement is sent when a new private
- folder is created.
-
-A.1.4 mappingFile
-
- The file consulted by the mailbot to determine how to process
- "impersonal" messages. Each line of the file consists of a folder
- name and value, seperated by a colon (":"). There are three reserved
- values: "bounce", "ignore", and "store".
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-Rose [Page 14]
-
-README The personal.tcl Mailbot February 2002
-
-
-A.2 Configurable Procedures
-
- All of these procedures are defined in personal.tcl. You may
- override any of them in configFile.
-
-A.2.1 impersonalMail
-
- proc impersonalMail {}
-
- If the message is deemed "impersonal", return the name of a
- corresponding private folder; otherwise, return the empty-string.
-
- Many mail systems have a mechanism of passing additional information
- when performing final delivery using a program. With modern versions
- of sendmail, for example, if mail is sent to a local user named
- "user+detail", then, in the absense of an alias for either
- "user+detail" or "user+*", then the message is delivered to "user".
- The trick is to get sendmail to pass the "detail" part to the
- mailbot.
-
- At present, sendmail passes this information only if procmail is your
- local mailer. Here's how I do it:
-
- *** _alias.c Tue Dec 29 10:42:25 1998
- --- alias.c Sat Sep 18 21:51:35 1999
- ***************
- *** 813,818 ****
- --- 813,821 ----
- define('z', user->q_home, e);
- define('u', user->q_user, e);
- define('h', user->q_host, e);
- +
- + setuserenv("SUFFIX", user->q_host);
- +
- if (ForwardPath == NULL)
- ForwardPath = newstr("\201z/.forward");
-
- This makes available an environment variable called "SUFFIX" which
- has the "details" part. The drawback in this approach is that this
- information is lost if the message is re-queued for delivery (what's
- really needed is an addition to the .forward syntax to allow macros
- such as $h to be passed).
-
-
-
-
-
-
-
-
-
-Rose [Page 15]
-
-README The personal.tcl Mailbot February 2002
-
-
- The corresponding impersonalMail procedure is defined as:
-
- proc impersonalMail {} {
- global env
-
- return $env(SUFFIX)
- }
-
-
-A.2.2 processFolder
-
- proc processFolder {folderName mimeT} { return $string }
-
- If an entry for the folder exists in the mappingFile (Appendix
- A.1.4), and if the value for that entry is "process", then this
- procedure is invoked to return a string indicating what action to
- take (cf., Appendix A).
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-Rose [Page 16]
-
-README The personal.tcl Mailbot February 2002
-
-
-Appendix B. An Example configFile
-
- Here is the ".forward" file for the user "hewes":
-
- "|/usr/pkg/lib/mbot-1.1/personal.tcl
- -config .personal/config.tcl -user hewes"
-
- (Of course, it's all on one line.)
-
- Here is the user's ".personal/config.tcl" file:
-
- array set options [list \
- dataDirectory .personal \
- defaultMaildrop /var/mail/hewes \
- auditInFile [file join .personal INCOMING] \
- auditOutFile [file join .personal OUTGOING] \
- friendlyDomains [list tcp.int example.com] \
- logFile [file join .personal personal.log] \
- myMailbox "Arlington Hewes " \
- pdaMailboxes hewes.pager@example.com \
- noticeFile [file join .personal notice.txt] \
- foldersDirectory [file join .personal folders] \
- foldersFile [file join .personal .mailboxlist] \
- announceMailboxes hewes+sys.announce@example.com \
- mappingFile [file join .personal mapping] \
- friendlyFire 1 \
- dropNames [list *.bat *.exe *.src *.pif *.wav *.vbs] \
- ]
-
- proc impersonalMail {} {
- global env
-
- return $env(SUFFIX)
- }
-
- Note that because remoteMailboxes (Section 3.3.1.12) isn't defined,
- personal messages are ultimately stored in the user's defaultMaildrop
- (Section 3.3.1.2).
-
-
-
-
-
-
-
-
-
-
-
-
-
-Rose [Page 17]
-
-README The personal.tcl Mailbot February 2002
-
-
-Appendix C. Acknowledgements
-
- The original version of this mailbot was written by the author in
- 1994, implemented using the safe-tcl package (Borenstein and Rose,
- circa 1993).
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-Rose [Page 18]
-
DELETED examples/mime/mbot/README.xml
Index: examples/mime/mbot/README.xml
==================================================================
--- examples/mime/mbot/README.xml
+++ /dev/null
@@ -1,720 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-The personal.tcl Mailbot
-
-
-Dover Beach Consulting, Inc.
-
-
-POB 255268
-SacramentoCA95865-5268
-US
-
-+1 916 483 8878
-+1 916 483 8848
-mrose@dbc.mtview.ca.us
-
-
-
-
-
-The personal.tcl mailbot implements a highly-specialized
-filter for personal messages.
-It MUST not be used by people who receive mailing list traffic in
-their personal mailboxes.
-
-
-
-
-
-
-
-This package requires:
-
-Tcl version 8.3
-or later
-
-tcl lib
-
-TclX version 8.0
-or later
-
-
-
-
-(c) 1999-2002 Marshall T. Rose
-
-Hold harmless the author, and any lawful use is allowed.
-
-
-
-
-The mailbot's philosophy is simple:
-
-The mailbot receives all of your incoming personal mail.
-
-You ALWAYS copy yourself on every message you send,
-so that the mailbot receives all of your outgoing personal mail.
-
-The mailbot performs six tasks, all optional:
-
-makes audit copies of your incoming and outgoing mail;
-
-performs duplicate supression;
-
-performs originator supression by rejecting messages from people
-who aren't your friends or on a guest list;
-
-performs content supression by rejecting messages that contain
-attachments with extensions on your prohibited list;
-
-sends a textual synopsis to your PDA; and,
-
-sends a copy to your remote mailbox.
-
-
-
-Do NOT use the personal.tcl mailbot if you receive mailing list
-traffic in your personal mailbox.
-When sending mail to a mailing list,
-either:
-
-use a "From" address that the personal.tcl mailbot will process as
-"impersonal" mail,
-(e.g., "hewes+ietf.general@example.com"); or,
-
-set the "Reply-To" for the message to the mailing list.
-
-Consult for information on how
-"impersonal" mail is identified and processed.
-
-
-
-
-Guest lists are an effective mechanism for cutting back on
-excessive mail.
-
-when the mailbot receives a message from you,
-it adds any recipients it finds to a permanent-guest list;
-
-when the mailbot receives a message from someone on a guest list,
-it adds any recipients it finds to a temporary-guest list; but,
-
-when the mailbot receives a message from someone not on any guest
-list,
-they get a rejection notice.
-
-Note that in order to promote someone to the permanent-guest list,
-you must send them a message (with a copy to yourself).
-In most cases,
-simply replying to the original message accomplishes this.
-Of course,
-if you don't want to promote someone to the permanent-guest list,
-simply remove that address (or your address) from the list of
-recipients in your reply.
-
-Here are the fine points:
-
-rejection notices contain a passphrase that may be used at most
-once to bypass the guest list mechanism
-(notices also contain the original message to minimize type-in
-by the uninvited);
-
-a flip-flop is used to avoid mail loops; and,
-
-messages originated by an administrative address (e.g.,
-"Postmaster") bypass the guest list mechanism
-(unless the message refers to a previously-rejected message,
-in which case it is supressed).
-
-
-The rejection notice should be written carefully to minimize an
-extreme negative reaction on the part of the uninvited.
-Of course,
-by allowing a passphrase,
-this provides something of a CQ test for the uninvited --
-if someone can't pass the test...
-
-
-
-
-
-The mailbot supports the following command line arguments:
-
-
-specifies the name of the configuration file to use;
-
-
-enables debug output;
-
-
-specifies the name of the file containing the message;
-
-
-specifies the email-address of the originator of the message; and,
-
-
-specifies the user-identity of the recipient.
-
-Note that if "-user" is given,
-then the working directory is set to userName's home directory before
-configFile is sourced,
-and the umask is set defensively.
-
-
-
-A few other (sendmail related) tips:
-
-If sendmail is configured with smrsh,
-you'll need to symlink personal.tcl into the
-/usr/libexec/sm.bin/ directory.
-
-Make sure that tclsh8.0 is in the path specified on the third-line
-of personal.tcl.
-
-You should chmod your ".forward" file to 0600.
-
-
-
-
-
-
-The mailbot begins by parsing its arguments,
-sourcing configFile,
-and then examining the incoming message:
-
-If auditInFile is set,
-a copy of the message is
-saved there.
-
-If the message contains a previously-encountered "Message-ID",
-processing terminates.
-
-If the message's originator can not be determined,
-a copy of the message is
-saved in the
-defaultMaildrop and
-processing terminates.
-
-The originator's email-address is examined:
-
-If the originator appears to be an
-automated administrative process,
-and if a previously rejected email-address is found in the message,
-processing terminates.
-
-Otherwise,
-if the originator isn't the user,
-or a friend,
-or a permanent-access guest,
-or a temporary-access guest,
-and if noticeFile is set,
-then the message is rejected.
-
-Otherwise,
-each recipient email-address in the message's header is added to a guest
-list.
-(If the originator is the user,
-the permanent-guest list is used instead of the temporary-guest
-list.)
-
-
-If the originator is the the user,
-then:
-
-If auditOutFile is set,
-saved there.
-
-Regardless, processing terminates.
-
-
-If pdaMailboxes is set,
-and if any plaintext is contained in the message,
-then the plaintext is sent to those email-addresses.
-
-If remoteMailboxes is set,
-and if the message is successful resent to those email-addresses,
-then processing terminates.
-
-A copy of the message is
-saved in the
-defaultMaildrop and
-processing terminates.
-
-
-
-
-There are two kinds of information that may be defined in configFile:
-configuration options and
-configurable procedures.
-
-
-
-
-configFile must define
-dataDirectory
-and
-defaultMaildrop.
-All other configuration options are optional.
-
-
-The directory where the mailbot keeps its databases.
-The subdirectories are:
-
-the directory of rejected email-addresses
-
-the directory of originator email-addresses
-
-the directory of Message-IDs
-
-the permanent-guest list
-
-the directory of at-most-once passphrases
-
-the temporary-guest list
-
-If you want to remove someone from a guest list,
-simply go to that directory and delete the corresponding file.
-
-
-
-The filename where messages are
-saved for later viewing by
-your user agent.
-
-
-
-The filename where messages are
-saved for audit purposes.
-
-
-
-The filename where your outgoing messages are
-saved for audit purposes.
-
-
-
-A list of filename extensions for attachments that automatically
-cause the message to be rejected.
-
-
-
-A list used by friendP giving
-the domain names where your friends live.
-
-
-
-If present and true,
-then someone sending a message both to you and someone you've
-previously sent mail to,
-is considered a friend.
-
-
-
-The filename where the mailbot
-logs its actions.
-
-
-
-
-
-
-
-The filename containing the textual notice sent when a message is
-rejected.
-Note that all occurrances of "%passPhrase%" within this file are
-replaced with an at-most-once passphrase allowing the originator to
-bypass the mailbot's filtering.
-Similarly,
-any occurrences of "%subject%" are replaced by the "Subject" of the
-incoming message.
-
-
-
-The email-addresses where a textual synopsis of the incoming message is
-sent.
-
-
-
-The email-addresses where a copy of the incoming message is resent.
-
-
-
-
-
-
-All of these procedures are defined in personal.tcl.
-You may override any of them in configFile.
-
-
-
-
-Returns "1" if the email-address is an automated administrative
-process.
-
-
-
-
-
-Returns "1" if the email-address is from a
-friendly domain or
-sub-domain.
-
-
-
-
-
-Returns "1" if the email-address refers to the user
-(as determined by looking at
-myMailbox,
-pdaMailboxes, and
-remoteMailboxes.
-
-
-
-
-
-Saves a copy of the message contained in the file inF.
-If the destination file,
-outF,
-isn't specified,
-it defaults to the
-defaultMaildrop.
-
-
-
-
-
-Returns "1" if a previously-allocated passphrase is present in the
-subject.
-If so,
-the passphrase is forgotten.
-
-
-
-
-
-Returns an at-most-once passphrase for use with a rejection notice.
-
-
-
-
-
-Removes old entries from one of the mailbot's
-databases.
-The second parameter is one of "addr", "msgid", or "phrase".
-
-
-
-
-
-Writes a message to the logFile.
-
-
-
-
-
-
-
-
-
-
-
-
-If impersonalMail
-returns a non-empty string
-then the message is processed differently than the algorithm given in
-.
-Specifically:
-
-If the message contains a previously-encountered "Message-ID",
-processing terminates.
-
-If the message's originator can not be determined,
-processing terminates.
-
-The value returned by
-impersonalMail
-is the folder's name and is broken into one or more components
-seperated by dots (".").
-If there aren't at least two components,
-or if any of the components are empty
-(e.g., the folder is named "sys..announce"),
-then the message is bounced.
-
-If mappingFile exists,
-that file is examined to see if an entry is present for the folder.
-If so,
-the message is processed according to the value present,
-one of:
-
-the message is silently ignored;
-
-the message is noisily bounced; or,
-
-the message is resent to the address.
-
-Regardless,
-if an entry was present for the folder,
-then processing terminates.
-
-The message is saved
-in a file whose name is constructed by replacing each dot (".") in the
-folder name with a directory seperator
-(e.g., if the folder is named "sys.announce",
-then the file is called "announce" underneath the directory "sys"
-underneath the directory identified by
-foldersDirectory.
-
-Finally,
-the file identified by foldersFile
-is updated as necessary.
-
-
-
-
-
-If "impersonal" mail is received,
-then foldersFile and
-foldersDirectory
-must exist.
-
-
-The directory where the mailbot keeps private folders.
-
-
-
-This file contains one line for each private folder.
-
-
-
-The email-addresses where an announcement is sent when a new
-private folder is created.
-
-
-
-The file consulted by the mailbot to determine how to process
-"impersonal" messages.
-Each line of the file consists of a folder name and value,
-seperated by a colon (":").
-There are three reserved values: "bounce", "ignore", and "store".
-
-
-
-
-
-
-All of these procedures are defined in personal.tcl.
-You may override any of them in configFile.
-
-
-
-
-If the message is deemed "impersonal",
-return the name of a corresponding private folder;
-otherwise,
-return the empty-string.
-
-Many mail systems have a mechanism of passing additional
-information when performing final delivery using a program.
-With modern versions of sendmail,
-for example,
-if mail is sent to a local user named "user+detail",
-then,
-in the absense of an alias for either "user+detail" or "user+*",
-then the message is delivered to "user".
-The trick is to get sendmail to pass the "detail" part to the mailbot.
-
-
-
-
-
-
-
-
-
-If an entry for the folder exists in the
-mappingFile,
-and if the value for that entry is "process",
-then this procedure is invoked to return a string indicating what
-action to take
-(cf., ).
-
-
-
-
-
-
-
-
-
-
-
-The original version of this mailbot was written by the author in 1994,
-implemented using the safe-tcl package
-(Borenstein and Rose, circa 1993).
-
-
-
-
-
DELETED examples/mime/mbot/impersonal.tcl
Index: examples/mime/mbot/impersonal.tcl
==================================================================
--- examples/mime/mbot/impersonal.tcl
+++ /dev/null
@@ -1,533 +0,0 @@
-#!/bin/sh
-# the next line restarts using tclsh \
-PATH=/usr/pkg/bin:/usr/local/bin:/usr/bin:/bin LD_LIBRARY_PATH=/usr/pkg/lib:/usr/local/lib:/usr/lib export PATH LD_LIBRARY_PATH; exec tclsh8.3 "$0" "$@"
-
-# impersonal.tcl - export impersonal mail via the web
-#
-# (c) 1999 Marshall T. Rose
-# Hold harmless the author, and any lawful use is allowed.
-#
-
-
-global options
-
-
-# begin of routines that may be redefined in configFile
-
-proc tclLog {message} {
- global options
-
- if {([info exists options(debugP)]) && ($options(debugP) > 0)} {
- puts stderr $message
- }
-
- if {([string first "DEBUG " $message] == 0) \
- || ([catch { set fd [open $options(logFile) \
- { WRONLY CREAT APPEND }] }])} {
- return
- }
-
- regsub -all "\n" $message " " message
-
- catch { puts -nonewline $fd \
- [format "%s %-8.8s %06d %s\n" \
- [clock format [clock seconds] -format "%m/%d %T"] \
- personal [expr [pid]%65535] $message] }
-
- catch { close $fd }
-}
-
-# end of routines that may be redefined in configFile
-
-
-proc firstext {mime} {
- array set props [mime::getproperty $mime]
-
- if {[info exists props(parts)]} {
- foreach part $props(parts) {
- if {[string compare [firstext $part] ""]} {
- return $part
- }
- }
- } else {
- switch -- $props(content) {
- text/plain
- -
- text/html {
- return $mime
- }
- }
- }
-}
-
-proc sanitize {text} {
- regsub -all "&" $text {\&} text
- regsub -all "<" $text {\<} text
-
- return $text
-}
-
-proc cleanup {{message ""} {code 500}} {
- global errorCode errorInfo
-
- set ecode $errorCode
- set einfo $errorInfo
-
- if {[string compare $message ""]} {
- tclLog $message
-
- catch {
- puts stdout "HTTP/1.0 $code Server Error
-Content-Type: text/html
-Status: 500 Server Error
-
-Service Problem
-