When compiling for an embedded system that has Qt configured to use the libts touch screen library customers have reported linking errors like the one below:
/home/user/squish/arm-fsl-linux-gnueabi/bin/../lib/gcc/arm-fsl-linux- gnueabi/4.4.4/../../../../arm-fsl-linux-gnueabi/bin/ld: warning: libts-1.0.so.0, needed by /home/user/qt/qt-arm/lib/libQtGui.so, not found (try using -rpath or -rpath-link) /home/user/qt/qt-arm/lib/libQtGui.so: undefined reference to `ts_read_raw' (and so on)
Possible Cause and Suggested Solution¶
This problem appears to be caused by the fact that the QtGui dependency libts-1.0.so is not found in a standard library search path. Thus linking against libQtGui.so only is not sufficient.
A quick and dirty solution to overcome this problem consists of adding the full path to the library as a new entry of the config[LIBQT] array found in the Build.conf created by the configure.
From automated builds this element can also be added like this:
./configure (other options) --with-qt-extra-lflags=/home/user/squish/qt/ts/lib/libts-1.0.so.0