aboutsummaryrefslogtreecommitdiff
path: root/vcpkg/ports/gloo
diff options
context:
space:
mode:
authorEthan Morgan <ethan@gweithio.com>2026-02-14 16:44:06 +0000
committerEthan Morgan <ethan@gweithio.com>2026-02-14 16:44:06 +0000
commit54409423f767d8b1cf30cb7d0efca6b4ca138823 (patch)
treed915ac7828703ce4b963efdd9728a1777ba18c1e /vcpkg/ports/gloo
move to own git serverHEADmaster
Diffstat (limited to 'vcpkg/ports/gloo')
-rw-r--r--vcpkg/ports/gloo/portfile.cmake41
-rw-r--r--vcpkg/ports/gloo/vcpkg.json39
2 files changed, 80 insertions, 0 deletions
diff --git a/vcpkg/ports/gloo/portfile.cmake b/vcpkg/ports/gloo/portfile.cmake
new file mode 100644
index 0000000..1e0cd0a
--- /dev/null
+++ b/vcpkg/ports/gloo/portfile.cmake
@@ -0,0 +1,41 @@
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO facebookincubator/gloo
+ REF 81925d1c674c34f0dc34dd9a0f2151c1b6f701eb
+ SHA512 2783908e7e0d6bd7f8cf59f4e6a94c84908e459f394c294cdf34aa8d1943a193fb25d15a8662f5a32a82b23a2657e63b1aa562f3ad8953ef79c9f502d04fed20
+ HEAD_REF master
+)
+
+# Determine which backend to build via specified feature
+vcpkg_check_features(
+ OUT_FEATURE_OPTIONS GLOO_FEATURE_OPTIONS
+ FEATURES
+ mpi USE_MPI
+ redis USE_REDIS
+ cuda USE_CUDA
+ cuda USE_NCCL
+ )
+
+if ("cuda" IN_LIST FEATURES)
+ vcpkg_find_cuda(OUT_CUDA_TOOLKIT_ROOT cuda_toolkit_root)
+ list(APPEND GLOO_FEATURE_OPTIONS
+ "-DCMAKE_CUDA_COMPILER:FILEPATH=${NVCC}"
+ "-DCUDAToolkit_ROOT=${cuda_toolkit_root}"
+ )
+endif()
+
+vcpkg_cmake_configure(
+ SOURCE_PATH "${SOURCE_PATH}"
+ OPTIONS ${GLOO_FEATURE_OPTIONS}
+ MAYBE_UNUSED_VARIABLES
+ CMAKE_CUDA_COMPILER
+ CUDAToolkit_ROOT
+ )
+vcpkg_cmake_install()
+vcpkg_copy_pdbs()
+
+vcpkg_cmake_config_fixup(CONFIG_PATH share/cmake/Gloo)
+file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
+file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
+
+vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE")
diff --git a/vcpkg/ports/gloo/vcpkg.json b/vcpkg/ports/gloo/vcpkg.json
new file mode 100644
index 0000000..c9dca37
--- /dev/null
+++ b/vcpkg/ports/gloo/vcpkg.json
@@ -0,0 +1,39 @@
+{
+ "name": "gloo",
+ "version": "20240626",
+ "port-version": 1,
+ "description": "Collective communications library with various primitives for multi-machine training.",
+ "homepage": "https://github.com/facebookincubator/gloo",
+ "supports": "x64 & linux",
+ "dependencies": [
+ {
+ "name": "vcpkg-cmake",
+ "host": true
+ },
+ {
+ "name": "vcpkg-cmake-config",
+ "host": true
+ }
+ ],
+ "features": {
+ "cuda": {
+ "description": "for CUDA aware algorithms",
+ "dependencies": [
+ "cuda",
+ "nccl"
+ ]
+ },
+ "mpi": {
+ "description": "for coordinating machine rendezvous through MPI",
+ "dependencies": [
+ "openmpi"
+ ]
+ },
+ "redis": {
+ "description": "for coordinating machine rendezvous through Redis",
+ "dependencies": [
+ "hiredis"
+ ]
+ }
+ }
+}