## START: Set by rpmautospec ## (rpmautospec version 0.8.4) ## RPMAUTOSPEC: autorelease, autochangelog %define autorelease(e:s:pb:n) %{?-p:0.}%{lua: release_number = 2; base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}")); print(release_number + base_release_number - 1); }%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}} ## END: Set by rpmautospec %global commit0 08fcb290a89871a2d1175d655a34b7674b1dcc4b %global shortcommit0 %(c=%{commit0}; echo ${c:0:7}) %global date0 20260801 %global so_date0 260801 # MPI build based on spec file dbcsr by Orion %global mpi_list openmpi mpich # $mpi will be evaluated in the loops below %global _vpath_builddir %{_vendor}-%{_target_os}-build-${mpi:-serial} %ifarch x86_64 %bcond_without rocm %endif %if %{with rocm} %global build_rocm ON %else %global build_rocm OFF %endif Summary: Communications library for AI/ML Name: gloo License: BSD-3-Clause Version: 0.5.0^git%{date0}.%{shortcommit0} Release: %autorelease URL: https://github.com/facebookincubator/%{name} Source0: %{url}/archive/%{commit0}/%{name}-%{shortcommit0}.tar.gz Patch0: 0001-gloo-fedora-cmake-changes.patch #Patch1: 0002-gloo-fedora-cmake-libuv.patch #Patch2: 0001-gloo-gcc-15-cstdint.patch # See CMakeLists, gloo only builds on 64 bit systems ExcludeArch: i686 BuildRequires: cmake BuildRequires: gcc-c++ BuildRequires: hiredis-devel BuildRequires: libibverbs BuildRequires: libuv-devel BuildRequires: libuv-static BuildRequires: mpich-devel BuildRequires: openmpi-devel BuildRequires: rdma-core-devel BuildRequires: redis-devel %if %{with rocm} BuildRequires: hipify BuildRequires: rccl-devel BuildRequires: rocm-comgr-devel BuildRequires: rocm-compilersupport-macros BuildRequires: rocm-hip-devel BuildRequires: rocm-runtime-devel BuildRequires: rocm-rpm-macros %endif Requires: %{name}-docs %global base_description \ Gloo is a collective communications library. It comes with a number of\ collective algorithms useful for machine learning applications. These\ include a barrier, broadcast, and allreduce.\ \ Transport of data between participating machines is abstracted so that\ IP can be used at all times, or InifiniBand (or RoCE) when available.\ In the latter case, if the InfiniBand transport is used, GPUDirect can\ be used to accelerate cross machine GPU-to-GPU memory transfers.\ \ Where applicable, algorithms have an implementation that works with\ system memory buffers, and one that works with NVIDIA GPU memory buffers.\ In the latter case, it is not necessary to copy memory between host and\ device; this is taken care of by the algorithm implementations. %description %{base_description} %package docs Summary: Documentation and license for %{name} Buildarch: noarch %description docs Documentation only package used by other packages for %{name}. %package devel Summary: Headers and libraries for %{name} Requires: %{name}%{?_isa} = %{version}-%{release} %description devel Libraries and headers for developing applications that use %{name}. %package openmpi Summary: Gloo - openmpi version BuildRequires: openmpi-devel Requires: %{name}-docs %description openmpi %{base_description} This package can use openmpi as a backend. %package openmpi-devel Summary: Development libraries and headers Requires: %{name}-openmpi%{?_isa} = %{version}-%{release} %description openmpi-devel Libraries and header files for developing applications that use %{name}-openmpi. %package mpich Summary: Gloo - mpich version BuildRequires: mpich-devel Requires: %{name}-docs %description mpich %{base_description} This package can use mpich as a backend. %package mpich-devel Summary: Development libraries and headers BuildRequires: mpich-devel Requires: %{name}-mpich%{?_isa} = %{version}-%{release} %description mpich-devel Libraries and header files for developing applications that use %{name}-mpich. %prep %autosetup -p1 -n %{name}-%{commit0} # cmake version change sed -i -e 's@cmake_minimum_required(VERSION 2.8.12 FATAL_ERROR)@cmake_minimum_required(VERSION 3.5 FATAL_ERROR)@' CMakeLists.txt # change YYMMDD to match commit0 date and get a fake so version sed -i -e 's@YYMMDD@%{so_date0}@' gloo/CMakeLists.txt sed -i -e 's@POSITION_INDEPENDENT_CODE ON@POSITION_INDEPENDENT_CODE ON VERSION 0.0.%{so_date0} SOVERSION 0.0.%{so_date0}@' cmake/Hip.cmake # some help with installing headers sed -i -e 's@${CMAKE_INSTALL_PREFIX}/include/${DIR}@${CMAKE_INSTALL_PREFIX}/include/gloo/@' gloo/CMakeLists.txt %build %define gloo_cmake_options -DUSE_IBVERBS=ON -DUSE_LIBUV=OFF -DUSE_REDIS=ON %if %{with rocm} ROCM_PATH=%{_prefix} GLOO_ROCM_ARCH=%{rocm_gpu_list_rccl} %endif %cmake %gloo_cmake_options \ -DUSE_MPI=OFF \ -DUSE_ROCM=%{build_rocm} \ -DUSE_RCCL=%{build_rocm} \ -DCMAKE_INSTALL_PREFIX=%{_prefix} \ -DCMAKE_INSTALL_LIBDIR=lib64 %cmake_build for mpi in %{mpi_list} do module load mpi/$mpi-%{_arch} %cmake %gloo_cmake_options \ -DUSE_MPI=ON \ -DUSE_ROCM=OFF \ -DCMAKE_INSTALL_PREFIX=$MPI_HOME \ -DCMAKE_INSTALL_LIBDIR=lib %cmake_build module purge done %install %cmake_install mkdir -p %{buildroot}%{_datadir}/Gloo/docs cp -p -r docs/* %{buildroot}%{_datadir}/Gloo/docs for mpi in %{mpi_list} do module load mpi/$mpi-%{_arch} %cmake_install module purge done %files docs %license LICENSE %doc README.md %dir %{_datadir}/Gloo %doc %{_datadir}/Gloo/docs/ %files %{_libdir}/lib%{name}.so.* %if %{with rocm} %{_libdir}/lib%{name}_hip.so.* %endif %files devel %{_includedir}/%{name}/ %{_libdir}/cmake/Gloo/ %{_libdir}/lib%{name}.so %if %{with rocm} %{_libdir}/lib%{name}_hip.so %endif %files mpich %{_libdir}/mpich/lib/lib%{name}.so.* %files mpich-devel %{_libdir}/mpich/lib/lib%{name}.so %{_libdir}/mpich/lib/cmake/ %{_libdir}/mpich/include/ %files openmpi %{_libdir}/openmpi/lib/lib%{name}.so.* %files openmpi-devel %{_libdir}/openmpi/lib/lib%{name}.so %{_libdir}/openmpi/lib/cmake/ %{_libdir}/openmpi/include/ %changelog ## START: Generated by rpmautospec * Tue Aug 18 2026 Tom Rix - 0.5.0^git20260801.08fcb29-2 - Update patch * Tue Aug 18 2026 Tom Rix - 0.5.0^git20260801.08fcb29-1 - Update to a recent gloo, enable rocm * Thu Jul 16 2026 Fedora Release Engineering - 0.5.0^git20241203.dc507d1-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_45_Mass_Rebuild * Fri Jan 16 2026 Fedora Release Engineering - 0.5.0^git20241203.dc507d1-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_44_Mass_Rebuild * Wed Jul 23 2025 Fedora Release Engineering - 0.5.0^git20241203.dc507d1-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild * Sat Mar 01 2025 Tom Rix - 0.5.0^git20241203.dc507d1-2 - cmake version changed * Thu Jan 16 2025 Tom Rix - 0.5.0^git20241203.dc507d1-1 - Update to 20141203 * Thu Jul 18 2024 Fedora Release Engineering - 0.5.0^git20230824.01a0c81-7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild * Sat May 11 2024 Kevin Fenzi - 0.5.0^git20230824.01a0c81-6 - rebuild for hiredis soname bump * Mon Apr 15 2024 Tom Rix - 0.5.0^git20230824.01a0c81-5 - openssl 1.1 no longer available * Wed Jan 24 2024 Fedora Release Engineering - 0.5.0^git20230824.01a0c81-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild * Fri Jan 19 2024 Fedora Release Engineering - 0.5.0^git20230824.01a0c81-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild * Sun Oct 29 2023 Orion Poplawski - 0.5.0^git20230824.01a0c81-2 - Rebuild for openmpi 5.0.0, drops C++ API * Thu Oct 12 2023 Tom Rix - 0.5.0^git20230824.01a0c81-1 - Initial project ## END: Generated by rpmautospec