blob: 67d254677ee5f092867427fff469fca5083459c9 (
plain) (
blame)
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
|
# Created by: ijliao
# $FreeBSD$
PORTNAME= mpb
PORTVERSION= 1.5
PORTREVISION= 1
CATEGORIES= science
MASTER_SITES= http://ab-initio.mit.edu/mpb/
MAINTAINER= rhurlin@gwdg.de
COMMENT= MIT Photonic-Bands
LICENSE= GPLv2
BUILD_DEPENDS= bash:${PORTSDIR}/shells/bash
LIB_DEPENDS= libfftw.so:${PORTSDIR}/math/fftw \
libhdf5.so:${PORTSDIR}/science/hdf5 \
libctl.so:${PORTSDIR}/science/libctl \
libguile-2.0.so:${PORTSDIR}/lang/guile2
OPTIONS_DEFINE= ATLAS NLOPT
ATLAS_DESC= Use math/atlas instead of math/lapack
NLOPT_DESC= Use math/nlopt (check also in science/libctl)
USES= fortran libtool pkgconfig
GNU_CONFIGURE= yes
MAKE_JOBS_UNSAFE= yes
CPPFLAGS+= -I${LOCALBASE}/include
LDFLAGS+= -L${LOCALBASE}/lib
NLOPT_LIB_DEPENDS= libnlopt.so:${PORTSDIR}/math/nlopt
.include <bsd.port.options.mk>
.if ${PORT_OPTIONS:MATLAS}
LIB_DEPENDS+= libatlas.so:${PORTSDIR}/math/atlas
CONFIGURE_ARGS+= --with-lapack=-lalapack
.else
LIB_DEPENDS+= libblas.so:${PORTSDIR}/math/blas \
liblapack.so:${PORTSDIR}/math/lapack
CONFIGURE_ARGS+= --with-lapack=-llapack
.endif
post-patch:
@${REINPLACE_CMD} -e 's|-lhdf5 |-lhdf5 -lpthread |g' \
${WRKSRC}/configure
@${REINPLACE_CMD} \
-e '/INSTALL/s/$$(prefix)/$$(DESTDIR)$$(prefix)/' \
-e '/INSTALL/s/$$(mandir)/$$(DESTDIR)$$(mandir)/' \
${WRKSRC}/mpb/Makefile.in ${WRKSRC}/utils/Makefile.in
.include <bsd.port.mk>
|