assembly language function names to be called by Turbo C++. Your
assembly language program should be assembled with Case Sensitivity.
If compiling as C++ (rather than C), see the "Common C++ Questions"
section above which discusses the use of extern "C".
Q: I am getting an error out of the linker "segment group exceeds 64K :
_text".
A: If you are using the BGIOBJ utility, the default segment into which
the objects will be place is _text. You should try using BGIOBJ with
the /f option to place the resultant objects into a separate segment.
You will then need to use the functions registerfarbgidriver and
registerfarbgifont to register the objects for the graphics system.
See UTIL.DOC for instructions on using these functions.
Q: I am attempting to link Turbo C 2.0 objects into my Turbo C++ programs,
but continually get unresolved external symbols at link time.
A: The names of many of the "helper" functions have changed from what they
were in Turbo C 2.0. If you are getting undefined symbols like _LXLSH and
_FMUL, this is the problem you are running into. Your best solution is to
get the source code to the old object modules and recompile with Turbo C++.
The only other possibility would be to extract the helper function objects
from the Turbo C 2.0 libraries and link them into the Turbo C++ program.
Q. I'm porting an application that uses communal variables to C++.
I've set up the compiler to recognize them, but I still get linker
errors:
Error:
A. C++ doesn't support explicit COMDEFs; you must use static
----------------------------------------------------------------------
Q. I get a "floating point formats not linked" message when I run
my program. What can I do about it?
A. Floating point formats (for scanf() and related functions) are
not always linked, for savings in executable size. To force their
inclusion, put the following somewhere in your source files:
extern unsigned _floatconvert;
Q. How do I change the stack size?
A. The size of the stack of a Turbo C++ program is determined at
run time by the global variable _stklen. To change the size
to, for example, 10,000 bytes, include the following line in
extern unsigned _stklen = 10000;
This statement must not be inside any function definition.
The default stack size is 4,096 bytes (4K).
Q. I'm getting a 'Stack Overflow!' message when I run my program.
A. You may increase the stack size by
No comments:
Post a Comment