AIX

AIX

Connect with fellow AIX users and experts to gain knowledge, share insights, and solve problems.

 View Only
Expand all | Collapse all

WARNING: Duplicate symbol: .std::basic_ostream

  • 1.  WARNING: Duplicate symbol: .std::basic_ostream

    Posted Thu May 03, 2007 05:51 PM

    Originally posted by: SystemAdmin


    Using Visual Age C++, Version 5

    Has anyone seen the following?
    Does anyone know a cure?

    I see "WARNING: Duplicate symbol: .std::basic_ostream ..."
    and corresponding messages for nearly everything in
    /usr/vacpp/include/

    Searhing program.i after using
    xlC ... -E ... program.cpp > program.i
    reveals no definitions that appear to be duplicated
    (all differ in argument types).

    The includes are
    //
    // Interface files
    //

    // Visual Age C++
    #include <iostream> // std::cerr
    #include <stdexcept> // runtime_error

    // Visual Age C
    #include <stdio.h> // sscanf()
    #include <errno.h> // EINVAL
    #include <strings.h>

    Any help appreciated.


  • 2.  SOLUTION: Re: WARNING: Duplicate symbol: .std::basic_ostream

    Posted Thu May 03, 2007 05:56 PM

    Originally posted by: SystemAdmin


    I regret if I wasted anybody's time.

    The problem was at link not compile stage.

    I'd acceidently added -lC in the library flags.

    Sheepishly,