Mail Archives: djgpp/2000/04/26/05:16:32
Joseph Rose <jorose AT pop DOT gis DOT net> wrote:
> I'm having a problem linking object files and calling
> functions in one source file from another.
[...]
> I can't get beyond the 'undefined reference' error
> messages.
You don't show any compilable source, your Makefile, or the actual
error message, which makes it close to impossible to be sure what your
error might be. But from various keywords you used, my main suspicion
is that you're trying to link assembly .o files with C++ code, and
didn't use 'extern "C"' in the header files that contain the
prototypes for those assembly functions. In a nutshell: put an
extern "C" {
/* all assembly function prototypes, here */
}
in the interface header(s) for your assembly module(s). Look up the
meaning of this construct in your C++ textbook of choice.
--
Hans-Bernhard Broeker (broeker AT physik DOT rwth-aachen DOT de)
Even if all the snow were burnt, ashes would remain.
- Raw text -