nacer@hpmcaa.mcm.hp.com (Abdenacer Moussaoui) (12/30/89)
Can TP generate .obj files that are linkable using say Microsoft link.exe? Is there a provided TP .lib to support TP builtins? Can one call TP routines from turbo C? Thank you. --Abdenacer (nacer@hpmcaa.mcm.hp.COM)
leonard@bucket.UUCP (Leonard Erickson) (12/31/89)
nacer@hpmcaa.mcm.hp.com (Abdenacer Moussaoui) writes: >Can TP generate .obj files that are linkable using say Microsoft link.exe? No. TP only produces EXE or TPU files. (TPU is a special format file that allows the compiler to execlude unused code from linked in units) >Is there a provided TP .lib to support TP builtins? I'm not sure that I understand this. But no, there's no .lib file. >Can one call TP routines from turbo C? I beleive it can be done but all I remember of what I was told about it was that it was *real strange*. On the other hand, you can link in any .obj file just by doing $L name.obj. You do have to follow a few simple rules about segment names, but that's it. -- 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
jds@mimsy.umd.edu (James da Silva) (01/02/90)
In article <1867@bucket.UUCP> leonard@bucket.UUCP (Leonard Erickson) writes: >nacer@hpmcaa.mcm.hp.com (Abdenacer Moussaoui) writes: >>Is there a provided TP .lib to support TP builtins? > >I'm not sure that I understand this. But no, there's no .lib file. But there is a TP-specific lib format (TPL), and the runtime library is in TURBO.TPL. (For what it's worth) >... On the other hand, you can link in any .obj file just by doing $L >name.obj. You do have to follow a few simple rules about segment names, but >that's it. Almost. You also aren't allowed to have initialized data in the DATA segment. This is a big pain for some applications. Like mine. :-) Jaime ........................................................................... : domain: jds@cs.umd.edu James da Silva : path: uunet!mimsy!jds
dmurdoch@watstat.waterloo.edu (Duncan Murdoch) (01/02/90)
In article <1867@bucket.UUCP> leonard@bucket.UUCP (Leonard Erickson) writes: > >On the other hand, you can link in >any .obj file just by doing $L name.obj. You do have to follow a few >simple rules about segment names, but that's it. There are very strong restrictions on the .obj files, that essentially limit you to linking assembly code, not any high level language. - you can have only one code segment - you can have only one data segment, and it can't have initialized data - any external references have to be resolved in the TP code, not in other .OBJ files or .LIBs. I think it would be a good idea to complain about this to Borland. I've heard the same restrictions apply to Microsoft's QuickPascal, but I can't imagine that Microsoft will keep them for long - their big fat MS Pascal can link to any other Microsoft language. Duncan Murdoch
lzirkel@i-core.UUCP (Louis Zirkel III) (01/04/90)
In article <1490006@hpmcaa.mcm.hp.com>, nacer@hpmcaa.mcm.hp.com (Abdenacer Moussaoui) writes: >Can TP generate .obj files that are linkable using say Microsoft link.exe? No, as for the versions up to v5.5 they cannot create .obj files because Borland thought that the .OBJ format was inherently slow so they created the .TPU format that is what makes TPv5.5 so much faster. >Can one call TP routines from turbo C? Yes, you can when you are doing mixed language programming... (now the proverbial...) BUT, when you use the C routines you must realize that you cannot access any of the Standard Library routines as they are compiled. When You use the mixed language programming capabilities of the C language (Turbo) it ignores case and so it cannot recognize the Standard Library functions. Also, when you make 'pascal' functions in C you cannot use variable argument lists.s Louis. -- > It's not a bug... it's a feature! lzirkel @ i-core