More tweaks to MSVC solution folders.

develop
Petr Mrázek 2012-03-13 21:05:25 +01:00 committed by Quietust
parent 778a1cd6bb
commit 36e3aada8e
1 changed files with 6 additions and 1 deletions

@ -15,12 +15,17 @@ endif(CMAKE_CONFIGURATION_TYPES)
# Check for MFC! # Check for MFC!
find_package(MFC QUIET) find_package(MFC QUIET)
if(MFC_FOUND OR (NOT MSVC)) if(MFC_FOUND OR (NOT MSVC))
SET_PROPERTY(GLOBAL PROPERTY USE_FOLDERS ON)
OPTION(CMAKE_USE_FOLDERS "Enable folder grouping of projects in IDEs." ON) OPTION(CMAKE_USE_FOLDERS "Enable folder grouping of projects in IDEs." ON)
else() else()
OPTION(CMAKE_USE_FOLDERS "Enable folder grouping of projects in IDEs." OFF) OPTION(CMAKE_USE_FOLDERS "Enable folder grouping of projects in IDEs." OFF)
endif() endif()
if(CMAKE_USE_FOLDERS)
SET_PROPERTY(GLOBAL PROPERTY USE_FOLDERS ON)
else()
SET_PROPERTY(GLOBAL PROPERTY USE_FOLDERS OFF)
endif()
# macro for setting up IDE folders without nasty IF()s everywhere # macro for setting up IDE folders without nasty IF()s everywhere
MACRO(IDE_FOLDER target folder) MACRO(IDE_FOLDER target folder)
if(CMAKE_USE_FOLDERS) if(CMAKE_USE_FOLDERS)