[comp.lang.pascal] old .TPUs under TP5.5???

scott@boa.gatech.edu (02/19/90)

It would appear that Units compiled with previous versions of Turbo Pascal
do not work with version 5.5.  This is rather frustrating, as there is
a lot of PD/shareware TP stuff out there that is only available in .TPU
form.  Is there a program to convert old units to the new format?  Is such
a thing possible?  Does anyone know what the differences in format are?

Thanks for any pointers,
Scotters

pmk@cip-s01.informatik.rwth-aachen.de (Michael Keukert) (02/20/90)

Hi,

I havn't yet received the update to 5.5 (as to bring it on the point - I
don't know, if my entreprise has ordered it), but in earlier versions of
turbo-pascal, there was the program UPGRADE, with wich you could change
code to the newest version.
---------------------------------------------------------------------------
Michael Keukert, Elsasstrasse 58, D-5100 Aachen, FRG, Tel: +49 241 513297 Q
Fido: Michael Keukert@Maus AC 2:242/2   ZNet:MICHAEL_KEUKERT!AC@ZERMAUS.ZER
Twenty bucks per day plus expenses - hundred in advance.        (Sam Spade)

milne@ics.uci.edu (Alastair Milne) (02/20/90)

>It would appear that Units compiled with previous versions of Turbo Pascal
>do not work with version 5.5.

   In fact, the TPU file starts with a signature that indicates precisely
   which version of Turbo wrote it.  That alone presumably keeps later Turbo's
   from using it.  Whether any other aspect of TPU's differs I couldn't say.
   The signature system was probably installed in case they did.


   Alastair Milne
   U. Calif. Irvine

dmurdoch@watstat.waterloo.edu (Duncan Murdoch) (02/21/90)

In article <25E0E80B.10233@paris.ics.uci.edu> milne@ics.uci.edu (Alastair Milne) writes:
>   In fact, the TPU file starts with a signature that indicates precisely
>   which version of Turbo wrote it.  That alone presumably keeps later Turbo's
>   from using it.  Whether any other aspect of TPU's differs I couldn't say.
>   The signature system was probably installed in case they did.

All three versions of .TPU files differ significantly.  Borland is free to
make changes, since any new SYSTEM unit makes all existing .TPU files
obsolete anyways.

Duncan Murdoch

leonard@bucket.UUCP (Leonard Erickson) (02/21/90)

scott@boa.gatech.edu writes:

>It would appear that Units compiled with previous versions of Turbo Pascal
>do not work with version 5.5.  This is rather frustrating, as there is
>a lot of PD/shareware TP stuff out there that is only available in .TPU
>form.  Is there a program to convert old units to the new format?  Is such
>a thing possible?  Does anyone know what the differences in format are?

From what I've been told, the guy "in charge" of Turbo Pascal refuses to
commit to any kind of "standard" for unit structure. Apparently he is 
paranoid about the possibility that if he commits to one he may later need
to extend it in an incompatible manner. So he feels free to change the
structure any way he pleases between versions (BTW, TP5.5 units say that
they are TP6 units...)

I think I saw a conversion program, but it wasn't guaranteed to work.
-- 
Leonard Erickson		...!tektronix!reed!percival!bucket!leonard
CIS: [70465,203]
"I'm all in favor of keeping dangerous weapons out of the hands of fools.
Let's start with typewriters." -- Solomon Short

hawk@hpavla.AVO.HP.COM (Dave Hawk) (02/23/90)

Borland's habit of altering the binary format of the TPUs for each version
of Turbo Pascal (4.0, 5.0 and 5.5) has been a real nuisance if you have 
purchased binary libraries from other vendors.  The Turbo Analyst Package
had a good solution to this.  Their 5.0 version (after they got burned by
the 4.0 to 5.0 change) had their TPUs in a mangled source form rather than
in binary form.  Thus when 5.5 came along all their customers had to do
was recompile the mangled source to generate the new binary format.  Their
mangled source is not human readable, but will get through the compiler.

Borland would do us all a service if they provided a utilitiy for 
automatically upgrading binary TPUs.  (The only upgrade programs I have
seen from them upgraded 3.0 SOURCE to 4.0 SOURCE - it wouldn't do anything
for binarys).

David Hawk
Hewlett-Packard, Avondale Pa.

"Arnold G. Gill" <GILLA@QUCDN.QueensU.CA> (02/25/90)

     If this is the case, that .TPUs are *NOT* upwards/downwards compatible,
then the user community should seriously think about bitching to Borland in
earnest and in great numbers, or else switching to someone else's software.
It sounds to me like an idiotic ploy to keep the user community locked into
using Borland software and forcing them to buy new versions whenever they
come out.  With so much public domain material around, this is really a bad
practice.
-------
 -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
|  Arnold Gill                        |                                     |
|  Queen's University at Kingston     |                                     |
|  BITNET   : gilla@qucdn             |     Damn, I need something here!    |
|  X-400    : Arnold.Gill@QueensU.CA  |                                     |
|  INTERNET : gilla@qucdn.queensu.ca  |                                     |
 -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

dmurdoch@watstat.waterloo.edu (Duncan Murdoch) (02/25/90)

In article <1968@bucket.UUCP> leonard@bucket.UUCP (Leonard Erickson) writes:
>scott@boa.gatech.edu writes:
>
>From what I've been told, the guy "in charge" of Turbo Pascal refuses to
>commit to any kind of "standard" for unit structure. Apparently he is 
>paranoid about the possibility that if he commits to one he may later need
>to extend it in an incompatible manner. So he feels free to change the
>structure any way he pleases between versions (BTW, TP5.5 units say that
>they are TP6 units...)

