[comp.sys.dec.micro] Patch for TPULIB to avoid 64k .TPL file barrier

OBRIEN%OBRIEN@VENUS.YCC.YALE.EDU ("James A. O'Brien 432-4382", 203) (06/10/88)

Posting to info-dec-micro, 6/9/88

I posted the TPULIB package earlier and mentioned the problem with libraries
larger than 64k.  The limitation was accidental - the author set the heap
size to 64k when he compiled the code!  (It was written by Brian Foley of
TurboPower Software of Scotts Valley, CA).  Here are two simple methods
to fix the problem.  (It's an easy problem to solve, since an .EXE file
has stored in its header the heap size to assume.  Thus, we can change it
and the program will never know that the value was put there by us, and not
the compiler!!).
 
First method:
a) Rename tpulib.exe to tpu.abc.  (Don't use your original TPULIB,
   just in case)

b) Next, issue at the DOS prompt: 
		debug tpu.abc < tpumods.deb
   where TPUMODS.DEB is a debug script file listed below.

c) finally, copy tpu.abc to tpulib.exe.

The modification in the .DEB file changes the heap space to 256k, which
should be plenty (of course, if you have less than that in your machine,
you'll be limited by that!).
                   

Alternative method:
If you happen to have the program EXEMOD.EXE which Microsoft distributed
(at least some time ago) with their languages, you can get the same effect
by typing
                exemod tpulib.exe /max 4275 
(again making sure not to use your original copy).


----Here's tpumods.deb----cut this line and above--------
e 10d
42

w
q

----end of tpumods.deb----cut this line and below--------
             
Hope this sorts out the problem.  Otherwise, TPULIB is an extremely useful
utility.  Usual disclaimers (I'm not responsible for your use of this fix
- do it at your own risk!) apply.  I've tried both methods, and they both
work just fine for me. 

                                Jim O'Brien
				Department of Chemical Engineering
				Yale University
				P.O.Box 2159 Yale Station
				New Haven, CT 06520, U.S.A.
				+1 203 432 4382 (days)
				+1 203 322 7222 (eves)
                                                         
Return Addresses (both equivalent):   
		OBRIEN%OBRIEN@YALEVMS				BITNET
		OBRIEN%OBRIEN@VENUS.YCC.YALE.EDU		Internet
                |--+-| |--+-| |-------+--------|
                   |      |           |
                   |      |           +--------| host network address
                   |      +--------| microvax node name
                   +---------| userid on microvax