Jim Anderson <[EMAIL PROTECTED]> writes:

> I tried compiling a C++ program that I have. All of the
> C++ files compile ok, but during the linking phase,
> I get numerous error messages. The first of which is:
>
>  >>> test.o: In function
>  >>> 
> `__static_initialization_and_destruction_0':/usr/local/lib/gcc/i686-pc-linux-gnu/4.1.2/../../../../include/c++/4.1.2/iostream:76:
>  >>> undefined reference to `std::ios_base::Init::Init()'

The first question is: what's your failing link line?
Always use correct compiler driver (g++ for C++ code) when compiling
and linking. IOW, do not do this:

  gcc main.cpp

do this instead:

  g++ main.cpp

> It looks to me like the libraries are not being found right.

Possible, but less likely than the "user mistake" above.

Cheers,
-- 
In order to understand recursion you must first understand recursion.
Remove /-nsp/ for email.
_______________________________________________
help-gplusplus mailing list
help-gplusplus@gnu.org
http://lists.gnu.org/mailman/listinfo/help-gplusplus

Reply via email to