From 99b68bc2593d2b1a9dc6f176caee5ec909827c05 Mon Sep 17 00:00:00 2001 From: Lincoln Ramsay Date: Thu, 29 Sep 2011 17:46:01 +1000 Subject: Run qmake at "make docs" time doc.pri requires QT.xxx.variable variables but they are not set the first (and normally only) time qmake parses doc.pri. As a result, you can't build docs without first manually running "make qmake". This change adds an explicit dependency such that all of the doc commands (docs, online_docs, qch_docs, dita_docs) first force qmake to run and process doc.pri again. This ensures that the QT.xxx.variable variables have the appropriate values. Change-Id: I688c432284605e9f56e7597f564f1c50e972f059 Reviewed-on: http://codereview.qt-project.org/5779 Reviewed-by: Qt Sanity Bot Reviewed-by: Alex --- qtdoc.pro | 33 +++++++++++++++++++++++++++++++-- 1 file changed, 31 insertions(+), 2 deletions(-) (limited to 'qtdoc.pro') diff --git a/qtdoc.pro b/qtdoc.pro index 92aaf958..fd7dfe78 100644 --- a/qtdoc.pro +++ b/qtdoc.pro @@ -1,3 +1,32 @@ TEMPLATE = subdirs -SUBDIRS = tools # demos -include(doc/doc.pri) +SUBDIRS = tools doc # demos + +# Doc rules + +UPDATE_PRI = "echo \"MODULE_BUILD_DIR=$$OUT_PWD\" > $$OUT_PWD/qtdoc.pri" +UPDATE_PRI = $$replace(UPDATE_PRI, "/", $$QMAKE_DIR_SEP) +system($$UPDATE_PRI) +force_qmake.commands = $$UPDATE_PRI + +online_docs.CONFIG = recursive +online_docs.recurse_target = online_docs +online_docs.recurse = doc +online_docs.depends += force_qmake + +dita_docs.CONFIG = recursive +dita_docs.recurse_target = dita_docs +dita_docs.recurse = doc +dita_docs.depends += force_qmake + +qch_docs.CONFIG = recursive +qch_docs.recurse_target = qch_docs +qch_docs.recurse = doc +qch_docs.depends += force_qmake + +docs.CONFIG = recursive +docs.recurse_target = docs +docs.recurse = doc +docs.depends += force_qmake + +QMAKE_EXTRA_TARGETS += force_qmake online_docs qch_docs docs dita_docs + -- cgit v1.2.1