Go back to Richel Bilderbeek's homepage.
Go back to Richel Bilderbeek's C++ page.
link error: cannot find -lQtCore and I want it.
Caused while trying to solve the Qt FAQ How to cross-compile a Qt Creator project from Ubuntu to a windows executable?.
Operating system: Ubuntu 10.04 LTS Lucid Lynx
IDE: Qt Creator 2.0.0
Project type: GUI application
Libraries used:
#------------------------------------------------- |
#include <iostream> |
A makefile is successfully produced. When calling make in the makefile's folder, the following command was shown to give the error:
make |
Adding one,two or all of these lines below did not solve the problem:
LIBS += -L/usr/lib -lQtCore |
If, in the makefile I change the following line:
LIBS = $(SUBLIBS) -L/usr/lib -L/usr/lib -L/usr/local/lib -lQtCore -lpthread
|
To this line:
LIBS = $(SUBLIBS)
|
An then call make:
make |
A Windows executable is produced.
Unknown.
My hypothesis: when cross-compiling, one needs to cros-compile the libraries first! In this case, QtCore!
Go back to Richel Bilderbeek's C++ page.
Go back to Richel Bilderbeek's homepage.