CMP0143ΒΆ

Added in version 3.26.

USE_FOLDERS global property is treated as ON by default.

When using CMake 3.25 or earlier, USE_FOLDERS is treated as OFF by default unless projects enable the feature. For example:

cmake_minimum_required(VERSION 3.25)
project(foobar LANGUAGES CXX)
set_property(GLOBAL PROPERTY USE_FOLDERS ON)

CMake 3.26 and later prefer to enable the feature by default.

Note that it is the policy setting at the end of the top level CMakeLists.txt file that matters. The policy setting applies globally to the whole project.

This policy provides compatibility with projects that have not been updated to expect enabling of folders. Enabling folders causes projects to appear differently in IDEs.

This policy was introduced in CMake version 3.26. It may be set by cmake_policy() or cmake_minimum_required(). If it is not set, CMake does not warn, and uses OLD behavior.

Note

The OLD behavior of a policy is deprecated by definition and may be removed in a future version of CMake.