Temporarily use -O1 until segfault with -O2+krb5+iksd is fixed
[ckermit.git] / ckuins.txt
1
2    [1]The Columbia Crown The Kermit Project | Columbia University
3    612 West 115th Street, New York NY 10025 USA o [2]kermit@columbia.edu
4    ...since 1981
5    [3]Home [4]Kermit 95 [5]C-Kermit [6]Scripts [7]Current [8]New [9]FAQ
6    [10]Support
7
8 C-Kermit 9.0 Installation Instructions and Options for Unix
9
10    [ [11]Contents ] [ [12]C-Kermit ] [ [13]Kermit Home ]
11
12    Frank da Cruz
13    The Kermit Project
14    Columbia University
15
16       As of C-Kermit version: 9.0.300, 30 June 2011
17       This file last updated: Tue Jun 28 08:28:08 2011 (New York City
18    time)
19
20    IF YOU ARE READING A PLAIN-TEXT version of this document, it is a
21    plain-text copy of a Web page. You can visit the original (and possibly
22    more up-to-date) Web page here:
23
24 [14]http://www.columbia.edu/kermit/ckuins.html
25
26 CONTENTS
27
28    [15]OVERVIEW
29     1. [16]INTERNET QUICK START
30     2. [17]INSTALLING FROM PACKAGES
31     3. [18]INSTALLING PREBUILT BINARIES
32     4. [19]BUILDING FROM SOURCE CODE
33     5. [20]INSTALLING THE KERMIT FILES
34     6. [21]INSTALLING UNIX C-KERMIT FROM DOS-FORMAT DISKETTES
35     7. [22]CHECKING THE RESULTS
36     8. [23]REDUCING THE SIZE OF THE EXECUTABLE PROGRAM IMAGE
37     9. [24]UNIX VERSIONS
38    10. [25]DIALING OUT AND COORDINATING WITH UUCP
39    11. [26]RUNNING UNIX C-KERMIT SETUID OR SETGID
40    12. [27]CONFIGURING UNIX WORKSTATIONS
41    13. [28]BIZARRE BEHAVIOR AT RUNTIME
42    14. [29]CRASHES AND CORE DUMPS
43    15. [30]SYSLOGGING
44    16. [31]BUILDING SECURE VERSIONS OF C-KERMIT 9.0
45    17. [32]INSTALLING C-KERMIT AS AN SSH SERVER SUBSYSTEM
46
47 OVERVIEW
48
49    [ [33]Top ] [ [34]Contents ] [ [35]Next ]
50
51      WARNING: This document contains notes that have been accumulating
52      since the mid 1980s. Many of the products and Unix versions
53      mentioned here have not been heard of in a long while, but that does
54      not necessarily mean they are not still running in some obscure
55      nook.
56
57    This file contains Unix-specific information. A lot of it. Unlike most
58    other packages, C-Kermit tries very hard to be portable to every Unix
59    variety (and every release of each one) known to exist, including many
60    that are quite old, as well as to other platforms like VMS, AOS/VS,
61    VOS, OS-9, the BeBox, the Amiga, etc.
62
63    Since C-Kermit gets so deeply into the file system, i/o system, and
64    other areas that differ radically from one Unix platform to the next,
65    this means that a lot can go wrong when you try to install C-Kermit on
66    (for example) a new release of a particular variety of Unix, in which
67    certain things might have changed that C-Kermit depended upon.
68
69    This file concentrates on installation. For a description of general
70    configuration options for C-Kermit, please read the [36]Configurations
71    Options document. For troubleshooting after installation, see the
72    [37]General Hints and Tips and [38]Unix-Specific Hints and Tips
73    documents. The latter, in particular, contains lots of information on
74    lots of specific Unix platforms. If you want to work on the source
75    code, see the [39]C-Kermit Program Logic Manual
76
77    You may install C-Kermit:
78
79      * From an "[40]install package", if one is available.
80      * As a [41]prebuilt binary, if available, plus accompanying text
81        files.
82      * By building from [42]source code.
83
84 1. INTERNET QUICK START
85
86    [ [43]Top ] [ [44]Contents ] [ [45]Next ] [ [46]Previous ]
87
88    If your Unix computer is on the Internet and it has a C compiler,
89    here's how to download, build, and install C-Kermit directly from the
90    "tarballs" or Zip archives:
91
92     1. Make a fresh directory and cd to it.
93     2. Download the C-Kermit source code:
94        [47]ftp://www.columbia.edu/kermit/archives/cku211.tar.Z (compress
95        format) or [48]ftp://www.columbia.edu/kermit/archives/cku211.tar.gz
96        (gunzip format). If those links don't work, FTP transfers are being
97        blocked; try these HTTP links instead:
98        [49]http://kermit.columbia.edu/ftp/archives/cku211.tar.Z (compress
99        format) or
100        [50]http://kermit.columbia.edu/ftp/archives/cku211.tar.gz (gunzip
101        format).
102     3. Uncompress the compressed tar file with "uncompress" or "gunzip",
103        according to which type of compressed file you downloaded. (If you
104        don't understand this, you could download a (much larger)
105        uncompressed tar archive directly:
106        [51]ftp://www.columbia.edu/kermit/archives/cku211.tar or
107        [52]http://kermit.columbia.edu/ftp/archives/cku211.tar
108     4. Now type "tar xvf cku211.tar" to unpack the individual files from
109        the tar archive.
110     5. Type "rm cku211.tar" to get rid of the tar archive, which is no
111        longer needed.
112     6. Read the comments at the top of the makefile to find out which
113        target to use and then type the appropriate "make" command, such as
114        "make linux", "make solaris8", etc.
115     7. This produces a binary in your current directory called "wermit".
116        Start it by typing "./wermit" and [53]try it out to make sure it
117        works. Then read [54]Section 5 for how to install it, or simply
118        copy the wermit binary to the desired public directory, rename it
119        to kermit, and give it the needed permissions (and, if it is going
120        to be used to dial out, give it the same group and owner and
121        permissions as the cu, tip, or minicom program).
122
123    For secure installations, see [55]Sections 5 and [56]16.
124
125 2. INSTALLING FROM PACKAGES
126
127    [ [57]Top ] [ [58]Contents ] [ [59]Next ] [ [60]Previous ]
128
129    Various Unix varieties -- Linux, Solaris, AIX, etc -- now incorporate
130    the idea of "install packages", and many users expect to find all new
131    applications in this format. A selection of install packages might be
132    available for any given release of C-Kermit, but there is a tradeoff
133    between convenience and safety. Unix presents several notable problems
134    to the builder of install packages:
135
136     a. Since C-Kermit is portable to many non-Unix platforms (VMS, VOS,
137        AOS/VS, etc), some of the files in the C-Kermit distribution do not
138        fit into the Unix application model. In particular, C-Kermit
139        includes some plain text files (described in [61]Section 5) and
140        Unix has no standard place to put such files. Typical Unix package
141        managers do not allow for them. Where should they go, and how will
142        the user know where to find them?
143     b. Installation of any program that will be used to make modem calls
144        requires some important decisions from the installer regarding
145        security and privilege.
146
147    Item (b) is discussed at length in [62]Sections 10 and [63]11 of this
148    document, but the package-related aspects are also given here. The
149    basic problem is that Unix dialout devices and the UUCP "lock files"
150    that regulate contention for them (described in [64]Section 10) are
151    usually protected against "world". Therefore, the install procedure
152    must either run as root in order to give the Kermit binary the required
153    permissions, group, and/or owner, or else the dialout devices and
154    associated directories must be open for group or world reading and
155    writing. Otherwise, the Kermit program just installed WILL NOT WORK for
156    dialing out.
157
158    Thus, a well-crafted installation procedure should present the options
159    and allow the installer to choose the method, if any, for regulating
160    access to the dialout devices:
161
162     a. Check the permissions of the lockfile directory and the dialout
163        devices. If they do not allow group or world R/W access, then:
164     b. "Your UUCP lockfile directory and/or dialout devices require
165        privilege to access. You must either change their permissions or
166        install Kermit with privileges."
167     c. "If you wish to install Kermit with privileges, it will be given
168        the same owner, group, and permissions as the cu program so it can
169        use the dialout devices." (This is increasingly problematic as some
170        newer Unix systems like Mac OS X don't have a cu program, or even a
171        serial port!)
172     d. If they choose (c) but the user is not root, give a message that
173        the install procedure can be run only by root and then quit.
174
175    It should go without saying, of course, that any binaries that are to
176    be included in an install package should be built fresh on the exact
177    platform (e.g. Red Hat 8.0 on Intel) for which the package is targeted;
178    prebuilt binaries ([65]next section) from other sites are likely to
179    have library mismatches. [66]CLICK HERE for more about building
180    C-Kermit install packages.
181
182    The Kermit Project does not have the resources or the expertise to make
183    install packages for every platform. Most install packages, therefore,
184    are contributed by others, and they do not necessarily follow the
185    guidelines given above. Pay attention to what they do.
186
187    If you are an end user who has obtained a C-Kermit install package for
188    a particular platform, you should be aware that some additional steps
189    might needed if you want to use Kermit to dial out. Read [67]Section 10
190    for details.
191
192 3. INSTALLING PREBUILT BINARIES
193
194    [ [68]Top ] [ [69]Contents ] [ [70]Next ] [ [71]Previous ]
195
196    Hundreds of prebuilt C-Kermit binaries are available on the CDROM in
197    the BINARY tree [NOTE: The C-Kermit CDROM is still for version 7.0],
198    and at our ftp site in the [72]kermit/bin area (with names starting
199    with "ck"), also accessible on the [73]C-Kermit website. To install a
200    prebuilt binary:
201
202     a. Rename the binary to "wermit".
203     b. Make sure it works; some tests are suggested in [74]Section 7.
204     c. Follow steps (b) through (e) in [75]Section 4.
205     d. Install related files as described in [76]Section 5.
206
207    But first... Please heed the following cautions:
208
209     a. If you pick the wrong binary, it won't work (or worse).
210     b. Even when you pick the appropriate binary, it still might not work
211        due to shared-library mismatches, etc. (see [77]Section 4.0).
212     c. Don't expect a binary built on or for version n of your OS to work
213        on version n - x (where x > 0). However, it is supposed to be safe
214        to run a binary built on (or for) an older OS release on a newer
215        one (but is [78]increasingly less so as time-honored principles of
216        stability and backwards compatibility go fading into obscurity).
217
218    Therefore, it is always better to build your own binary from source
219    code ([79]next section) if you can. But since it is increasingly common
220    for Unix systems (not to mention VMS and other OS's) to be delivered
221    without C compilers, it is sometimes not possible. In such cases, try
222    the most appropriate prebuilt binary or binaries, and if none of them
223    work, [80]contact us and we'll see what we can do to help.
224
225 4. BUILDING FROM SOURCE CODE
226
227    [ [81]Top ] [ [82]Contents ] [ [83]Next ] [ [84]Previous ]
228
229    Also see: [85]Section 8 and [86]Section 9.
230
231    C-Kermit is designed to be built and used on as many platforms as
232    possible: Unix and non-Unix, old and new (and ancient), ANSI C and K&R.
233    The Unix version does not use or depend on any external tools for
234    building except the "make" utility, the C compiler, the linker, and the
235    shell. It does not use any external automated configuration tools such
236    as configure, autoconf, automake, libtool, etc. Everything in C-Kermit
237    has been built by hand based on direct experience or reports or
238    contributions from users of each platform.
239
240    The [87]C-Kermit makefile contains the rules for building the program
241    for each of the hundreds of different kinds of Unix systems that
242    C-Kermit attempts to support. It covers all Unix variations since about
243    1980 -- pretty much everything after Unix V6. Separate makefiles are
244    used for [88]Plan 9 and [89]2.x BSD.
245
246    Prerequisites:
247
248      * The C compiler, linker, and make program must be installed.
249      * The C libraries and header files must be installed (*).
250      * The C-Kermit source code and makefile in your current directory.
251      * The C-Kermit text files ([90]Section 5) in your current directory.
252
253      * This is becoming problematic in this new age of "selective
254        installs" e.g. of Linux packages. C-Kermit builds will often fail
255        because replying "no" to some obscure Linux installation option
256        will result in missing libraries or header files. Ditto on
257        platforms like AIX and Solaris that don't come with C compilers,
258        and then later have gcc installed, but are still missing crucial
259        libraries, like libm (math).
260
261    Plus:
262
263      * For TCP/IP networking support, the sockets library and related
264        header files must be installed.
265      * The math library for floating-point arithmetic support (can be
266        deselected by adding -DNOFLOAT to CFLAGS and removing -lm from
267        LIBS).
268      * Many and varied security libraries for building a secure version
269        (Kerberos, SSL/TLS, SRP, Zlib,...) These are required only if you
270        select a secure target.
271      * For the curses-based fullscreen file-ransfer display, the curses or
272        ncurses header file(s) and library, and probably also the termcap
273        and/or termlib library. Note that the names and locations of these
274        files and libraries are likely to change capriciously with every
275        new release of your Unix product. If you discover that the C-Kermit
276        build procedure fails because your curses and/or termxxx headers or
277        libraries are not named or located as expected, please [91]let us
278        know. In the meantime, work around by installing symlinks.
279      * IMPORTANT: Modern Linux distributions might give you the choice
280        during installation of whether to install the "ncurses development
281        package" (perhaps called "ncurses-devel"). If you did not install
282        it, you won't be able to build C-Kermit with curses support
283        included. In this case, either go back and install ncurses, or else
284        choose (or create) a non-curses makefile target for your platform.
285        To install the ncurses developers tools in Red Hat Linux, do
286        "apt-get install ncurses-developer" or if you have the CD:
287
288 mount redhat cdrom
289 goto RedHat/RPMS
290 rpm -ivh ncurses-devel*.rpm
291 or to have the exact name ls ncurse* and load as
292 rpm -ivh filename
293 then leave the cdrom and unmount it.
294
295      * In AIX you might have to go back and install any or all of:
296
297 bos.adt.base
298 bos.adt.include
299 bos.adt.lib
300 bos.adt.libm
301 bos.adt.utils
302
303        from the first installation CD.
304
305    Depending on where you got it, the makefile might need to be renamed
306    from ckuker.mak to makefile. Directions:
307
308     a. Type "make xxx" where xxx is the name of the makefile target most
309        appropriate to your platform, e.g. "make linux", "make aix43", etc.
310        Read the [92]comments at the top of the makefile for a complete
311        list of available targets (it's a long list).
312     b. Test the resulting 'wermit' file (see [93]Section 7 for
313        suggestions). If it's OK, proceed; otherwise [94]notify us.
314
315      NOTE: steps (c) through (e) can be accomplished using the
316      [95]makefile 'install' target as described in [96]Section 5.4.
317     c. Rename the 'wermit' file to 'kermit', copy it to the desired binary
318        directory (such as /usr/local/bin or /opt/something), and if it is
319        to be used for dialing out, give it the same owner, group, and
320        permissions as the 'cu' program (IMPORTANT: read [97]Sections 10
321        and [98]11 for details).
322     d. Install the man page, ckuker.nr, with your other man pages.
323     e. Install the accompanying text files (see [99]Section 5).
324     f. If you want C-Kermit to also offer a Telnet command-line
325        personality, make a symbolic link as follows:
326
327 cd directory-where-kermit-binary-is
328 ln -s kermit telnet
329
330        If you want C-Kermit to be the default Telnet client, make sure the
331        directory in which you created the symlink is in the PATH ahead of
332        the where the regular Telnet client is.
333     g. If you want C-Kermit to also offer an FTP command-line personality,
334        make a symlink called "ftp" as in (f).
335     h. If you want C-Kermit to also offer an FTTP command-line
336        personality, make a symlink called "http" as in (f).
337     i. If you want to offer an Internet Kermit Service, follow the
338        directions in the [100]IKSD Administrator's Guide.
339
340 4.0. Special Considerations for C-Kermit 8.0-9.0
341
342    [ [101]Top ] [ [102]Contents ] [ [103]Next ]
343
344    Also see: [104]C-Kermit Configuration Options
345
346    SECTION CONTENTS
347
348 4.1. [105]The Unix Makefile
349 4.2. [106]The C-Kermit Initialization File
350 4.3. [107]The 2.x BSD Makefile
351 4.4. [108]The Plan 9 Makefile
352 4.5. [109]Makefile Failures
353
354    (Also see the [110]Configurations Options document, [111]Section 8).
355
356    Lots of new features have been added in versions 7.0 and 8.0 that
357    require access to new symbols, APIs, libraries, etc, and this will no
358    doubt cause problems in compiling, linking, or execution on platforms
359    where 6.0 and earlier built without incident. This section contains
360    what we know as of the date of this file.
361
362    The first category concerns the new Kermit Service Daemon (IKSD; see
363    the [112]IKSD Administrator's Guide for details):
364
365    The wtmp File
366           When C-Kermit is started as an IKSD (under inetd), it makes
367           syslog and wtmp entries, and also keeps its own ftpd-like log.
368           The code assumes the wtmp log is /var/log/wtmp on Linux and
369           /usr/adm/wtmp elsewhere. No doubt this assumption will need
370           adjustment. Use -DWTMPFILE=path to override at compile time
371           (there is also a runtime override). See [113]iksd.html for
372           details.
373
374    UTMP, utsname(), etc
375           C-Kermit 7.0 gets as much info as it can about its job -- mainly
376           for IKSD logging -- from utmp. But of course utmp formats and
377           fields differ, and for that matter, there can be two different
378           header files, <utmp.h> and <utmpx.h>. Look for HAVEUTMPX and
379           HAVEUTHOST in [114]ckufio.c and let me know of any needed
380           adjustments.
381
382    Password lookup
383           IKSD needs to authenticate incoming users against the password
384           list. In some cases, this requires the addition of -lcrypt (e.g.
385           in Unixware 2.x). In most others, the crypt functions are in the
386           regular C library. If you get "crypt" as an unresolved symbol at
387           link time, add -lcrypt to LIBS. If your site has local
388           replacement libraries for authentication, you might need a
389           special LIBS clause such as "LIBS=-L/usr/local/lib -lpwent".
390
391           These days most Unix systems take advantage of shadow password
392           files or Pluggable Authentication Modules (PAM). If your system
393           uses shadow passwords you must add -DCK_SHADOW to the CFLAGS
394           list. If your system requires PAM you must add -DCK_PAM to the
395           CFLAGS and -lpam -ldl to LIBS.
396
397    getusershell()
398           This is called by the IKSD at login time to see if a user has
399           been "turned off". But many Unix platforms lack this function.
400           In that case, you will get unresolved symbol reports at link
401           time for _getusershell, _endusershell; to work around, add
402           -DNOGETUSERSHELL.
403
404    initgroups()
405           This is called by IKSD after successful authentication. But some
406           platforms do not have this function, so obviously it can't be
407           called there, in which case add -DNOINITGROUPS.
408
409    setreuid(), setreuid(), setregid() not found or "deprecated"
410           Find out what your Unix variety wants you to use instead, and
411           make appropriate substitutions in routine zvpass(), module
412           [115]ckufio.c, and [116]let us know.
413
414    printf()
415           IKSD installs a printf() substitute to allow redirection of
416           printf-like output to the connection. However, this can conflict
417           with some curses libraries. In this case, separate binaries must
418           be built for IKSD and non-IKSD use.
419
420    If you encounter difficulties with any of the above, and you are not
421    interested in running C-Kermit as an IKSD, then simply add NOIKSD to
422    CFLAGS and rebuild. Example:
423
424 make sco286
425 (get lots of errors)
426 make clean
427 make sco286 "KFLAGS=-DNOIKSD"
428
429    Some non-IKSD things to watch out for:
430
431    Return type of main()
432           The main() routine is in [117]ckcmai.c. If you get complaints
433           about "main: return type is not blah", define MAINTYPE on the CC
434           command line, e.g.:
435
436 make xxx "KFLAGS=-DMAINTYPE=blah
437
438           (where blah is int, long, or whatever). If the complaint is
439           "Attempt to return a value from a function of type void" then
440           add -DMAINISVOID:
441
442 make xxx "KFLAGS=-DMAINISVOID=blah
443
444    DNS Service Records
445           This feature allows a remote host to redirect C-Kermit to the
446           appropriate socket for the requested service; e.g. if C-Kermit
447           requests service "telnet" and the host offers Telnet service on
448           port 999 rather than the customary port 23. If you get
449           compile-time complaints about not being able to find <resolv.h>,
450           <netdb.h>, or <arpa/nameser.h>, add -DNO_DNS_SRV to CFLAGS. If
451           you get link-time complaints about unresolved symbols res_search
452           or dn_expand, try adding -lresolve to LIBS.
453
454    \v(ipaddress)
455           If "echo \v(ipaddress)" shows an empty string rather than your
456           local IP address, add -DCKGHNLHOST to CFLAGS and rebuild.
457
458    <sys/wait.h>
459           If this file can't be found at compile time, add -DNOREDIRECT to
460           CFLAGS. This disables the REDIRECT and PIPE commands and
461           anything else that needs the wait() system service.
462
463    syslog()
464           C-Kermit can now write syslog records. Some older platforms
465           might not have the syslog facility. In that case, add
466           -DNOSYSLOG. Others might have it, but require addition of
467           -lsocket to LIBS (SCO OSR5 is an example). See [118]Section 15.
468
469    putenv()
470           If "_putenv" comes up as an undefined symbol, add -DNOPUTENV to
471           CFLAGS and rebuild.
472
473    "Passing arg1 of 'time' from incompatible pointer"
474           This is a mess. See the mass of #ifdefs in the appropriate
475           module, [119]ckutio.c or [120]ckufio.c.
476
477    gettimeofday()
478           Wrong number of arguments. On most platforms, gettimeofday()
479           takes two arguments, but on a handful of others (e.g. Motorola
480           System V/88 V4, SNI Reliant UNIX 5.43, etc) it takes one. If
481           your version of gettimeofday() is being called with two args but
482           wants one, add -DGTODONEARG.
483
484    "Assignment makes pointer from integer without a cast"
485           This warning might appear in [121]ckutio.c or [122]ckufio.c. (or
486           elsewhere), and usually can be traced to the use of a system or
487           library function that returns a pointer but that is not declared
488           in the system header files even though it should be. Several
489           functions are commonly associated with this error:
490
491           + getcwd(): Add -DDCLGETCWD to CFLAGS and rebuild.
492           + popen() : Add -DDCLPOPEN to CFLAGS and rebuild.
493           + fdopen(): Add -DDCLFDOPEN to CFLAGS and rebuild.
494
495    "Operands of = have incompatible types"
496    "Incompatible types in assignment"
497           If this comes from [123]ckcnet.c and comes from a statement
498           involving inet_addr(), try adding -DINADDRX to CFLAGS. If that
499           doesn't help, then try adding -DNOMHHOST.
500
501    Complaints about args to get/setsockopt(), getpeername(), getsockname()
502           These are all in [124]ckcnet.c. Different platforms and OS's and
503           versions of the same OS change this all the time: int, size_t,
504           unsigned long, etc. All the affected variables are declared
505           according to #ifdefs within ckcnet.c, so find the declarations
506           and adjust the #ifdefs accordingly.
507
508    size_t
509           In case of complaints about "unknown type size_t", add
510           -DSIZE_T=int (or other appropriate type) to CFLAGS.
511
512    'tz' undefined
513    Use of undefined enum/struct/union 'timezone'
514           Left of 'tv_sec' specifies undefined struct/union 'timeval' And
515           similar complaints in [125]ckutio.c: Add -DNOGFTIMER and/or
516           -DNOTIMEVAL.
517
518    Symlinks
519           The new built-in DIRECTORY command should show symlinks like "ls
520           -l" does. If it does not, check to see if your platform has the
521           lstat() and readlink() functions. If so, add -DUSE_LSTAT and
522           -DCKSYMLINK to CFLAGS and rebuild. On the other hand, if lstat()
523           is unresolved at link time, add -DNOLSTAT to CFLAGS. If
524           readlink() is also unresolved, add -DNOSYMLINK.
525
526    realpath()
527           Link-time complains about realpath() -- find the library in
528           which it resides and add it to LIBS (example for Unixware 7.1:
529           "-lcudk70") or add -DNOREALPATH to CFLAGS and rebuild. If built
530           with realpath() but debug log file is truncated or mangled,
531           ditto (some realpath() implementations behave differently from
532           others). If built with realpath() and seemingly random core
533           dumps occur during file path resolution, ditto.
534
535    Failure to locate header file <term.h>
536           Usually happens on Linux systems that have the C compiler
537           installed, but not the ncurses package (see comments about
538           selective installs above). Go back and install ncurses, or use
539           "make linuxnc" (Linux No Curses).
540
541    "Can't find shared library libc.so.2.1"
542    "Can't find shared library libncurses.so.3.0", etc...
543           You are trying to run a binary that was built on a computer that
544           has different library versions than your computer, and your
545           computer's loader is picky about library version numbers.
546           Rebuild from source on your computer.
547
548    Time (struct tm) related difficulties:
549           Errors like the following:
550
551 "ckutio.c", line 11994: incomplete struct/union/enum tm: _tm
552 "ckutio.c", line 11995: error: cannot dereference non-pointer type
553 "ckutio.c", line 11995: error: assignment type mismatch
554 "ckutio.c", line 11997: warning: using out of scope declaration: localtime
555 "ckutio.c", line 11997: error: unknown operand size: op "="
556 "ckutio.c", line 11997: error: assignment type mismatch
557 "ckutio.c", line 11998: error: undefined struct/union member: tm_year
558 "ckutio.c", line 12000: error: undefined struct/union member: tm_mon
559 "ckutio.c", line 12001: error: undefined struct/union member: tm_mday
560 "ckutio.c", line 12002: error: undefined struct/union member: tm_hour
561 "ckutio.c", line 12003: error: undefined struct/union member: tm_min
562 "ckutio.c", line 12004: error: undefined struct/union member: tm_sec
563
564           are due to failure to include the appropriate time.h header
565           files. Unix platforms generally have one or more of the
566           following: <time.h>, <sys/time.h>, and <sys/timeb.h>. Any
567           combination of these might be required. Defaults are set up for
568           each makefile target. The defaults can be corrected on the CC
569           command line by adding the appropriate definition from the
570           following list to CFLAGS:
571
572 -DTIMEH         Include <time.h>
573 -DNOTIMEH       Don't include <time.h>
574 -DSYSTIMEH      Include <sys/time.h>
575 -DNOSYSTIMEH    Don't include <sys/time.h>
576 -DSYSTIMEBH     Include <sys/timeb.h>
577 -DNOSYSTIMEBH   Don't include <sys/timeb.h>
578
579           Note that <sys/timeb.h> is relatively scarce in the System V and
580           POSIX environments; the only platform of recent vintage where it
581           was/is used is OSF/1 and its derivatives (Digital Unix and Tru64
582           Unix).
583
584    Struct timeval and/or timezone not declared:
585           In some cases, merely including the appropriate time.h header
586           files is still not enough. POSIX.1 does not define the timeval
587           struct, and so the items we need from the header are protected
588           against us by #ifndef _POSIX_SOURCE or somesuch. In this case,
589           we have to declare the timeval (and timezone) structs ourselves.
590           To force this, include -DDCLTIMEVAL in CFLAGS.
591
592    Warnings about dn_expand() Argument #4
593           WARNING: argument is incompatible with prototyp. It's the old
594           char versus unsigned char stupidity again. Try to find a
595           compiler switch like GCC's "-funsigned-char". Failing that, add
596           -DCKQUERYTYPE=xxx to CFLAGS, where xxx is whatever 'man
597           dn_expand' tells you the type of the 4th argument should be
598           (presumably either char or unsigned char; in the latter case use
599           CHAR to avoid confusion caused by multiple words.
600
601    Switch Table Overflow (in [126]ckcuni.c)
602           Add -DNOUNICODE to CFLAGS.
603
604    Compile-time warnings about ck_out() or tgetstr() or tputs():
605           Easy solution: Add -DNOTERMCAP to CFLAGS. But then you lose the
606           SCREEN function. Real solution: Try all different combinations
607           of the following CFLAGS:
608
609 -DTPUTSARGTYPE=char    -DTPUTSFNTYPE=int
610 -DTPUTSARGTYPE=int     -DTPUTSFNTYPE=void
611
612           Until the warnings go away, except maybe "ck_outc: return with a
613           value in a function returning void", and in that case also add
614           -DTPUTSISVOID.
615
616    "Passing arg 1 of to tputs() makes pointer from integer without a
617           cast":
618           Add -DTPUTSARG1CONST to CFLAGS.
619
620    "Undefined symbol: dup2"
621           Add -DNOZEXEC to CFLAGS.
622
623    "header file 'termcap.h' not found"
624           Add -DNOHTERMCAP to CFLAGS.
625
626    Other difficulties are generally of the "where is curses.h and what is
627    it called this week?" variety (most easily solved by making symlinks in
628    the include and lib directories), or overzealous complaints regarding
629    type mismatches in function calls because of the totally needless and
630    silly signed versus unsigned char conflict (*), etc. In any case,
631    please send any compilation or linking warnings or errors to the
632    author, preferably along with fixes.
633
634      * C-Kermit does not use the signed property of chars at all anywhere,
635        ever. So if all chars and char *'s can be made unsigned at compile
636        time, as they can in gcc with "-funsigned-char", they should be.
637
638    IMPORTANT: If you find any of these hints necessary for a particular
639    make target (or you hit upon others not listed here), PLEASE SEND A
640    REPORT TO:
641
642 [127]kermit-support@columbia.edu
643
644 4.1. The Unix Makefile
645
646    [ [128]Top ] [ [129]Contents ] [ [130]Section Contents ] [ [131]Next ]
647    [ [132]Previous ]
648
649    If your distribution does not contain a file with the name "makefile"
650    or "Makefile", then rename the file called ckuker.mak to makefile:
651
652 mv ckuker.mak makefile
653
654    Then type "make xxx", where xxx is the platform you want to build
655    C-Kermit for. These are listed in the [133]comments at the top of the
656    makefile. For example, to build C-Kermit for Linux, type:
657
658 make linux
659
660    Here are some typical examples:
661
662      Target    Description
663      linux     Linux, any version on any hardware platform
664      openbsd   OpenBSD, any version on any hardware platform
665      aix43     AIX 4.3
666      aix43g    AIX 4.3, built with gcc
667      solaris9  Solaris 9
668      solaris9g Solaris 9 built with gcc
669      hpux1100  HP-UX 11-point-anything
670
671    The makefile is quite long, and at least two versions of Unix, SCO
672    Xenix/286 and 2.x BSD, cannot cope with its length. An attempt to "make
673    sco286" gives the message "Make: Cannot alloc mem for env.. Stop".
674    Solution: edit away some or all of the nonrelevant material from the
675    makefile. (A separate version of the makefile is provided for BSD 2.x:
676    ckubs2.mak but C-Kermit 8.0 can't be built for BSD 2.x -- it has simply
677    grown too large.)
678
679    Some make programs reportedly cannot handle continued lines (lines
680    ending in backslash (\)). If you have a problem with the makefile, try
681    editing the makefile to join the continued lines (remove the
682    backslashes and the following linefeed).
683
684    Other makefile troubles may occur because tabs in the makefile have
685    somehow been converted to spaces. Spaces and tabs are distinct in Unix
686    makefiles.
687
688    Similarly, carriage returns might have been added to the end of each
689    line, which also proves confusing to most Unix versions of make.
690
691    Check to see if there are comments about your particular version in its
692    makefile target itself. In a text editor such as EMACS or VI, search
693    for the make entry name followed by a colon, e.g. "linux:" (if you
694    really are building C-Kermit for Linux, do this now).
695
696    Check to see if there are comments about your particular version in the
697    [134]ckubwr.txt file ([135]CLICK HERE for the Web version).
698
699    If you have trouble with building [136]ckwart.c, or running the
700    resulting wart preprocessor program on [137]ckcpro.w:
701
702     1. Just "touch" the [138]ckcpro.c file that comes in the distribution
703        and then give the "make" command again, or:
704     2. Compile ckwart.c "by hand": cc -o wart ckwart.c, or:
705     3. Try various other tricks. E.g. one Linux user reported that that
706        adding the "static" switch to the rule for building wart fixed
707        everything:
708
709 wart: ckwart.$(EXT)
710         $(CC) -static -o wart ckwart.$(EXT) $(LIBS)
711
712    If your compiler supports a compile-time option to treat ALL chars (and
713    char *'s, etc) as unsigned, by all means use it -- and send me email to
714    let me know what it is (I already know about gcc -funsigned-char).
715
716    To add compilation options (which are explained later in this document)
717    to your makefile target without editing the makefile, include
718    "KFLAGS=..." on the make command line, for example:
719
720 make linux KFLAGS=-DNODEBUG
721 make bsd "KFLAGS=-DKANJI -DNODEBUG -DNOTLOG -DDYNAMIC -UTCPSOCKET"
722
723    Multiple options must be separated by spaces. Quotes are necessary if
724    the KFLAGS= clause includes spaces. The KFLAGS are added to the end of
725    the CFLAGS that are defined in the selected makefile target. For
726    example, the "bsd" entry includes -DBSD4 -DTCPSOCKET, so the second
727    example above compiles Kermit with the following options:
728
729 -DBSD4 -DTCPSOCKET -DKANJI -DNODEBUG -DNOTLOG -DDYNAMIC -UTCPSOCKET
730
731    (Notice how "-UTCPSOCKET" is used to negate the effect of the
732    "-DTCPSOCKET" option that is included in the makefile target.)
733
734    WARNING: Be careful with KFLAGS. If you build C-Kermit, change some
735    files, and then run make again using the same make entry but specifying
736    different KFLAGS than last time, make won't detect it and you could
737    easily wind up with inconsistent object modules, e.g. some of them
738    built with a certain option, others not. When in doubt, "make clean"
739    first to make sure all your object files are consistent. Similarly, if
740    you change CFLAGS, LIBS, or any other items in the makefile, or you
741    rebuild using a different makefile target, "make clean" first.
742
743    If you create a new makefile target, use static linking if possible.
744    Even though this makes your C-Kermit binary bigger, the resulting
745    binary will be more portable. Dynamically linked binaries tend to run
746    only on the exact configuration and version where they were built; on
747    others, invocation tends to fail with a message like:
748
749 Can't find shared library "libc.so.2.1"
750
751 4.2. The C-Kermit Initialization File
752
753    [ [139]Top ] [ [140]Contents ] [ [141]Section Contents ] [ [142]Next ]
754    [ [143]Previous ]
755
756    (This section is obsolete.) Read [144]Section 5 about the
757    initialization file.
758
759 4.3. The 2.x BSD Makefile
760
761    [ [145]Top ] [ [146]Contents ] [ [147]Section Contents ] [ [148]Next ]
762    [ [149]Previous ]
763
764      This section is obsolete. C-Kermit 6.0 was the last release that
765      could be built on PDP-11 based BSD versions.
766
767 4.4. The Plan 9 Makefile
768
769    [ [150]Top ] [ [151]Contents ] [ [152]Section Contents ] [ [153]Next ]
770    [ [154]Previous ]
771
772    Use the separate makefile [155]ckpker.mk. NOTE: The Plan 9 version of
773    C-Kermit 8.0 has not yet been built. There should be no impediment to
774    building it. However, even when built successfully, certain key
775    features are missing, notably TCP/IP networking.
776
777 4.5. Makefile Failures
778
779    [ [156]Top ] [ [157]Contents ] [ [158]Section Contents ] [
780    [159]Previous ]
781
782    First, be sure the source files are stored on your current disk and
783    directory with the right names (in lowercase). Second, make sure that
784    the makefile itself does not contain any lines with leading spaces:
785    indented lines must all start with horizontal TAB, and no spaces.
786
787    Then make sure that your Unix PATH is defined to find the appropriate
788    compiler for your makefile target. For example, on SunOS systems, "make
789    sunos41" builds C-Kermit for the BSD environment, and assumes that
790    /usr/ucb/cc will be used for compilation and linking. If your PATH has
791    /usr/5bin ahead of /usr/ucb, you can have problems at compile or link
792    time (a commonly reported symptom is the inability to find "ftime"
793    during linking). Fix such problems by redefining your Unix PATH, or by
794    specifying the appropriate "cc" in CC= and CC2= statements in your
795    makefile target.
796
797    During edits 166-167, considerable effort went into making C-Kermit
798    compilable by ANSI C compilers. This includes prototyping all of
799    C-Kermit's functions, and including the ANSI-defined system header
800    files for system and library functions, as defined in K&R, second
801    edition: <string.h>, <stdlib.h>, <unistd.h> (except in NeXTSTEP this is
802    <libc.h>), and <sys/stdtypes.h>. If you get warnings about any of these
803    header files not being found, or about argument mismatches involving
804    pid_t, uid_t, or gid_t, look in ckcdeb.h and make amendments. C-Kermit
805    assumes it is being compiled by an ANSI-compliant C compiler if
806    __STDC__ is defined, normally defined by the compiler itself. You can
807    force ANSI compilation without defining __STDC__ (which some compilers
808    won't let you define) by including -DCK_ANSIC on the cc command line.
809
810    On the other hand, if your compiler defines __STDC__ but still
811    complains about the syntax of Kermit's function prototypes, you can
812    disable the ANSI-style function prototyping by including -DNOANSI on
813    the command line.
814
815    For SCO OpenServer, UNIX, ODT, and XENIX compilations, be sure to pick
816    the most appropriate [160]makefile target, and be sure you have
817    installed an SCO development system that is keyed to your exact SCO
818    operating system release, down to the minor version (like 2.3.1).
819
820    Also note that SCO distributes some of its libraries in encrypted form,
821    and they must be decrypted before C-Kermit can be linked with them. If
822    not, you might see a message like:
823
824 ld: file /usr/lib/libsocket.a is of unknown type: magic number = 6365
825
826    To decrypt, you must supply a key (password) that came with your
827    license. Call SCO for further info.
828
829    If your compiler uses something other than int for the pid (process id)
830    data type, put -DPID_T=pid_t or whatever in your CFLAGS.
831
832    If you get complaints about unknown data types uid_t and gid_t, put
833    -DUID_T=xxx -DGID_T=yyy in your CFLAGS, where xxx and yyy are the
834    appropriate types.
835
836    If your compilation fails because of conflicting or duplicate
837    declarations for sys_errlist, add -DUSE_STRERROR or -DNDSYSERRLIST to
838    CFLAGS.
839
840    If your compilation dies because getpwnam() is being redeclared (or
841    because of "conflicting types for getwpnam"), add -DNDGPWNAM to your
842    CFLAGS. If that doesn't work, then add -DDCGPWNAM to your CFLAGS (see
843    ckufio.c around line 440).
844
845    If the compiler complains about the declaration of getpwnam() during an
846    ANSI C compilation, remove the declaration from ckufio.c or change the
847    argument in the prototype from (char *) to (const char *).
848
849    If you get complaints that getpwuid() is being called with an improper
850    type, put -DPWID_T=xx in your CFLAGS.
851
852    If you get compile-time warnings that t_brkc or t_eofc (tchars
853    structure members, used in BSD-based versions) are undefined, or
854    structure-member- related warnings that might be traced to this fact,
855    add -DNOBRKC to CFLAGS.
856
857    If you get a linker message to the effect that _setreuid or _setregid
858    is not defined, add -DNOSETREU to CFLAGS, or add -DCKTYP_H=blah to
859    CFLAGS to make C-Kermit read the right <types.h>-kind-of-file to pick
860    up these definitions.
861
862    If you get a message that _popen is undefined, add -DNOPOPEN to CFLAGS.
863
864    If you get a complaint at compile time about an illegal pointer-integer
865    combination in ckufio.c involving popen(), or at link time that _popen
866    is an undefined symbol, add the declaration "FILE *popen();" to the
867    function zxcmd() in ckufio.c (this declaration is supposed to be in
868    <stdio.h>). If making this change does not help, then apparently your
869    Unix does not have the popen() function, so you should add -DNOPOPEN to
870    your make entry, in which case certain functions involving "file" i/o
871    to the standard input and output of subprocesses will not be available.
872
873    If your linker complains that _getcwd is undefined, you can add a
874    getcwd() function to ckufio.c, or add it to your libc.a library using
875    ar:
876
877 #include <stdio.h>
878
879 char *
880 getcwd(buf,size) char *buf; int size; {
881 #ifndef NOPOPEN
882 #ifdef DCLPOPEN
883     FILE *popen();
884 #endif
885     FILE *pfp;
886
887     if (!buf) return(NULL);
888     if (!(pfp = popen("pwd","r"))) return(NULL);
889     fgets(buf,size-2,pfp);
890     pclose(pfp);
891     buf[strlen(buf)-1] = '\0';
892     return((char *)buf);
893 #else
894     buf[0] = '\0';
895     return(NULL);
896 #endif /* NOPOPEN */
897 }
898
899 #ifdef NOPOPEN
900 FILE *popen(s,t) char *s,*t; {
901     return(NULL);
902 }
903 #endif /* NOPOPEN */
904
905    If you get complaints about NPROC having an invalid value, add a valid
906    definition for it (depends on your system), as in the cray entry.
907
908    If you get some symbol that's multiply defined, it probably means that
909    a variable name used by Kermit is also used in one of your system
910    libraries that Kermit is linked with. For example, under PC/IX some
911    library has a variable or function called "data", and the variable
912    "data" is also used extensively by Kermit. Rather than edit the Kermit
913    source files, just put a -D in the make entry CFLAGS to change the
914    Kermit symbol at compile time. In this example, it might be
915    -Ddata=xdata.
916
917    Some symbol is defined in your system's header files, but it produces
918    conflicts with, or undesired results from, Kermit. Try undefining the
919    symbol in the makefile target's CFLAGS, for example -UFIONREAD.
920
921    Some well-known symbol is missing from your system header files. Try
922    defining in the makefile target's CFLAGS, for example -DFREAD=1.
923
924    You get many warnings about pointer mismatches. This probably means
925    that Kermit is assuming an int type for signal() when it should be
926    void, or vice-versa. Try adding -DSIG_I (for integer signal()) or
927    -DSIG_V (for void) to CFLAGS. Or just include KFLAGS=-DSIG_V (or
928    whatever) in your "make" command, for example:
929
930 make bsd KFLAGS=-DSIG_V
931
932    You get many messages about variables that are declared and/or set but
933    never used. It is difficult to avoid these because of all the
934    conditional compilation in the program. Ignore these messages.
935
936    Some of C-Kermit's modules are so large, or contain so many character
937    string constants, or are so offensive in some other way, that some C
938    compilers give up and refuse to compile them. This is usually because
939    the -O (optimize) option is included in the make entry. If this happens
940    to you, you can (a) remove the -O option from the make entry, which
941    will turn off the optimizer for ALL modules; or (b) compile the
942    offending module(s) by hand, including all the switches from make entry
943    except for -O, and then give the appropriate "make" command again; or
944    (c) increase the value of the -Olimit option, if your compiler supports
945    this option; or (d) change the [161]makefile target to first compile
946    each offending module explicitly without optimization, then compile the
947    others normally (with optimization), for example:
948
949 #Fortune 32:16, For:Pro 2.1 (mostly like 4.1bsd)
950 ft21:
951         @echo 'Making C-Kermit $(CKVER) for Fortune 32:16 For:Pro 2.1...'
952         $(MAKE) ckuusx.$(EXT) "CFLAGS= -DNODEBUG -DBSD4 -DFT21 -DNOFILEH \
953         -SYM 800 \ -DDYNAMIC -DNOSETBUF -DCK_CURSES $(KFLAGS) -DPID_T=short"
954         $(MAKE) ckuxla.$(EXT) "CFLAGS= -DNODEBUG -DBSD4 -DFT21 -DNOFILEH \
955         -SYM 800 \ -DDYNAMIC -DNOSETBUF -DCK_CURSES $(KFLAGS) -DPID_T=short"
956         $(MAKE) ckudia.$(EXT) "CFLAGS= -DNODEBUG -DBSD4 -DFT21 -DNOFILEH \
957         -SYM 800 \ -DDYNAMIC -DNOSETBUF -DCK_CURSES $(KFLAGS) -DPID_T=short"
958         $(MAKE) wermit "CFLAGS= -O -DNODEBUG -DBSD4 -DFT21 -DNOFILEH -SYM 800 \
959         -DDYNAMIC -DNOSETBUF -DCK_CURSES $(KFLAGS) -DPID_T=short" \
960         "LNKFLAGS= -n -s" "LIBS= -lcurses -ltermcap -lv -lnet"
961
962    As an extreme example, some compilers (e.g. gcc on the DG AViiON) have
963    been known to dump core when trying to compile ckwart.c with
964    optimization. So just do this one "by hand":
965
966 cc -o wart ckwart.c
967
968    or:
969
970 touch ckcpro.c
971
972    and then give the "make" command again.
973
974    Speaking of wart, it is unavoidable that some picky compilers might
975    generate "statement unreachable" messages when compiling ckcpro.c.
976    Unreachable statements can be generated by the wart program, which
977    generates ckcpro.c automatically from [162]ckcpro.w, which translates
978    lex-like state/input constructions into a big switch/case construction.
979
980    Some function in Kermit wreaks havoc when it is called. Change all
981    invocations of the function into a macro that evaluates to the
982    appropriate return code that would have been returned by the function
983    had it been called and failed, for example: -Dzkself()=0. Obviously not
984    a good idea if the function is really needed.
985
986    If you have just installed SunOS 4.1.2 or 4.1.3, you might find that
987    C-Kermit (and any other C program) fails to link because of unresolved
988    references from within libc. This is because of a mistake in Sun's
989    /usr/lib/shlib.etc files for building the new libc. Change the libc
990    Makefile so that the "ld" lines have "-ldl" at the end. Change the
991    README file to say "mv xccs.multibyte. xccs.multibyte.o" and follow
992    that instruction.
993
994 5. INSTALLING THE KERMIT FILES
995
996    [ [163]Top ] [ [164]Contents ] [ [165]Next ] [ [166]Previous ]
997
998    SECTION CONTENTS
999
1000 5.1. [167]The C-Kermit Initialization File
1001 5.2. [168]Text Files
1002 5.3. [169]Installing the Kermit Files
1003 5.4. [170]The Makefile Install Target
1004
1005    The C-Kermit executable does not need any external files to run.
1006    Unlike, say, the cu program, which on most platforms is useless unless
1007    you (as root) edit the /usr/spool/uucp/Systems and
1008    /usr/spool/uucp/Devices files to supply whatever obscure and
1009    undocumented syntax is required to match some supposedly user-friendly
1010    mnemonic to the real pathname of whatever device you want to use,
1011    Kermit runs on its own without needing any external configuration
1012    files, and lets you refer to device (and network hosts and services) by
1013    their own natural undisguised names.
1014
1015    Nevertheless, a number of external files can be installed along with
1016    the C-Kermit executable if you wish. These include configuration and
1017    customization files that are read by Kermit as well as documentation
1018    files to be read by people. All of this material is (a) optional, and
1019    (b) available on the Kermit website:
1020
1021 [171]http://www.columbia.edu/kermit/
1022
1023    and usually in a more pleasant form, perhaps also with updated content.
1024    So if your computer is on the Internet, there is no need to install
1025    anything but the Kermit executable if users know how to find the Kermit
1026    website (and if they don't, Kermit's "help" command tells them).
1027
1028 5.1. The C-Kermit Initialization File
1029
1030    In C-Kermit 7.0 and earlier, the standard initialization file was a key
1031    C-Kermit component because:
1032
1033     a. It "loaded" the dialing and network directories.
1034     b. It defined all the macros and variables for the services directory.
1035     c. It defined macros for quickly changing Kermit's file-transfer
1036        performance tuning.
1037
1038    The standard initialization file is quite long (more than 600 lines)
1039    and requires noticeable processing time (the slower the computer, the
1040    more noticeable), yet few people actually use the services directory,
1041    whose definition takes up most of its bulk. Meanwhile, in C-Kermit 8.0,
1042    many of the remaining functions of the standard initialization file are
1043    now built in; for example, the FAST, CAUTIOUS, and ROBUST commands.
1044
1045    More to the point, many of the settings that could be made only in the
1046    initialization and customization files can now be picked up from
1047    environment variables. The first group identifies initialization and
1048    directory files:
1049
1050    CKERMIT_INI
1051           The path of your Kermit initialization file, if any. This
1052           overrides the built-in search for $HOME/.kermrc.
1053
1054    K_CHARSET
1055           The character set used for encoding local text files. Equivalent
1056           to SET FILE CHARACTER-SET.
1057
1058    K_DIAL_DIRECTORY
1059           The full pathname of one or more Kermit dialing directory files.
1060           Equivalent to SET DIAL DIRECTORY.
1061
1062    K_NET_DIRECTORY
1063           The full pathname of one or more Kermit network directory files.
1064           Equivalent to SET NETWORK DIRECTORY.
1065
1066    K_INFO_DIRECTORY
1067    K_INFO_DIR
1068           The full pathname of a directory containing Kermit (if any)
1069           containing ckubwr.txt and other Kermit text files. Overrides
1070           Kermit's built-in search for this directory.
1071
1072    The next group is related to dialing modems:
1073
1074    K_COUNTRYCODE
1075           The telephonic numeric country code for this location, e.g. 1
1076           for North America or 39 for Italy. It is recommended that this
1077           one be set for all users, system-wide. Not only is it used to
1078           process portable-format dialing directory entries, but it is
1079           also compared against Kermit's built-in list of "tone countries"
1080           to see if tone dialing can be used. Equivalent to Kermit's SET
1081           DIAL COUNTRY-CODE command.
1082
1083    K_AREACODE
1084           The telephonic numeric area code for this location, e.g. 212 for
1085           Manhattan, New York, USA. Recommend this one also be set
1086           system-wide, so shared portable-format dialing directories will
1087           work automatically for everybody. Equivalent to Kermit's SET
1088           DIAL AREA-CODE command.
1089
1090    K_DIAL_METHOD
1091           TONE or PULSE. Equivalent to Kermit's SET DIAL METHOD command.
1092           If a dial method is not set explicitly (or implicitly from the
1093           country code), Kermit does not specify a dialing method, and
1094           uses the modem's default method, which tends to be pulse.
1095
1096    K_INTL_PREFIX
1097           The telephonic numeric international dialing prefix for this
1098           location. Equivalent to Kermit's SET DIAL INTL-PREFIX command.
1099
1100    K_LD_PREFIX
1101           The telephonic numeric long-distance dialing prefix for this
1102           location. Equivalent to Kermit's SET DIAL LD-PREFIX command.
1103
1104    K_PBX_ICP
1105           The telephonic numeric PBX internal call prefix for this
1106           location. Equivalent to Kermit's SET DIAL PBX-INSIDE-PREFIX
1107           command.
1108
1109    K_PBX_OCP
1110           The telephonic numeric PBX external call prefix for this
1111           location. Equivalent to Kermit's SET DIAL PBX-OUTSIDE-PREFIX
1112           command.
1113
1114    K_PBX_XCH
1115           The telephonic numeric PBX exchange (first part of the
1116           subscriber number). Equivalent to Kermit's SET DIAL PBX-EXCHANGE
1117           command.
1118
1119    K_TF_AREACODE
1120           A list of one or more telephonic numeric toll-free area codes.
1121
1122    K_TF_PREFIX
1123           The telephonic numeric toll-free dialing prefix, in case it is
1124           different from the long-distance prefix. Equivalent to Kermit's
1125           SET DIAL TF-PREFIX command.
1126
1127    The final group includes well-known environment variables that are also
1128    used by Kermit:
1129
1130    CDPATH
1131           Where the CD command should look for relative directory names.
1132
1133    SHELL
1134           The path of your Unix shell. Used by the RUN (!) command to
1135           choose the shell to execute its arguments.
1136
1137    USER
1138           Your Unix username.
1139
1140    EDITOR
1141           The name or path of your preferred editor (used by the EDIT
1142           command). Equivalent to SET EDITOR.
1143
1144    BROWSER
1145           The name or path of your preferred web browser (used by the
1146           BROWSE command). Equivalent to Kermit's SET BROWSER command.
1147
1148    Does this mean the initialization file can be abolished? I think so.
1149    Here's why:
1150
1151      * Kermit already does everything most people want it to do without
1152        one.
1153      * Important site-specific customizations can be done with global
1154        environment variables.
1155      * There is no longer any need for everybody to have to use the
1156        standard initialization file.
1157      * This means that your initialization file, if you want one, can
1158        contain your own personal settings, definitions, and preferences,
1159        rather than 600 lines of "standard" setups.
1160      * If you still want the services directory, you can either TAKE the
1161        standard initialization file (which must be named anything other
1162        than $HOME/.kermrc to avoid being executed automatically every time
1163        you start Kermit), or you can make it a kerbang script and execute
1164        it "directly" (the [172]makefile install target does this for you
1165        by putting ckermit.ini in the same directory as the Kermit binary,
1166        adding the appropriate Kerbang line to the top, and giving it
1167        execute permission).
1168
1169    In fact, you can put any number of kerbang scripts in your PATH to
1170    start up C-Kermit in different ways, to have it adopt certain settings,
1171    make particular connections, execute complicated scripts, whatever you
1172    want.
1173
1174 5.2. Text Files
1175
1176    These are entirely optional. Many of them are to be found at the Kermit
1177    website in HTML form (i.e. as Web pages with clickable links, etc), and
1178    very likely also more up to date. Plain-text files that correspond to
1179    Web pages were simply "dumped" by Lynx from the website to plain ASCII
1180    text. The format is whatever Lynx uses for this purpose. If you wish,
1181    you can install them on your computer as described in the [173]next
1182    section.
1183
1184    [174]COPYING.TXT
1185           Copyright notice, permissions, and disclaimer.
1186
1187    [175]ckermit.ini
1188           The standard initialization file, intended more for reference
1189           (in most cases) than actual use; see [176]Section 5.1.
1190
1191    [177]ckermod.ini
1192           A sample customization file.
1193
1194    [178]ckermit70.txt
1195           Supplement to [179]Using C-Kermit for version 7.0. Available on
1196           the Kermit website as:
1197           [180]http://www.columbia.edu/kermit/ckermit70.html
1198
1199    [181]ckermit80.txt
1200           Supplement to [182]Using C-Kermit for version 8.0. Available on
1201           the Kermit website as:
1202           [183]http://www.columbia.edu/kermit/ckermit80.html
1203
1204    [184]ckcbwr.txt
1205           The general C-Kermit hints and tips ("beware") file. Available
1206           on the Kermit website as:
1207           [185]http://www.columbia.edu/kermit/ckcbwr.html
1208
1209    [186]ckubwr.txt
1210           The Unix-specific C-Kermit hints and tips file. Available on the
1211           Kermit website as:
1212           [187]http://www.columbia.edu/kermit/ckubwr.html
1213
1214    [188]ckuins.txt
1215           Unix C-Kermit Installation Instructions (this file). Available
1216           on the Kermit website as:
1217           [189]http://www.columbia.edu/kermit/ckuins.html
1218
1219    [190]ckccfg.txt
1220           C-Kermit compile-time configuration options. Available on the
1221           Kermit website as:
1222           [191]http://www.columbia.edu/kermit/ckccfg.html
1223
1224    [192]ckcplm.txt
1225           The C-Kermit program logic manual. Available on the Kermit
1226           website as:
1227           [193]http://www.columbia.edu/kermit/ckcplm.html
1228
1229    [194]ca_certs.pem
1230           Certificate Authority certificates for secure connections (see
1231           [195]Section 16).
1232
1233 5.3. Installing the Kermit Files
1234
1235    There is an "install" target in the [196]makefile that you can use if
1236    you wish. However, since every site has its own layout and
1237    requirements, it is often better to install the Kermit files by hand.
1238    You don't have to use the makefile install target to install C-Kermit.
1239    This is especially true since not all sites build C-Kermit from source,
1240    and therefore might not even have the makefile. But you should read
1241    this section in any case.
1242
1243      If your computer already has an older version of C-Kermit installed,
1244      you should rename it (e.g. to "kermit6" or "kermit7") so in case you
1245      have any trouble with the new version, the old one is still
1246      available.
1247
1248    In most cases, you need to be root to install C-Kermit, if only to gain
1249    write access to directories in which the binary and manual page are to
1250    be copied. The C-Kermit binary should be installed in a directory that
1251    is in the users' PATH, but that is not likely to be overwritten when
1252    you install a new version of the operating system. A good candidate
1253    would be the /usr/local/bin/ directory, but the specific choice is site
1254    dependent. Example (assuming the appropriate Kermit binary is stored in
1255    your current directory as "wermit", e.g. because you just built it from
1256    source and that's the name the makefile gave it):
1257
1258 mv wermit /usr/local/bin/kermit
1259 chmod 755 /usr/local/bin/kermit
1260
1261    or (only after you finish reading this section!) simply:
1262
1263 make install
1264
1265    IMPORTANT: IF C-KERMIT IS TO BE USED FOR DIALING OUT, you must also do
1266    something to give it access to the dialout devices and lockfile
1267    directories. The 'install' target does not attempt to set Kermit's
1268    owner, group, and permissions to allow dialing out. This requires
1269    privileges, open eyes, and human decision-making. Please read
1270    [197]Sections 10 and [198]11 below, make the necessary decisions, and
1271    then implement them by hand as described in those sections.
1272
1273    You should also install the man page, which is called ckuker.nr, in the
1274    man page directory for local commands, such as /usr/man/man1/, renamed
1275    appropriately, e.g. to kermit.1. This is also taken care of by "make
1276    install".
1277
1278    Optionally, the text files listed in the [199]previous section can be
1279    placed in a publicly readable directory. Suggested directory names are:
1280
1281 /usr/local/doc/kermit/
1282 /usr/local/lib/kermit/
1283 /usr/share/lib/kermit/
1284 /opt/kermit/doc/
1285
1286    (or any of these without the "/kermit"). Upon startup, C-Kermit checks
1287    the following environment variables whose purpose is to specify the
1288    directory where the C-Kermit text files are, in the following order:
1289
1290 K_INFO_DIRECTORY
1291 K_INFO_DIR
1292
1293    If either of these is defined, C-Kermit checks for the existence of the
1294    ckubwr.txt file (Unix C-Kermit Hints and Tips). If not found, it checks
1295    the directories listed above (both with and without the "/kermit") plus
1296    several others to see if they contain the ckubwr.txt file. If found,
1297    various C-Kermit messages can refer the user to this directory.
1298
1299    Finally, if you want to put the source code files somewhere for people
1300    to look at, you can do that too.
1301
1302 5.4. The Makefile Install Target
1303
1304    The makefile "install" target does almost everything for you if you
1305    give it the information it needs by setting the variables described
1306    below. You can use this target if:
1307
1308      * You downloaded the [200]complete C-Kermit archive and built
1309        C-Kermit from source; or:
1310      * You downloaded an [201]individual C-Kermit binary and the
1311        [202]C-Kermit text-file archive, and your computer has a "make"
1312        command.
1313
1314    Here are the parameters you need to know:
1315
1316    BINARY
1317           Name of the binary you want to install as "kermit". Default:
1318           "wermit".
1319
1320    prefix
1321           (lower case) If you define this variable, its value is prepended
1322           to all the following xxxDIR variables (8.0.211 and later).
1323
1324    DESTDIR
1325           If you want to install the Kermit files in a directory structure
1326           like /opt/kermit/bin/, /opt/kermit/doc/, /opt/kermit/src/, then
1327           define DESTIR as the root of this structure; for example,
1328           /opt/kermit. The DESTDIR string should not end with a slash. By
1329           default, DESTDIR is not defined. If it is defined, but the
1330           directory does not exist, the makefile attempts to create it,
1331           which might require you to be root. Even so, this can fail if
1332           any segments in the path except the last one do not already
1333           exist. WARNING: If the makefile creates any directories, it
1334           gives them a mode of 755, and the default owner and group.
1335           Modify these by hand if necessary.
1336
1337    BINDIR
1338           Directory in which to install the Kermit binary (and the
1339           standard C-Kermit initialization file, if it is found, as a
1340           Kerbang script). If DESTDIR is defined, BINDIR must start with a
1341           slash. BINDIR must not end with a slash. If DESTDIR is defined,
1342           BINDIR is a subdirectory of DESTDIR. If BINDIR does not exist,
1343           the makefile attempts to create it as with DESTDIR. Default:
1344           /usr/local/bin.
1345
1346    MANDIR
1347           Directory in which to install the C-Kermit manual page as
1348           "kermit" followed by the manual-chapter extension (next item).
1349           Default: /usr/man/man1. If MANDIR is defined, the directory must
1350           already exist.
1351
1352    MANEXT
1353           Extension for the manual page. Default: 1 (digit one).
1354
1355    SRCDIR
1356           Directory in which to install the C-Kermit source code. If
1357           DESTDIR is defined, this is a subdirectory of DESTDIR. Default:
1358           None.
1359
1360    CERTDIR
1361           For secure builds only: Directory in which to install the
1362           ca_certs.pem file. This must be the verification directory used
1363           by programs that use the SSL libraries at your site. Default:
1364           none. Possibilities include: /usr/local/ssl, /opt/ssl,
1365           /usr/lib/ssl, . . .     If CERTDIR is defined, the directory
1366           must already exist.
1367
1368    INFODIR
1369           Directory in which to install the C-Kermit text files. If
1370           DESTDIR is defined, this is a subdirectory of DESTDIR. Default:
1371           None. If INFODIR is defined but does not exist, the makefile
1372           attempts to create it, as with DESTDIR.
1373
1374    Examples:
1375
1376    make install
1377           Installs "wermit" as /usr/local/bin/kermit with permissions 755,
1378           the default owner and group, and no special privileges. The
1379           manual page is installed as /usr/man/man1/kermit.1. Text files
1380           are not copied anywhere, nor are the sources.
1381
1382    make MANDIR= install
1383           Just like "make install" but does not attempt to install the
1384           manual page.
1385
1386    make DESTDIR=/opt/kermit BINDIR=/bin SRCDIR=/src INFODIR=/doc install
1387           Installs the Kermit binary "wermit" as /opt/kermit/bin/kermit,
1388           puts the source code in /opt/kermit/src, and puts the text files
1389           in /opt/kermit/doc, creating the directories if they don't
1390           already exist, and puts the man page in the default location.
1391
1392    make BINDIR=/usr/local/bin CERTDIR=/usr/local/ssl install
1393           Installs the Kerberized Kermit binary "wermit" as
1394           /usr/local/bin/kermit, puts the CA Certificates file in
1395           /usr/local/ssl/, and the man page in the normal place.
1396
1397    For definitive information, see the makefile. The following is
1398    excerpted from the 8.0.211 makefile:
1399
1400 # The following symbols are used to specify library and header file locations
1401 # Redefine them to the values used on your system by:
1402 # . editing this file
1403 # . defining the values on the command line
1404 # . defining the values in the environment and use the -e option
1405 #
1406 prefix  = /usr/local
1407 srproot = $(prefix)
1408 sslroot = $(prefix)
1409 manroot = $(prefix)
1410
1411 K4LIB=-L/usr/kerberos/lib
1412 K4INC=-I/usr/kerberos/include
1413 K5LIB=-L/usr/kerberos/lib
1414 K5INC=-I/usr/kerberos/include
1415 SRPLIB=-L$(srproot)/lib
1416 SRPINC=-I$(srproot)/include
1417 SSLLIB=-L$(sslroot)/ssl/lib
1418 SSLINC=-I$(sslroot)/ssl/include
1419 ...
1420 WERMIT = makewhat
1421 BINARY = wermit
1422 DESTDIR =
1423 BINDIR = $(prefix)/bin
1424 MANDIR = $(manroot)/man/man1
1425 MANEXT = 1
1426 SRCDIR =
1427 INFODIR =
1428 CERTDIR =
1429
1430 6. INSTALLING UNIX C-KERMIT FROM DOS-FORMAT DISKETTES
1431
1432    [ [203]Top ] [ [204]Contents ] [ [205]Next ] [ [206]Previous ]
1433
1434      This section is obsolete. We don't distribute C-Kermit on diskettes
1435      any more because (a)there is no demand, and (b) it no longer fits.
1436
1437    If you received a DOS-format diskette containing a binary executable
1438    C-Kermit program plus supporting text files, be sure to chmod +x the
1439    executable before attempting to run it.
1440
1441    In version 5A(190) and later, all the text files on the C-Kermit
1442    DOS-format diskettes are in Unix format: LF at the end of each line
1443    rather than CRLF. This means that no conversions are necessary when
1444    copying to your Unix file system, and that all the files on the
1445    diskette, text and binary, can be copied together. The following
1446    comments apply to the DOS-format diskettes furnished with version
1447    5A(189) and earlier or to other DOS-format diskettes you might have
1448    obtained from other sources.
1449
1450    If you have received C-Kermit on MS-DOS format diskettes (such as those
1451    distributed by Columbia University), you should make sure that your
1452    DOS-to-Unix conversion utility (such as "dosread") both: (1) changes
1453    line terminators in all files from carriage-return linefeed (CRLF) to
1454    just linefeed (LF) (such as "dosread -a") and remove any Ctrl-Z's, and
1455    (2) that all filenames are converted from uppercase to lowercase. If
1456    these conversions were not done, you can use the following shell script
1457    on your Unix system to do them:
1458
1459 ---(cut here)---
1460 #!/bin/sh
1461 #
1462 # Shell script to convert C-Kermit DOS-format files into Unix format.
1463 # Lowercases the filenames, strips out carriage returns and Ctrl-Z's.
1464 #
1465 x=$1 # the name of the source directory
1466 y=$2 # the name of the target directory if [ $# -lt 2 ]; then
1467   echo "usage: $0 source-directory target-directory"
1468   exit 1
1469 fi
1470 if cd $1 ; then
1471   echo "Converting files from $1 to $2"
1472 else
1473   echo "$0: cannot cd to $1"
1474   exit 1
1475 fi
1476 for i in *; do
1477   j=`echo $i | tr 'A-Z' 'a-z'`
1478   echo $x/$i =\> $y/$j
1479   tr -d '\015\032' < $i > $y/$j
1480 done
1481 ---(cut here)---
1482
1483    Cut out this shell script, save it as "convert.sh" (or any other name
1484    you prefer), then "chmod +x convert.sh". Then, create a new, empty
1485    directory to put the converted files in, and then "convert.sh /xxx
1486    /yyy" where /xxx is the name of the directory where the PC-format files
1487    are, and /yyy is the name of the new, empty directory. The converted
1488    files will appear in the new directory.
1489
1490 7. CHECKING THE RESULTS
1491
1492    [ [207]Top ] [ [208]Contents ] [ [209]Next ] [ [210]Previous ]
1493
1494    First some quick checks for problems that can be easily corrected by
1495    recompiling with different options:
1496
1497    DIRECTORY listing is garbage
1498           Permissions, size, and date are random garbage (but the
1499           filenames are correct) in a C-Kermit DIRECTORY listing. On some
1500           platforms, the lstat() function is present but simply doesn't
1501           work; try adding -DNOLSTAT to CFLAGS and rebuild. If that
1502           doesn't fix it, also add -DNOLINKBITS. If it's still not fixed,
1503           remove -DNOLSTAT and -DNOLINKBITS and add -DNOSYMLINK.
1504
1505    curses
1506           When you make a connection with C-Kermit and transfer files
1507           using the fullscreen (curses) file-transfer display, and then
1508           get the C-Kermit> prompt back afterwards, do characters echo
1509           when you type them? If not, the curses library has altered the
1510           buffering of /dev/tty. Try rebuilding with KFLAGS=-DCK_NEWTERM.
1511           If it already has -DCK_NEWTERM in CFLAGS, try removing it. If
1512           that doesn't help, then rebuild with -DNONOSETBUF (yes, two
1513           NO's). If none of this works (and you can't fix the code), then
1514           either don't use the fullscreen display, or rebuild with
1515           -DNOCURSES.
1516
1517    Ctrl-L or any SCREEN command crashes C-Kermit:
1518           Rebuild with -DNOTERMCAP.
1519
1520    No prompt after CONNECT:
1521           After escaping back from CONNECT mode, does your C-Kermit>
1522           prompt disappear? (Yet, typing "?" still produces a command
1523           list, etc) In that case, add -DCKCONINTB4CB to CFLAGS and
1524           rebuild.
1525
1526    Here is a more thorough checklist can use to tell whether your version
1527    of C-Kermit was built correctly for your Unix system, with hints on how
1528    to fix or work around problems:
1529
1530     a. Start C-Kermit (usually by typing "./wermit" in the directory where
1531        you ran the makefile). Do you see the C-Kermit> prompt? If not,
1532        C-Kermit incorrectly deduced that it was running in the background.
1533        The test is in conbgt() in [211]ckutio.c. If you can fix it for
1534        your system, please send in the fix (Hint: read about "PID_T"
1535        below). Otherwise, you can force C-Kermit to foreground mode by
1536        starting it with the -z command line option, as in "kermit -z", or
1537        giving the interactive command SET BACKGROUND OFF.
1538     b. When you type characters at the C-Kermit prompt, do they echo
1539        immediately? If not, something is wrong with concb() and probably
1540        the other terminal mode settings routines in [212]ckutio.c. Be sure
1541        you have used the most appropriate make entry.
1542     c. At the C-Kermit> prompt, type "send ./?". C-Kermit should list all
1543        the files in the current directory. If not, it was built for the
1544        wrong type of Unix file system. Details below. In the meantime, try
1545        SET WILDCARD-EXPANSION SHELL as a workaround.
1546     d. CD to a directory that contains a variety of files, symlinks, and
1547        subdirectories and give a DIRECTORY command at the C-Kermit>
1548        prompt. Do the permissions, size, and date appear correct? If not
1549        see [213]Section 4.0.
1550     e. Assuming your platform supports long file names, create a file with
1551        a long name in your current directory, e.g.:
1552
1553 $ touch thisisafilewithaveryveryveryveryveryveryveryverylooooooooongname
1554
1555        (you might need to make it longer than this, perhaps as long as 257
1556        or even 1025 characters).
1557        Check with ls to see if your version of Unix truncated the name.
1558        Now start C-Kermit and type "send thisis<ESC>". Does Kermit
1559        complete the name, showing the same name as ls did? If not, wrong
1560        filesystem. Read on.
1561     f. Make sure that Kermit has the maximum path length right. Just type
1562        SHOW FILE and see what it says about this. If it is too short,
1563        there could be some problems at runtime. To correct, look in
1564        [214]ckcdeb.h to see how the symbol CKMAXPATH is set and make any
1565        needed adjustments.
1566     g. Send a file to your new Kermit program from a different Kermit
1567        program that is known to work. Is the date/timestamp of the new
1568        file identical to the original? If not, adjustments are needed in
1569        zstrdt() in [215]ckufio.c.
1570     h. Go to another computer (Computer B) from which you can send files
1571        to C-Kermit. Connect Computer B to the computer (A) where you are
1572        testing C-Kermit. Then:
1573     i. Send a file from B to A. Make sure it transferred OK and was
1574        created with the the right name.
1575     j. Send a file from B to A, specifying an "as-name" that is very, very
1576        long (longer than the maximum name length on computer A). Check to
1577        make sure that the file was received OK and that its name was
1578        truncated to Computer A's maximum length. If not, check the
1579        MAXNAMLEN definition in [216]ckufio.c.
1580     k. Tell C-Kermit on Computer A to "set receive pathnames relative" and
1581        then send it a file from Computer B specifying an as-name that
1582        contains several directory segments:
1583
1584 send foo dir1/dir2/dir3/foo
1585
1586        Check to make sure that dir1/dir2/dir3/foo was created in Computer
1587        A's current directory (i.e. that three levels of directories were
1588        created).
1589     l. Repeat step k, but make each path segment in the pathname longer
1590        than Computer A's maximum name length. Make sure each directory
1591        name, and the final filename, were truncated properly.
1592     m. Type Ctrl-C (or whatever your Unix interrupt character is) at the
1593        prompt. Do you get "^C..." and a new prompt? If instead, you get a
1594        core dump (this shouldn't happen any more) "rm core" and then
1595        rebuild with -DNOCCTRAP added to your CFLAGS. If it did work, then
1596        type another Ctrl-C. If this does the same thing as the first one,
1597        then Ctrl-C handling is OK. Otherwise, the SIGINT signal is either
1598        not getting re-armed (shouldn't happen) or is being masked off
1599        after the first time it is caught, in which case, if your Unix is
1600        POSIX-based, try rebuilding C-Kermit with -DCK_POSIX_SIG.
1601     n. Type Ctrl-Z (or whatever your Unix suspend character is) to put
1602        C-Kermit in the background. Did it work? If nothing happened, then
1603        (a)your version of Unix does not support job control, or (b) your
1604        version of C-Kermit was probably built with -DNOJC. If your session
1605        became totally frozen, then you are probably running C-Kermit on a
1606        Unix version that supports job control, but under a shell that
1607        doesn't. If that's not the case, look in the congm() and psuspend()
1608        routines in [217]ckutio.c and see if you can figure out what's
1609        wrong. If you can't, rebuild with -DNOJC.
1610     o. Give a SET LINE command for a dialout device, e.g. "set line
1611        /dev/tty00". If you got some kind of permission or access denied
1612        message, go read [218]Section 10 and then come back here.
1613     p. After giving a successful SET LINE command, type "show comm" to see
1614        the communication parameters. Do they make sense?
1615     q. Type "set speed ?" and observe the list of available speeds. Is it
1616        what you expected? If not, see [219]Section 2) of the
1617        [220]Configurations Options document.
1618     r. Give a SET SPEED command to change the device's speed. Did it work?
1619        (Type "show comm" again to check.)
1620     s. Try dialing out: SET MODEM TYPE , SET LINE , SET SPEED , DIAL . If
1621        it doesn't work, keep reading. After dialing, can you REDIAL?
1622     t. If your version was built with TCP/IP network support, try the
1623        TELNET command.
1624     u. Transfer some files in remote mode on incoming asynchronous serial
1625        (direct or modem) connections, and on incoming network (telnet,
1626        rlogin, terminal server) connections. If you get lots of errors,
1627        try different SET FLOW settings on the remote Kermit program.
1628     v. Establish a serial connection from C-Kermit to another computer
1629        (direct or dialed) and transfer some files. If you have network
1630        support, do the same with a network connection.
1631     w. If your version was built with fullscreen file transfer display
1632        support, check that it works during local-mode file transfer. Also,
1633        check C-Kermit's operation afterwards: is the echoing funny? etc
1634        etc. If there are problems, see [221]Section 4.
1635     x. If your version was built with script programming language support,
1636        TAKE the ckedemo.ksc file to give it a workout.
1637     y. Does C-Kermit interlock correctly with UUCP-family programs (cu,
1638        tip, uucp, etc)? If not, read the section [222]DIALING OUT AND
1639        COORDINATING WITH UUCP below.
1640     z. Modem signals... Give a SET LINE command to a serial device and
1641        then type the SHOW MODEM command. If it says "Modem signals
1642        unavailable in this version of Kermit", then you might want to look
1643        at the ttgmdm() routine in [223]ckutio.c and add the needed code --
1644        if indeed your version of Unix provides a way to get modem signals
1645        (some don't; e.g. modem signals are a foreign concept to POSIX,
1646        requiring politically incorrect workarounds).
1647    aa. If it says "Modem signals unavailable", then it is likely that the
1648        API for getting modem signals is provided, but it doesn't actually
1649        do anything (e.g. ioctl(ttyfd,TIOCMGET,&x) returns EINVAL).
1650    ab. In any case, it still should be able to manipulate the DTR signal.
1651        To test, SET LINE , SET MODEM NONE, and HANGUP. The DTR light
1652        should go out momentarily. If it doesn't, see if you can add the
1653        needed code for your system to the tthang() routine in
1654        [224]ckutio.c.
1655    ac. If your version of Kermit has the SET FLOW RTS/CTS command, check
1656        to see if it works: give Kermit this command, set your modem for
1657        RTS/CTS, transfer some files (using big packet and window sizes)
1658        and watch the RTS and CTS lights on the modem. If they go on and
1659        off (and Kermit does not get packet errors), then it works. If your
1660        version of Kermit does not have this command, but your version of
1661        Unix does support hardware flow control, take a look at the
1662        tthflow() command in [225]ckutio.c and see if you can add the
1663        needed code (see the section on [226]HARDWARE FLOW CONTROL below).
1664        (And please [227]send back any added code, so that others can
1665        benefit from it and it can be carried forward into future
1666        releases.)
1667    ad. If C-Kermit starts normally and issues its prompt, echoing is
1668        normal, etc, but then after returning from a CONNECT session, the
1669        prompt no longer appears, try rebuilding with -DCKCONINTB4CB.
1670    ae. (8.0.206 or later) Type some commands at the C-Kermit prompt. Can
1671        you use the Up-arrow and Down-arrow keys on your keyboard to access
1672        Kermit's command history? If not, and you're a programmer, take a
1673        look at the USE_ARROWKEYS sections of ckucmd.c.
1674
1675 8. REDUCING THE SIZE OF THE EXECUTABLE PROGRAM IMAGE
1676
1677    [ [228]Top ] [ [229]Contents ] [ [230]Next ] [ [231]Previous ]
1678
1679    Also see: [232]C-Kermit Configuration Options
1680
1681     a. Many of C-Kermit's options and features can be deselected at
1682        compile time. The greatest savings at the least sacrifice in
1683        functionality is to disable the logging of debug information by
1684        defining NODEBUG during compilation. See the [233]Configurations
1685        Options document for further information.
1686     b. Use shared libraries rather than static linking. This is the
1687        default on many Unix systems anyway. However, executables built for
1688        dynamic linking with shared libraries are generally not portable
1689        away from the machine they were built on, so this is recommended if
1690        the binary is for your use only.
1691     c. Most Unix systems have a "strip" command to remove symbol table
1692        information from an executable program image. "man strip" for
1693        further information. The same effect can be achieved by including
1694        "-s" among the link flags when building C-Kermit.
1695     d. SCO, Interactive, and some other Unix versions have an "mcs"
1696        command. "mcs -d wermit" can be used to delete the contents of the
1697        ".comment" section from the executable program image.
1698     e. Many modern optimizers can be instructed to optimize for space
1699        rather than execution efficiency. Check the CFLAGS in the makefile
1700        target, adjust as desired.
1701
1702 9. UNIX VERSIONS
1703
1704    [ [234]Top ] [ [235]Contents ] [ [236]Next ] [ [237]Previous ]
1705
1706    SECTION CONTENTS
1707
1708 9.1 [238]Standards
1709      9.1.1. [239]POSIX
1710      9.1.2. [240]ANSI C
1711      9.1.3. [241]Other Standards
1712 9.2. [242]Library Issues
1713 9.3. [243]Unix File System Peculiarities
1714 9.4. [244]Hardware Flow Control
1715 9.5. [245]Terminal Speeds
1716 9.6. [246]Millisecond Sleeps
1717 9.7. [247]Nondestructive Input Buffer Peeking
1718 9.8. [248]Other System-Dependent Features
1719 9.9. [249]Terminal Interruption
1720
1721    There are several major varieties of Unix: Bell Laboratories Seventh
1722    Edition, AT&T System V, Berkeley Standard Distribution (BSD), and
1723    POSIX. Each has many, many subvarieties and descendents, and there are
1724    also hybrids that exhibit symptoms of two or more varieties, plus
1725    special quirks of their own.
1726
1727    Seventh edition versions of C-Kermit include the compile-time option
1728    -DV7 in the CFLAGS string in the makefile target. Various V7-based
1729    implementations are also supported: -DCOHERENT, -DMINIX, etc.
1730
1731    AT&T-based versions of Unix Kermit include the compile-time option
1732    -DATTSV (standing for AT&mp;T Unix System V). This applies to System
1733    III and to System V up to and including Release 2. For System V Release
1734    3, the flag -DSVR3 should be used instead (which also implies -DATTSV).
1735    This is because the data type of signal() and several other functions
1736    was changed between SVR2 and SVR3. For System V Release 4, include
1737    -DSVR4 because of changes in UUCP lockfile conventions; this also
1738    implies -DSVR3 and -DATTSV.
1739
1740    For BSD, the flag -BSDxx must be included, where xx is the BSD version
1741    number, for example BSD4 (for version 4.2 or later, using only 4.2
1742    features), -DBSD41 (for BSD 4.1 only), -DBSD43 (for 4.3), -DBSD29 (BSD
1743    2.9 for DEC PDP-11s). -DBSD44 is for 4.4BSD, which is the basis of
1744    FreeBSD, NetBSD, OpenBSD, BSDI, and Mac OS X, and which contains many
1745    POSIX features, and has little relation to 4.3BSD and earlier.
1746
1747    For POSIX, include the flag -DPOSIX. POSIX defines a whole new set of
1748    terminal i/o functions that are not found in traditional AT&T or
1749    Berkeley implementations, and also defines the symbol _POSIX_SOURCE,
1750    which is used in many system and library header files, mainly to
1751    disable non-POSIX (i.e. useful) features.
1752
1753    Note (circa 1997): In order to enable serial speeds higher than 38400
1754    bps, it is generally necessary to add -DPOSIX (among other things),
1755    since the older terminal APIs can not accommodate the new speeds -- out
1756    o' bits. But this often also means wholesale conversion to POSIX APIs.
1757    In general, just try adding -DPOSIX and then see what goes wrong. Be
1758    wary of features disappearing: when _POSIX_SOURCE is defined, all sorts
1759    of things that were perfectly OK before suddenly become politically
1760    incorrect -- like reading modem signals, doing hardware flow control,
1761    etc. POSIX was evidently not designed with serial communication in
1762    mind!
1763
1764    Case in point: In UnixWare 7.0, #define'ing POSIX causes strictness
1765    clauses in the header files to take effect. These prevent <sys/time.h>
1766    from defining the timeval and timezone structs, which are needed for
1767    all sorts of things (like select()). Thus, if we want the high serial
1768    speeds, we have to circumvent the POSIX clauses.
1769
1770    Similarly in SCO OpenServer R5.0.4 where, again, we must use the POSIX
1771    APIs to get at serial speeds higher than 38400, but then doing so
1772    removes hardware flow control -- just when we need it most! In cases
1773    like this, dirty tricks are the only recourse (search for SCO_OSR504 in
1774    [250]ckutio.c for examples).
1775
1776    For reasons like this, Unix implementations tend to be neither pure
1777    AT&T nor pure BSD nor pure POSIX, but a mixture of two or more of
1778    these, with "compatibility features" allowing different varieties of
1779    programs to be built on the same computer. In general, Kermit tries not
1780    to mix and match but to keep a consistent repertoire throughout.
1781    However, there are certain Unix implementations that only work when you
1782    mix and match. For example, the Silicon Graphics IRIX operating system
1783    (prior to version 3.3) is an AT&T Unix but with a BSD file system. The
1784    only way you can build Kermit successfully for this configuration is to
1785    include -DSVR3 plus the special option -DLONGFN, meaning "pretend I was
1786    built with -DBSDxx when it's time to compile file-related code". See
1787    the "iris" makefile target.
1788
1789 9.1. Standards
1790
1791    [ [251]Top ] [ [252]Section Contents ] [ [253]Contents ] [ [254]Next ]
1792
1793    SUBSECTION CONTENTS
1794
1795 9.1.1. [255]POSIX
1796 9.1.2. [256]ANSI C
1797 9.1.3. [257]Other Standards
1798
1799    In edits 166-167 (1988-89), C-Kermit was heavily modified to try to
1800    keep abreast of new standards while still remaining compatible with old
1801    versions of C and Unix. There are two new standards of interest: ANSI C
1802    (as described in Kernighan and Ritchie, "The C Programming Language",
1803    Second Edition, Prentice Hall, 1988) and POSIX.1 (IEEE Standard 1003.1
1804    and ISO/IEC 9945-1, 1990, "Portable Operating System Interface"). These
1805    two standards have nothing to do with each other: you can build
1806    C-Kermit with a non-ANSI compiler for a POSIX system, or for a
1807    non-POSIX system with with an ANSI compiler.
1808
1809 9.1.1. POSIX
1810
1811    POSIX.1 defines a repertoire of system functions and header files for
1812    use by C language programs. Most notably, the ioctl() function is not
1813    allowed in POSIX; all ioctl() functions have been replaced by
1814    device-specific functions like tcsetattr(), tcsendbreak(), etc.
1815
1816    Computer systems that claim some degree of POSIX compliance have made
1817    some attempt to put their header files in the right places and give
1818    them the right names, and to provide system library functions with the
1819    right names and calling conventions. Within the header files,
1820    POSIX-compliant functions are supposed to be within #ifdef
1821    _POSIX_SOURCE..#endif conditionals, and non-POSIX items are not within
1822    these conditionals.
1823
1824    If Kermit is built with neither -D_POSIX_SOURCE nor -DPOSIX, the
1825    functions and header files of the selected version of Unix (or VMS,
1826    etc) are used according to the CFLAGS Kermit was built with.
1827
1828    If Kermit is built with -D_POSIX_SOURCE but not -DPOSIX, then one of
1829    the -DBSD or -DATTSV flags (or one that implies them) must also be
1830    defined, but it still uses only the POSIX features in the system header
1831    files. This allows C-Kermit to be built on BSD or AT&T systems that
1832    have some degree of POSIX compliance, but still use BSD or AT&T
1833    specific features.
1834
1835    The dilimma is this: it is often necessary to define _POSIX_SOURCE to
1836    get at new or modern features, such as high serial speeds and the APIs
1837    to deal with them. But defining _POSIX_SOURCE also hides other APIs
1838    that Kermit needs, for example the ones dealing with modem signals
1839    (others are listed just below). Thus all sorts of hideous contortions
1840    are often required to get a full set of features.
1841
1842    The POSIX standard does not define anything about uucp lockfiles. "make
1843    posix" uses NO (repeat, NO) lockfile conventions. If your
1844    POSIX-compliant Unix version uses a lockfile convention such as HDBUUCP
1845    (see below), use the "posix" entry, but include the appropriate
1846    lockfile option in your KFLAGS on the "make" command line, for example:
1847
1848 make posix "KFLAGS=-DHDBUUCP"
1849
1850    POSIX.1 also lacks certain other features that Kermit needs. For
1851    example:
1852
1853      * There is no defined way for an application to do wildcard matching
1854        of filenames. Kermit uses the inode in the directory structure, but
1855        POSIX.1 does not include this concept. (Later POSIX revisions
1856        include functions named (I think) glob() and fnmatch(), but these
1857        functions are not yet in Kermit, and might not be appropriate in
1858        any case.)
1859      * There is no POSIX mechanism for sensing or controlling modem
1860        signals, nor to enable RTS/CTS or other hardware flow control.
1861      * There is no select() for multiplexing i/o, and therefore no TCP/IP.
1862      * There is no way to check if characters are waiting in a
1863        communications device (or console) input buffer, short of trying to
1864        read them -- no select(), ioctl(fd,FIONREAD,blah), rdchk(), etc.
1865        This is bad for CONNECT mode and bad for sliding windows.
1866      * No way to do a millisecond sleep (no nap(), usleep(), select(),
1867        etc).
1868      * There is no popen().
1869
1870    So at this point, there cannot be one single fully functional POSIX
1871    form of C-Kermit unless it also has "extensions", as do Linux, QNX,
1872    etc.
1873
1874    More on POSIX (quoting from a newsgroup posting by Dave Butenhof):
1875
1876      Standards tend to look at themselves as "enabling". So POSIX
1877      standards say that, in order to use POSIX functions, a program must
1878      define some macro that will put the development environment in
1879      "POSIX mode". For the ancient POSIX 1003.1-1990, the symbol is
1880      _POSIX_SOURCE. For recent revisions, it's _POSIX_C_SOURCE with an
1881      appropriate value. POSIX 1003.1-1996 says that, to use its features
1882      in a portable manner, you must define _POSIX_C_SOURCE=199506L before
1883      including any header files.
1884
1885      But for Solaris, or Digital Unix, the picture is different. POSIX is
1886      one important but small part of the universe. Yet POSIX
1887      unconditionally and unambiguously REQUIRES that, when
1888      _POSIX_C_SOURCE=199506L, ALL of the functions and definitions
1889      required by the standard, and NO others (except in specific
1890      restricted namespaces, specifically "_" followed by an uppercase
1891      letter or "__" followed by a lowercase letter) shall be visible.
1892      That kinda puts a cramp on BSD and SVID support, because those
1893      require names that are not in the "protected" POSIX namespaces. It's
1894      ILLEGAL to make those symbols visible, unless you've done something
1895      else that's beyond the scope of POSIX to allow the system to infer
1896      that you didn't really mean it.
1897
1898      In most cases, you should just compile, with no standards-related
1899      macros defined. The system will make available every interface and
1900      definition that isn't incompatible with the "main stream". There may
1901      indeed be cases where two standards cross, and you really can't use
1902      both together. But, in general, they play nicely together as long as
1903      you don't do anything rash -- like telling the system that it's not
1904      allowed to let them.
1905
1906      In the area of threads, both Solaris and Digital Unix support
1907      incompatible thread APIs. We have POSIX and DCE, they have POSIX and
1908      UI. The nasty areas are in the _r routines and in some aspects of
1909      signal behavior. You cannot compile a single source file that uses
1910      both semantics. That's life. It sounds as if Solaris defaults to the
1911      UI variants, but allows you to define this _POSIX_THREAD_SEMANTICS
1912      to get around it. We default to POSIX, and allow you to define
1913      _PTHREAD_USE_D4 (automatically defined by the cc "-threads" switch)
1914      to select the DCE thread variants. That default, because you're
1915      operating outside of any individual standard, is really just a
1916      marketing decision.
1917
1918 9.1.2. ANSI C
1919
1920    [ [258]Top ] [ [259]Contents ] [ [260]Section Contents ] [
1921    [261]Subsection Contents ] [ [262]Next ] [ [263]Previous ]
1922
1923    The major difference between ANSI C and earlier C compilers is function
1924    prototyping. ANSI C allows function arguments to be checked for type
1925    agreement, and (when possible) type coercion in the event of a
1926    mismatch. For this to work, functions and their arguments must be
1927    declared before they are called. The form for function declarations is
1928    different in ANSI C and non-ANSI C (ANSI C also accepts the earlier
1929    form, but then does not do type checking).
1930
1931    As of edit 167, C-Kermit tries to take full advantage of ANSI C
1932    features, especially function prototyping. This removes many bugs
1933    introduced by differing data types used or returned by the same
1934    functions on different computers. ANSI C features are automatically
1935    enabled when the symbol __STDC__ is defined. Most ANSI C compilers,
1936    such as GNU CC and the new DEC C compiler define this symbol
1937    internally.
1938
1939    On the downside, ANSI C compilation increases the
1940    administrative/bureacratic burden, spewing out countless unneeded
1941    warnings about mismatched types, especially when we are dealing with
1942    signed and unsigned characters, requiring casts everywhere to shut up
1943    the mindless complaints -- there is no use for signed chars in Kermit
1944    (or probably anywhere else). Some compilers, mercifully, include a
1945    "treat all chars as unsigned" option, and when available it should be
1946    used -- not only to stop the warnings, but also to avoid unhelpful sign
1947    extension on high-bit characters.
1948
1949    To force use of ANSI C prototypes, include -DCK_ANSIC on the cc command
1950    line. To disable the use of ANSI prototypes, include -DNOANSI.
1951
1952 9.1.3. Other Standards
1953
1954    [ [264]Top ] [ [265]Contents ] [ [266]Section Contents ] [
1955    [267]Subsection Contents ] [ [268]Next ] [ [269]Previous ]
1956
1957    As the years go by, standards with-which-all-must-comply continue to
1958    pile up: AES, XPG2, XPG3, XPG4, FIPS 151-2, successive generations of
1959    POSIX, OSF/1, X/Open, Spec 1170, UNIX95, Open Group UNIX98, ISO/IEC
1960    9945 parts 1-4, ISO 9899, 88Open, OS 99, Single Unix Specification
1961    (SUS, [270]IEEE 1003.1-2001, not to mention "mature standards" like V7,
1962    4.2/4.3BSD, System V R3 and R4 (SVID2 and SVID3), 4.4BSD (the basis for
1963    BSDI, OpenBSD, NetBSD, FreeBSD, Mac OS X etc), /usr/group, plus
1964    assorted seismic pronouncements of the neverending series of ephemeral
1965    corporate consortia, not to mention the libc-vs-glibc turmoil in the
1966    Linux arena and who knows what else.
1967
1968    None of these standards simplifies life for portable applications like
1969    C-Kermit -- each one is simply one more environment to support (or
1970    circumvent, as in many cases these standards do more harm than good by
1971    denying access to facilities we need, e.g. as noted in above in
1972    [271]9.1.1).
1973
1974 9.2. Library Issues
1975
1976    [ [272]Top ] [ [273]Contents ] [ [274]Section Contents ] [
1977    [275]Subsection Contents ] [ [276]Next ] [ [277]Previous ]
1978
1979    On most modern platforms, applications are -- and often must be --
1980    dynamically linked. This has numerous advantages (smaller executables,
1981    ability to patch a library and thereby patch all applications that use
1982    it, etc), but also causes some headaches: most commonly, the library ID
1983    built into the executable at link time does not match the ID of the
1984    corresponding library on the target system, and so the loader refuses
1985    to let the application run.
1986
1987    This problem only gets worse over time. In the Linux and *BSD world, we
1988    also have totally different libraries (each with their own names and
1989    numbering systems) that cover the same territory; for example, curses
1990    vs ncurses, libc versus glibc. Combinations proliferate and any given
1991    Unix computer might have any combination. For this reason it is
1992    becoming increasingly difficult to produce a "Linux binary" for a given
1993    architecture (e.g. PC or Alpha). There has to be a separate binary for
1994    (at least) every combination of curses vs ncurses and libc vs glibc.
1995
1996    In such cases, the best advice is for every user to build C-Kermit from
1997    source code on the system where it will run. Too bad most commercial
1998    Unix vendors have stopped including C compilers with the operating
1999    system!
2000
2001 9.3. Unix File System Peculiarities
2002
2003    [ [278]Top ] [ [279]Contents ] [ [280]Section Contents ] [ [281]Next ]
2004    [ [282]Previous ]
2005
2006    Normally, including a BSD, System-V, POSIX, or DIRENT flag in the make
2007    entry selects the right file system code. But some versions of Unix are
2008    inconsistent in this regard, and building in the normal way either
2009    gives compiler or linker errors, or results in problems at runtime,
2010    typically failure to properly expand wildcard file specifications when
2011    you do something like "send *.*", or failure to recognize long
2012    filenames, as in "send filewithaveryveryveryveryverylongname".
2013
2014    C-Kermit is supposed to know about all the various styles of Unix file
2015    systems, but it has to be told which one to use when you build it,
2016    usually in the makefile target CFLAGS as shown below, but you might
2017    also have to add something like -I/usr/include/bsd to CFLAGS, or
2018    something like -lbsd to LIBS.
2019
2020    C-Kermit gives you the following CFLAGS switches to adapt to your file
2021    system's peculiarities:
2022
2023 -DDIRENT   - #include <dirent.h>
2024 -DSDIRENT  - #include <sys/dirent.h>
2025 -DNDIR     - #include <ndir.h>
2026 -DXNDIR    - #include <sys/ndir.h>
2027 -DRTU      - #include "/usr/lib/ndir.h", only if NDIR and XNDIR not defined.
2028 -DSYSUTIMH - #include <sys/utime.h> for setting file creation dates.
2029 -DUTIMEH   - #include <utime.h> for setting file creation dates.
2030
2031    (Note, RTU should only be used for Masscomp RTU systems, because it
2032    also selects certain other RTU-specific features.)
2033
2034    If none of these is defined, then <sys/dir.h> is used. IMPORTANT: If
2035    your system has the file /usr/include/dirent.h then be sure to add
2036    -DDIRENT to your makefile target's CFLAGS. "dirent" should be used in
2037    preference to any of the others, because it supports all the features
2038    of your file system, and the others probably don't.
2039
2040    Having selected the appropriate directory header file, you might also
2041    need to tell Kermit how to declare the routines and variables it needs
2042    to read the directory. This happens most commonly on AT&T System-V
2043    based UNIXes, particularly System V R3 and earlier, that provide long
2044    file and directory names (longer than 14 characters). Examples include
2045    certain releases of HP-UX, DIAB DNIX, older versions of Silicon
2046    Graphics IRIX, and perhaps also MIPS. In this case, try adding -DLONGFN
2047    to your makefile target.
2048
2049    Another problem child is <sys/file.h>. Most Unix C-Kermit versions need
2050    to #include this file from within [283]ckufio.c and [284]ckutio.c, but
2051    some not only do not need to include it, but MUST not include it
2052    because (a) it doesn't exist, or (b) it has already been included by
2053    some other header file and it doesn't protect itself against multiple
2054    inclusion, or (c) some other reason that prevents successful
2055    compilation. If you have compilation problems that seem to stem from
2056    including this file, then add the following switch to CFLAGS in your
2057    makefile target:
2058
2059 -DNOFILEH
2060
2061    There are a few odd cases where <sys/file.h> must be included in one of
2062    the cku[ft]io.c files, but not the other. In that case, add the
2063    aforementioned switch, but go into the file that needs <sys/file.h> and
2064    add something like this:
2065
2066 #ifdef XXX       /* (where XXX is a symbol unique to your system) */
2067 #undef NOFILEH
2068 #endif /* XXX */
2069
2070    before the section that includes <sys/file.h>.
2071
2072    Kermit's SEND command expands wildcard characters "?" and "*" itself.
2073    Before version 5A, commands like "send *" would send all regular
2074    (non-directory) files, including "hidden files" (whose names start with
2075    "."). In version 5A, the default behavior is to match like the Bourne
2076    shell or the ls command, and not include files whose names start with
2077    dot. Such files can still be sent if the dot is included explicitly in
2078    the SEND command: "send .oofa, send .*". To change back to the old way
2079    and let leading wildcard characters match dot files, include the
2080    following in your CFLAGS:
2081
2082 -DMATCHDOT
2083
2084    (In C-Kermit 6.0, there is also a command to control this at runtime.)
2085
2086    Complaints about data-type mismatches:
2087
2088      * If you get compile-time complaints about data type mismatches for
2089        process-ID related functions like getpid(), add -DPID_T=pid_t.
2090      * If you get compile-time complaints about data type mismatches for
2091        user ID related functions like getuid(), add -DUID_T=uid_t.
2092      * If you get compile-time complaints about data type mismatches for
2093        user-ID related functions like getgid(), add -DGID_T=gid_t.
2094      * If you get compile-time complaints about data type mismatches for
2095        getpwuid(), add -DPWID_T=uid_t (or whatever it should be).
2096
2097    File creation dates: C-Kermit attempts to set the creation date/time of
2098    an incoming file according to the date/time given in the file's
2099    attribute packet, if any. If you find that the dates are set
2100    incorrectly, you might need to build Kermit with the -DSYSUTIMEH flag,
2101    to tell it to include <sys/utime.h>. If that doesn't help, look at the
2102    code in zstrdt() in [285]ckufio.c.
2103
2104 9.4. Hardware Flow Control
2105
2106    [ [286]Top ] [ [287]Contents ] [ [288]Section Contents ] [ [289]Next ]
2107    [ [290]Previous ]
2108
2109    Hardware flow control is a problematic concept in many popular Unix
2110    implementations. Often it is lacking altogether, and when available,
2111    the application program interface (API) to it is inconsistent from
2112    system to system. Here are some examples:
2113
2114     a. POSIX does not support hardware flow control.
2115     b. RTS/CTS flow control support MIGHT be available for System V R3 and
2116        later if /usr/include/termiox.h exists (its successful operation
2117        also depends on the device driver, and the device itself, not to
2118        mention the [291]cable, etc, actually supporting it). If your
2119        SVR3-or-later Unix system does have this file, add:
2120
2121 -DTERMIOX
2122
2123        to your CFLAGS. If the file is in /usr/include/sys instead, add:
2124
2125 -DSTERMIOX
2126
2127        Note that the presence of this file does not guarantee that RTS/CTS
2128        will actually work -- that depends on the device-driver
2129        implementation (reportedly, many Unix versions treat
2130        hardware-flow-control related ioctl's as no-ops).
2131     c. Search ("grep -i") through /usr/include/*.h and
2132        /usr/include/sys/*.h for RTS or CTS and see what turns up. For
2133        example, in SunOS 4.x we find "CRTSCTS". Figuring out how to use it
2134        is another question entirely! In IBM AIX RS/6000 3.x, we have to
2135        "add" a new "line discipline" (and you won't find uppercase RTS or
2136        CTS symbols in the header files).
2137     d. NeXTSTEP and IRIX, and possibly others, support hardware flow
2138        control, but do not furnish an API to control it, and thus on these
2139        systems Kermit has no command to select it -- instead, a special
2140        device name must be used. (NeXTSTEP: /dev/cufa instead of /dev/cua;
2141        IRIX: /dev/ttyf00)
2142
2143    See the routine tthflow() in [292]ckutio.c for details. If you find
2144    that your system offers hardware flow control selection under program
2145    control, you can add this capability to C-Kermit as follows:
2146
2147     a. See if it agrees with one of the methods already used in tthflow().
2148        if not, add new code, appropriately #ifdef'd.
2149     b. Add -DCK_RTSCTS to the compiler CFLAGS in your makefile target or
2150        define this symbol within the appropriate #ifdefs in [293]ckcdeb.h.
2151
2152    To illustrate the difficulties with RTS/CTS, here is a tale from Jamie
2153    Watson <jw@adasoft.ch>, who added the RTS/CTS code for the RS/6000,
2154    about his attempts to do the same for DEC ULTRIX:
2155
2156      "The number and type of hardware signals available to/from a serial
2157      port vary between different machines and different types of serial
2158      interfaces on each machine. This means that, for example, there are
2159      virtually no hardware signals in or out available on the DECsystem
2160      3000/3100 series; on the DECsystem 5000/2xx series all modem signals
2161      in/out are present on both built-in serial ports; on the DECsystem
2162      5100 some ports have all signals and some only have some; and so
2163      on... It looks to me as if this pretty well rules out any attempt to
2164      use hardware flow control on these platforms, even if we could
2165      figure out how to do it. The confusion on the user level about
2166      whether or not it should work for any given platform or port would
2167      be tremendous. And then it isn't clear how to use the hardware
2168      signals even in the cases where the device supports them."
2169
2170   9.5. Terminal Speeds
2171
2172    [ [294]Top ] [ [295]Contents ] [ [296]Section Contents ] [ [297]Next ]
2173    [ [298]Previous ]
2174
2175    The allowable speeds for the SET SPEED command are defined in
2176    [299]ckcdeb.h. If your system supports speeds that are not listed in
2177    "set speed ?", you can add definitions for them to ckcdeb.h.
2178
2179    Then if the speed you are adding is one that was never used before in
2180    Kermit, such as 921600, you'll also need to add the appropriate
2181    keywords to spdtab[] in [300]ckuus3.c, and the corresponding case to
2182    ttsspd() in [301]ckutio.c.
2183
2184   9.6. Millisecond Sleeps
2185
2186    [ [302]Top ] [ [303]Contents ] [ [304]Section Contents ] [ [305]Next ]
2187    [ [306]Previous ]
2188
2189    There is no standard for millisecond sleeps, but at least five
2190    different functions have appeared in various Unix versions that can be
2191    used for this purpose: nap() (mostly in System V), usleep() (found at
2192    least in SunOS and NeXT OS), select() (found in 4.2BSD and later, and
2193    part of any TCP/IP sockets library), nanosleep(), and sginap(). If you
2194    have any of these available, pick one (in this order of preference, if
2195    you have more than one):
2196
2197 -DSELECT: Include this in CFLAGS if your system has the select() function.
2198 -DNAP:    Include this in CFLAGS if your system has the nap() function.
2199 -USLEEP:  Include this in CFLAGS if your system has the usleep() function.
2200
2201    NOTE: The nap() function is assumed to be a function that puts the
2202    process to sleep for the given number of milliseconds. If your system's
2203    nap() function does something else or uses some other units of time
2204    (like the NCR Tower 32, which uses clock-ticks), do not include -DNAP.
2205
2206    Reportedly, all versions of System V R4 for Intel-based computers, and
2207    possibly also SVR3.2, include nap() as a kernel call, but it's not in
2208    the library. To include code to use it via syscall(3112,x), without
2209    having to include Xenix compatibility features, include the following
2210    compile-time option:
2211
2212 -DNAPHACK
2213
2214   9.7. Nondestructive Input Buffer Peeking
2215
2216    [ [307]Top ] [ [308]Contents ] [ [309]Section Contents ] [ [310]Next ]
2217    [ [311]Previous ]
2218
2219    Some AT&T Unix versions have no way to check if input is waiting on a
2220    tty device, but this is a very important feature for Kermit. Without
2221    it, sliding windows might not work very well (or at all), and you also
2222    have to type your escape character to get Kermit's attention in order
2223    to interrupt a local-mode file transfer. If your system offers an
2224    FIONREAD ioctl, the build procedure should pick that up automatically
2225    and use it, which is ideal.
2226
2227    If your system lacks FIONREAD but has a select() function, this can be
2228    used instead. If the build procedure fails to include it (SHOW FEATURES
2229    will list SELECT), then you can add it to your CFLAGS:
2230
2231 -DSELECT
2232
2233    Conversely, if the build procedure tries to use select() when it really
2234    is not there, add:
2235
2236 -DNOSELECT
2237
2238    Note: select() is not part of System V nor of POSIX, but it has been
2239    added to various System-V- and POSIX-based systems as an extension.
2240
2241    Some System-V variations (SCO Xenix/UNIX/ODT and DIAB DNIX) include a
2242    rdchk() function that can be used for buffer peeking. It returns 0 if
2243    no characters are waiting and 1 if characters are waiting (but unlike
2244    FIONREAD, it does not tell the actual number). If your system has
2245    rdchk(), add:
2246
2247 -DRDCHK:  Include this in CFLAGS if your system has the rdchk() function.
2248
2249    Otherwise, if your version of Unix has the poll() function (and the
2250    /usr/include/poll.h file) -- which appears to be a standard part of
2251    System V going back to at least SVR3, include:
2252
2253 -DCK_POLL
2254
2255   9.8. Other System-Dependent Features
2256
2257    [ [312]Top ] [ [313]Contents ] [ [314]Section Contents ] [ [315]Next ]
2258    [ [316]Previous ]
2259
2260    Systems with <termios.h> might have the symbol IEXTEN defined. This is
2261    used to turn "extended features" in the tty device driver on and off,
2262    such as Ctrl-O to toggle output flushing, Ctrl-V to quote input
2263    characters, etc.
2264
2265    In most Unix implementations, it should be turned off during Kermit
2266    operation, so if [317]ckutio.c finds this symbol, it uses it. This is
2267    necessary, at least, on BSDI. On some systems, however, IEXTEN is
2268    either misdefined or misimplemented. The symptom is that CR, when typed
2269    to the command processor, is echoed as LF, rather than CRLF. This
2270    happens (at least) on Convex/OS 9.1. The solution is to add the
2271    following symbol to the makefile target's CFLACS:
2272
2273 -DNOIEXTEN
2274
2275    However, in at least one Unix implementation, QNX 4.21, IEXTEN must be
2276    set before hardware flow control can be used.
2277
2278    In edits 177 and earlier, workstation users noticed a "slow screen
2279    writing" phenomenon during interactive command parsing. This was traced
2280    to a setbuf() call in [318]ckutio.c that made console (stdout) writes
2281    unbuffered. This setbuf() call has been there forever, and could not be
2282    removed without some risk. Kermit's operation was tested on the NeXT in
2283    edit 178 with the setbuf() call removed, and the slow-writing symptom
2284    was cured, and everything else (command parsing, proper wakeup on ?,
2285    ESC, Ctrl-U, and other editing characters, terminal emulation,
2286    remote-mode and local-mode file transfer, etc) seemed to work as well
2287    as or better than before. In subsequent edits, this change was made to
2288    many other versions too, with no apparent ill effects. To remove the
2289    setbuf() call for your version of Kermit, add:
2290
2291 -DNOSETBUF
2292
2293    Later reports indicate that adding -DNOSETBUF has other beneficial
2294    effects, like cutting down on swapping when Kermit is run on
2295    workstations with small memories. But BEWARE: on certain small Unix
2296    systems, notably the AT&T 6300 and 3B1 (the very same ones that benefit
2297    from NOSETBUF), NOSETBUF seems to conflict with CK_CURSES. The program
2298    builds and runs OK, but after once using the curses display, echoing is
2299    messed up. In this case, we use a System-V specific variation in the
2300    curses code, using newterm() to prevent System V from altering the
2301    buffering. See makefile entries for AT&T 6300 and 3B1.
2302
2303    The Unix version of C-Kermit includes code to switch to file descriptor
2304    zero (stdin) for remote-mode file transfer. This code is necessary to
2305    prevent Kermit from giving the impression that it is "idle" during file
2306    transfers, which, at some sites, can result in the job being logged out
2307    in the middle of an active file transfer by idle-job monitors.
2308
2309    However, this feature can interfere with certain setups; for example,
2310    there is a package which substitutes a pty/tty pair for /dev/tty and
2311    sets file descriptor 0 to be read-only, preventing Kermit from sending
2312    packets. Or... When a Unix shell is invoked under the PICK environment,
2313    file descriptor 0 is inoperative.
2314
2315    To remove this feature and allow Kermit to work in such environments,
2316    add the compile-time option:
2317
2318 -DNOFDZERO
2319
2320    On some versions of Unix, earlier releases of C-Kermit were reported to
2321    render a tty device unusable after a hangup operation. Examples include
2322    IBM AIX on the RT PC and RS/6000. A typical symptom of this phenomenon
2323    is that the DIAL command doesn't work, but CONNECTing to the device and
2324    dialing manually do work. A further test is to SET DIAL HANGUP OFF,
2325    which should make dialing work once by skipping the pre-dial hangup.
2326    However, after the connection is broken, it can't be used any more:
2327    subsequent attempts to DIAL the same device don't work. The cure is
2328    usually to close and reopen the device as part of the hangup operation.
2329    To do this, include the following compile-time option:
2330
2331 -DCLSOPN
2332
2333    Similarly, there is a section of code in ttopen(), which does another
2334    close(open()) to force the O_NDELAY mode change. On some systems, the
2335    close(open()) is required to make the mode change take effect, and
2336    apparently on most others it does no harm. But reportedly on at least
2337    one System V R4 implementation, and on SCO Xenix 3.2, the close(open())
2338    operation hangs if the device lacks carrier, EVEN THOUGH the CLOCAL
2339    characteristic has just been set to avoid this very problem. If this
2340    happens to you, add this to your CFLAGS:
2341
2342 -DNOCOTFMC
2343
2344    or, equivalently, in your KFLAGS on the make command line. It stands
2345    for NO Close(Open()) To Force Mode Change.
2346
2347    C-Kermit renames files when you give a RENAME command and also
2348    according to the current SET FILE COLLISION option when receiving
2349    files. The normal Unix way to rename a file is via two system calls:
2350    link() and unlink(). But this leaves open a window of vulnerability.
2351    Some Unix systems also offer an atomic rename(oldname,newname)
2352    function. If your version of Unix has this function, add the following
2353    to your CFLAGS:
2354
2355 -DRENAME
2356
2357    C-Kermit predefines the RENAME for several Unix versions in
2358    [319]ckcdeb.h (SVR4, SUNOS41, BSD44, AIXRS, etc). You can tell if
2359    rename() is being used if the SHOW FEATURES command includes RENAME in
2360    the compiler options list. If the predefined RENAME symbol causes
2361    trouble, then add NORENAME to your CFLAGS. Trouble includes:
2362
2363     a. Linker complains that _rename is an unresolved symbol.
2364     b. Linking works, but Kermit's RENAME command doesn't work (which
2365        happens because older versions of rename() might have their
2366        arguments reversed).
2367
2368    If rename() is not used, then Kermit uses link()/unlink(), which is
2369    equivalent except it is not atomic: there is a tiny interval in which
2370    some other process might "do something" to one of the files or links.
2371
2372    Some Unix systems (Olivetti X/OS, Amdahl UTS/V, ICL SVR3, etc) define
2373    the S_ISREG and S_ISDIR macros incorrectly. This is compensated for
2374    automatically in [320]ckufio.c. Other systems might have this same
2375    problem. If you get a compile-time error message regarding S_ISREG
2376    and/or S_ISDIR, add the following to your CFLAGS:
2377
2378 -DISDIRBUG
2379
2380    Finally, here's a symbol you should NEVER define:
2381
2382 -DCOMMENT
2383
2384    It's used for commenting out blocks of code. If for some reason you
2385    find that your compiler has COMMENT defined, then add -UCOMMENT to
2386    CFLAGS or KFLAGS! Similarly, some header files have been known to
2387    define COMMENT, in which case you must add "#undef COMMENT" to each
2388    C-Kermit source module, after all the #includes.
2389
2390   9.9. Terminal Interruption
2391
2392    [ [321]Top ] [ [322]Contents ] [ [323]Section Contents ] [ [324]Next ]
2393    [ [325]Previous ]
2394
2395    When C-Kermit enters interactive command mode, it sets a Control-C
2396    (terminal keyboard interrupt = SIGINT) trap to allow it to return to
2397    the command prompt whenever the user types Control-C (or whatever is
2398    assigned to be the interrupt character). This is implemented using
2399    setjmp() and longjmp(). On some systems, depending on the machine
2400    architecture and C compiler and who knows what else, you might get
2401    "Memory fault (coredump)" or "longjmp botch" instead of the desired
2402    effect (this should not happen in 5A(190) and later). In that case, add
2403    -DNOCCTRAP to your CFLAGS and rebuild the program.
2404
2405    Job control -- the ability to "suspend" C-Kermit on a Unix system by
2406    typing the "susp" character (normally Ctrl-Z) and then resume execution
2407    later (with the "fg" command) -- is a tricky business. C-Kermit must
2408    trap suspend signals so it can put the terminal back into normal mode
2409    when you suspend it (Kermit puts the terminal into various strange
2410    modes during interactive command parsing, CONNECT, and file transfer).
2411    Supporting code is compiled into C-Kermit automatically if <signal.h>
2412    includes a definition for the SIGTSTP signal. HOWEVER... some systems
2413    define this signal without supporting job control correctly. You can
2414    build Kermit to ignore SIGTSTP signals by including the -DNOJC option
2415    in CFLAGS. (You can also do this at runtime by giving the command SET
2416    SUSPEND OFF.)
2417
2418      NOTE: As of version 5A(190), C-Kermit makes another safety check.
2419      Even if job control is available in the operating system (according
2420      to the numerous checks made in congm()), it will still disable the
2421      catching of SIGTSTP signals if SIGTSTP was set to SIG_IGN at the
2422      time C-Kermit was started.
2423
2424    System V R3 and earlier systems normally do not support job control. If
2425    you have an SVR3 system that does, include the following option in your
2426    CFLAGS:
2427
2428 -DSVR3JC
2429
2430    On systems that correctly implement POSIX signal handling, signals can
2431    be handled more reliably than in Bell, Berkeley, or AT&T Unixes. On
2432    systems (such as QNX) that are "strictly POSIX", POSIX signal handling
2433    *must* be used, otherwise no signal will work more than once. If you
2434    have POSIX-based system and you find that your version of Kermit
2435    responds to Ctrl-C (SIGINT) or Ctrl-Z (SIGTSTP) only once, then you
2436    should add the following option to your CFLAGS:
2437
2438 -DCK_POSIX_SIG
2439
2440    But be careful; some POSIX implementations, notably 4.4BSD, include
2441    POSIX signal handling symbols and functions as "stubs" only, which do
2442    nothing. Look in <signal.h> for sigsetjmp and siglongjmp and read the
2443    comments.
2444
2445 10. DIALING OUT AND COORDINATING WITH UUCP
2446
2447    [ [326]Top ] [ [327]Contents ] [ [328]Next ] [ [329]Previous ]
2448
2449    The short version (general):
2450
2451      In order for C-Kermit to be able to dial out from your Unix
2452      computer, you need to give it the same owner, group, and permissions
2453      as your other dialout programs, such as cu, tip, minicom, uucp,
2454      seyon, etc.
2455
2456    The short version for Linux only:
2457
2458      Since Red Hat 7.2, about 2002, Linux does not leave the lockfile
2459      handling to each application, but instead provides an external
2460      application, /usr/sbin/lockdev, that all applications should invoke
2461      when they need to access a serial port; lockdev locks and unlocks
2462      the port without requiring the application to have privileges, since
2463      the privileges on the lockfile directory are assigned to lockdev.
2464      C-Kermit 8.0.211 and later support this method. But C-Kermit still
2465      needs to be able to open the port itself, and therefore if the
2466      port's permissions do not allow read/write access to the general
2467      public, the general rule must still be followed: in the most common
2468      case, it must be SETGID to the group uucp (explained below). If a
2469      pre-8.0.211 version of C-Kermit is to be installed for use with
2470      serial ports on any version of Linux, it must still be installed as
2471      described in the following sections.
2472
2473    The long version:
2474
2475    Make sure your dialout line is correctly configured for dialing out (as
2476    opposed to login). The method for doing this is different for each kind
2477    of Unix. Consult your system documentation for configuring lines for
2478    dialing out (for example, Sun SPARCstation IPC users should read the
2479    section "Setting up Modem Software" in the Desktop SPARC Sun System and
2480    Network Manager's Guide, or the Terminals and Modems section of the HP
2481    manual, "Configuring HP-UX for Peripherals" (e.g. /usr/sbin/sam =>
2482    Peripheral Devices => Terminals and Modems => Add Modem).
2483
2484    Unlike most other multiuser, multitasking operating systems, Unix
2485    allows multiple users to access the same serial device at the same
2486    time, even though there is no earthly reason why two users should do
2487    this. When they do, user A will read some of the incoming characters,
2488    and user B will read the others. In all likelihood, neither user will
2489    see them all. Furthermore, User B can hang up User A's call, and so
2490    one.
2491
2492    Rather than change Unix to enforce exclusive access to serial devices
2493    such as ttys, when it might still have been possible, Unix developers
2494    opted for a "lock file" mechanism. Any process that wants to open a tty
2495    device should first check to see if a file of a certain name exists,
2496    and if so, not to open the device. If the file does not exist, the
2497    process creates the file and then opens the device. When the process
2498    closes the device, it destroys the lockfile. This procedure was
2499    originated for use with Unix's UUCP, CU, and TIP programs, and so these
2500    lockfiles are commonly called "UUCP lockfiles" (UUCP = Unix-to-Unix
2501    Copy Program).
2502
2503    As you can imagine, this method is riddled with pitfalls:
2504
2505      * If a process does not observe the prevailing lockfile convention,
2506        then it can interfere with other "polite" processes. And in fact,
2507        very few Unix applications or commands handle lockfiles at all; an
2508        original design goal of Unix was that "everything is a file", and
2509        countless utilities operate on files directly (by opening them) or
2510        indirectly through redirection of standard i/o, without creating or
2511        looking for lockfiles.
2512      * If a process crashes while it has the device open, the lockfile is
2513        left behind, preventing further processes from using the device.
2514      * Various versions of Unix use different names for the lockfiles, put
2515        them in different directories, with different owners and groups and
2516        permissions, and specify their contents differently.
2517      * On a given platform, the lockfile conventions may change from one
2518        Unix release to the next (for example, SunOS 4.0 to 4.1) or, in the
2519        case of Linux, across different distributions.
2520      * The same tty device might have more than one name, and most
2521        lockfile conventions don't allow for this. Similarly for symbolic
2522        links.
2523
2524    In an attempt to address the problem of "stale" lockfiles, most UUCP
2525    implementations put the PID (Process ID) of the creating process in the
2526    lockfile. Thus, another process that wants to open the corresponding
2527    device can check not only for the lockfile itself, but also can check
2528    the PID for validity. But this doesn't work well either:
2529
2530      * PIDs are stored in diverse formats that change with every new
2531        release (short, integer, long, or string in any of various
2532        formats). If the reading program does not follow the same
2533        convention as the writing program, it can diagnose a valid PID to
2534        be invalid, and therefore not honor the lock.
2535      * PIDs recycle. If the lockfile was created by PID 1234, which later
2536        crashed without removing the lockfile, and then a new process 1234
2537        exists a the time the lockfile is checked, the lockfile will be
2538        improperly taken as valid, and access to the device denied
2539        unnecessarily.
2540
2541    Several techniques address the problem of multiple names for the same
2542    device:
2543
2544      * Multiple lockfiles. For example, if the user opens a device through
2545        a symlink, a lockfile is created for both the symlink name and the
2546        true name (obtained from readlink()). However, when multiple
2547        drivers are installed for the same device (e.g. /dev/cua,
2548        /dev/cufa, etc), this approach won't work unless all applications
2549        *know* all the different names for the same device and make
2550        lockfiles for all of them, which is obviously not practical.
2551      * Lockfiles whose names are not based on the device name. These
2552        lockfiles generally have names like LK.inode/major/minor, where
2553        inode, major, and minor are numbers, which will always be the same
2554        for any physical device, no matter what its name. This form of
2555        lockfile is used in System V R4 and its derivatives, such as
2556        Solaris, UnixWare, etc. If lockfiles must be used (as opposed to,
2557        say, kernel-based locks), this would seem to be the most effective
2558        form.
2559
2560    Most versions of Unix were not designed to accommodate third-party
2561    communications software; thus vendors of these Unix products feel no
2562    compunction about changing lockfile conventions from release to
2563    release, since they also change their versions of the cu, uucp, tip,
2564    etc, programs at the same time to match. And since the source code to
2565    these programs might not be published, it is difficult for makers of
2566    third-party products like C-Kermit to find out what the new conventions
2567    are. It also forces release of new versions of C-Kermit whenever the OS
2568    vendor makes a change like this.
2569
2570    Some Unix vendors have taken a small step to simplify communications
2571    application development for their products: the inclusion of lockfile
2572    routines in the standard system C runtime libraries to shield the
2573    application from the details of lockfile management (IBM AIX is an
2574    example). When such routines are used, communications applications do
2575    not need modification when lockfile conventions change (although they
2576    will need recompiling if the routines are statically linked into the
2577    application). In the AIX example, the simple function calls ttylock(),
2578    ttyunlock(), and ttylocked() replace hundreds of lines of ugly code in
2579    C-Kermit that attempts to keep pace with every release of every Unix
2580    product over the last 20 years. Inclusion of ttylock() code occurs
2581    when:
2582
2583 -DUSETTYLOCK
2584
2585    is included in the CFLAGS.
2586
2587    If such routines are available, they should be used. The rest of this
2588    section applies when they are not.
2589
2590    To fit in with UUCP and other Unix-based serial-port communication
2591    software, C-Kermit must have the same idea as your system's uucp, cu,
2592    and tip programs about what the UUCP lock directory is called, what the
2593    lockfile itself is called, and what its contents should be. In most
2594    cases, C-Kermit preprocessor flags create the appropriate configuration
2595    at compile time if the appropriate makefile target was used (see
2596    [330]ckutio.c). The following CFLAGS options can be used to override
2597    the built-in configuration:
2598
2599    -DLCKDIR
2600           Tells Kermit that the UUCP lock directory is
2601           /usr/spool/uucp/LCK.
2602
2603    -DACUCNTRL
2604           Tells Kermit to use the BSD 4.3 acucntrl() program to turn off
2605           getty (login) on the line before using it, and restore getty
2606           when done.
2607
2608    -DHDBUUCP
2609           Include this if your system uses Honey DanBer UUCP, in which the
2610           lockfile directory and format are relatively standardized.
2611
2612    -DLOCK_DIR=\\\"/xxx/yyy\\\"
2613           Gives the lock directory name explicitly. The triple quoting is
2614           necessary. For example:
2615
2616 CFLAGS= -DBSD4 -DLOCK_DIR=\\\"/usr/local/locks\\\" -DNODEBUG
2617
2618           (NOTE: The triple quoting assumes this is a "top-level" make
2619           entry, and not a make entry that calls another one.)
2620
2621    -DLFDEVNO The lockfile name uses the tty device inode and major and
2622           minor
2623           numbers: LK.dev.maj.min, as in Sys V R4, e.g. LK.035.044.008.
2624
2625    When the LK.inode.major.minor form is used, a single lockfile is
2626    enough. Otherwise, a single lockfile rarely suffices. For example, in
2627    Linux, it is common to have a /dev/modem symbolic link to an actual
2628    dialout device, like /dev/cua0 or /dev/ttyS0, whose purpose is to hide
2629    the details of the actual driver from the user. So if one user opens
2630    /dev/modem, a lockfile called LCK..modem is created, which does not
2631    prevent another user from simulataneously opening the same device by
2632    its real name.
2633
2634    On SCO Unix platforms, we have a slightly different problem: the same
2635    device is, by convention, known by "lowercase" and "uppercase" names,
2636    depending on whether it has modem control. So by convention,
2637    communications programs are supposed to create the lockfiles based on
2638    the lowercase name. But some programs don't follow this convention. In
2639    HP-UX, we have several different names for each serial device. And so
2640    on.
2641
2642    For this reason, on platforms where the LK.inode.major.minor form is
2643    not used, C-Kermit also creates a secondary lockfile (which is simply a
2644    link to the first) if:
2645
2646     a. The given device name is a symbolic link. The secondary link is
2647        based on the device's real name.
2648     b. On SCO: The device name is not a symbolic link, but it contains
2649        uppercase letters. The primary link is based on the lowercase name;
2650        the secondary link is based on the name that was given.
2651     c. On HP-UX: The device name starts with "cu". The primary link is
2652        based on the name that was given; the secondary link is based on
2653        the corresponding "ttyd" device, e.g. "LCK..cua0p0" and
2654        "LCK..ttyd0p0".
2655
2656    NOTE: symlinks are not handled in HP-UX.
2657
2658    Honey DanBer (HDB) UUCP, the basis of many UUCP implementations, has
2659    two characteristics:
2660
2661     a. Lockfiles are kept in /usr/spool/locks/ (usually).
2662     b. A lockfile contains the process id (pid) in ASCII, rather than as
2663        an int.
2664
2665    Non-HDB selections assume the lockfile contains the pid in int form
2666    (or, more precisely, in PID_T form, where PID_T is either int or pid_t,
2667    depending on your system's C library and header files). (b), by the
2668    way, is subject to interpretation: the numeric ASCII string may or may
2669    not be terminated by a newline, it may or may not have leading spaces
2670    (or zeros), and the number of leading spaces or zeros can differ, and
2671    the differences can be significant.
2672
2673    Even if you build the program with the right lockfile option, you can
2674    still have problems when you try to open the device. Here are the error
2675    messages you can get from SET LINE, and what they mean:
2676
2677     a. "Timed out, no carrier." This one is not related to lockfiles. It
2678        means that you have SET CARRIER ON xx, where xx is the number of
2679        seconds to wait for carrier, and carrier did not appear within xx
2680        seconds. Solution: SET CARRIER AUTO or OFF.
2681     b. "Sorry, access to lock denied." Kermit has been configured to use
2682        lockfiles, but (a)the lockfile directory is write-protected against
2683        you, or (b) it does not exist. The "access to lock denied" message
2684        will tell you the reason. If the directory does not exist, check to
2685        make sure Kermit is using the right name. Just because version n of
2686        your Unix used a certain lockfile directory is no gurantee that
2687        version n.1 does not use a different one. Workaround: ask the
2688        system administrator to install a symbolic link from the old name
2689        to the new name. Other solutions: (see below)
2690     c. "Sorry, access to tty device denied." The tty device that you
2691        specified in your SET LINE command is read/write protected against
2692        you. Solution: (see below)
2693     d. "Sorry, device is in use." The tty device you have specified is
2694        currently being used by another user. A prefatory message gives you
2695        an "ls -l" listing of the lockfile, which should show the username
2696        of the person who created it, plus a message "pid = nnn" to show
2697        you the process id of the user's program. Solutions: try another
2698        device, wait until the other user is finished, ask the other user
2699        to hurry up, or ask the system manager for help.
2700     e. "Sorry, can't open connection: reason". The device cannot be opened
2701        for some other reason, which is listed.
2702     f. "sh: /usr/lib/uucp/acucntrl: not found". This means your Kermit
2703        program was built with the -DACUCNTRL switch, but your computer
2704        system does not have the BSD 4.3 acucntrl program. Solution:
2705        install the acucntrl program if you have it, or rebuild Kermit
2706        without the -DACUCNTRL switch.
2707
2708    There are two solutions for problems (b) and (c), both of which involve
2709    intervention by your Unix system administrator (superuser):
2710
2711     a. Have the superuser change the permission of the lockfile directory
2712        and to the tty devices so that everyone on the system has
2713        read/write permission.
2714
2715 su% chmod 777 /usr/spool/locks (or whatever the path is)
2716 su% chmod 666 /dev/ttyXX
2717
2718        One risk here is that people can write lots of junk into the
2719        lockfile directory, delete other people's files in the lockfile
2720        directory, and intercept other people's data as it goes in and out
2721        of the tty device. The major danger here would be intercepting a
2722        privileged password. Of course, any user could write a short,
2723        ordinary, unprivileged program to do exactly the same thing if the
2724        tty device was world read/writeable. The other risk as that
2725        telephone calls are not controlled -- anybody on your system can
2726        make them, without having to belong to any particular group, and
2727        this could run up your phone bill.
2728     b. Use groups to regulate access. Normally the lockfile directory and
2729        and the dialout devices will have the same group (such as uucp). If
2730        so, then put everybody who's allowed to dial out into that group,
2731        and make sure that the lockfile directory and the tty devices have
2732        group read AND write permission. Example:
2733
2734 su% chmod 770 /usr/spool/locks (or whatever the path is)
2735 su% chmod 660 /dev/ttyXX
2736
2737        User whatever tool is available on your platform to add users to
2738        the appropropriate group (e.g. edit the /etc/group file).
2739     c. Have the superuser change Kermit to run setuid and/or setgid to the
2740        owner and/or group of the lockfile directory and the tty devices if
2741        necessary), typically uucp (see [331]next section), but NOT root.
2742        Example:
2743
2744 su% chown uucp kermit          - or -  chgrp uucp kermit
2745 su% chmod u+s kermit (setuid)  - or -  chmod g+s kermit (setgid)
2746
2747        and then make sure the lockfile directory, and the tty devices,
2748        have owner (setuid) and/or group (setgid) write permission. For
2749        example:
2750
2751 su% chmod o+rwx /usr/spool/uucp
2752 su% chown uucp /dev/ttyXX ; chmod 600 /dev/ttyXX
2753
2754        In some cases, the owner and group must be distinct; the key point
2755        is that read/write access is required to both the UUCP lockfile
2756        directory and the tty itself.
2757
2758    If you make C-Kermit setuid or setgid to root, it refuses to run:
2759
2760 Fatal: C-Kermit setuid to root!
2761
2762    Example:
2763
2764 crw-r-----   1 uucp     uucp       5,  67 Feb 11 06:23 /dev/cua3
2765 drwxrwxr-x   3 root     uucp         1024 Feb 11 06:22 /var/lock
2766
2767    requires suid uucp to get read/write access on /dev/cua3 and sgid to
2768    get read/write access on /var/lock (since you can't set Kermit's uid or
2769    gid to root).
2770
2771      The reason Kermit can't be setuid or setgid to root has to do with
2772      the fact that some Unix OS's can't switch user or group IDs in that
2773      case. Unfortunately, the prohibition against making Kermit setuid or
2774      setgid to root means that Unix C-Kermit can't be used to make rlogin
2775      connections by non-root users. (The rlogin port is privileged, which
2776      is why the regular rlogin command is setuid root -- which is safe
2777      because the rlogin program never has to create or access files like
2778      Kermit does.)
2779
2780    For the lockfile mechanism to achieve its desired purpose -- prevention
2781    of access to the same tty device by more than one process at a time --
2782    ALL programs on a given computer that open, read or write, and close
2783    tty devices must use the SAME lockfile conventions. Unfortunately, this
2784    is often not the case. Here is a typical example of how this can go
2785    wrong: In SunOS 4.0 and earler, the lockfile directory was
2786    /usr/spool/uucp; in 4.1 it was changed to /var/spool/locks in the quest
2787    for political correctness. Consequently, any third-party programs (such
2788    as C-Kermit) that were not modified to account for this change,
2789    recompiled, and reinstalled, did not use the same lockfiles as uucp,
2790    tip, etc, and so the entire purpose of the lockfile is defeated.
2791
2792    What if your Unix system does not have UUCP installed? For example, you
2793    have a Unix workstation, and you do not use uucp, cu, or tip, or UUCP
2794    was not even supplied with your version of Unix (QNX is an example). In
2795    this case, you have two choices:
2796
2797     a. If there may be more than one person running Kermit at the same
2798        time, competing for the same tty device, then create a special
2799        lockfile directory just for Kermit, for example, /usr/spool/kermit,
2800        and make sure you have read/write access to it. Then add the
2801        following to your makefile target CFLAGS, as shown earlier:
2802
2803 -DLOCK_DIR=\\\"/usr/spool/kermit\\\"
2804
2805     b. If you are the only user on your workstation, and no other
2806        processes will ever be competing with Kermit for the dialout tty
2807        device, then add -DNOUUCP to your makefile target's CFLAGS and
2808        rebuild Kermit.
2809
2810 11. RUNNING UNIX C-KERMIT SETUID OR SETGID
2811
2812    [ [332]Top ] [ [333]Contents ] [ [334]Next ] [ [335]Previous ]
2813
2814    Even if you don't intend to run C-Kermit setuid, somebody else might
2815    come along and chown and chmod it after it has been built. You should
2816    be sure that it is built correctly to run setuid on your system. For
2817    POSIX and AT&T Unix based versions, you don't have to do anything
2818    special.
2819
2820    For 4.2 and 4.3 BSD-based Unix versions, you normally need not add
2821    anything special to the makefile. The program assumes that the
2822    setreuid() and setregid() functions are available, without which we
2823    cannot switch back and forth between real and effective uids. If "make"
2824    complains that _setreuid or _setregid is/are not defined, add
2825    -DNOSETREU to CFLAGS. In this case it is very likely (but not certain)
2826    that you cannot protect ttys and lockfiles against people and have them
2827    run Kermit setuid.
2828
2829    If make does not complain about this, you should find out whether your
2830    BSD version (4.3 or other systems like SunOS 4.x that claim to include
2831    BSD 4.3 compatibility) includes the saved-setuid feature (see long
2832    notes under edit 146 in ckc178.upd). If it does, then add -DSAVEDUID to
2833    CFLAGS.
2834
2835      IMPORTANT NOTE: Most Unix system documentation will not give you the
2836      required information. To determine whether your Unix system supplies
2837      the the saved-original-effective-user/group-id feature, use the
2838      ckuuid.c program. Read and follow the instructions in the comments
2839      at the beginning.
2840
2841    C-Kermit for 4.4BSD-based systems automatically use sete[ug]id(). See
2842    [336]ckutio.c.
2843
2844    If you have a version of Unix that is not BSD-based, but which supplies
2845    the setreuid() and setregid() functions, and these are the only way to
2846    switch between real and effective uid, add -DSETREUID to your makefile
2847    target.
2848
2849      WARNING: There are two calls to access() in [337]ckufio.c, by which
2850      Kermit checks to see if it can create an output file. These calls
2851      will not work correctly when (a)you have installed C-Kermit setuid
2852      or setgid on a BSD-based Unix system, and (b) the
2853      saved-original-effective-uid/gid feature is not present, and (c) the
2854      access() function always checks what it believes to be the real ID
2855      rather than the effective ID. This is the case, for example, in
2856      Olivetti X/OS and in NeXTSTEP. In such cases, you can force correct
2857      operation of access() calls by defining the symbol SW_ACC_ID at
2858      compile time in CFLAGS.
2859
2860    If you have a version of Unix that does not allow a process to switch
2861    back and forth between its effective and real user and group ids
2862    multiple times, you probably should not attempt to run Kermit setuid,
2863    because once having given up its effective uid or gid (which it must do
2864    in order to transfer files, fork a shell, etc) it can never get it
2865    back, and so it can not use the original effective uid or gid to create
2866    or delete uucp lockfiles. In this case, you'll either have to set the
2867    permissions on your lockfile directory to make them publicly
2868    read/writable, or dispense with locking altogether.
2869
2870    MORAL: Are you thoroughly sickened and/or frightened by all that you
2871    have just read? You should be. What is the real answer? Simple. Serial
2872    devices -- such as ttys and magnetic tapes -- in Unix should be opened
2873    with exclusive access only, enforced by the Unix kernel. Shared access
2874    has no conceivable purpose, legitimate or otherwise, except by
2875    privileged system programs such as getty. The original design dates
2876    from the late 1960s, when Unix was developed for laboratory use under a
2877    philosophy of trust by people within shouting distance of each other --
2878    but even then, no useful purpose was served by this particular form of
2879    openness; it was probably more of a political statement. Since the
2880    emergence of Unix from the laboratory into the commercial market, we
2881    have seen every vestige of openness -- but this one -- stripped away.
2882    I'd like to see some influential Unix maker take the bold step of
2883    making the simple kernel change required to enforce exclusive access to
2884    serial devices. (Well, perhaps not so simple when bidirectionality must
2885    also be a goal -- but then other OS's like VMS solved this problem
2886    decades ago.)
2887
2888 12. CONFIGURING UNIX WORKSTATIONS
2889
2890    [ [338]Top ] [ [339]Contents ] [ [340]Next ] [ [341]Previous ]
2891
2892    On desktop workstations that are used by only the user at the console
2893    keyboard, C-Kermit is always used in local mode. But as delivered,
2894    C-Kermit runs in remote mode by default. To put it in local mode at
2895    startup, you can put a SET LINE command in your .mykermrc.
2896
2897    You can also build C-Kermit to start up in local mode by default. To do
2898    this, include the following in the CFLAGS in your makefile target:
2899
2900 -DDFTTY=\\\"/dev/ttyxx\\\"
2901
2902    where ttyxx is the name of the device you will be using for
2903    communications. Presently there is no way of setting the default modem
2904    type at compile time, so use this option only for direct lines.
2905
2906    C-Kermit does not work well on certain workstations if it is not run
2907    from within a terminal window. For example, you cannot start C-Kermit
2908    on a NeXT by launching it directly from NeXTstep. Similarly for Sun
2909    workstations in the Open Windows environment. Run Kermit in a terminal
2910    window.
2911
2912 13. BIZARRE BEHAVIOR AT RUNTIME
2913
2914    [ [342]Top ] [ [343]Contents ] [ [344]Next ] [ [345]Previous ]
2915
2916    See the "beware file",
2917
2918    [346]ckubwr.txt, for hints about runtime misbehavior. This section
2919    lists some runtime problems that can be cured by rebuilding C-Kermit.
2920
2921    The program starts, but there is no prompt, and certain operations
2922    don't work (you see error messages like "Kermit command error in
2923    background execution"). This is because Kermit thinks it is running in
2924    the background. See conbgt() in [347]ckutio.c. Try rebuilding Kermit
2925    with:
2926
2927  -DPID_T=pid_t
2928
2929    added to your CFLAGS. If that doesn't help, find out the actual data
2930    type for pids (look in types.h or similar file) and use it in place of
2931    "pid_t", for example:
2932
2933  -DPID_T=short
2934
2935    Unexplainable and inappropriate error messages ("Sockets not supported
2936    on this device", etc) have been traced in at least one case to a lack
2937    of agreement between the system header files and the actual kernel.
2938    This happened because the GNU C compiler (gcc) was being used. gcc
2939    wants to have ANSI-C-compliant header files, and so part of the
2940    installation procedure for gcc is (or was) to run a shell script called
2941    "fixincludes", which translates the system's header files into a
2942    separate set of headers that gcc likes. So far so good. Later, a new
2943    version of the operating system is installed and nobody remembers to
2944    run fixincludes again. From that point, any program compiled with gcc
2945    that makes use of header files (particularly ioctl.h) is very likely to
2946    misbehave. Solution: run fixincludes again, or use your system's
2947    regular C compiler, libraries, and header files instead of gcc.
2948
2949 14. CRASHES AND CORE DUMPS
2950
2951    [ [348]Top ] [ [349]Contents ] [ [350]Next ] [ [351]Previous ]
2952
2953    If C-Kermit constitently dumps core at the beginning of a file
2954    transfer, look in SHOW FEATURES for CKREALPATH. If found, rebuild with
2955    -DNOREALPATH and see if that fixes the problem (some UNIXes have
2956    realpath() but it doesn't work).
2957
2958    Total failure of the Kermit program can occur because of bad memory
2959    references, bad system calls, or problems with dynamic memory
2960    allocation. First, try to reproduce the problem with debugging turned
2961    on: run Kermit with the -d command-line option (for example, "wermit
2962    -d") and then examine the resulting debug.log file. The last entry
2963    should be in the vicinity of the crash. In VMS, a crash automatically
2964    produces a "stack dump" which shows the routine where the crash occurs.
2965    In some versions of Unix, you can get a stack dump with "adb" -- just
2966    type "adb wermit core" and then give the command "$c", then Ctrl-D to
2967    quit (note: replace "wermit" by "kermit" or by the full pathname of the
2968    executable that crashed if it is not in the current directory). Or use
2969    gdb to get a backtrace, etc.
2970
2971    In edit 186, one implementation, UNISYS 5000/95 built with "make
2972    sys5r3", has been reported to run out of memory very quickly (e.g.
2973    while executing a short initialization file that contains a SET DIAL
2974    DIRECTORY command). Debug logs show that malloc calls are failing,
2975    reason unknown. For this and any other implementation that gives error
2976    messages about "malloc failure" or "memory allocation failure", rebuild
2977    the program *without* the -DDYNAMIC CFLAGS definition, for example:
2978
2979 make sys5r3 KFLAGS=-UDYNAMIC
2980
2981    As of edit 169, C-Kermit includes a malloc() debugging package which
2982    you may link with the Kermit program to catch runtime malloc errors.
2983    See the makefile entries for sunos41md and nextmd for examples of how
2984    to select malloc debugging. Once you have linked Kermit with the malloc
2985    debugger, it will halt with an informative message if a malloc-related
2986    error occurs and, if possible, dump core. For this reason,
2987    malloc-debugging versions of Kermit should be built without the "-s"
2988    link option (which removes symbols, preventing analysis of the core
2989    dump). You have several ways to track down the malloc error: Analyze
2990    the core dump with adb. Or reproduce the problem with "log debug" and
2991    then look at the code around the last debug.log entry. If you have gcc,
2992    build the program with "-g" added to CFLAGS and then debug it with gdb,
2993    e.g.
2994
2995 gdb wermit
2996 break main
2997 run
2998 .. set other breakpoints or watchpoints
2999 continue
3000
3001    Watchpoints are especially useful for finding memory leaks, but they
3002    make the program run about a thousand times slower than usual, so don't
3003    set them until the last possible moment. When a watchpoint is hit, you
3004    can use the "where" command to find out which C-Kermit source statement
3005    triggered it.
3006
3007    If you have the Pure Software Inc "Purify" product, see the sunos41cp
3008    makefile entry for an example of how to use it to debug C-Kermit.
3009
3010 15. SYSLOGGING
3011
3012    [ [352]Top ] [ [353]Contents ] [ [354]Next ] [ [355]Previous ]
3013
3014    "Syslogging" means recording selected information in the system log via
3015    the Unix syslog() facility, which is available in most Unix versions.
3016    Syslogging is not done unless C-Kermit is started with:
3017
3018 --syslog:n
3019
3020    on the command-line, where n is a number greater than 0 to indicate the
3021    level of syslogging. See [356]Section 4.2 of the [357]IKSD
3022    Administrator's Guide for details.
3023
3024    Obviously you can't depend on users to include --syslog:3 (or whatever)
3025    on the command line every time they start C-Kermit, so if you want
3026    certain kinds of records to be recorded in the system log, you can
3027    build C-Kermit with forced syslogging at the desired level; for
3028    example, to record logins and dialouts:
3029
3030 make linux KFLAGS=-DSYSLOGLEVEL=2
3031
3032    Levels 2 and 3 are the most likely candidates for this treatment. Level
3033    2 forces logging of all successful dialout calls (e.g. for checking
3034    against or phone bills), and level 3 records all connections (SET LINE
3035    or SET HOST / TELNET / RLOGIN, etc) so you can see who is connecting
3036    out from your system, and to where, e.g. for security auditing.
3037
3038    Level 2 and 3 records are equivalent to those in the connection log;
3039    see the [358]C-Kermit 7.0 Supplement) for a detailed description of the
3040    connection log.
3041
3042 16. BUILDING SECURE VERSIONS OF C-KERMIT 8.0
3043
3044    [ [359]Top ] [ [360]Contents ] [ [361]Next ] [ [362]Previous ]
3045
3046    C-Kermit 7.0 and later may be built with Kerberos(TM) and/or SRP(TM)
3047    (Secure Remote Password) and/or SSL/TLS security for strong
3048    authentication and encryption of Internet connections. These security
3049    methods require external libraries that, in their binary forms, are
3050    restricted from export by USA law. See the [363]Kermit Security
3051    Reference) for details. C-Kermit binaries themselves are likewise
3052    restricted; the C-Kermit binaries that are available for public
3053    download on the Internet are not allowed to contain the security
3054    options.
3055
3056    Sample makefile entries are provided for Linux and many other operating
3057    systems. A list of secure makefile entries is included in the Makefile.
3058    Complete instructions on building C-Kermit 8.0 with MIT Kerberos;
3059    Secure Remote Password; and/or OpenSSL can be found in the [364]Kermit
3060    Security Reference.
3061
3062    SSL/TLS and Kerberos builds are increasingly problematic with the
3063    "deprecation" of DES. There is code to detect the presence or absence
3064    of DES in the OpenSSL builds, but it doesn't always work because
3065    sometimes the SSL libraries are present but routines are missing from
3066    them.
3067
3068      * First of all remember that if your SSL and/or Kerberos header files
3069        and libraries are not in the default place, you'll need to override
3070        the assumed paths. To find out what the default places are type
3071        "make show", e.g.:
3072
3073 [~/kermit] make show
3074 prefix=/usr/local
3075 srproot=/usr/local
3076 sslroot=/usr/local
3077 manroot=/usr/local
3078 K4LIB=-L/usr/kerberos/lib
3079 K4INC=-I/usr/kerberos/include
3080 K5LIB=-L/usr/kerberos/lib
3081 K5INC=-I/usr/kerberos/include
3082 SRPLIB=-L/usr/local/lib
3083 SRPINC=-I/usr/local/include
3084 SSLLIB=-L/usr/local/ssl/lib
3085 SSLINC=-I/usr/local/ssl/include
3086 [~/kermit]
3087
3088      * You can override any or all of these by putting assignments on the
3089        'make' command line; examples:
3090
3091 make linux+krb5 \
3092  "K5INC=-I/usr/include/" \
3093  "K5LIB=-L/usr/lib64/"
3094
3095 make solaris9g+ssl \
3096   "SSLLIB=-L/opt/openssl-0.9.8q/lib" \
3097   "SSLINC=-I/opt/openssl-0.9.8q/include"
3098
3099        Or by setting and exporting environment variables prior to giving
3100        the 'make' command, as in this example in which (after Beta.01 was
3101        uploaded) C-Kermit was successfully linked with OpenSSL 1.0.0d,
3102        which was installed alongside OpenSSL 0.9.8r on the same computer.
3103        Note the use of the '-i' option instead of '-I' to force gcc to
3104        include the right header files (thanks to Nelson Beebe for this):
3105
3106 export PATH=/usr/bin:$PATH
3107 export SSLINC=-isystem/usr/include
3108 export "SSLLIB=-L/usr/lib -Wl,-rpath,/usr/lib"
3109 make linux+ssl
3110
3111        -i is explained in 'man gcc'; there is a change in what -I does
3112        that could have ramifications for many makefile targets, not just
3113        Kermit. And -Wl and -rpath are explained in 'man ld'; the idea is
3114        build a binary from which useful reports can be obtained with ldd.
3115      * Building with OpenSSL versions prior to 0.9.7 doesn't work, even
3116        though C-Kermit is designed to work with both the old and new
3117        versions. This could probably be fixed if anybody cares.
3118      * If a Kerberos or SSL build fails at link time because
3119        des_ecb3_encrypt, des_random_seed, and/or des_set_odd_parity come
3120        up missing, redo the build with -UCK_DES:
3121
3122 make netbsd+krb5+ssl \
3123  "K5INC=-I/usr/local/include" \
3124  "K5LIB=-L/usr/local/kerblib" KFLAGS=-UCK_DES
3125
3126        I suppose all the SSL and Kerberos targets could be recoded to
3127        figure this out automatically (i.e. that DES is installed but with
3128        some entry points missing), but it wouldn't be pretty.
3129      * Different Kerberos and OpenSSL distributions can be installed with
3130        different options; certain libraries might be missing or named
3131        differently (for example, libgssapi vs libgssapi_krb5). Some, but
3132        not all, of the C-Kermit makefile targets have been fixed to take
3133        some of these variations into account by testing for them, most
3134        notably the linux ones, linux+ssl, linux+krb5, and linux+krb5+ssl.
3135        Probably every target that builds with OpenSSL or Kerberos needs
3136        the same treatment but I won't have time.
3137      * Why doesn't C-Kermit just use Autoconf? Mainly because the makefile
3138        is full of targets for platforms that don't have Autoconf or any
3139        other tool like it. (Another reason is that I've always preferred
3140        that Kermit have the least dependencies possible on external
3141        toolsets.) Perhaps certain targets could be converted to use them,
3142        especially Linux because there are so many variations among
3143        distributions and versions. Anybody who wants to make, say, an
3144        Autonf-based Linux target, be my guest, but bear in mind that one
3145        Linux target is supposed to work for all versions and distributions
3146        of Linux on all platforms. Well, one target for Linux by itself,
3147        another for Linux with OpenSSL, another for Linux with Kerberos 5,
3148        and another for Linux with Kerberos 5 and OpenSSL. Each of these is
3149        supposed to work on any Linux version with any version of
3150        Kerberos 5 or OpenSSL.
3151
3152    Also note that Kerberos support is for the MIT version only, Heimdal
3153    and others are not supported (never have been). Of course anybody can
3154    pitch in and add or improve support for whatever they want.
3155
3156 17. INSTALLING C-KERMIT AS AN SSH SERVER SUBSYSTEM
3157
3158    [ [365]Top ] [ [366]Contents ] [ [367]Previous ]
3159
3160    This requires C-Kermit 8.0.206 or later and an SSH v2 server. If you
3161    list C-Kermit as a Subsystem in the SSH v2 server configuration file
3162    (as, for example, SFTP is listed), users can make SSH connections
3163    direct to a Kermit server as explained here:
3164
3165 [368]http://www.columbia.edu/kermit/skermit.html
3166
3167    The name and location of the SSH server configuration file depends on
3168    your platform, which SSH product(s) you have, etc. C-Kermit itself must
3169    be referred to in this file as "kermit-sshsub". On the host, install
3170    the C-Kermit 8.0.211 binary in the normal way. Then, in the same
3171    directory as the C-Kermit binary, make a symbolic link:
3172
3173 ln -s kermit kermit-sshsub
3174
3175    (Note: the "make install" makefile target does this for you.) Then in
3176    the sshd configuration file, add a line:
3177
3178 Subsystem  kermit   /some/path/kermit-sshsub
3179
3180    (where /some/path is the fully specified directory where the symlink
3181    is.) This is similar to the line that sets up the SFTP susbsystem.
3182    Example:
3183
3184 Subsystem   sftp    /usr/local/libexec/sftp-server
3185 Subsystem   kermit  /usr/local/bin/kermit-sshsub
3186
3187    The mechanics might vary for other SSH servers; "man sshd" for details.
3188    The method shown here is used because the OpenSSH server does not
3189    permit the subsystem invocation to include command-line options.
3190    C-Kermit would have no way of knowing that it should enter Server mode
3191    if it were not called by a special name.
3192
3193    [ [369]Top ] [ [370]Contents ] [ [371]C-Kermit Home ] [ [372]C-Kermit
3194    9.0 Overview ] [ [373]Kermit Home ]
3195      __________________________________________________________________
3196
3197
3198     C-Kermit 9.0 Unix Installation Instructions / The Kermit Project /
3199     Columbia University / 30 June 2011
3200
3201 References
3202
3203    1. http://www.columbia.edu/
3204    2. mailto:kermit@columbia.edu
3205    3. http://www.columbia.edu/kermit/index.html
3206    4. http://www.columbia.edu/kermit/k95.html
3207    5. http://www.columbia.edu/kermit/ckermit.html
3208    6. http://www.columbia.edu/kermit/ckscripts.html
3209    7. http://www.columbia.edu/kermit/current.html
3210    8. http://www.columbia.edu/kermit/whatsnew.html
3211    9. http://www.columbia.edu/kermit/faq.html
3212   10. http://www.columbia.edu/kermit/support.html
3213   11. http://www.columbia.edu/kermit/ckuins.html#contents
3214   12. http://www.columbia.edu/kermit/ckermit.html
3215   13. http://www.columbia.edu/kermit/index.html
3216   14. http://www.columbia.edu/kermit/ckuins.html
3217   15. http://www.columbia.edu/kermit/ckuins.html#x0
3218   16. http://www.columbia.edu/kermit/ckuins.html#x1
3219   17. http://www.columbia.edu/kermit/ckuins.html#x2
3220   18. http://www.columbia.edu/kermit/ckuins.html#x3
3221   19. http://www.columbia.edu/kermit/ckuins.html#x4
3222   20. http://www.columbia.edu/kermit/ckuins.html#x5
3223   21. http://www.columbia.edu/kermit/ckuins.html#x6
3224   22. http://www.columbia.edu/kermit/ckuins.html#x7
3225   23. http://www.columbia.edu/kermit/ckuins.html#x8
3226   24. http://www.columbia.edu/kermit/ckuins.html#x9
3227   25. http://www.columbia.edu/kermit/ckuins.html#x10
3228   26. http://www.columbia.edu/kermit/ckuins.html#x11
3229   27. http://www.columbia.edu/kermit/ckuins.html#x12
3230   28. http://www.columbia.edu/kermit/ckuins.html#x13
3231   29. http://www.columbia.edu/kermit/ckuins.html#x14
3232   30. http://www.columbia.edu/kermit/ckuins.html#x15
3233   31. http://www.columbia.edu/kermit/ckuins.html#x16
3234   32. http://www.columbia.edu/kermit/ckuins.html#x17
3235   33. http://www.columbia.edu/kermit/ckuins.html#top
3236   34. http://www.columbia.edu/kermit/ckuins.html#contents
3237   35. http://www.columbia.edu/kermit/ckuins.html#x1
3238   36. http://www.columbia.edu/kermit/ckccfg.html
3239   37. http://www.columbia.edu/kermit/ckcbwr.html
3240   38. http://www.columbia.edu/kermit/ckubwr.html
3241   39. http://www.columbia.edu/kermit/ckcplm.html
3242   40. http://www.columbia.edu/kermit/ckuins.html#x2
3243   41. http://www.columbia.edu/kermit/ckuins.html#x3
3244   42. http://www.columbia.edu/kermit/ckuins.html#x4
3245   43. http://www.columbia.edu/kermit/ckuins.html#top
3246   44. http://www.columbia.edu/kermit/ckuins.html#contents
3247   45. http://www.columbia.edu/kermit/ckuins.html#x2
3248   46. http://www.columbia.edu/kermit/ckuins.html#x0
3249   47. ftp://www.columbia.edu/kermit/archives/cku211.tar.Z
3250   48. ftp://www.columbia.edu/kermit/archives/cku211.tar.gz
3251   49. http://kermit.columbia.edu/ftp/archives/cku211.tar.Z
3252   50. http://kermit.columbia.edu/ftp/archives/cku211.tar.gz
3253   51. ftp://www.columbia.edu/kermit/archives/cku211.tar
3254   52. http://kermit.columbia.edu/ftp/archives/cku211.tar
3255   53. http://www.columbia.edu/kermit/ckuins.html#x7
3256   54. http://www.columbia.edu/kermit/ckuins.html#x5
3257   55. http://www.columbia.edu/kermit/ckuins.html#x5
3258   56. http://www.columbia.edu/kermit/ckuins.html#x16
3259   57. http://www.columbia.edu/kermit/ckuins.html#top
3260   58. http://www.columbia.edu/kermit/ckuins.html#contents
3261   59. http://www.columbia.edu/kermit/ckuins.html#x3
3262   60. http://www.columbia.edu/kermit/ckuins.html#x1
3263   61. http://www.columbia.edu/kermit/ckuins.html#x5
3264   62. http://www.columbia.edu/kermit/ckuins.html#X10
3265   63. http://www.columbia.edu/kermit/ckuins.html#x11
3266   64. http://www.columbia.edu/kermit/ckuins.html#x10
3267   65. http://www.columbia.edu/kermit/ckuins.html#x3
3268   66. http://www.columbia.edu/kermit/ck80packages.html
3269   67. http://www.columbia.edu/kermit/ckuins.html#x10
3270   68. http://www.columbia.edu/kermit/ckuins.html#top
3271   69. http://www.columbia.edu/kermit/ckuins.html#contents
3272   70. http://www.columbia.edu/kermit/ckuins.html#x4
3273   71. http://www.columbia.edu/kermit/ckuins.html#x2
3274   72. ftp://www.columbia.edu/kermit/bin/
3275   73. http://www.columbia.edu/kermit/ck80binaries.html
3276   74. http://www.columbia.edu/kermit/ckuins.html#x7
3277   75. http://www.columbia.edu/kermit/ckuins.html#build
3278   76. http://www.columbia.edu/kermit/ckuins.html#x5
3279   77. http://www.columbia.edu/kermit/ckuins.html#x4
3280   78. http://www.columbia.edu/kermit/ckfaq.html#version
3281   79. http://www.columbia.edu/kermit/ckuins.html#x4
3282   80. mailto:kermit@columbia.edu
3283   81. http://www.columbia.edu/kermit/ckuins.html#top
3284   82. http://www.columbia.edu/kermit/ckuins.html#contents
3285   83. http://www.columbia.edu/kermit/ckuins.html#x5
3286   84. http://www.columbia.edu/kermit/ckuins.html#x3
3287   85. http://www.columbia.edu/kermit/ckuins.html#x8
3288   86. http://www.columbia.edu/kermit/ckuins.html#x9
3289   87. ftp://kermit.columbia.edu/kermit/c-kermit/makefile
3290   88. ftp://kermit.columbia.edu/kermit/c-kermit/ckpker.mk
3291   89. ftp://kermit.columbia.edu/kermit/c-kermit/ckubsd.mak
3292   90. http://www.columbia.edu/kermit/ckuins.html#x5
3293   91. mailto:kermit-support@columbia.edu
3294   92. ftp://kermit.columbia.edu/kermit/c-kermit/makefile
3295   93. http://www.columbia.edu/kermit/ckuins.html#x7
3296   94. mailto:kermit-support@columbia.edu
3297   95. ftp://kermit.columbia.edu/kermit/c-kermit/makefile
3298   96. http://www.columbia.edu/kermit/ckuins.html#x5.4
3299   97. http://www.columbia.edu/kermit/ckuins.html#x10
3300   98. http://www.columbia.edu/kermit/ckuins.html#x11
3301   99. http://www.columbia.edu/kermit/ckuins.html#x5
3302  100. http://www.columbia.edu/kermit/iksd.html
3303  101. http://www.columbia.edu/kermit/ckuins.html#top
3304  102. http://www.columbia.edu/kermit/ckuins.html#contents
3305  103. http://www.columbia.edu/kermit/ckuins.html#x4.1
3306  104. http://www.columbia.edu/kermit/ckccfg.html
3307  105. http://www.columbia.edu/kermit/ckuins.html#x4.1
3308  106. http://www.columbia.edu/kermit/ckuins.html#x4.2
3309  107. http://www.columbia.edu/kermit/ckuins.html#x4.3
3310  108. http://www.columbia.edu/kermit/ckuins.html#x4.4
3311  109. http://www.columbia.edu/kermit/ckuins.html#x4.5
3312  110. http://www.columbia.edu/kermit/ckccfg.html
3313  111. http://www.columbia.edu/kermit/ckccfg.html#x8
3314  112. http://www.columbia.edu/kermit/iksd.html
3315  113. http://www.columbia.edu/kermit/iksd.html
3316  114. ftp://kermit.columbia.edu/kermit/c-kermit/ckufio.c
3317  115. ftp://kermit.columbia.edu/kermit/c-kermit/ckufio.c
3318  116. mailto:kermit-support@columbia.edu
3319  117. ftp://kermit.columbia.edu/kermit/c-kermit/ckcmai.c
3320  118. http://www.columbia.edu/kermit/ckuins.html#x15
3321  119. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3322  120. ftp://kermit.columbia.edu/kermit/c-kermit/ckufio.c
3323  121. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3324  122. ftp://kermit.columbia.edu/kermit/c-kermit/ckufio.c
3325  123. ftp://kermit.columbia.edu/kermit/c-kermit/ckcnet.c
3326  124. ftp://kermit.columbia.edu/kermit/c-kermit/ckcnet.c
3327  125. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3328  126. ftp://kermit.columbia.edu/kermit/c-kermit/ckcuni.c
3329  127. mailto:kermit-support@columbia.edu
3330  128. http://www.columbia.edu/kermit/ckuins.html#top
3331  129. http://www.columbia.edu/kermit/ckuins.html#contents
3332  130. http://www.columbia.edu/kermit/ckuins.html#x4
3333  131. http://www.columbia.edu/kermit/ckuins.html#x4.2
3334  132. http://www.columbia.edu/kermit/ckuins.html#x4.0
3335  133. ftp://kermit.columbia.edu/kermit/c-kermit/makefile
3336  134. ftp://kermit.columbia.edu/kermit/c-kermit/ckubwr.txt
3337  135. http://www.columbia.edu/kermit/ckubwr.html
3338  136. ftp://kermit.columbia.edu/kermit/c-kermit/ckwart.c
3339  137. ftp://kermit.columbia.edu/kermit/c-kermit/ckcpro.w
3340  138. ftp://kermit.columbia.edu/kermit/c-kermit/ckcpro.c
3341  139. http://www.columbia.edu/kermit/ckuins.html#top
3342  140. http://www.columbia.edu/kermit/ckuins.html#contents
3343  141. http://www.columbia.edu/kermit/ckuins.html#x4
3344  142. http://www.columbia.edu/kermit/ckuins.html#x4.3
3345  143. http://www.columbia.edu/kermit/ckuins.html#x4.1
3346  144. http://www.columbia.edu/kermit/ckuins.html#x5
3347  145. http://www.columbia.edu/kermit/ckuins.html#top
3348  146. http://www.columbia.edu/kermit/ckuins.html#contents
3349  147. http://www.columbia.edu/kermit/ckuins.html#x4
3350  148. http://www.columbia.edu/kermit/ckuins.html#x4.4
3351  149. http://www.columbia.edu/kermit/ckuins.html#x4.2
3352  150. http://www.columbia.edu/kermit/ckuins.html#top
3353  151. http://www.columbia.edu/kermit/ckuins.html#contents
3354  152. http://www.columbia.edu/kermit/ckuins.html#x4
3355  153. http://www.columbia.edu/kermit/ckuins.html#x4.5
3356  154. http://www.columbia.edu/kermit/ckuins.html#x4.3
3357  155. ftp://kermit.columbia.edu/kermit/c-kermit/ckpker.mk
3358  156. http://www.columbia.edu/kermit/ckuins.html#top
3359  157. http://www.columbia.edu/kermit/ckuins.html#contents
3360  158. http://www.columbia.edu/kermit/ckuins.html#x4
3361  159. http://www.columbia.edu/kermit/ckuins.html#x4.4
3362  160. ftp://kermit.columbia.edu/kermit/c-kermit/makefile
3363  161. ftp://kermit.columbia.edu/kermit/c-kermit/makefile
3364  162. ftp://kermit.columbia.edu/kermit/c-kermit/ckcpro.w
3365  163. http://www.columbia.edu/kermit/ckuins.html#top
3366  164. http://www.columbia.edu/kermit/ckuins.html#contents
3367  165. http://www.columbia.edu/kermit/ckuins.html#x6
3368  166. http://www.columbia.edu/kermit/ckuins.html#x4
3369  167. http://www.columbia.edu/kermit/ckuins.html#x5.1
3370  168. http://www.columbia.edu/kermit/ckuins.html#x5.2
3371  169. http://www.columbia.edu/kermit/ckuins.html#x5.3
3372  170. http://www.columbia.edu/kermit/ckuins.html#x5.4
3373  171. http://www.columbia.edu/kermit/
3374  172. http://www.columbia.edu/kermit/ckuins.html#x5.4
3375  173. http://www.columbia.edu/kermit/ckuins.html#x5.3
3376  174. ftp://kermit.columbia.edu/kermit/c-kermit/COPYING.TXT
3377  175. ftp://kermit.columbia.edu/kermit/c-kermit/ckermit.ini
3378  176. http://www.columbia.edu/kermit/ckuins.html#x5.1
3379  177. ftp://kermit.columbia.edu/kermit/c-kermit/ckermod.ini
3380  178. ftp://kermit.columbia.edu/kermit/c-kermit/ckermit70.txt
3381  179. http://www.columbia.edu/kermit/ck60manual.html
3382  180. http://www.columbia.edu/kermit/ckermit70.html
3383  181. ftp://kermit.columbia.edu/kermit/c-kermit/ckermit80.txt
3384  182. http://www.columbia.edu/kermit/ck60manual.html
3385  183. http://www.columbia.edu/kermit/ckermit80.html
3386  184. ftp://kermit.columbia.edu/kermit/c-kermit/ckcbwr.txt
3387  185. http://www.columbia.edu/kermit/ckcbwr.html
3388  186. ftp://kermit.columbia.edu/kermit/c-kermit/ckubwr.txt
3389  187. http://www.columbia.edu/kermit/ckubwr.html
3390  188. ftp://kermit.columbia.edu/kermit/c-kermit/ckuins.txt
3391  189. http://www.columbia.edu/kermit/ckuins.html
3392  190. ftp://kermit.columbia.edu/kermit/c-kermit/ckccfg.txt
3393  191. http://www.columbia.edu/kermit/ckccfg.html
3394  192. ftp://kermit.columbia.edu/kermit/c-kermit/ckcplm.txt
3395  193. http://www.columbia.edu/kermit/ckcplm.html
3396  194. ftp://kermit.columbia.edu/kermit/c-kermit/ca_certs.pem
3397  195. http://www.columbia.edu/kermit/ckuins.html#x16"
3398  196. ftp://kermit.columbia.edu/kermit/c-kermit/makefile
3399  197. http://www.columbia.edu/kermit/ckuins.html#x?
3400  198. http://www.columbia.edu/kermit/ckuins.html#x11
3401  199. http://www.columbia.edu/kermit/ckuins.html#x5.2
3402  200. http://www.columbia.edu/kermit/ckermit.html#download
3403  201. http://www.columbia.edu/kermit/ck80binaries.html
3404  202. http://www.columbia.edu/kermit/ckermit.html#download
3405  203. http://www.columbia.edu/kermit/ckuins.html#top
3406  204. http://www.columbia.edu/kermit/ckuins.html#contents
3407  205. http://www.columbia.edu/kermit/ckuins.html#x7
3408  206. http://www.columbia.edu/kermit/ckuins.html#x5
3409  207. http://www.columbia.edu/kermit/ckuins.html#top
3410  208. http://www.columbia.edu/kermit/ckuins.html#contents
3411  209. http://www.columbia.edu/kermit/ckuins.html#x8
3412  210. http://www.columbia.edu/kermit/ckuins.html#x6
3413  211. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3414  212. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3415  213. http://www.columbia.edu/kermit/ckuins.html#x4.0
3416  214. ftp://kermit.columbia.edu/kermit/c-kermit/ckcdeb.h
3417  215. ftp://kermit.columbia.edu/kermit/c-kermit/ckufio.c
3418  216. ftp://kermit.columbia.edu/kermit/c-kermit/ckufio.c
3419  217. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3420  218. http://www.columbia.edu/kermit/ckuins.html#x10
3421  219. http://www.columbia.edu/kermit/ckccfg.html#x2
3422  220. http://www.columbia.edu/kermit/ckccfg.html
3423  221. http://www.columbia.edu/kermit/ckuins.html#x4
3424  222. http://www.columbia.edu/kermit/ckuins.html#x10
3425  223. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3426  224. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3427  225. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3428  226. http://www.columbia.edu/kermit/ckuins.html#x9.4
3429  227. mailto:kermit-support@columbia.edu
3430  228. http://www.columbia.edu/kermit/ckuins.html#top
3431  229. http://www.columbia.edu/kermit/ckuins.html#contents
3432  230. http://www.columbia.edu/kermit/ckuins.html#x9
3433  231. http://www.columbia.edu/kermit/ckuins.html#x7
3434  232. http://www.columbia.edu/kermit/ckccfg.html
3435  233. http://www.columbia.edu/kermit/ckccfg.html
3436  234. http://www.columbia.edu/kermit/ckuins.html#top
3437  235. http://www.columbia.edu/kermit/ckuins.html#contents
3438  236. http://www.columbia.edu/kermit/ckuins.html#x10
3439  237. http://www.columbia.edu/kermit/ckuins.html#x8
3440  238. http://www.columbia.edu/kermit/ckuins.html#x9.1
3441  239. http://www.columbia.edu/kermit/ckuins.html#x9.1.1
3442  240. http://www.columbia.edu/kermit/ckuins.html#x9.1.2
3443  241. http://www.columbia.edu/kermit/ckuins.html#x9.1.3
3444  242. http://www.columbia.edu/kermit/ckuins.html#x9.2
3445  243. http://www.columbia.edu/kermit/ckuins.html#x9.3
3446  244. http://www.columbia.edu/kermit/ckuins.html#x9.4
3447  245. http://www.columbia.edu/kermit/ckuins.html#x9.5
3448  246. http://www.columbia.edu/kermit/ckuins.html#x9.6
3449  247. http://www.columbia.edu/kermit/ckuins.html#x9.7
3450  248. http://www.columbia.edu/kermit/ckuins.html#x9.8
3451  249. http://www.columbia.edu/kermit/ckuins.html#x9.9
3452  250. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3453  251. http://www.columbia.edu/kermit/ckuins.html#top
3454  252. http://www.columbia.edu/kermit/ckuins.html#x9
3455  253. http://www.columbia.edu/kermit/ckuins.html#contents
3456  254. http://www.columbia.edu/kermit/ckuins.html#x9.2
3457  255. http://www.columbia.edu/kermit/ckuins.html#x9.1.1
3458  256. http://www.columbia.edu/kermit/ckuins.html#x9.1.2
3459  257. http://www.columbia.edu/kermit/ckuins.html#x9.1.3
3460  258. http://www.columbia.edu/kermit/ckuins.html#top
3461  259. http://www.columbia.edu/kermit/ckuins.html#contents
3462  260. http://www.columbia.edu/kermit/ckuins.html#x9
3463  261. http://www.columbia.edu/kermit/ckuins.html#x9.1
3464  262. http://www.columbia.edu/kermit/ckuins.html#x9.1.3
3465  263. http://www.columbia.edu/kermit/ckuins.html#x9.1.1
3466  264. http://www.columbia.edu/kermit/ckuins.html#top
3467  265. http://www.columbia.edu/kermit/ckuins.html#contents
3468  266. http://www.columbia.edu/kermit/ckuins.html#x9
3469  267. http://www.columbia.edu/kermit/ckuins.html#x9.1
3470  268. http://www.columbia.edu/kermit/ckuins.html#x9.2
3471  269. http://www.columbia.edu/kermit/ckuins.html#x9.1.2
3472  270. http://www.opengroup.org/onlinepubs/007904975/
3473  271. http://www.columbia.edu/kermit/ckuins.html#x9.1.1
3474  272. http://www.columbia.edu/kermit/ckuins.html#top
3475  273. http://www.columbia.edu/kermit/ckuins.html#contents
3476  274. http://www.columbia.edu/kermit/ckuins.html#x9
3477  275. http://www.columbia.edu/kermit/ckuins.html#x9.1
3478  276. http://www.columbia.edu/kermit/ckuins.html#x9.3
3479  277. http://www.columbia.edu/kermit/ckuins.html#x9.1
3480  278. http://www.columbia.edu/kermit/ckuins.html#top
3481  279. http://www.columbia.edu/kermit/ckuins.html#contents
3482  280. http://www.columbia.edu/kermit/ckuins.html#x9
3483  281. http://www.columbia.edu/kermit/ckuins.html#x9.4
3484  282. http://www.columbia.edu/kermit/ckuins.html#x9.2
3485  283. ftp://kermit.columbia.edu/kermit/c-kermit/ckufio.c
3486  284. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3487  285. ftp://kermit.columbia.edu/kermit/c-kermit/ckufio.c
3488  286. http://www.columbia.edu/kermit/ckuins.html#top
3489  287. http://www.columbia.edu/kermit/ckuins.html#contents
3490  288. http://www.columbia.edu/kermit/ckuins.html#x9
3491  289. http://www.columbia.edu/kermit/ckuins.html#x9.5
3492  290. http://www.columbia.edu/kermit/ckuins.html#x9.3
3493  291. http://www.columbia.edu/kermit/cable.html
3494  292. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3495  293. ftp://kermit.columbia.edu/kermit/c-kermit/ckcdeb.h
3496  294. http://www.columbia.edu/kermit/ckuins.html#top
3497  295. http://www.columbia.edu/kermit/ckuins.html#contents
3498  296. http://www.columbia.edu/kermit/ckuins.html#x9
3499  297. http://www.columbia.edu/kermit/ckuins.html#x9.6
3500  298. http://www.columbia.edu/kermit/ckuins.html#x9.4
3501  299. ftp://kermit.columbia.edu/kermit/c-kermit/ckcdeb.h
3502  300. ftp://kermit.columbia.edu/kermit/c-kermit/ckuus3.c
3503  301. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3504  302. http://www.columbia.edu/kermit/ckuins.html#top
3505  303. http://www.columbia.edu/kermit/ckuins.html#contents
3506  304. http://www.columbia.edu/kermit/ckuins.html#x9
3507  305. http://www.columbia.edu/kermit/ckuins.html#x9.7
3508  306. http://www.columbia.edu/kermit/ckuins.html#x9.5
3509  307. http://www.columbia.edu/kermit/ckuins.html#top
3510  308. http://www.columbia.edu/kermit/ckuins.html#contents
3511  309. http://www.columbia.edu/kermit/ckuins.html#x9
3512  310. http://www.columbia.edu/kermit/ckuins.html#x9.8
3513  311. http://www.columbia.edu/kermit/ckuins.html#x9.6
3514  312. http://www.columbia.edu/kermit/ckuins.html#top
3515  313. http://www.columbia.edu/kermit/ckuins.html#contents
3516  314. http://www.columbia.edu/kermit/ckuins.html#x9
3517  315. http://www.columbia.edu/kermit/ckuins.html#x9.9
3518  316. http://www.columbia.edu/kermit/ckuins.html#x9.7
3519  317. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3520  318. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3521  319. ftp://kermit.columbia.edu/kermit/c-kermit/ckcdeb.h
3522  320. ftp://kermit.columbia.edu/kermit/c-kermit/ckufio.c
3523  321. http://www.columbia.edu/kermit/ckuins.html#top
3524  322. http://www.columbia.edu/kermit/ckuins.html#contents
3525  323. http://www.columbia.edu/kermit/ckuins.html#x9
3526  324. http://www.columbia.edu/kermit/ckuins.html#x10
3527  325. http://www.columbia.edu/kermit/ckuins.html#x9.8
3528  326. http://www.columbia.edu/kermit/ckuins.html#top
3529  327. http://www.columbia.edu/kermit/ckuins.html#contents
3530  328. http://www.columbia.edu/kermit/ckuins.html#x11
3531  329. http://www.columbia.edu/kermit/ckuins.html#x9
3532  330. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3533  331. http://www.columbia.edu/kermit/ckuins.html#x11
3534  332. http://www.columbia.edu/kermit/ckuins.html#top
3535  333. http://www.columbia.edu/kermit/ckuins.html#contents
3536  334. http://www.columbia.edu/kermit/ckuins.html#x12
3537  335. http://www.columbia.edu/kermit/ckuins.html#x10
3538  336. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3539  337. ftp://kermit.columbia.edu/kermit/c-kermit/ckufio.c
3540  338. http://www.columbia.edu/kermit/ckuins.html#top
3541  339. http://www.columbia.edu/kermit/ckuins.html#contents
3542  340. http://www.columbia.edu/kermit/ckuins.html#x13
3543  341. http://www.columbia.edu/kermit/ckuins.html#x11
3544  342. http://www.columbia.edu/kermit/ckuins.html#top
3545  343. http://www.columbia.edu/kermit/ckuins.html#contents
3546  344. http://www.columbia.edu/kermit/ckuins.html#x14
3547  345. http://www.columbia.edu/kermit/ckuins.html#x12
3548  346. ftp://kermit.columbia.edu/kermit/c-kermit/ckubwr.txt
3549  347. ftp://kermit.columbia.edu/kermit/c-kermit/ckutio.c
3550  348. http://www.columbia.edu/kermit/ckuins.html#top
3551  349. http://www.columbia.edu/kermit/ckuins.html#contents
3552  350. http://www.columbia.edu/kermit/ckuins.html#x15
3553  351. http://www.columbia.edu/kermit/ckuins.html#x13
3554  352. http://www.columbia.edu/kermit/ckuins.html#top
3555  353. http://www.columbia.edu/kermit/ckuins.html#contents
3556  354. http://www.columbia.edu/kermit/ckuins.html#x16
3557  355. http://www.columbia.edu/kermit/ckuins.html#x14
3558  356. http://www.columbia.edu/kermit/uiksd.html#x4.2
3559  357. http://www.columbia.edu/kermit/uiksd.html
3560  358. http://www.columbia.edu/kermit/ckermit2.html
3561  359. http://www.columbia.edu/kermit/ckuins.html#top
3562  360. http://www.columbia.edu/kermit/ckuins.html#contents
3563  361. http://www.columbia.edu/kermit/ckuins.html#x17
3564  362. http://www.columbia.edu/kermit/ckuins.html#x15
3565  363. http://www.columbia.edu/kermit/security.html
3566  364. http://www.columbia.edu/kermit/security80.html
3567  365. http://www.columbia.edu/kermit/ckuins.html#top
3568  366. http://www.columbia.edu/kermit/ckuins.html#contents
3569  367. http://www.columbia.edu/kermit/ckuins.html#x16
3570  368. http://www.columbia.edu/kermit/skermit.html
3571  369. http://www.columbia.edu/kermit/ckuins.html#top
3572  370. http://www.columbia.edu/kermit/ckuins.html#contents
3573  371. http://www.columbia.edu/kermit/ckermit.html
3574  372. http://www.columbia.edu/kermit/ck90updates.html
3575  373. http://www.columbia.edu/kermit/index.html