Results 1 to 7 of 7

Thread: weird error

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jan 2006
    Posts
    976
    Thanks
    53
    Qt products
    Qt3
    Platforms
    Windows

    Default weird error

    Hi, I've got this strange error that's only sometimes when I build app; why only sometimes? thanks...
    linking ../bin/person (g++)
    main.o: In function `main':main.cpp.text+0xf2): undefined reference to `Person::setName(std::basic_string<char, std::char_traits<char>, std::allocator<char> >)'
    collect2: ld returned 1 exit status
    make[1]: *** [../bin/person] Error 1
    make[1]: Target `first' not remade because of errors.
    make: *** [sub-src] Error 2
    make: Target `first' not remade because of errors.
    *** Exited with status: 2 ***
    Qt Code:
    1. class Person{
    2. private:
    3. string name;
    4. ....................
    5. };
    6. inline void Person::setName(const string n) {
    7. name = n;
    8. }
    9. p.setName("we we we\n");
    To copy to clipboard, switch view to plain text mode 
    Last edited by jacek; 10th November 2006 at 16:26. Reason: changed [code] to [quote]
    Regards

Similar Threads

  1. Qt-x11-commercial-src-4.2.0-snapshot-20060824 error
    By DevObject in forum Installation and Deployment
    Replies: 4
    Last Post: 24th August 2006, 23:31
  2. use qpsql
    By raphaelf in forum Installation and Deployment
    Replies: 34
    Last Post: 22nd August 2006, 12:52
  3. Problems
    By euthymos in forum Installation and Deployment
    Replies: 2
    Last Post: 13th June 2006, 19:11
  4. Fed up with M$ Window$ !!! Why is Tux leaving me alone???
    By fullmetalcoder in forum General Discussion
    Replies: 35
    Last Post: 18th March 2006, 12:57
  5. Am I the only one with "make" error ?
    By probine in forum Installation and Deployment
    Replies: 1
    Last Post: 13th February 2006, 12:54

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.