diff options
| author | Robert Schumacher <roschuma@microsoft.com> | 2018-03-11 23:41:51 -0700 |
|---|---|---|
| committer | Robert Schumacher <roschuma@microsoft.com> | 2018-03-11 23:42:54 -0700 |
| commit | 9f9778ccff48981a691bf34f30ecc4bf2efd5ac1 (patch) | |
| tree | 10ec609d13836ddc266345f441bae6f9e824056a /ports/sdl2 | |
| parent | ece289b9a6466dca885fd2555ed783d70dcad9bf (diff) | |
| download | vcpkg-9f9778ccff48981a691bf34f30ecc4bf2efd5ac1.tar.gz vcpkg-9f9778ccff48981a691bf34f30ecc4bf2efd5ac1.zip | |
[many ports] Improve behavior on Linux and general cleanup
Diffstat (limited to 'ports/sdl2')
| -rw-r--r-- | ports/sdl2/CONTROL | 2 | ||||
| -rw-r--r-- | ports/sdl2/portfile.cmake | 27 |
2 files changed, 25 insertions, 4 deletions
diff --git a/ports/sdl2/CONTROL b/ports/sdl2/CONTROL index ffebda760..6f39484dd 100644 --- a/ports/sdl2/CONTROL +++ b/ports/sdl2/CONTROL @@ -1,3 +1,3 @@ Source: sdl2 -Version: 2.0.8 +Version: 2.0.8-1 Description: Simple DirectMedia Layer is a cross-platform development library designed to provide low level access to audio, keyboard, mouse, joystick, and graphics hardware via OpenGL and Direct3D. diff --git a/ports/sdl2/portfile.cmake b/ports/sdl2/portfile.cmake index 572fef829..a3cb80e3f 100644 --- a/ports/sdl2/portfile.cmake +++ b/ports/sdl2/portfile.cmake @@ -32,11 +32,32 @@ vcpkg_configure_cmake( vcpkg_install_cmake() -file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include) +if(EXISTS "${CURRENT_PACKAGES_DIR}/cmake") + vcpkg_fixup_cmake_targets(CONFIG_PATH "cmake") +elseif(EXISTS "${CURRENT_PACKAGES_DIR}/lib/cmake/SDL2") + vcpkg_fixup_cmake_targets(CONFIG_PATH "lib/cmake/SDL2") +elseif(EXISTS "${CURRENT_PACKAGES_DIR}/SDL2.framework/Resources") + vcpkg_fixup_cmake_targets(CONFIG_PATH "SDL2.framework/Resources") +endif() + +file(REMOVE_RECURSE + ${CURRENT_PACKAGES_DIR}/debug/include + ${CURRENT_PACKAGES_DIR}/debug/share + ${CURRENT_PACKAGES_DIR}/bin/sdl2-config + ${CURRENT_PACKAGES_DIR}/debug/bin/sdl2-config + ${CURRENT_PACKAGES_DIR}/SDL2.framework + ${CURRENT_PACKAGES_DIR}/debug/SDL2.framework +) -vcpkg_fixup_cmake_targets(CONFIG_PATH "cmake") +file(GLOB BINS ${CURRENT_PACKAGES_DIR}/debug/bin/* ${CURRENT_PACKAGES_DIR}/bin/*) +if(NOT BINS) + file(REMOVE_RECURSE + ${CURRENT_PACKAGES_DIR}/bin + ${CURRENT_PACKAGES_DIR}/debug/bin + ) +endif() -if(NOT VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStore") +if(NOT VCPKG_CMAKE_SYSTEM_NAME) file(MAKE_DIRECTORY ${CURRENT_PACKAGES_DIR}/lib/manual-link ${CURRENT_PACKAGES_DIR}/debug/lib/manual-link) file(RENAME ${CURRENT_PACKAGES_DIR}/lib/SDL2main.lib ${CURRENT_PACKAGES_DIR}/lib/manual-link/SDL2main.lib) file(RENAME ${CURRENT_PACKAGES_DIR}/debug/lib/SDL2maind.lib ${CURRENT_PACKAGES_DIR}/debug/lib/manual-link/SDL2maind.lib) |
