Skip to content

Commit

Permalink
Enable ROCm support
Browse files Browse the repository at this point in the history
Enable ROCm support, and rework CUDA support
  • Loading branch information
fwyzard committed Jul 7, 2022
1 parent 190c2bc commit e5ef1c5
Showing 1 changed file with 14 additions and 4 deletions.
18 changes: 14 additions & 4 deletions hwloc.spec
Expand Up @@ -3,6 +3,9 @@ Source: https://download.open-mpi.org/release/%{n}/v2.8/%{n}-%{realversion}.tar.

BuildRequires: autotools
Requires: cuda libpciaccess libxml2 numactl
%ifarch x86_64
Requires: rocm
%endif

%prep
%setup -n %{n}-%{realversion}
Expand All @@ -13,17 +16,24 @@ Requires: cuda libpciaccess libxml2 numactl
--disable-static \
--disable-dependency-tracking \
--enable-cpuid \
--enable-cuda \
--enable-nvml \
--enable-libxml2 \
--disable-cairo \
--disable-doxygen \
--disable-opencl \
--with-cuda=$CUDA_ROOT \
--enable-cuda \
--enable-nvml \
--enable-plugins=cuda,nvml \
%ifarch x86_64
--with-rocm=$ROCM_ROOT \
--enable-rsmi \
--enable-plugins=cuda,nvml,rsmi \
%else
--enable-plugins=cuda,nvml \
%endif
--with-pic \
--with-gnu-ld \
--without-x \
CPPFLAGS="-I$CUDA_ROOT/include" \
LDFLAGS="-L$CUDA_ROOT/lib64 -L$CUDA_ROOT/lib64/stubs" \
HWLOC_PCIACCESS_CFLAGS="-I$LIBPCIACCESS_ROOT/include" \
HWLOC_PCIACCESS_LIBS="-L$LIBPCIACCESS_ROOT/lib -lpciaccess" \
HWLOC_LIBXML2_CFLAGS="-I$LIBXML2_ROOT/include/libxml2" \
Expand Down

0 comments on commit e5ef1c5

Please sign in to comment.