Skip to content

Commit

Permalink
syncqt: Fix resolution of injected headers for external modules
Browse files Browse the repository at this point in the history
Injected headers were made relative to MODULE_BASE_OUTDIR by syncqt
and made absolute by resolving against REAL_MODULE_BASE_OUTDIR.
This breaks for modules that reside outside the original Qt source
tree (if the directory depth doesn't coincidentally match).

Now, we resolve injected headers against build_basedir, which is
REAL_MODULE_BASE_OUTDIR. To emphasize the equivalence of
REAL_MODULE_BASE_OUTDIR and syncqt's build_basedir, use the former for
syncqt's -output argument.

This commit amends 2aa779e.

Fixes: QTBUG-70587
Change-Id: I2935d87d7ee681fa4aa795a270b94ab7a43abe59
Reviewed-by: Dominik Holland <[email protected]>
Reviewed-by: Oliver Wolff <[email protected]>
  • Loading branch information
jobor committed Apr 23, 2019
1 parent 6a21dc9 commit c291724
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion bin/syncqt.pl
Original file line number Diff line number Diff line change
Expand Up @@ -1111,7 +1111,7 @@ ($$)
elsif (!$shadow) {
$pri_install_pfiles.= "$pri_install_iheader ";;
}
$pri_injections .= fixPaths($iheader, $out_basedir)
$pri_injections .= fixPaths($iheader, $build_basedir)
.":".($no_stamp ? "^" : "").fixPaths($oheader, "$out_basedir/include/$lib")
.$injection." " if ($shadow);
}
Expand Down
2 changes: 1 addition & 1 deletion mkspecs/features/qt_module_headers.prf
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ load(qt_build_paths)
QMAKE_SYNCQT += -module $$mod
QMAKE_SYNCQT += \
-version $$VERSION -outdir $$system_quote($$MODULE_BASE_OUTDIR) \
-builddir $$system_quote($$shadowed($$MODULE_BASE_INDIR)) $$MODULE_SYNCQT_DIR
-builddir $$system_quote($$REAL_MODULE_BASE_OUTDIR) $$MODULE_SYNCQT_DIR
!silent: message($$QMAKE_SYNCQT)
system($$QMAKE_SYNCQT)|error("Failed to run: $$QMAKE_SYNCQT")

Expand Down

0 comments on commit c291724

Please sign in to comment.