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/libtcod | |
Diffstat (limited to 'vcpkg/ports/libtcod')
| -rw-r--r-- | vcpkg/ports/libtcod/portfile.cmake | 37 | ||||
| -rw-r--r-- | vcpkg/ports/libtcod/vcpkg.json | 55 |
2 files changed, 92 insertions, 0 deletions
diff --git a/vcpkg/ports/libtcod/portfile.cmake b/vcpkg/ports/libtcod/portfile.cmake new file mode 100644 index 0000000..96d2414 --- /dev/null +++ b/vcpkg/ports/libtcod/portfile.cmake @@ -0,0 +1,37 @@ +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO libtcod/libtcod + REF ${VERSION} + SHA512 09e98f26ccc65afa6f739a90d64ca0be93a768cb01bf87932a18a07132fb8a5895a5b5194c80698e08d0fcbbaca926df6f0d9797901ecc82bd36a1cbe076464f + HEAD_REF main +) + +vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS + INVERTED_FEATURES + "png" CMAKE_DISABLE_FIND_PACKAGE_lodepng-c + "sdl" CMAKE_DISABLE_FIND_PACKAGE_SDL3 + "threads" CMAKE_DISABLE_FIND_PACKAGE_Threads + "unicode" CMAKE_DISABLE_FIND_PACKAGE_utf8proc + "unicode" CMAKE_DISABLE_FIND_PACKAGE_unofficial-utf8proc + "zlib" CMAKE_DISABLE_FIND_PACKAGE_ZLIB +) + +vcpkg_cmake_configure( + SOURCE_PATH ${SOURCE_PATH} + OPTIONS + ${FEATURE_OPTIONS} + -DCMAKE_INSTALL_INCLUDEDIR=${CURRENT_PACKAGES_DIR}/include + -DLIBTCOD_SDL3=find_package + -DLIBTCOD_ZLIB=find_package + -DLIBTCOD_LODEPNG=find_package + -DLIBTCOD_UTF8PROC=vcpkg + -DLIBTCOD_STB=find_package +) + +vcpkg_cmake_install() + +vcpkg_copy_pdbs() + +vcpkg_cmake_config_fixup() + +file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share") diff --git a/vcpkg/ports/libtcod/vcpkg.json b/vcpkg/ports/libtcod/vcpkg.json new file mode 100644 index 0000000..67cd611 --- /dev/null +++ b/vcpkg/ports/libtcod/vcpkg.json @@ -0,0 +1,55 @@ +{ + "name": "libtcod", + "version-semver": "2.2.1", + "maintainers": "Kyle Benesch <4b796c65+github@gmail.com>", + "description": "Common algorithms and tools for roguelikes.", + "homepage": "https://github.com/libtcod/libtcod", + "documentation": "https://libtcod.readthedocs.io/en/latest/", + "license": "BSD-3-Clause", + "dependencies": [ + "stb", + { + "name": "vcpkg-cmake", + "host": true + }, + { + "name": "vcpkg-cmake-config", + "host": true + } + ], + "default-features": [ + "png", + "sdl", + "unicode", + "zlib" + ], + "features": { + "png": { + "description": "Support for reading and writing PNG files. Required to save screenshots and to load tilesets from files.", + "dependencies": [ + "lodepng" + ] + }, + "sdl": { + "description": "Support for SDL windows and events with the libtcod context.", + "dependencies": [ + "sdl3" + ] + }, + "threads": { + "description": "Support for deprecated threading functions. If in doubt then leave this disabled." + }, + "unicode": { + "description": "Support for non-ASCII characters. Required for text printing functions", + "dependencies": [ + "utf8proc" + ] + }, + "zlib": { + "description": "Support for REXPaint files and TCODZip archives.", + "dependencies": [ + "zlib" + ] + } + } +} |