diff options
| author | Ethan Morgan <ethan@gweithio.com> | 2026-02-14 16:44:06 +0000 |
|---|---|---|
| committer | Ethan Morgan <ethan@gweithio.com> | 2026-02-14 16:44:06 +0000 |
| commit | 54409423f767d8b1cf30cb7d0efca6b4ca138823 (patch) | |
| tree | d915ac7828703ce4b963efdd9728a1777ba18c1e /vcpkg/ports/glm | |
Diffstat (limited to 'vcpkg/ports/glm')
| -rw-r--r-- | vcpkg/ports/glm/portfile.cmake | 25 | ||||
| -rw-r--r-- | vcpkg/ports/glm/usage | 8 | ||||
| -rw-r--r-- | vcpkg/ports/glm/vcpkg.json | 17 |
3 files changed, 50 insertions, 0 deletions
diff --git a/vcpkg/ports/glm/portfile.cmake b/vcpkg/ports/glm/portfile.cmake new file mode 100644 index 0000000..3951bc9 --- /dev/null +++ b/vcpkg/ports/glm/portfile.cmake @@ -0,0 +1,25 @@ +vcpkg_check_linkage(ONLY_STATIC_LIBRARY) + +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO g-truc/glm + REF "${VERSION}" + SHA512 e66e4f192f6579128198c47ed20442dda13c741f371b447722b7449200f05785e1b69386a465febf97f33b437f6eb69b3fb282e1e9eabf6261eb7b57998cd68c + HEAD_REF master +) + +vcpkg_cmake_configure( + SOURCE_PATH "${SOURCE_PATH}" + OPTIONS + -DGLM_BUILD_LIBRARY=ON + -DGLM_BUILD_TESTS=OFF + -DGLM_BUILD_INSTALL=ON +) + +vcpkg_cmake_install() +vcpkg_cmake_config_fixup() + +file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include") + +vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/copying.txt") +file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}") diff --git a/vcpkg/ports/glm/usage b/vcpkg/ports/glm/usage new file mode 100644 index 0000000..0f63af2 --- /dev/null +++ b/vcpkg/ports/glm/usage @@ -0,0 +1,8 @@ +The package glm provides CMake targets: + + find_package(glm CONFIG REQUIRED) + target_link_libraries(main PRIVATE glm::glm) + + # Or use the header-only version + find_package(glm CONFIG REQUIRED) + target_link_libraries(main PRIVATE glm::glm-header-only) diff --git a/vcpkg/ports/glm/vcpkg.json b/vcpkg/ports/glm/vcpkg.json new file mode 100644 index 0000000..81485e2 --- /dev/null +++ b/vcpkg/ports/glm/vcpkg.json @@ -0,0 +1,17 @@ +{ + "name": "glm", + "version": "1.0.2", + "description": "OpenGL Mathematics (GLM)", + "homepage": "https://glm.g-truc.net", + "license": "MIT", + "dependencies": [ + { + "name": "vcpkg-cmake", + "host": true + }, + { + "name": "vcpkg-cmake-config", + "host": true + } + ] +} |