Mail Archives: djgpp/2010/03/29/10:03:35
> From: RayeR <glaux AT centrum DOT cz>
> Date: Mon, 29 Mar 2010 07:35:28 -0700 (PDT)
> Bytes: 2424
>
> So it seems it is a problem of ncurses. Does ncurses use conio
> functions? Or does it redefine them its own way?
It defines its own versions of those functions.
> I think it should be possible to use same function from different
> modules or libraries.
No, names of external functions have global scope. There can be only
one definition for each such function.
> E.g. I use printf from libc and other library can aslo use printf and
> all get linked together without any problem.
You can _use_, i.e., _call_ the same function from many places. But
ncurses does not _call_ getch etc., it _implements_ them.
> But what would happen if any other library will define it's own printf
> (without including stdio.h)?
You will get similar linker errors.
- Raw text -