Browse Prior Art Database

Dynamic Link Library Mechanism in DOS Environment

IP.com Disclosure Number: IPCOM000122198D
Original Publication Date: 1991-Nov-01
Included in the Prior Art Database: 2005-Apr-04
Document File: 2 page(s) / 75K

Publishing Venue

IBM

Related People

Johnson, WJ: AUTHOR [+3]

Abstract

A programmatic methodology is described for providing a dynamic link library in a DOS environment. The problems solved by OS/2* dynamic linking hold true for the DOS environment, e.g., linking code without all the object as part of the executable, eliminate duplicated code in the system, break out common code in the system and make it available to many executables, etc.

This text was extracted from an ASCII text file.
This is the abbreviated version, containing approximately 52% of the total text.

Dynamic Link Library Mechanism in DOS Environment

      A programmatic methodology is described for providing a
dynamic link library in a DOS environment. The problems solved by
OS/2* dynamic linking hold true for the DOS environment, e.g.,
linking code without all the object as part of the executable,
eliminate duplicated code in the system, break out common code in the
system and make it available to many executables, etc.

      A dynamic link library (DLL) can be achieved in DOS by
providing a header file for compiling or assembling with which
contains macros that elaborate function calls into one soft interrupt
call (hereinafter called function bindit()) having a literal
argument. The soft interrupt function, bindit(), is executed as a
Terminate and Stay Resident (TSR) function before any DLL calls are
made so that it is present to perform DLL functionality. The literal
argument is a predefined token representing the DLL function to be
called. The soft interrupt bindit() function has parameters passed in
registers for performance. The bindit() function needs only one
argument if the only requirement is to support DLLs without special
environment constraints such as swapping -- compiled in unique
literal representing the specific DLL function name to be called. The
bindit() function, which was also compiled or assembled with the
function name literals, will perform the dynamic link by loading the
requested function if not already present in memory. Otherwise, a
call to the existing copy is made.  Upon initial execution, bindit()
validates the literal to be a known DLL function; otherwise an error
is returned. bindit() contains a collection, of functions for
managing the DLL call. The means for calling consists of a table
(3-dimen...