47 lines
1.3 KiB
Makefile
47 lines
1.3 KiB
Makefile
|
# $FreeBSD$
|
||
|
|
||
|
PORTNAME= sparta
|
||
|
PORTVERSION= ${GH_TAGNAME:C/([0-9]{1,2})([A-Z][a-z][a-z])([0-9]{4})/\3.\2.\1/S/Jan/01/S/Feb/02/S/Mar/03/S/Apr/04/S/May/05/S/Jun/06/S/Jul/07/S/Aug/08/S/Sep/09/S/Oct/10/S/Nov/11/S/Dec/12/}
|
||
|
CATEGORIES= science
|
||
|
PKGNAMESUFFIX= -dsmc # Direct Simulation Monte Carlo
|
||
|
|
||
|
MAINTAINER= yuri@FreeBSD.org
|
||
|
COMMENT= Gas simulator: SPARTA DSMC software package
|
||
|
|
||
|
LICENSE= GPLv2
|
||
|
LICENSE_FILE= ${WRKSRC}/../LICENSE
|
||
|
|
||
|
BUILD_DEPENDS= bash:shells/bash
|
||
|
|
||
|
USES= gmake localbase
|
||
|
USE_GITHUB= yes
|
||
|
GH_TAGNAME= 29Oct2018
|
||
|
|
||
|
CXXFLAGS+= -DSPARTA_UNORDERED_MAP
|
||
|
|
||
|
WRKSRC_SUBDIR= src
|
||
|
MAKE_ARGS= CC=${CXX} CCFLAGS="${CXXFLAGS}" LINK=${CXX} LINKFLAGS="${LDFLAGS}" mode=exe
|
||
|
|
||
|
OPTIONS_SINGLE= PARALLEL
|
||
|
OPTIONS_SINGLE_PARALLEL= SERIAL MPI
|
||
|
OPTIONS_DEFAULT= MPI
|
||
|
PARALLEL_DESC= Parallelization
|
||
|
|
||
|
SERIAL_DESC= Serial: no parallelization
|
||
|
SERIAL_ALL_TARGET= serial
|
||
|
SERIAL_PLIST_FILES= bin/spa_serial
|
||
|
|
||
|
MPI_ALL_TARGET= mpi
|
||
|
MPI_PLIST_FILES= bin/spa_mpi
|
||
|
MPI_CXXFLAGS= -I${LOCALBASE}/mpi/openmpi/include
|
||
|
MPI_LDFLAGS= ${LOCALBASE}/mpi/openmpi/lib/libmpi.so -Wl,-rpath=${LOCALBASE}/mpi/openmpi/lib
|
||
|
MPI_LIB_DEPENDS= libmpi.so:net/openmpi
|
||
|
|
||
|
post-patch:
|
||
|
@${REINPLACE_CMD} 's|SHELL = /bin/bash|SHELL = ${LOCALBASE}/bin/bash|' ${WRKSRC}/Makefile
|
||
|
|
||
|
do-install:
|
||
|
${INSTALL_PROGRAM} ${WRKSRC}/spa_* ${STAGEDIR}${PREFIX}/bin/
|
||
|
|
||
|
.include <bsd.port.mk>
|