archrelease: copy trunk to extra-x86_64
[arch-packages.git] / openmpi / trunk / PKGBUILD
blob2cb49f5383153bdb0ccf5148eee8579fa50e99c5
1 # Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>
2 # Maintainer: David Runge <dvzrv@archlinux.org>
3 # Contributor: Anatol Pomozov <anatol dot pomozov at gmail>
4 # Contributor: Stéphane Gaudreault <stephane@archlinux.org>
6 pkgname=openmpi
7 pkgver=4.1.5
8 pkgrel=1
9 pkgdesc='High performance message passing library (MPI)'
10 arch=(x86_64)
11 url='https://www.open-mpi.org'
12 license=('custom:OpenMPI')
13 depends=(gcc-libs glibc hwloc libevent libnl openpmix openssh zlib)
14 makedepends=(cuda gcc-fortran inetutils valgrind)
15 optdepends=(
16   'cuda: cuda support'
17   'gcc-fortran: fortran support'
18   'perl: for aggregate_profile.pl and profile2mat.pl'
20 provides=(
21   libmca_common_cuda.so
22   libmca_common_monitoring.so
23   libmca_common_ompio.so
24   libmca_common_sm.so
25   libmpi.so
26   libmpi_cxx.so
27   libmpi_mpifh.so
28   libmpi_usempi_ignore_tkr.so
29   libmpi_usempif08.so
30   libompitrace.so
31   libopen-pal.so
32   libopen-rte.so
34 source=(https://www.open-mpi.org/software/ompi/v${pkgver%.*}/downloads/$pkgname-$pkgver.tar.bz2)
35 sha256sums=('a640986bc257389dd379886fdae6264c8cfa56bc98b71ce3ae3dfbd8ce61dbe3')
36 b2sums=('135a8373ed6173b7a94def18e3b964c6b6050c909382e0dbb1898a6d261ae428931358121ef6d325d303f4f510017a94970f7c66b280a5fc460365821f36dece')
38 build() {
39   local configure_options=(
40     --prefix=/usr
41     --enable-builtin-atomics
42     --enable-memchecker
43     --enable-mpi-cxx
44     --enable-mpi-fortran=all
45     --enable-pretty-print-stacktrace
46     --libdir=/usr/lib
47     --sysconfdir=/etc/$pkgname
48     --with-cuda=/opt/cuda
49     --with-hwloc=external
50     --with-libevent=external
51     --with-pmix=external
52     --with-valgrind
53   )
54   cd $pkgname-$pkgver
56   # TODO: depend on prrte with openmpi >= 5
57   ./configure "${configure_options[@]}"
58   # prevent excessive overlinking due to libtool
59   sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
60   make V=1
63 check() {
64   make check -C $pkgname-$pkgver
67 package() {
68   depends+=(libpmix.so)
70   make DESTDIR="$pkgdir" install -C $pkgname-$pkgver
71   install -Dm 644 $pkgname-$pkgver/LICENSE -t "$pkgdir/usr/share/licenses/$pkgname/"
74 # vim: ts=2 sw=2 et: