README for gkermit 1.0 on CP/M-68K Usage ----- The CP/M-68K port of gkermit can only be used if your CP/M-68K system supports console operation over an RS-232 serial port. It operates as the "far end" of a connection in exactly the same way as gkermit on Unix. See section 2 of the original README for more details. Differences from Unix gkermit ----------------------------- CP/M-68K does not support case-sensitive command-line arguments, all arguments are translated to lower case. This means that the T,P,K,S and X options are not available. Since text mode is too useful to lose, gkermit for CP/M-68K will accept a lower-case 't' instead. Limitations ----------- No support for streaming (built with the DUMBIO option selected). Also no support for XON/XOFF or parity setting (limitation imposed by the minimal stty() capabilities on CP/M-68K). Test environment ---------------- The CP/M-68K port is based on gkermit 1.0 for Unix. It was compiled on a CP/M-68K 1.2 system running on an Isicad Prisma 700 workstation. Although built on a 1.2 system, the C compiler and libraries used for the build were taken from a 1.3 system. This was done to take advantage of any bug fixes that might have been done between 1.2 and 1.3 (the 1.3 README does say that a new version of the compiler is included but doesn't say anything about what the changes were). File transfer was tested with the console port, running at 9600/8/N/1, connected to a PC running C-Kermit 7.0 on Slackware Linux 7.1. Text and binary transfers were successfully completed. Porting notes ------------- The CP/M-68K C library claims be largely compatible with Unix Version 7. Notable differences include: No alarm(), sleep() or any other time-related functions. Very limited stty(), gtty(), no speed or parity settings. No fork()/exec(). No stat() or fstat(). No getenv(). Separate open() and fopen() calls for ascii and binary files. There is also no 'make' command, compiling is done one file at a time using a SUBMIT batch command file. Another SUBMIT file is used for the final linking. Most of the changes are in 'gunixio.c' and concern the serial I/O and file handling. Changes in the other source files were mainly to work round compiler quirks and shouldn't affect operation on other platforms. Since there is no alarm(), the input timeout has been implemented using a polling loop and counter, as has a basic sleep() function. The counter values were chosen to give approximately the right amount of delay on the development machine, which uses a 33MHz 68020 processor. They should be reduced for slower systems. A 'feature' of the CP/M-68K C library that deserves special mention is the inclusion of stub routines intended to reduce the size of executables by leaving out sections of the library that the programmer knows will never be used by his/her program. These are not mentioned in any of the manuals the author has access to but are mentioned in one of the include files, option.h. Although the default behaviour should be for the linker to use the full function, it appears that the stub gets linked instead for _filesz(). The only solution found so far is to remove the stub module from the C library. This can be accomplished using AR68 as follows: C>ar68 dv clib nofilesz.o But make sure you have a backup copy of CLIB first! The compiler, assembler, linker and include files all came from CP/M-68K 1.3 with the exception of sgtty.h, which was missing from my copy of 1.3, and was taken from the 1.2 release. Files ----- Unmodified files from the Unix gkermit distribution: ANNOUNCE COPYING README gkermit.nr makefile Source files updated for CP/M-68K: gcmdline.c gkermit.c gkermit.h gproto.c gproto.w gunixio.c gwart.c SUBMIT files to compile and link on CP/M-68K: cgk.sub Use this to compile each source file. logk.sub Linker script for gkermit. logw.sub Linker script for gwart. CP/M-68K binaries: gkermit.rel gwart.rel Others: README.68K This file! gkermit.diff Context diffs from the Unix sources. Web sites --------- G-Kermit home page: http://www.kermit-project.org/gkermit.html The Unofficial CP/M Web site: http://www.cpm.z80.de/ George Harvey fr30@dial.pipex.com 16th March 2002