1CMAKE_AUTOMOC_MACRO_NAMES 2---------------------------- 3 4.. versionadded:: 3.10 5 6:ref:`Semicolon-separated list <CMake Language Lists>` list of macro names used by 7:variable:`CMAKE_AUTOMOC` to determine if a C++ file needs to be 8processed by ``moc``. 9 10This variable is used to initialize the :prop_tgt:`AUTOMOC_MACRO_NAMES` 11property on all the targets. See that target property for additional 12information. 13 14The default value is ``Q_OBJECT;Q_GADGET;Q_NAMESPACE;Q_NAMESPACE_EXPORT``. 15 16Example 17^^^^^^^ 18Let CMake know that source files that contain ``CUSTOM_MACRO`` must be ``moc`` 19processed as well:: 20 21 set(CMAKE_AUTOMOC ON) 22 list(APPEND CMAKE_AUTOMOC_MACRO_NAMES "CUSTOM_MACRO") 23