开发者

Cannot build Qt SDK from source on Mac OS X

I've been trying to build the SDK statically on Mac OS X but I run into errors that don't make sense to me. Here is my configure command:

sh configure -static -opensource -universal

Then I build the framework using:

sudo make sub-src

The build process works well initially but after some time, I start getting errors like the ones below, there are hundred of these:

ranlib: for architecture: i386 file: /usr/local/Trolltech/Qt-4.7.1/lib/libQtScript.a(ARMAssembler.o) has no symbols
ranlib: for architecture: i386 file: /usr/local/Trolltech/Qt-4.7.1/lib/libQtScript.a(MacroAssemblerARM.o) has no symbols

Then after some time, the build process hits this command:

g++ -headerpad_max_install_names -Xarch_i386 -mmacosx-version-min=10.4 -Xarch_ppc -mmacosx-version-min=10.4 -arch i386 -arch ppc -all_load -o ../../../../bin/Assistant.app/Contents/MacOS/Assistant .obj/debug-static/fontpanel.o .obj/debug-static/aboutdialog.o .obj/debug-static/bookmarkdialog.o .obj/debug-static/bookmarkfiltermodel.o .obj/debug-static/bookmarkitem.o .obj/debug-static/bookmarkmanager.o .obj/debug-static/bookmarkmanagerwidget.o .obj/debug-static/bookmarkmodel.o .obj/debug-static/centralwidget.o .obj/debug-static/cmdlineparser.o .obj/debug-static/contentwindow.o .obj/debug-static/findwidget.o .obj/debug-static/filternamedialog.o .obj/debug-static/helpenginewrapper.o .obj/debug-static/helpviewer.o .obj/debug-static/indexwindow.o .obj/debug-static/installdialog.o .obj/debug-static/main.o .obj/debug-static/mainwindow.o .obj/debug-static/preferencesdialog.o .obj/debug-static/qtdocinstaller.o .obj/debug-static/remotecontrol.o .obj/debug-static/searchwidget.o .obj/debug-static/topicchooser.o .obj/debug-static/xbelsupport.o .obj/debug-static/collectionconfiguration.o .obj/debug-static/helpviewer_qtb.o .obj/debug-static/moc_fontpanel.o .obj/debug-static/moc_aboutdialog.o .obj/debug-static/moc_bookmarkdialog.o .obj/debug-static/moc_bookmarkfiltermodel.o .obj/debug-static/moc_bookmarkmanager.o .obj/debug-static/moc_bookmarkmanagerwidget.o .obj/debug-static/moc_bookmarkmodel.o .obj/debug-static/moc_centralwidget.o .obj/debug-static/moc_contentwindow.o .obj/debug-static/moc_findwidget.o .obj/debug-static/moc_filternamedialog.o .obj/debug-static/moc_helpenginewrapper.o .obj/debug-static/moc_indexwindow.o .obj/debug-static/moc_installdialog.o .obj/debug-static/moc_mainwindow.o .obj/debug-static/moc_preferencesdialog.o .obj/debug-static/moc_qtdocinstaller.o .obj/debug-static/moc_remotecontrol.o .obj/debug-static/moc_searchwidget.o .obj/debug-static/moc_topicchooser.o .obj/debug-static/moc_helpviewer_qtb.o .obj/debug-static/qrc_assistant.o .obj/debug-static/qrc_assistant_images.o    -L/Users/laurent/.Trash/qt-src-4.7.1/lib -L/Users/laurent/.Trash/qt-src-4.7.1/plugins/sqldrivers -lQtHelp_debug -L/Users/laurent/.Trash/qt-src-4.7.1/lib -lQtCLucene_debug -L/usr/local/Trolltech/Qt-4.7.1/plugins/sqldrivers -lqsqlite_debug -lQtSql_debug -lQtXml_debug -lQtGui_debug -framework Carbon -framework AppKit -lQtNetwork_debug -framework SystemConfiguration -framework CoreFoundation -lQtCore_debug -lz -lm -framework ApplicationServices

which is followed by hundreds of these lines:

ld: warning: qt_noop()    has different visibility (hidden) in /Users/laurent/.Trash/qt-src-4.7.1/lib/libQtHelp_debug.a(qhelpenginecore.o) and开发者_运维问答 (default) in .obj/debug-static/fontpanel.o
ld: warning: QBool::operator void const*() consthas different visibility (hidden) in /Users/laurent/.Trash/qt-src-4.7.1/lib/libQtHelp_debug.a(qhelpenginecore.o) and (default) in .obj/debug-static/fontpanel.o

after that, I get many of these:

Undefined symbols for architecture ppc:
  "QCLuceneStandardAnalyzer::QCLuceneStandardAnalyzer()", referenced from:
      fulltextsearch::clucene::QHelpSearchIndexWriter::optimizeIndex()      in libQtHelp_debug.a(qhelpsearchindexwriter_clucene.o)
      fulltextsearch::clucene::QHelpSearchIndexWriter::run()     in libQtHelp_debug.a(qhelpsearchindexwriter_clucene.o)
      fulltextsearch::clucene::QHelpSearchIndexReaderClucene::boostSearchHits(QHelpEngineCore const&, QList >&, QList const&)in libQtHelp_debug.a(qhelpsearchindexreader_clucene.o)
      fulltextsearch::clucene::QHelpSearchIndexReaderClucene::run()     in libQtHelp_debug.a(qhelpsearchindexreader_clucene.o)

At that point, the build process stops with this error:

ld: symbol(s) not found for architecture ppc
collect2: ld returned 1 exit status
lipo: can't open input file: /var/tmp//cc5nBJvn.out (No such file or directory)
make[4]: *** [../../../../bin/Assistant.app/Contents/MacOS/Assistant] Error 1
make[3]: *** [sub-assistant-install_subtargets-ordered] Error 2
make[2]: *** [sub-tools-install_subtargets-ordered] Error 2
make[1]: *** [sub-assistant-install_subtargets-ordered] Error 2
make: *** [sub-tools-install_subtargets-ordered] Error 2

My config is Snow Leopard and I'm building from the source downloaded there: http://get.qt.nokia.com/qt/source/qt-everywhere-opensource-src-4.7.1.tar.gz

Can anybody see what could be the problem? I've been working on this for hours and can't figure it out, so I would really appreciate any advice.


Your problem:

ld: symbol(s) not found for architecture ppc

If you build for 10.6, AFAIK PPC is not supported. If you want to build for PPC, then you'll probably need to build for a different target version of OS X - 10.4 or 10.5.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