#-------------------------------------------------------------------
# This file is part of the CMake build system for OGRE
#     (Object-oriented Graphics Rendering Engine)
# For the latest info, see http://www.ogre3d.org/
#
# The contents of this file are placed in the public domain. Feel
# free to make use of it in any way you like.
#-------------------------------------------------------------------

# Configure Ogre HLMS User Interface (2D) for OpenGL 3.3+ and D3D11 build

PROJECT(OgreHlmsUnlit)

file(
    GLOB HEADER_FILES
    "${CMAKE_CURRENT_SOURCE_DIR}/include/*.h"
    "${CMAKE_CURRENT_SOURCE_DIR}/../Common/include/*.h"
    "${CMAKE_CURRENT_SOURCE_DIR}/../Common/include/*.inl"
)
file(
    GLOB SOURCE_FILES
    "${CMAKE_CURRENT_SOURCE_DIR}/src/*.cpp"
    "${CMAKE_CURRENT_SOURCE_DIR}/../Common/src/*.cpp"
)

include_directories(${CMAKE_CURRENT_SOURCE_DIR}/include)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/../Common/include)

ogre_add_library(OgreHlmsUnlit ${OGRE_COMP_LIB_TYPE} ${HEADER_FILES} ${SOURCE_FILES})
set_target_properties(OgreHlmsUnlit PROPERTIES VERSION ${OGRE_SOVERSION} SOVERSION ${OGRE_SOVERSION})
target_link_libraries(OgreHlmsUnlit OgreMain)

ogre_config_framework(OgreHlmsUnlit)
ogre_config_component(OgreHlmsUnlit)

install (DIRECTORY include/
        DESTINATION include/OGRE/Hlms/Unlit
        FILES_MATCHING PATTERN "*.h"
        )

# also install HLMS Common folder
install (DIRECTORY ../Common/include/
        DESTINATION include/OGRE/Hlms/Common
        FILES_MATCHING PATTERN "*.h" PATTERN "*.inl"
        )
