From 1e6b4f8483daa56e583c8af763d028ba4299f024 Mon Sep 17 00:00:00 2001 From: John Bowler Date: Sun, 8 Oct 2023 12:08:59 -0700 Subject: [PATCH] make generate This adds 'make generate' which correctly handles rebuilding of the resources if they have been modified before generating the generated_cpp directory. This fixes the problem where editing typesystem_*.xml then running pythonqt_generator does nothing; the typesystem_*.xml files are compiled into the generator and 'make' must be used to rebuild the generator before the changes can be seen. Signed-off-by: John Bowler --- generator/generator.pro | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/generator/generator.pro b/generator/generator.pro index c159e23b9..1f2145249 100644 --- a/generator/generator.pro +++ b/generator/generator.pro @@ -13,7 +13,7 @@ HEADERS += \ shellimplgenerator.h \ shellheadergenerator.h \ setupgenerator.h - + SOURCES += \ generatorsetqtscript.cpp \ metaqtscriptbuilder.cpp \ @@ -22,3 +22,9 @@ SOURCES += \ shellimplgenerator.cpp \ shellheadergenerator.cpp \ setupgenerator.cpp + +#The generate target is NOT built automatically! +QMAKE_EXTRA_TARGETS += generate + +generate.depends = $$TARGET +generate.commands = ./$$TARGET --qt-headers="$$[QT_INSTALL_HEADERS]" --core-error --output-directory="."