mirror of
https://github.com/bkaradzic/bgfx.cmake.git
synced 2026-02-17 21:12:35 +01:00
Add tinyexr to build files
This commit is contained in:
@@ -126,7 +126,7 @@ if( BGFX_INSTALL )
|
||||
INCLUDES DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}"
|
||||
)
|
||||
if( NOT BGFX_LIBRARY_TYPE MATCHES "SHARED" )
|
||||
install( TARGETS bimg bx astc-codec astc edtaa3 etc1 etc2 iqa squish nvtt pvrtc
|
||||
install( TARGETS bimg bx astc-codec astc edtaa3 etc1 etc2 iqa squish nvtt pvrtc tinyexr
|
||||
EXPORT "${TARGETS_EXPORT_NAME}"
|
||||
LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}"
|
||||
ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}"
|
||||
|
||||
9
cmake/3rdparty/tinyexr.cmake
vendored
Normal file
9
cmake/3rdparty/tinyexr.cmake
vendored
Normal file
@@ -0,0 +1,9 @@
|
||||
if( TARGET tinyexr )
|
||||
return()
|
||||
endif()
|
||||
|
||||
file( GLOB_RECURSE TINYEXR_SOURCES ${BIMG_DIR}/3rdparty/tinyexr/*.c ${BIMG_DIR}/3rdparty/tinyexr/*.h )
|
||||
|
||||
add_library( tinyexr STATIC ${TINYEXR_SOURCES} )
|
||||
target_include_directories( tinyexr PUBLIC $<BUILD_INTERFACE:${BIMG_DIR}/3rdparty> $<BUILD_INTERFACE:${BIMG_DIR}/3rdparty/tinyexr/deps/miniz> )
|
||||
set_target_properties( tinyexr PROPERTIES FOLDER "bgfx/3rdparty" )
|
||||
@@ -18,6 +18,7 @@ include( cmake/3rdparty/iqa.cmake )
|
||||
include( cmake/3rdparty/libsquish.cmake )
|
||||
include( cmake/3rdparty/nvtt.cmake )
|
||||
include( cmake/3rdparty/pvrtc.cmake )
|
||||
include( cmake/3rdparty/tinyexr.cmake )
|
||||
|
||||
# Ensure the directory exists
|
||||
if( NOT IS_DIRECTORY ${BIMG_DIR} )
|
||||
@@ -38,7 +39,7 @@ target_include_directories( bimg
|
||||
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>)
|
||||
|
||||
# bimg dependencies
|
||||
target_link_libraries( bimg PUBLIC bx PRIVATE astc-codec astc edtaa3 etc1 etc2 iqa squish nvtt pvrtc )
|
||||
target_link_libraries( bimg PUBLIC bx PRIVATE astc-codec astc edtaa3 etc1 etc2 iqa squish nvtt pvrtc tinyexr )
|
||||
|
||||
# Put in a "bgfx" folder in Visual Studio
|
||||
set_target_properties( bimg PROPERTIES FOLDER "bgfx" )
|
||||
Reference in New Issue
Block a user