Back to home page

DOS ain't dead

Forum index page

Log in | Register

Back to the forum
Board view  Mix view

.DXE .DLL .SO (etc.) (Developers)

posted by Laaca Homepage, Czech republic, 15.12.2019, 22:50

Borland pascal 7.0 can use both - overlays in realmode and DLL libraries in DOS 16-bit protected mode. (and for windows, of course).
The DLL stuff is described quite well in the help system in IDE.

The bad thing in DLLs in DOS is that they are a little bit usesless. What advantage give it against static linking in the single-task OS?

However the good thing ih the BP way of the DLL implementation is that it is quite straitforward and not much more complicated ovet normal static-linked unit.

The DXE1 modules in the FPC has severe limitation that it has almost no connection with other parts of the program.


The EXE sees the inside of the DXE but the DXE sees nothing from EXE.
The practical impact is the the DXE modules can not use any procedures (or functions) from any system or user unit. Nothing from unit CRT, nothing from DOS, even nothing from unit SYSTEM.
So it is an extreme limitation for using this stuff.
The only way how to bypass this situation is using the procedural variables.

In the DXE can be something like that:
var Alloc:procedure(size:longint);
var DrawLine:procedure(x1,y1,x2,y2:longint);

And in the EXE you must initialize these variables:
DXE.Alloc:=@GetMem;
DXE.DrawLine:=@Line;

...and so on.

So it is so paintful that nobody uses it.
Maybe in theory could be possible the implement into FPC the DXE3 handling which should not suffer by this limitation but it would need some DOS-and-pascal-megaguru...

---
DOS-u-akbar!

 

Complete thread:

Back to the forum
Board view  Mix view
22752 Postings in 2119 Threads, 402 registered users (1 online)
DOS ain't dead | Admin contact
RSS Feed
powered by my little forum