[fpc-pascal] Bug #0021680: Mixup of library imported/exported function names

patspiper patspiper at gmail.com
Sun Apr 8 21:56:30 CEST 2012


The following is related to bug #0021680:

The idea is to let libraryB intercept calls to libraryA.

1- How can this be accomplished in Linux?
Using ordinals would have been a way, but Linux does use them.

Another venture (to be tested yet) may be dynamic loading of libraryA.

2- Does this mechanism take place even when the function is imported 
under another name?
function functionB: char; stdcall;
             external 'sharedlibrarya'
             name 'functionA';

3- Should there be a warning about the name hiding?

4- The link http://blogs.embarcadero.com/eboling/2010/02/16/5656 
mentions: 'The linux support is a major PITA to implement'. Does that 
refer to implementing a non flat namespace linker model? In other words, 
difficult but not impossible?

Stephano



More information about the fpc-pascal mailing list