That may be true, but even if the structure hadn't changed, or had changed
in an upwardly compatible manner, all 4.0 and 5.0 .TPU files would be useless
with TP 5.5.  

The reason is basic to the design of the TPU:  anytime you change
the interface to a unit, any unit that depends on it must be recompiled.  (This
is because external references are by location in the referenced .TPU file, 
not by named reference.)  Since the interface to the SYSTEM unit has changed 
with each revision, and every unit depends on the SYSTEM unit, every .TPU file 
becomes obsolete with each release of a new version of TP.  

This doesn't seem likely to change.  So why should Borland bother to stabilize 
the format?

And why would anybody bother with a .TPU file if they didn't have the source?

Duncan Murdoch

beoneel@well.sf.ca.us (Bruce O'Neel) (02/26/90)

Actually, since Turbo 4.0 is close to turbo 5.5, the upgrade program continues

to work well

scott@kong.gatech.edu (Scott Coulter) (02/26/90)

In article <1573@maytag.waterloo.edu> dmurdoch@watstat.waterloo.edu (Duncan Murdoch) writes:
>And why would anybody bother with a .TPU file if they didn't have the source?
>
>Duncan Murdoch

Because someone else wrote a unit which does exactly what I need it too, 
but he didn't see fit to release the source.  Any more questions?
===============================================================================
Scott D. Coulter        Georgia Institute of Technology, Atlanta Georgia, 30332
uucp: {most anywhere}!gatech!kong!scott         Internet: scott@kong.gatech.edu
"Sometimes I just sit back & close my eyes; I enjoy the view"--Michael W. Smith

wsinpp@lso.win.tue.nl (Peter Peters) (02/27/90)

Although I agree that it is ridiculous what Borland is doing with
it's TPU file format (incompatibility), we should also take a look
at ourselves. The only way this policy of Borland has any success
is when WE distribute .TPU files and no sources. So gimme al them
sources instead of TPU's ( 1/2 a :-) ) !!!

		Peter.

| Peter Peters                              | UUCP : wsinpp@lso.win.tue.nl  |
| Eindhoven University of Technology (TUE)  | SURF : heithe5::wsdcpp        |
| Dept. of Mathematics and Computer Science | VHF  : PA0PPE                 |
| Disclaimer : I said WHAT ???              | TUE  : HG 8.86 tst. 4283      |
-- 
| Peter Peters                              | UUCP : wsinpp@lso.win.tue.nl  |
| Eindhoven University of Technology (TUE)  | SURF : heithe5::wsdcpp        |
| Dept. of Mathematics and Computer Science | VHF  : PA0PPE                 |
| Disclaimer : I said WHAT ???              | TUE  : HG 8.86 tst. 4283      |

dmurdoch@watstat.waterloo.edu (Duncan Murdoch) (02/27/90)

In article <90055.172954GILLA@QUCDN.BITNET> GILLA@QUCDN.QueensU.CA (Arnold G. Gill) writes:
>
>     If this is the case, that .TPUs are *NOT* upwards/downwards compatible,
>then the user community should seriously think about bitching to Borland in
>earnest and in great numbers, or else switching to someone else's software.

I agree with this part completely, but...

>It sounds to me like an idiotic ploy to keep the user community locked into
>using Borland software and forcing them to buy new versions whenever they
>come out.  With so much public domain material around, this is really a bad
>practice.

It seems like just the opposite to me:  a strong disincentive to upgrade.  
After all, if you upgrade your compiler, you lose all your sourceless .TPUs.

Or, from an optimistic point of view, a strong encouragement to library writers
to release source code. 

(Actually, there are a couple of ways to avoid releasing
source code while allowing multi-version compatibility.  Anything written as
an external .OBJ need not be recompiled; thus there's no need to release
the low-level assembler code.  If a unit is mostly written in TP, then it
can be made unreadable by removing all the comments and renaming all the 
local variables to meaningless junk names.  I've heard that this is done
by TurboPower in their Turbo Analyst package, which uses parts of their
Turbo Professional package.  They don't want to give away those parts of
TPro, so they garble them.)

Duncan Murdoch

ts@uwasa.fi (Timo Salmi LASK) (02/28/90)

In article <1591@maytag.waterloo.edu> dmurdoch@watstat.waterloo.edu (Duncan Murdoch) writes:
>In article <90055.172954GILLA@QUCDN.BITNET> GILLA@QUCDN.QueensU.CA (Arnold G. Gill) writes:
... some text deleted ...
>>It sounds to me like an idiotic ploy to keep the user community locked into
>>using Borland software and forcing them to buy new versions whenever they
>>come out.  With so much public domain material around, this is really a bad
>>practice.
>
>It seems like just the opposite to me:  a strong disincentive to upgrade.  
>After all, if you upgrade your compiler, you lose all your sourceless .TPUs.
>
>Or, from an optimistic point of view, a strong encouragement to library writers
>to release source code. 

   I quite agree with what is being said above, but having
distributed some of these sourceless (and priceless , since they are
PD :-) tpus myself, I don't see any real incentives from the
*author's* point of view to release the sources.  I do, of cource,
see that Borland's policy makes having the sources even more
desirable from the *user's* point of view.  But what is in it for
the author other than being a good sport.  Nothing. 
   As I've said in an earlier message, I (too) feel that Borland's
tpu policy is badly counterproductive to its otherwise commendable
quality.  Personally, I am going to stick to using TP 5.0, since
upgrading is not worth the hassle! They are going to lose much sales
potential, and in a market economy that is going to be costly in the
end. 

...................................................................
Prof. Timo Salmi        (Moderating at anon. ftp site 128.214.12.3)
School of Business Studies, University of Vaasa, SF-65101, Finland
Internet: ts@chyde.uwasa.fi Funet: gado::salmi Bitnet: salmi@finfun