Reputation: 3470
I am trying to add build settings for a custom build configuration.
By default Qt Creator creates debug
and release
configurations (http://doc.qt.digia.com/qtcreator-2.4/creator-build-settings.html).
For those configs you can add custom build settings. For ex:
release: DESTDIR = $${build_root_dir}/release
debug: DESTDIR = $${build_root_dir}/debug
I created another build configuration called debug_menu_active
in Qt Creator.
And I'd like to use the same kind of statements:
debug_menu_active: DEFINES += FORCE_ACTIVE_MENU_DEBUG
debug_menu_active: DESTDIR = $${build_root_dir}/debug_menu_active
Unfortunately it doesn't work message("DEFINES: "$${DEFINES})
gives:
Project MESSAGE: DEFINES :UNICODE QT_LARGEFILE_SUPPORT
I think I need to define something else, but I have no clue what it could be.
Could someone help me with this?
Thanks!
I tested @svlasov answer, but unfortunately it breaks the compilation:
qtinternal\moc\moc_scenario.cpp:10:154: error: scenario.h: No such file or directory
qtinternal\moc\moc_scenario.cpp:12:2: error: #error "The header file 'scenario.h' doesn't include <QObject>."
qtinternal\moc\moc_scenario.cpp:20: error: expected constructor, destructor, or type conversion before 'static'
qtinternal\moc\moc_scenario.cpp:48: error: 'scenario' has not been declared
qtinternal\moc\moc_scenario.cpp:48: error: variable or field 'qt_static_metacall' declared void
qtinternal\moc\moc_scenario.cpp:48: error: 'QObject' was not declared in this scope
qtinternal\moc\moc_scenario.cpp:48: error: '_o' was not declared in this scope
qtinternal\moc\moc_scenario.cpp:48: error: 'QMetaObject' has not been declared
qtinternal\moc\moc_scenario.cpp:48: error: expected primary-expression before 'int'
qtinternal\moc\moc_scenario.cpp:48: error: expected primary-expression before 'void'
Here is how I did it:
Upvotes: 4
Views: 4216
Reputation: 10455
Under Build Steps
, for qmake
step set Additional arguments
as:
CONFIG+=debug_menu_active
Upvotes: 4