# Copyright (c) 2014 Dave Love, Liverpool University # Licence: MIT %global commit 20c286659ca09c253a8283bb6ff7c1a9226194f8 %global shortcommit %(c=%{commit}; echo ${c:0:7}) Name: wrap Version: 20170511 Release: 1%{?dist} Summary: MPI Wrapper Generator License: BSD URL: https://github.com/LLNL/wrap Source0: https://github.com/LLNL/%name/archive/%commit/%name-%shortcommit.tar.gz Patch1: wrap-deprecated.patch BuildRequires: openmpi-devel gcc-c++ /usr/bin/python3 Requires: /usr/bin/python3 BuildArch: noarch %description Python script for creating PMPI wrappers. Roughly follows the syntax of the Argonne PMPI wrapper generator, with some enhancements. %prep %setup -q -n wrap-%commit %patch1 -p1 sed -i 's,bin/env python$,bin/python3,' wrap.py %build %install install -Dp wrap.py %buildroot%_bindir/wrap.py install -Dp WrapConfig.cmake %buildroot%_datadir/cmake/WrapConfig.cmake %check %_openmpi_load cd examples %buildroot%_bindir/wrap.py -D world48.w > world48.C # Just ensure it links echo >main.c 'main () {return 0;}' mpicxx main.c world48.C rm world48.[Co] main.c a.out %files %license LICENSE %doc README.md FAQ examples %_bindir/wrap.py %_datadir/cmake/WrapConfig.cmake %changelog * Tue Dec 18 2018 Dave Love - 20170511-1 - New version - Use python3 - Patch to be able to avoid deprecated functions rmeoved in openmpi4 * Sun Mar 9 2014 Dave Love - 20130809-1 - Initial packaging