Skip to content

Commit 3bf2ecf

Browse files
committed
Allow querying for alternate Qt6 libexec directory
This is closer to how Qt6's moc.prf finds moc, i.e. ``` qtPrepareLibExecTool(QMAKE_MOC, moc) ... defineTest(qtPrepareLibExecTool) { isEmpty(instloc): instloc = "$$[QT_HOST_LIBEXECS]" qtPrepareTool($$1, $$2, $$3, $$4, $$instloc) } ```
1 parent a06ca9e commit 3bf2ecf

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

scripts/src/osd/modules.lua

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -384,12 +384,16 @@ function qtdebuggerbuild()
384384
if _OPTIONS["QT_HOME"]~=nil then
385385
MOCTST = backtick(_OPTIONS["QT_HOME"] .. "/bin/moc --version 2>/dev/null")
386386
if (MOCTST=='') then
387-
MOCTST = backtick(_OPTIONS["QT_HOME"] .. "/libexec/moc --version 2>/dev/null")
387+
local qt_host_libexecs = backtick(_OPTIONS["QT_HOME"] .. "/bin/qmake -query QT_HOST_LIBEXECS")
388+
if (qt_host_libexecs=='') then
389+
qt_host_libexecs = _OPTIONS["QT_HOME"] .. "/libexec"
390+
end
391+
MOCTST = backtick(qt_host_libexecs .. "/moc --version 2>/dev/null")
388392
if (MOCTST=='') then
389393
print("Qt's Meta Object Compiler (moc) wasn't found!")
390394
os.exit(1)
391395
else
392-
MOC = _OPTIONS["QT_HOME"] .. "/libexec/moc"
396+
MOC = qt_host_libexecs .. "/moc"
393397
end
394398
else
395399
MOC = _OPTIONS["QT_HOME"] .. "/bin/moc"

0 commit comments

Comments
 (0)