add vcpkg-cmake-wrapper for irrlicht (#7296)

This commit is contained in:
DailyShana 2019-07-18 07:26:18 +08:00 committed by Phil Christensen
parent 709e042134
commit 835d3de78b
3 changed files with 15 additions and 1 deletions

View File

@ -1,5 +1,5 @@
Source: irrlicht
Version: 1.8.4
Version: 1.8.4-1
Description: Irrlicht lightning fast 3d engine
Build-Depends: zlib, libpng, bzip2, libjpeg-turbo

View File

@ -90,5 +90,8 @@ freely, subject to the following restrictions:
vcpkg_copy_pdbs()
if(VCPKG_LIBRARY_LINKAGE STREQUAL "static")
file(COPY ${CMAKE_CURRENT_LIST_DIR}/vcpkg-cmake-wrapper.cmake DESTINATION ${CURRENT_PACKAGES_DIR}/share/irrlicht)
endif()
# Post-build test for cmake libraries
vcpkg_test_cmake(PACKAGE_NAME irrlicht)

View File

@ -0,0 +1,11 @@
_find_package(${ARGS})
find_package(ZLIB REQUIRED)
find_package(PNG REQUIRED)
find_package(JPEG REQUIRED)
find_package(BZip2 REQUIRED)
if(TARGET Irrlicht::Irrlicht)
set_property(TARGET Irrlicht::Irrlicht APPEND PROPERTY INTERFACE_LINK_LIBRARIES ZLIB::ZLIB PNG::PNG JPEG::JPEG BZip2::BZip2)
endif()
if(IRRLICHT_LIBRARIES)
list(APPEND IRRLICHT_LIBRARIES ${ZLIB_LIBRARIES} ${PNG_LIBRARIES} ${JPEG_LIBRARIES} ${BZIP2_LIBRARIES})
endif()