This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: screen processing fns


>  Wed Jan 15 08:52:53 2003

> does anybody know about any header containing fns for clearing
> screen and such stuff.

Take a look at the  curses  library.  There are many tutorials
on the web.

> i have a header : conio.h (from turbo c++ )
> for this purpose but when i put this file in my /usr/include
> directry
> (and other relevant include files) i still get a
> "undefined refrence to <fn name>"

Headers are usually very system-dependant.  Thus, you cannot
generally use a header from one OS on another, and often cannot
even use the same header on two different versions of the same
OS.  Furthermore,  conio.h  is a non-standard header (unlike
stdio.h, stdlib.h, string.h, and so on).

Anyway, you are probably getting the "undefined reference" during
link time.  This would mean that your header (erroneously, as I
describe in the above paragraph) made things "look right" from 
the source code point of view, but that the function entry point
couldn't be found in the libraries specified at link time (usually
just libc specified implicitly).

In other words, to use a certain function, you not only need 
a declaration in a header (with sometimes some other infrastructure)
but you also need an object (the "certain function" compiled, usually
also added to a library of functions) to link in.  Also, both of 
these (the header and the library) need to match your system.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]