mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-08 22:45:43 +00:00
75 lines
2.6 KiB
Bash
75 lines
2.6 KiB
Bash
# Maintainer: Felix Yan <felixonmars@archlinux.org>
|
|
|
|
# ALARM: Kevin Mihelich <kevin@archlinuxarm.org>
|
|
# - removed makedepend on pandoc
|
|
# - cmake with -DNO_MAN_PAGES=1
|
|
|
|
pkgname=rdma-core
|
|
pkgdesc='RDMA core userspace libraries and daemons'
|
|
pkgver=49.0
|
|
pkgrel=1
|
|
arch=('x86_64')
|
|
url="https://github.com/linux-rdma/rdma-core"
|
|
license=('GPL2' 'custom:OpenIB.org BSD (MIT variant)')
|
|
depends=('libnl' 'ethtool' 'perl' 'systemd-libs')
|
|
makedepends=('git' 'cmake' 'systemd' 'ninja' 'libdrm' 'cython0' 'python' 'python-docutils' 'valgrind')
|
|
_provides=('rdma' 'ibacm' 'libiwpm' 'libibcm' 'libibumad' 'libibverbs'
|
|
'librdmacm' 'libcxgb3' 'libcxgb4' 'libmlx4' 'libmlx5' 'libmthca' 'libnes' 'libocrdma'
|
|
'srptools' 'infiniband-diags' 'libibmad')
|
|
provides=("${_provides[@]}")
|
|
conflicts=("${_provides[@]}")
|
|
replaces=("${_provides[@]}")
|
|
backup=(etc/rdma/{rdma.conf,mlx4.conf})
|
|
source=("https://github.com/linux-rdma/rdma-core/archive/v$pkgver/$pkgname-$pkgver.tar.gz")
|
|
sha512sums=('2da35b489d6a82776dceac4b067a7a9f931b6c4737a205f522616fa028c74c10c098195d6843970ffeb22c8b416975bcfcd11d53a60ff855653624673f1d498a')
|
|
validpgpkeys=('42D25385C1A1C02B8B1B1C6F801BDDB825988F64') # nicolas@morey-chaisemartin.com
|
|
|
|
prepare() {
|
|
mkdir -p build
|
|
|
|
cd rdma-core-$pkgver
|
|
find redhat -type f -exec sed --in-place \
|
|
--expression='s|/usr/libexec|/usr/lib/rdma|g' \
|
|
--expression='s|/usr/sbin|/usr/bin|g' \
|
|
--expression='s|/sbin|/usr/bin|g' \
|
|
'{}' '+'
|
|
|
|
sed -e 's|"drm"|"libdrm"|' -i CMakeLists.txt # Fix drm include dir
|
|
}
|
|
|
|
build() {
|
|
cd build
|
|
cmake \
|
|
-GNinja \
|
|
-DCMAKE_INSTALL_PREFIX=/usr \
|
|
-DCMAKE_INSTALL_RUNDIR=/run \
|
|
-DCMAKE_INSTALL_SBINDIR=/usr/bin \
|
|
-DCMAKE_INSTALL_LIBEXECDIR=/usr/lib/rdma \
|
|
-DCMAKE_INSTALL_SYSCONFDIR=/etc \
|
|
-DCMAKE_INSTALL_PERLDIR=/usr/share/perl5/vendor_perl \
|
|
-DNO_MAN_PAGES=1 \
|
|
../rdma-core-$pkgver
|
|
ninja
|
|
}
|
|
|
|
check() {
|
|
cd rdma-core-$pkgver
|
|
PYTHONPATH="$srcdir/build/python" tests/run_tests.py
|
|
}
|
|
|
|
package() {
|
|
cd build
|
|
DESTDIR="$pkgdir" ninja install
|
|
|
|
rm -vr "$pkgdir"/etc/init.d
|
|
|
|
cd "$srcdir"/rdma-core-$pkgver/redhat
|
|
install -D --mode=0644 rdma.conf "$pkgdir"/etc/rdma/rdma.conf
|
|
install -D --mode=0755 rdma.mlx4-setup.sh "$pkgdir"/usr/lib/rdma/mlx4-setup.sh
|
|
install -D --mode=0644 rdma.mlx4.conf "$pkgdir"/etc/rdma/mlx4.conf
|
|
install -D --mode=0644 rdma.mlx4.sys.modprobe "$pkgdir"/usr/lib/modprobe.d/libmlx4.conf
|
|
install -D --mode=0755 rdma.modules-setup.sh "$pkgdir"/usr/lib/dracut/modules.d/05rdma/module-setup.sh
|
|
|
|
cd ..
|
|
install -D --mode=0644 COPYING.BSD_MIT "$pkgdir"/usr/share/licenses/$pkgname/COPYING.BSD_MIT
|
|
}
|