# Set build directories
SET( EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin )
SET( LIBRARY_OUTPUT_PATH ${PROJECT_BINARY_DIR}/lib )

# Logging level
IF(OGS_DISABLE_LOGGING)
	SET(OGS_LOG_LEVEL LOGOG_LEVEL_NONE)
ENDIF()

IF(NOT DEFINED OGS_LOG_LEVEL)
	IF(CMAKE_BUILD_TYPE STREQUAL "Debug")
		ADD_DEFINITIONS(-DLOGOG_LEVEL=LOGOG_LEVEL_DEBUG)
	ELSE()
		ADD_DEFINITIONS(-DLOGOG_LEVEL=LOGOG_LEVEL_INFO)
	ENDIF() # CMAKE_BUILD_TYPE = Debug
ELSE()
	ADD_DEFINITIONS(-DLOGOG_LEVEL=${OGS_LOG_LEVEL})
ENDIF() # NOT DEFINED OGS_LOG_LEVEL

# Enable Visual Studio project folder grouping
SET_PROPERTY(GLOBAL PROPERTY USE_FOLDERS ON)

INCLUDE_DIRECTORIES( ${CMAKE_CURRENT_SOURCE_DIR} )

# Check if this project is included in another
IF(NOT CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
	SET(IS_SUBPROJECT ON INTERNAL)
ENDIF()