ablu added a comment.

  The SYSROOT variable should not (directly) impact that. The install directory 
is configured by ECM_MKSPECS_INSTALL_DIR, which usually will point to 
/usr/lib/mkspecs/modules/ on Linux. For a cross-compile toolchain it will 
however be additionally prefixed with separate path. But Qt and qmake will also 
be configured with that prefix so those know to lookup the mkspecs dir under 
that prefix. Issuing QT += <module> can then trigger the including of the 
include and lib paths from the .pri generated by this code. So the case I am 
trying to fix with this patch is the case where the .pri is found (so 
ECM_MKSPECS_INSTALL_DIR was specified correctly) but now the libs and include 
paths are pointing to /usr/{include,lib} and not to 
<cross-compile-prefix>/usr/{include,lib}. Now since <cross-compile-prefix> can 
differ depending on the installation dir of the tool chain it may not be 
possible to know that path during compile / install time. However, we can 
assume that Qt / qmake will know about the sysroot (which is the prefix 
essentially). So as long qmake is configured for the cross compile our Qt 
module now should be too.

REPOSITORY
  R240 Extra CMake Modules

REVISION DETAIL
  https://phabricator.kde.org/D29096

To: ablu
Cc: kossebau, kde-frameworks-devel, kde-buildsystem, LeGast00n, cblack, 
bencreasy, michaelh, ngraham, bruns

Reply via email to