1
0
mirror of https://github.com/RPCS3/rpcs3.git synced 2024-11-22 02:32:36 +01:00

3rdparty: Add option to build against system flatbuffers

Signed-off-by: Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
This commit is contained in:
Emmanuel Gil Peyrot 2021-05-17 17:03:34 +02:00 committed by Megamouse
parent f6a70e2e08
commit 8f271861f5

View File

@ -26,7 +26,12 @@ target_include_directories(3rdparty_zlib INTERFACE ${ZLIB_INCLUDE_DIR})
add_subdirectory(7z EXCLUDE_FROM_ALL)
add_library(3rdparty_flatbuffers INTERFACE)
target_include_directories(3rdparty_flatbuffers INTERFACE flatbuffers/include)
if (USE_SYSTEM_FLATBUFFERS)
pkg_check_modules(FLATBUFFERS REQUIRED IMPORTED_TARGET flatbuffers>=2.0.0)
target_link_libraries(3rdparty_flatbuffers INTERFACE PkgConfig::FLATBUFFERS)
else()
target_include_directories(3rdparty_flatbuffers INTERFACE flatbuffers/include)
endif()
# libPNG
add_subdirectory(libpng EXCLUDE_FROM_ALL)