Path: utzoo!mnetor!uunet!husc6!mailrus!nrl-cmf!ames!pasteur!ucbvax!RADC-LONEX.ARPA!koziarzw From: koziarzw@RADC-LONEX.ARPA Newsgroups: comp.sys.zenith.z100 Subject: (none) Message-ID: <8803011152.AA28034@radc-lonex.arpa> Date: 1 Mar 88 11:52:16 GMT Sender: usenet@ucbvax.BERKELEY.EDU Organization: The Internet Lines: 216 Mail to: info-hz100@radc-tops20.arpa Date: Tue Mar 1 06:52:09 1988 From: koziarzw@radc-lonex.arpa Sender: koziarzw@radc-lonex.arpa Subject: Evil IBM dependencies in TurboC v1.5 cc: none Message: THIS MESSAGE WAS SUPPOSED TO PRECEED MY EARLIER ONE!!!!! This the text that should have appeared in the empty message. I mucked up, sorry. Faithful H/Z-100 Users: I do not know how many of you are users of Borland International's TurboC v1.5; but Borland committed an unforgivable act while creating v1.5 of TurboC. They rendered many of the console I/O functions totally I(nferior) B(ut) M(arketable) dependent. Functions like getche(), getch(), etcetera have been ruined for we 'Zenithers'. Fortunately, there is hope, I have (incompletely) tested the possibility of substituting v1.0 library functions (which worked on H/Z-100s) for the offending evil IBM dependent ones in v1.5. A batch command file follows which will make the needed repairs to the libraries. Some editing of this file may be required depending upon your hardware devices. FIXLIB15.BAT -- echo off cls echo Wally's TurboC v1.5 Z-100 Library Fixer echo . echo Getting CS.LIB; v1.5 echo . copy c:\tcc\lib\cs.lib i:cs_15.lib /v echo Getting CS.LIB; v1.0 echo . copy b:cs.lib i:cs_10.lib /v echo Removing Extra IBM Junk... echo . tlib cs_15 @remover.cmd del *.bak echo Extracting Good v1.0 Library Functions... echo . tlib cs_10 @get_obj.cmd echo Replacing Evil v1.5 IBM-Specific Library Functions... echo . tlib cs_15 @fix_lib.cmd echo Replacing CS.LIB... echo . copy i:cs_15.lib c:\tcc\lib\cs.lib /v del *.bak del *.obj del *.lib echo CS.LIB Fixed... echo . echo Getting CC.LIB; v1.5 echo . copy c:\tcc\lib\cc.lib i:cc_15.lib /v echo Getting CC.LIB; v1.0 echo . copy a:cc.lib i:cc_10.lib /v echo Removing Extra IBM Junk... echo . tlib cc_15 @remover.cmd del *.bak echo Extracting Good v1.0 Library Functions... echo . tlib cc_10 @get_obj.cmd echo Replacing Evil v1.5 IBM-Specific Library Functions... echo . tlib cc_15 @fix_lib.cmd echo Replacing CC.LIB... echo . copy i:cc_15.lib c:\tcc\lib\cc.lib /v del *.bak del *.obj del *.lib echo CC.LIB Fixed... echo . echo Getting CM.LIB; v1.5 echo . copy c:\tcc\lib\cm.lib i:cm_15.lib /v echo Getting CM.LIB; v1.0 echo . copy a:cm.lib i:cm_10.lib /v echo Removing Extra IBM Junk... echo . tlib cm_15 @remover.cmd del *.bak echo Extracting Good v1.0 Library Functions... echo . tlib cm_10 @get_obj.cmd echo Replacing Evil v1.5 IBM-Specific Library Functions... echo . tlib cm_15 @fix_lib.cmd echo Replacing CM.LIB... echo . copy i:cm_15.lib c:\tcc\lib\cm.lib /v del *.bak del *.obj del *.lib echo CM.LIB Fixed... echo . echo Getting CL.LIB; v1.5 echo . copy c:\tcc\lib\cl.lib i:cl_15.lib /v echo Getting CL.LIB; v1.0 echo . copy b:cl.lib i:cl_10.lib /v echo Removing Extra IBM Junk... echo . tlib cl_15 @remover.cmd del *.bak echo Extracting Good v1.0 Library Functions... echo . tlib cl_10 @get_obj.cmd echo Replacing Evil v1.5 IBM-Specific Library Functions... echo . tlib cl_15 @fix_lib.cmd echo Replacing CL.LIB... echo . copy i:cl_15.lib c:\tcc\lib\cl.lib /v del *.bak del *.obj del *.lib echo CL.LIB Fixed... echo . echo Getting CH.LIB; v1.5 echo . copy c:\tcc\lib\ch.lib i:ch_15.lib /v echo Getting CH.LIB; v1.0 echo . copy a:ch.lib i:ch_10.lib /v echo Removing Extra IBM Junk... echo . tlib ch_15 @remover.cmd del *.bak echo Extracting Good v1.0 Library Functions... echo . tlib ch_10 @get_obj.cmd echo Replacing Evil v1.5 IBM-Specific Library Functions... echo . tlib ch_15 @fix_lib.cmd echo Replacing CH.LIB... echo . copy i:ch_15.lib c:\tcc\lib\ch.lib /v del *.bak del *.obj del *.lib echo CH.LIB Fixed... echo . echo Libraries Are Ready To Use... REMOVER.CMD -- Specifies IBM-specific functions which can be deleted -bioscom -biosdisk -biosequ -bioskey -biosprin & -clreol -clrscr -color -crtinit & -delay & -gexit -gfreemem -ggetmem -gotoxy -gptext -gregistr -gvect & -insline & -kbhit & -movetext & -sound & -textmode & -vidinfo & -wherexy -window GET_OBJ.CMD -- Extracts v1.0 Library Functions *cprintf *cputs & *fputs & *getc *getch & *putc *putch & *ungetc FIX_LIB.CMD -- Replaces v1.5 Library Function With v1.0 Functions -+cprintf -+cputs & -+fputs & -+getc -+getch & -+putc -+putch & -+ungetc These *.CMD files are 'response files' for 'TLIB' -- the TurboLibrarian. See TurboC v1.5 documentation for more information on response files and on TLIB in general. I, myself, feel that it was an inexcusable act on the part of Borland to screw up a nice MS-DOS compiler (TurboC 1.0) the way they did (making TurboC v1.5) in the name of IBM dependence. Hope some of you will benefit from this information. I also hope that if anyone finds more functions that need replacing, you will post these additional changes to INFO-HZ100. I make no claim to have made all the necessary alterations to the TurboC v1.5 library and sincerely hope that everyone will test these changes before depending on them. They seem to work with the small amount of testing I have done. Happy TurboC'ing, Walt Koziarz -- alias: 71261,720 -- CompuServe wkoziarz -- BIX koziarzw -- @RADC-lonex.ARPA