
# Build Type Option
if(LIBRARY_BUILD_TYPE)
    set (LIBRARY_BUILD_TYPE ${LIBRARY_BUILD_TYPE} CACHE STRING "How to build the engine <STATIC/MODULE_DYNAMIC/FULL_DYNAMIC>")
else()
    set (LIBRARY_BUILD_TYPE MODULE_DYNAMIC CACHE STRING "How to build the engine <STATIC/MODULE_DYNAMIC/FULL_DYNAMIC>")
endif()
set_property(CACHE LIBRARY_BUILD_TYPE PROPERTY STRINGS STATIC MODULE_DYNAMIC FULL_DYNAMIC)

# Determine Build Type Variables
if(LIBRARY_BUILD_TYPE STREQUAL "STATIC")
    set(ENGINE_BUILD_TYPE STATIC)
    set(MODULE_BUILD_TYPE STATIC)
elseif(LIBRARY_BUILD_TYPE STREQUAL "FULL_DYNAMIC")
    set(ENGINE_BUILD_TYPE SHARED)
    set(MODULE_BUILD_TYPE SHARED)
else()
    set(ENGINE_BUILD_TYPE STATIC)
    set(MODULE_BUILD_TYPE SHARED)
endif()

# Default Install Locations
if(NOT ENGINE_INSTALL_LOCATION)
    set(ENGINE_INSTALL_LOCATION ${CMAKE_SOURCE_DIR}/engine)
endif(NOT ENGINE_INSTALL_LOCATION)
if(NOT EXTERNAL_INSTALL_LOCATION)
    set(EXTERNAL_INSTALL_LOCATION ${CMAKE_SOURCE_DIR}/external)
endif(NOT EXTERNAL_INSTALL_LOCATION)

# Specify Include and Link Directories
include_directories(${ENGINE_INSTALL_LOCATION}/include)
include_directories(${EXTERNAL_INSTALL_LOCATION}/include)
link_directories(${ENGINE_INSTALL_LOCATION}/lib)
link_directories(${EXTERNAL_INSTALL_LOCATION}/lib)

