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: SV: c++ compiling


i restarted my pc and everything's okay... i compile now with g++ ... thanks a 
lot for the help..
a curiosity, why doesn't it work with gcc? 
Eduardo Lidanski


On Tuesday 04 May 2004 00:36, Sigurd Saue wrote:
> Use g++ instead of gcc.
>
> Sigurd
>
> -----Opprinnelig melding-----
> Fra: gcc-help-owner@gcc.gnu.org [mailto:gcc-help-owner@gcc.gnu.org] På
> vegne av Jesus Eduardo Lidanski
> Sendt: 4. mai 2004 00:20
> Til: gcc-help@gcc.gnu.org
> Emne: c++ compiling
>
> hello!
> i have a very strange problem, please help me.
> i tried to compile a c++ program:
>
> #include <iostream>
> using namespace std;
>
>
> int main()
> {
>    cout << "Hello World!\n";
>    return 0;
> }
>
> and everything was okay ....
> the next day i tried to compile another program, a basic program, but it
> gave
> me a lot of errors, and i tried to compile another time my first program...
> and i got the following errors:
>
> jesus_edu@linux:~/Documents/C++> gcc prueba.cpp
> /tmp/ccIan2q6.o(.text+0xd): In function `std::__verify_grouping(char
> const*,
>
> uns
> igned int, std::basic_string<char, std::char_traits<char>,
> std::allocator<char>
>
> > const&)':
> >
> : undefined reference to `std::basic_string<char, std::char_traits<char>,
>
> std::a
> llocator<char> >::size() const'
> /tmp/ccIan2q6.o(.text+0x60): In function `std::__verify_grouping(char
> const*,
> un
> signed int, std::basic_string<char, std::char_traits<char>,
> std::allocator<char>
>
>  > const&)':
> :
> : undefined reference to `std::basic_string<char, std::char_traits<char>,
>
> std::a
> llocator<char> >::operator[](unsigned int) const'
> /tmp/ccIan2q6.o(.text+0x9f): In function `std::__verify_grouping(char
> const*,
> un
> signed int, std::basic_string<char, std::char_traits<char>,
> std::allocator<char>
>
> > const&)':
> >
> : undefined reference to `std::basic_string<char, std::char_traits<char>,
>
> std::a
>
> llocator<char> >::operator[](unsigned int) const'
> /tmp/ccIan2q6.o(.text+0xce): In function `std::__verify_grouping(char
> const*,
> un
>
> signed int, std::basic_string<char, std::char_traits<char>,
> std::allocator<char>
>
> > const&)':
> >
> : undefined reference to `std::basic_string<char, std::char_traits<char>,
>
> std::a
>
> llocator<char> >::operator[](unsigned int) const'
>
> /tmp/ccIan2q6.o(.text+0x127): In function `main':
> : undefined reference to `std::cout'
>
> /tmp/ccIan2q6.o(.text+0x12c): In function `main':
> : undefined reference to `std::basic_ostream<char, std::char_traits<char>
> : >&
>
> std
>
> ::operator<<
>
> <std::char_traits<char> >(std::basic_ostream<char, std::char_traits
>
> <char> >&, char const*)'
> /tmp/ccIan2q6.o(.text+0x155): In function
> `__static_initialization_and_destructi
>
> on_0(int, int)':
> : undefined reference to `std::ios_base::Init::Init()'
>
> /tmp/ccIan2q6.o(.text+0x170): In function
> `__static_initialization_and_destructi
>
> on_0(int, int)':
> : undefined reference to `std::ios_base::Init::~Init()'
>
> /tmp/ccIan2q6.o(.eh_frame+0x11): undefined reference to
> `__gxx_personality_v0'
> collect2: ld returned 1 exit status
> jesus_edu@linux:~/Documents/C++>
>
>
> what ist this?? how can i compile programs ? why do i get these errors?
> thanks,
> eduardo lidanski


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