From 931c16376b5ac82ab8e759764d63022b5278dd3d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89mile=20Gr=C3=A9goire?= Date: Thu, 13 Apr 2017 20:45:04 +0200 Subject: [PATCH] Fixes to CMake folder support. --- CMakeLists.txt | 3 +++ src/Magnum/Platform/CMakeLists.txt | 1 + 2 files changed, 4 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index cb717e2f3..07d1a8385 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -35,6 +35,9 @@ if(POLICY CMP0028) cmake_policy(SET CMP0028 NEW) endif() +# Use folders for nice tree in Visual Studio and XCode +set_property(GLOBAL PROPERTY USE_FOLDERS ON) + set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${PROJECT_SOURCE_DIR}/modules/") # Find Corrade first so we can check on the target diff --git a/src/Magnum/Platform/CMakeLists.txt b/src/Magnum/Platform/CMakeLists.txt index 4828bf280..69d24b1b7 100644 --- a/src/Magnum/Platform/CMakeLists.txt +++ b/src/Magnum/Platform/CMakeLists.txt @@ -760,6 +760,7 @@ if(NEED_WGLCONTEXT OR WITH_WGLCONTEXT) if(BUILD_STATIC_PIC) set_target_properties(MagnumWglContextObjects PROPERTIES POSITION_INDEPENDENT_CODE ON) endif() + set_target_properties(MagnumWglContextObjects PROPERTIES FOLDER "Magnum/Platform") # Also create proper static library, if requested if(WITH_WGLCONTEXT)