summaryrefslogtreecommitdiff
path: root/science/fleur/Makefile
blob: 7b632e3d1f00bca68f14b9b72a1905a0a4d1b1f8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
# $FreeBSD$

PORTNAME=	fleur
DISTVERSION=	0.27-3 # Release 3 of Version 0.27
PORTREVISION=	7
CATEGORIES=	science
MASTER_SITES=	http://www.flapw.de/pm/uploads/FLEUR/
DISTNAME=	fleurMaXR${DISTVERSION:C/.*-//}

MAINTAINER=	yuri@FreeBSD.org
COMMENT=	FLAPW code for atomic computations in quantum chemistry and physics

LICENSE=	MIT
LICENSE_FILE=	${WRKSRC}/LICENSE

BROKEN=		Fails to build with cmake-3.16.0

LIB_DEPENDS=	libopenblas.so:math/openblas

USES=		cmake:noninja fortran gnome localbase:ldflags tar:tgz
USE_GNOME=	libxml2

FFLAGS=		-I${LOCALBASE}/include

WRKSRC=		${WRKDIR}/${PORTNAME}

OPTIONS_DEFINE=		HDF5 MPI SCALAPACK ELPA WANNIER
OPTIONS_DEFAULT=	MPI SCALAPACK ELPA WANNIER

HDF5_CONFIGURE_ENV=	FLEUR_USE_HDF5=1 HDF5_ROOT=${LOCALBASE}/lib
HDF5_CONFIGURE_ENV_OFF=	FLEUR_USE_HDF5=0
HDF5_CMAKE_ON=		-DHDF5_INCLUDE_DIRS=${LOCALBASE}/include
HDF5_LDFLAGS=		-lhdf5
HDF5_LIB_DEPENDS=	libhdf5.so:science/hdf5
HDF5_BROKEN=		Missing hdf5.mod in hdf5

MPI_CONFIGURE_ENV=	FLEUR_USE_MPI=1
MPI_CONFIGURE_ENV_OFF=	FLEUR_USE_MPI=0
MPI_LDFLAGS=		-lmpich -lmpifort
MPI_LIB_DEPENDS=	libmpich.so:net/mpich
MPI_PLIST_FILES=	bin/fleur_MPI

SCALAPACK_DESC=		Use the ScaLAPACK Scalable LAPACK library
SCALAPACK_CMAKE_BOOL=	FREEBSD_USE_SCALAPACK
SCALAPACK_LDFLAGS=	-lscalapack
SCALAPACK_LIB_DEPENDS=	libscalapack.so:math/scalapack
SCALAPACK_IMPLIES=	MPI

ELPA_DESC=		Use libelpa, Eigenvalue SoLver for Petaflop Applications
ELPA_CMAKE_BOOL=	FREEBSD_USE_ELPA
ELPA_VARS=		FFLAGS+=-I${LOCALBASE}/include/elpa-2018.05.001/modules
ELPA_LDFLAGS=		-lelpa
ELPA_LIB_DEPENDS=	libelpa.so:math/elpa
ELPA_IMPLIES=		MPI

WANNIER_DESC=		Use Wannier library
WANNIER_CONFIGURE_ENV=	FLEUR_USE_WANNIER=1
WANNIER_CONFIGURE_ENV_OFF=	FLEUR_USE_WANNIER=0
WANNIER_LDFLAGS=	-lwannier
WANNIER_LIB_DEPENDS=	libwannier.so:science/wannier90

PLIST_FILES=	bin/fleur \
		bin/inpgen

.include <bsd.port.mk>