1 # Maintainer: Torsten Keßler <tpkessler at archlinux dot org>
2 # Contriubtor: Markus Näther <naetherm@informatik.uni-freiburg.de>
3 # Contributor: acxz <akashpatel2008 at yahoo dot com>
8 pkgdesc="ROCm Communication Collectives Library"
10 url='https://rccl.readthedocs.io/en/rocm-5.4.3/'
12 depends=('hip' 'rocm-smi-lib')
13 makedepends=('rocm-cmake' 'python')
14 _git='https://github.com/ROCmSoftwarePlatform/rccl'
15 source=("$pkgname-$pkgver.tar.gz::$_git/archive/rocm-$pkgver.tar.gz")
16 sha256sums=('a2524f602bd7b3b6afeb8ba9aff660216ee807fa836e46442d068b5ed5f51a4d')
18 _dirname="$(basename $_git)-$(basename ${source[0]} .tar.gz)"
21 # Compile source code for supported GPU archs in parallel
22 export HIPCC_COMPILE_FLAGS_APPEND="-parallel-jobs=$(nproc)"
23 export HIPCC_LINK_FLAGS_APPEND="-parallel-jobs=$(nproc)"
24 # -fcf-protection is not supported by HIP, see
25 # https://docs.amd.com/bundle/ROCm-Compiler-Reference-Guide-v5.4/page/Appendix_A.html
26 CXXFLAGS="${CXXFLAGS} -fcf-protection=none" \
31 -DCMAKE_BUILD_TYPE=None \
32 -DCMAKE_CXX_COMPILER=/opt/rocm/hip/bin/hipcc \
33 -DCMAKE_INSTALL_PREFIX=/opt/rocm
38 DESTDIR="$pkgdir" cmake --install build
40 echo "/opt/rocm/$pkgname/lib" > "$pkgname.conf"
41 install -Dm644 "$pkgname.conf" "$pkgdir/etc/ld.so.conf.d/$pkgname.conf"
43 install -Dm644 "$srcdir/$_dirname/LICENSE.txt" "$pkgdir/usr/share/licenses/$pkgname/LICENSE"