I recently started learning Qt, and that strange, fairly useless compilation error, "collect2: ld returned 1 exit status"
, got me stuck for a while. From a quick search I first found this was related to some kind of missing library… but it seems to be able to be pretty much any library. In my case, I eventually found out that this would appear after adding a QWebView, because I had forgotten to add:
QT += webkit
in my project file.
But this error message is actually just indicating that the linker failed. To find more helpful error messages, click on “compile output” at the bottom of the Qt Creator window.
0 Responses
Stay in touch with the conversation, subscribe to the RSS feed for comments on this post.