Auto Search for BGI in Turbo C
Adam Goldberg
tabu6 at CCVAX.IASTATE.EDU
Mon Mar 18 02:20:20 AEST 1991
In article <65841 at eerie.acsu.Buffalo.EDU>, haozhou at acsu.buffalo.edu (Hao Zhou) writes:
>I wrote an application program using Turbo C graphics package. The
>only problem I have is that I have to keep the BGI driver in the
>current directory otherwise the program will say the BGI driver is not
>found.
>
>My question is how do I tell my program to search for the BGI driver
>in a path specified somehow if the BGI driver is not present in the
>current directory?
>
It is possible to link the BGI driver in with the executable code (EXE file),
by:
o Using the BGIOBJ utility to create an OBJ verion of the BGI driver
o LINKing the OBJ BGI driver with your code OBJ file
o Doing either a 'registerbgidriver()' or 'registerfarbgidriver()' function
call before the 'initgraph()' call.
(Consult your manual for further info--though I got this from the Waite Group's
Turbo C++ Bible -- these functions work in TC2.0 as well).
------------
Part II:
if(a=b) {
... }
has legitimate use. This is a non-atomic slightly modified TestAndSet.
+----------------------------------------------------------------------------+
+ Adam Goldberg H:(515)233-5135 +
+ Iowa State University TABU6 at ccvax.iastate.edu +
+ "It's simple! Even a Pascal programmer could do it!" +
+----------------------------------------------------------------------------+
More information about the Comp.lang.c
mailing list