diff options
| author | Jack·Boos·Yu <47264268+JackBoosY@users.noreply.github.com> | 2020-11-30 11:01:16 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-11-30 11:01:16 -0800 |
| commit | 94fe8409336e2d86092bbde83bb80750cfe09d8a (patch) | |
| tree | e4861e1c9039080582e5825fd850e6f079631d71 | |
| parent | 09d71f30412a7c5b7b1c7adb7247b0ed0fcef657 (diff) | |
| download | vcpkg-94fe8409336e2d86092bbde83bb80750cfe09d8a.tar.gz vcpkg-94fe8409336e2d86092bbde83bb80750cfe09d8a.zip | |
[sdl2-image] Fix usage (#14796)
| -rw-r--r-- | ports/sdl2-image/CMakeLists.txt | 11 | ||||
| -rw-r--r-- | ports/sdl2-image/CONTROL | 1 |
2 files changed, 10 insertions, 2 deletions
diff --git a/ports/sdl2-image/CMakeLists.txt b/ports/sdl2-image/CMakeLists.txt index 9cc82de7a..48afeb538 100644 --- a/ports/sdl2-image/CMakeLists.txt +++ b/ports/sdl2-image/CMakeLists.txt @@ -110,13 +110,20 @@ install(TARGETS SDL2_image install(FILES SDL_image.h DESTINATION include/SDL2 CONFIGURATIONS Release) +file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/sdl2-image-config.cmake" +[[include(CMakeFindDependencyMacro) +find_dependency(SDL2 CONFIG) +include("${CMAKE_CURRENT_LIST_DIR}/sdl2-image-targets.cmake") +]]) + +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/sdl2-image-config.cmake DESTINATION share/sdl2-image) + install(EXPORT SDL2_image DESTINATION share/sdl2-image/ - FILE sdl2-image-config.cmake + FILE sdl2-image-targets.cmake NAMESPACE SDL2:: ) - message(STATUS "Link-time dependencies:") message(STATUS " " SDL2::SDL2) foreach(DEPENDENCY ${DEPENDENCIES}) diff --git a/ports/sdl2-image/CONTROL b/ports/sdl2-image/CONTROL index 19218ef3e..db07f7630 100644 --- a/ports/sdl2-image/CONTROL +++ b/ports/sdl2-image/CONTROL @@ -1,5 +1,6 @@ Source: sdl2-image Version: 2.0.5 +Port-Version: 1 Build-Depends: sdl2, libpng Homepage: https://www.libsdl.org/projects/SDL_image Description: SDL_image is an image file loading library. It loads images as SDL surfaces and textures, and supports the following formats: BMP, GIF, JPEG, LBM, PCX, PNG, PNM, TGA, TIFF, WEBP, XCF, XPM, XV |
