Results 1 to 1 of 1

Thread: Undefined references while building test app against Qt452-static

  1. #1
    Join Date
    Oct 2009
    Posts
    2
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Undefined references while building test app against Qt452-static

    Hi everyone,

    I only very recently got into Qt, and haven't had any problems until encountering the following.

    To start: I am using Qt452, opensource version. It was configured with (from config.status):

    configure -prefix /vend/qtlgpl/qt452-e4-static-gcc402 -I/usr/kerberos/include/ -static -stl -release -qt-gif -qt-libpng -qt-libjpeg -qt-libtiff -qt-zlib -glib -fontconfig -xmlpatterns -platform linux-g++-64 -confirm-license

    Now, the problem. As part of a test for this install and configuration of Qt, I am trying to build a relatively simple program (not of my own creation). My build against the shared configuration of Qt452 worked correctly.

    When I try to build against the static configuration, however, I run into thousands of undefined reference errors. The output of my make is attached and compressed, it's too large to consider putting into this post.

    I was able to fix about 50 of them by including the -qt-zlib option and reconfiguring -qt. I also tried including the -xmlpatterns and -glib arguments to the configuration (as suggested by various google/bing searches I performed on the various undefined references), but this did not solve anything.

    Another facet: The Makefile for this application was not created by qmake, rather it was created by hand by the person who wrote the code.

    Right now after all the reading I've done I have it narrowed down to two potential sources of error:
    First, and probably most likely, I'm missing a module (or several) that is required for the successful building of this code. It looks like the biggest areas of undefined references are glib, font stuff, QPersistentModel, and QAbstractItemModel.

    The second source of error lies in the Makefile (I have attached it for completeness' sake), where I suppose the error would be that the correct libraries aren't being linked in.

    I know there are a lot of lines in the make.out.txt file, but there is heavy repetition so it's not impossible to read through.

    I've been trying to figure out the source of this error for a little over 3 weeks now, and it's starting to drive me insane, especially as it is likely to be a real simple mistake. If someone could help even just point me in the correct direction (whether its likely to be a problem with Qt or my system) I'd be extremely gratified. Thank you so much in advance, I'm deeply appreciative.

    It should also probably be noted that this static configuration of Qt has been used to sucessfully build other projects, at the moment it is just this single project giving me difficulties.

    Thanks!
    Attached Files Attached Files

Similar Threads

  1. Ignore-double post
    By Meastaway in forum Newbie
    Replies: 0
    Last Post: 19th November 2009, 18:51
  2. Undefined reference to crt
    By derektaprell in forum Installation and Deployment
    Replies: 0
    Last Post: 20th October 2009, 08:34
  3. how to add static library into qmake
    By Namrata in forum Qt Tools
    Replies: 1
    Last Post: 20th November 2007, 17:33
  4. error undefined reference ...............
    By amit_pansuria in forum Qt Programming
    Replies: 2
    Last Post: 8th June 2007, 14:28
  5. how to correctly compile threads support?
    By srhlefty in forum Installation and Deployment
    Replies: 9
    Last Post: 25th June 2006, 19:15

Tags for this Thread

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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.