path: root/examples/widgets/gallery
diff options
authorAlexandru Croitor <>2020-10-26 16:07:44 +0100
committerAlexandru Croitor <>2020-10-27 12:49:39 +0100
commit65fe5b2ce22797389aa074ef2c30e873a3c38d48 (patch)
tree2b8a9ef9035ab6cb6cd5ab7a07da0e9851c3ef9d /examples/widgets/gallery
parent1e904ab342c1aaabbef67cbcc25cf3de9e35e755 (diff)
CMake: pro2cmake: Handle CONFIG+=console app_bundle in examples
Now that qt_add_executable doesn't set the WIN32_EXECUTABLE and MACOSX_BUNDLE properties anymore, pro2cmake needs to look at the qmake example projects and generate appropriate set_target_properties calls. The relevant CONFIG entries to look at are windows, console, app_bundle and cmdline. CONFIG += windows implies 'subsystem windows' on Windows, which maps to WIN32_EXECUTABLE == TRUE. CONFIG += console implies 'subsystem console' on Windows, which maps to WIN32_EXECUTABLE == FALSE. Aka the opposite of CONFIG += windows. Whichever is the last one set, cancels out the other one. CONFIG += app_bundle implies a macOS bundle executable, which maps to MACOSX_BUNDLE == TRUE. CONFIG += cmdline is the same as CONFIG += console and CONFIG -= app_bundle, aka WIN32_EXECUTABLE and MACOSX_BUNDLE set to false. In qmake, if no CONFIG is specified in an example project, the default is CONFIG += windows app_bundle, aka WIN32_EXECUTABLE and MACOSX_BUNDLE set to true. The script uses a heuristic to try and not write the properties for every single subscope, except for values different from the default. This is not strictly correct, but it covers most use cases, and keeps the generated projects a bit cleaner. Task-number: QTBUG-87664 Task-number: QTBUG-86827 Change-Id: If05606ec3205e0fe7c1803c07e114d9fd9c3e4f7 Reviewed-by: Joerg Bornemann <>
Diffstat (limited to 'examples/widgets/gallery')
0 files changed, 0 insertions, 0 deletions