Skip to content
Permalink
Browse files

tinygltf is a proper external now

  • Loading branch information
reinago committed Mar 23, 2020
1 parent 69e6632 commit bf34de58aaeded5e87adc2741e5f0db3850510fb
@@ -107,6 +107,16 @@ function(require_external NAME)
GIT_TAG "v1.3.0"
INCLUDE_DIR "include")

# tinygltf
elseif(NAME STREQUAL "tinygltf")
if(TARGET tinygltf)
return()
endif()

add_external_headeronly_project(tinygltf
GIT_REPOSITORY https://github.com/syoyo/tinygltf.git
GIT_TAG "v2.2.0")

# Built libraries #####################################################

# adios2
@@ -16,6 +16,7 @@ if(BUILD_${EXPORT_NAME}_PLUGIN)
# Add externals.
require_external(quickhull)
require_external(tinyobjloader)
require_external(tinygltf)

# Collect source files
file(GLOB_RECURSE public_header_files RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" "include/*.h")
@@ -28,11 +29,10 @@ if(BUILD_${EXPORT_NAME}_PLUGIN)
set_target_properties(${PROJECT_NAME} PROPERTIES SUFFIX ".mmplg")
target_compile_definitions(${PROJECT_NAME} PRIVATE ${EXPORT_NAME}_EXPORTS)
target_include_directories(${PROJECT_NAME} PUBLIC $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/external>
"src")
target_link_libraries(${PROJECT_NAME}
PRIVATE core
PUBLIC quickhull tinyobjloader compositing_gl)
PUBLIC quickhull tinyobjloader tinygltf compositing_gl)

if(MSVC)
target_compile_definitions(${PROJECT_NAME} PRIVATE NOMINMAX)

0 comments on commit bf34de5

Please sign in to comment.
You can’t perform that action at this time.