Qt+boost+Wt = problems...



  • Hello
    I've struggled to get Wt with Qt and so far I've managed to install the boost libraries and Wt.
    But when I try compile a Qt project in QtCreator (or terminal), it fails. With the following errors:

    Richard-Salins-MacBook-Pro:wtex richardsalin$ make
    g++ -headerpad_max_install_names -arch x86_64 -Xarch_x86_64 -mmacosx-version-min=10.5 -o CppWtMenu main.o menuapplication.o menuwidget.o -F/Users/richardsalin/QtSDK/Desktop/Qt/473/gcc/lib -L/Users/richardsalin/QtSDK/Desktop/Qt/473/gcc/lib -lwt -lwthttp -framework QtCore
    Undefined symbols for architecture x86_64:
    "boost::signals::connection::~connection()", referenced from:
    MenuWidget::MenuWidget()in menuwidget.o
    MenuWidget::MenuWidget()in menuwidget.o
    boost::signals::detail::slot_base::data_t::~data_t()in menuwidget.o
    "boost::signals::detail::slot_base::create_connection()", referenced from:
    boost::slot<boost::function1<void, Wt::WMouseEvent> >::slot<boost::_bi::bind_t<void, boost::_mfi::mf0<void, MenuWidget>, boost::_bi::list1<boost::_bi::value<MenuWidget*> > > >(boost::_bi::bind_t<void, boost::_mfi::mf0<void, MenuWidget>, boost::_bi::list1<boost::_bi::value<MenuWidget*> > > const&)in menuwidget.o
    "boost::signals::detail::signal_base_impl::connect_slot(boost::any const&, boost::signals::detail::stored_group const&, boost::shared_ptrboost::signals::detail::slot_base::data_t, boost::signals::connect_position)", referenced from:
    boost::signal1<void, Wt::WMouseEvent, boost::last_value<void>, int, std::less<int>, boost::function1<void, Wt::WMouseEvent> >::connect(boost::slot<boost::function1<void, Wt::WMouseEvent> > const&, boost::signals::connect_position)in menuwidget.o
    ld: symbol(s) not found for architecture x86_64
    collect2: ld returned 1 exit status

    The example is a direct copy paste from: http://www.richelbilderbeek.nl/CppWtExample1.htm.
    I'd really like to add capabilites provided by Wt to my Qt project, but currently I'm stuck. I'm using a Mac osx Lion platform. I'd really appreciate any assistance. Thank you!
    Best regards
    Richard



  • Have you add following line

    @
    CONFIG += no_keywords
    @

    to your XXX.pro file?



  • ...no, but unfortunately it didn't help. :( Thanks anyway. Still open for further suggestions.
    -Richard

    ps. This is my pro file in use (a direct example copy/paste + "no_keywords"):

    @QT += core
    QT -= gui
    LIBS += -lwt -lwthttp

    QMAKE_CXXFLAGS += -DNDEBUG

    TARGET = CppWtMenu
    CONFIG += console
    CONFIG -= app_bundle
    CONFIG += no_keywords
    TEMPLATE = app

    SOURCES += main.cpp
    menuapplication.cpp
    menuwidget.cpp

    HEADERS +=
    menuapplication.h
    menuwidget.h@



  • For what architecture did you build the boost an Wt libraries? The universal binaries must at least contain every architecture you build your application for.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.