I'm trying to create a NewConfiguration for my project:
set (CMAKE_CONFIGURATION_TYPES "Release;RelWithDebInfo;Debug;NewConfiguration" CACHE STRING "Configurations" FORCE) But when I run CMake, I have multiple errors:
CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly. Missing variable is: CMAKE_SHARED_LINKER_FLAGS_NEWCONFIGURATION CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly. Missing variable is: CMAKE_CXX_FLAGS_NEWCONFIGURATION I think I'm missing something...
I also followed CMake FAQ:
if(CMAKE_CONFIGURATION_TYPES) set(CMAKE_CONFIGURATION_TYPES Release RelWithDebInfo Debug NewConfiguration) set(CMAKE_CONFIGURATION_TYPES "${CMAKE_CONFIGURATION_TYPES}" CACHE STRING "Reset the configurations to what we need" FORCE) endif() But same errors...
EDIT:
If I do:
SET( CMAKE_CXX_FLAGS_PLAYERVIEWER "-Wall -Wabi" CACHE STRING "Flags used by the C++ compiler during maintainer builds." FORCE ) SET( CMAKE_C_FLAGS_PLAYERVIEWER "-Wall -pedantic" CACHE STRING "Flags used by the C compiler during maintainer builds." FORCE ) SET( CMAKE_EXE_LINKER_FLAGS_PLAYERVIEWER "-Wl,--warn-unresolved-symbols,--warn-once" CACHE STRING "Flags used for linking binaries during maintainer builds." FORCE ) SET( CMAKE_SHARED_LINKER_FLAGS_PLAYERVIEWER "-Wl,--warn-unresolved-symbols,--warn-once" CACHE STRING "Flags used by the shared libraries linker during maintainer builds." FORCE ) set (CMAKE_CONFIGURATION_TYPES "Release;RelWithDebInfo;Debug;PlayerViewer" CACHE STRING "Configurations" FORCE) It creates the new configuration, but I can not compile. I think flags are not correct. I am using Visual Studio 2008.
Thank you :)