View | Details | Raw Unified | Return to bug 220157 | Differences between
and this patch

Collapse All | Expand All

(-)science/mbdyn/Makefile (-42 / +23 lines)
Lines 2-79 Link Here
2
# $FreeBSD$
2
# $FreeBSD$
3
3
4
PORTNAME=	mbdyn
4
PORTNAME=	mbdyn
5
PORTVERSION=	1.7.1
5
PORTVERSION=	1.7.2
6
PORTREVISION=	2
7
CATEGORIES=	science
6
CATEGORIES=	science
8
MASTER_SITES=	https://www.mbdyn.org/userfiles/downloads/
7
MASTER_SITES=	https://www.mbdyn.org/userfiles/downloads/
9
8
10
MAINTAINER=	ports@FreeBSD.org
9
MAINTAINER=	amutu@amutu.com
11
COMMENT=	MultiBody Dynamics analysis system
10
COMMENT=	MultiBody Dynamics analysis system
12
11
13
LICENSE=	GPLv2
12
LICENSE=	GPLv2
14
LICENSE_FILE=	${WRKSRC}/COPYING
13
LICENSE_FILE=	${WRKSRC}/COPYING
15
14
15
BROKEN_powerpc=	Does not compile on powerpc
16
17
BUILD_DEPENDS=	libatomic_ops>0:devel/libatomic_ops
16
LIB_DEPENDS=	libltdl.so:devel/libltdl \
18
LIB_DEPENDS=	libltdl.so:devel/libltdl \
17
		libarpack.so:math/arpack \
19
		libarpack.so:math/arpack \
18
		libumfpack.so:math/suitesparse
20
		libumfpack.so:math/suitesparse
19
21
20
BROKEN_powerpc=	Does not compile on powerpc
21
22
GNU_CONFIGURE=	yes
22
GNU_CONFIGURE=	yes
23
USES=		compiler:c++11-lib fortran gmake libtool localbase
23
USES=		compiler:c++11-lib fortran gmake libtool:build localbase
24
USE_LDCONFIG=	yes
24
USE_LDCONFIG=	yes
25
CPPFLAGS+=	-fpermissive -I${LOCALBASE}/include/suitesparse
25
CPPFLAGS+=	-fpermissive -I${LOCALBASE}/include/suitesparse
26
CONFIGURE_ARGS+=	--program-prefix=''
26
CONFIGURE_ARGS=	--program-prefix='' --enable-multithread --with-mpi=no \
27
		--with-ginac=no
27
INSTALL_TARGET=	install-strip
28
INSTALL_TARGET=	install-strip
28
29
29
OPTIONS_DEFINE=	MPI METIS CHACO GINAC
30
OPTIONS_DEFINE=	METIS CHACO
30
OPTIONS_RADIO=	BLAS
31
OPTIONS_RADIO=	BLAS
31
OPTIONS_RADIO_BLAS=	REFERENCE GOTOBLAS ATLAS
32
OPTIONS_RADIO_BLAS=	REFERENCE GOTOBLAS ATLAS
32
OPTIONS_DEFAULT=	REFERENCE
33
OPTIONS_DEFAULT=	REFERENCE
33
34
35
ATLAS_DESC=	ATLAS
36
CHACO_DESC=	Enable chaco-support
37
GOTOBLAS_DESC=	GotoBLAS2
38
METIS_DESC=	Enable metis-support
34
REFERENCE_DESC=	Blas / Lapack
39
REFERENCE_DESC=	Blas / Lapack
35
REFERENCE_USES=	blaslapack:netlib
36
REFERENCE_CONFIGURE_ON=	--with-blas=blas
37
40
38
ATLAS_DESC=	ATLAS
41
ATLAS_CONFIGURE_ON=	--with-blas=atlas
39
ATLAS_USES=	blaslapack:atlas
42
ATLAS_USES=	blaslapack:atlas
40
ATLAS_CONFIGURE_ON=	--with-blas=atlas
41
43
42
GOTOBLAS_DESC=	GotoBLAS2
43
GOTOBLAS_USES=	blaslapack:gotoblas
44
GOTOBLAS_CONFIGURE_ON=	--with-blas=goto --with-goto=goto2
45
46
MPI_DESC=		Enable mpich-support (Requires Metis or Chaco, broken)
47
MPI_IGNORE=		you enabled MPI support, which is broken
48
MPI_BUILD_DEPENDS_OFF=	libatomic_ops>0:devel/libatomic_ops
49
MPI_LIB_DEPENDS=	libmpich.so:net/mpich2
50
MPI_CONFIGURE_ON=	--with-mpi=yes --enable-schur
51
MPI_CONFIGURE_OFF=	--with-mpi=no --enable-multithread
52
53
METIS_DESC=		Enable metis-support
54
METIS_LIB_DEPENDS=	libmetis.so:math/metis4
55
METIS_CONFIGURE_ON=	--with-metis=yes
56
METIS_CPPFLAGS=		-I${LOCALBASE}/include/metis
57
METIS_CONFIGURE_OFF=	--with-metis=no
58
59
CHACO_DESC=		Enable chaco-support
60
CHACO_BUILD_DEPENDS=	${LOCALBASE}/lib/libchaco.a:math/chaco
44
CHACO_BUILD_DEPENDS=	${LOCALBASE}/lib/libchaco.a:math/chaco
61
CHACO_CONFIGURE_ON=	--with-chaco=yes
45
CHACO_CONFIGURE_ON=	--with-chaco=yes
62
CHACO_CONFIGURE_OFF=	--with-chaco=no
46
CHACO_CONFIGURE_OFF=	--with-chaco=no
63
47
64
GINAC_DESC=		Enable GiNaC-support (not implemented yet)
48
GOTOBLAS_CONFIGURE_ON=	--with-blas=goto --with-goto=goto2
65
GINAC_IGNORE=		you enabled GiNaC-support, which is broken
49
GOTOBLAS_USES=	blaslapack:gotoblas
66
GINAC_LIB_DEPENDS=	libmetis.so:math/metis4 \
67
			libginac.so:math/GiNaC
68
GINAC_CONFIGURE_ON=	--with-ginac=yes
69
GINAC_CONFIGURE_OFF=	--with-ginac=no
70
GINAC_CPPFLAGS=		-I${LOCALBASE}/include/metis
71
50
72
.include <bsd.port.pre.mk>
51
METIS_CONFIGURE_ON=	--with-metis=yes
52
METIS_CONFIGURE_OFF=	--with-metis=no
53
METIS_CPPFLAGS=		-I${LOCALBASE}/include/metis
54
METIS_LIB_DEPENDS=	libmetis.so:math/metis4
73
55
74
.if ${PORT_OPTIONS:MMPI} && ! ${PORT_OPTIONS:MMETIS}
56
REFERENCE_CONFIGURE_ON=	--with-blas=blas
75
WITH_CHACO=	yes
57
REFERENCE_USES=	blaslapack:netlib
76
.endif
77
58
78
pre-configure:
59
pre-configure:
79
	${REINPLACE_CMD} -e '/try_lapack_LIBS=/s/-llapack/${LAPACKLIB}/' \
60
	${REINPLACE_CMD} -e '/try_lapack_LIBS=/s/-llapack/${LAPACKLIB}/' \
Lines 80-83 Link Here
80
		-e 's/ -lxerbla//; s/-lcholmod/-lcholmod ${BLASLIB} ${LAPACKLIB} -lsuitesparseconfig/'	\
61
		-e 's/ -lxerbla//; s/-lcholmod/-lcholmod ${BLASLIB} ${LAPACKLIB} -lsuitesparseconfig/'	\
81
		${WRKSRC}/configure
62
		${WRKSRC}/configure
82
63
83
.include <bsd.port.post.mk>
64
.include <bsd.port.mk>
(-)science/mbdyn/distinfo (-3 / +3 lines)
Lines 1-3 Link Here
1
TIMESTAMP = 1473272629
1
TIMESTAMP = 1497778371
2
SHA256 (mbdyn-1.7.1.tar.gz) = 2c1f21a6459c58103778cb5d771fc49f972baaa57866329ecd1e90dcf04b4ccf
2
SHA256 (mbdyn-1.7.2.tar.gz) = 383977c988ce0a3ebb40ecc62cae8a6276bf42f1aa34e80bd9f2f78d792cd4ff
3
SIZE (mbdyn-1.7.1.tar.gz) = 2834562
3
SIZE (mbdyn-1.7.2.tar.gz) = 2915000
(-)science/mbdyn/files/patch-include__ac__mpi.h (-11 lines)
Lines 1-11 Link Here
1
--- include/ac/mpi.h.orig	2015-10-30 05:05:33 UTC
2
+++ include/ac/mpi.h
3
@@ -35,7 +35,7 @@
4
 #ifdef HAVE_MPI___H
5
 #include <mpi++.h>
6
 #elif defined HAVE_MPICXX_H
7
-#include <mpicxx.h>
8
+#include <mpi.h>
9
 #endif /* ! HAVE_MPI___H && ! HAVE_MPICXX_H */
10
 
11
 #endif /* MPI_H */
(-)science/mbdyn/files/patch-mbdyn__base__invsolver.cc (-12 lines)
Lines 1-12 Link Here
1
--- mbdyn/base/invsolver.cc.orig	2016-04-24 19:10:43 UTC
2
+++ mbdyn/base/invsolver.cc
3
@@ -114,8 +114,8 @@ InverseSolver::Prepare(void)
4
 		pRTSolver->Setup();
5
 	}
6
 
7
-#ifdef USE_SCHUR
8
 	int mpi_finalize = 0;
9
+#ifdef USE_SCHUR
10
 
11
 	if (bParallel) {
12
 		DEBUGLCOUT(MYDEBUG_MEM, "creating parallel SchurDataManager"
(-)science/mbdyn/files/patch-mbdyn__base__solver.cc (-42 lines)
Lines 1-42 Link Here
1
--- mbdyn/base/solver.cc.orig	2016-04-24 19:10:43 UTC
2
+++ mbdyn/base/solver.cc
3
@@ -109,10 +109,17 @@ enum {
4
 };
5
 
6
 volatile sig_atomic_t mbdyn_keep_going = MBDYN_KEEP_GOING;
7
+#if defined(__FreeBSD__)
8
+__sighandler_t *mbdyn_sh_term = SIG_DFL;
9
+__sighandler_t *mbdyn_sh_int = SIG_DFL;
10
+__sighandler_t *mbdyn_sh_hup = SIG_DFL;
11
+__sighandler_t *mbdyn_sh_pipe = SIG_DFL;
12
+#else
13
 __sighandler_t mbdyn_sh_term = SIG_DFL;
14
 __sighandler_t mbdyn_sh_int = SIG_DFL;
15
 __sighandler_t mbdyn_sh_hup = SIG_DFL;
16
 __sighandler_t mbdyn_sh_pipe = SIG_DFL;
17
+#endif
18
 
19
 extern "C" void
20
 mbdyn_really_exit_handler(int signum)
21
@@ -200,7 +207,11 @@ extern "C" void
22
 mbdyn_signal_init(int pre)
23
 {
24
 #ifdef HAVE_SIGNAL
25
+#if defined(__FreeBSD__)
26
+	__sighandler_t *hdl;
27
+#else
28
 	__sighandler_t hdl;
29
+#endif
30
 	if (pre) {
31
 		hdl = mbdyn_really_exit_handler;
32
 
33
@@ -406,8 +417,8 @@ Solver::Prepare(void)
34
 		pRTSolver->Setup();
35
 	}
36
 
37
-#ifdef USE_SCHUR
38
 	int mpi_finalize = 0;
39
+#ifdef USE_SCHUR
40
 
41
 	if (bParallel) {
42
 		DEBUGLCOUT(MYDEBUG_MEM, "creating parallel SchurDataManager"
(-)science/mbdyn/files/patch-mbdyn__mbdyn.h (-18 lines)
Lines 1-18 Link Here
1
--- mbdyn/mbdyn.h.orig	2015-10-30 05:05:37 UTC
2
+++ mbdyn/mbdyn.h
3
@@ -50,6 +50,7 @@ typedef long int      Lint;
4
 typedef double        Real;
5
 
6
 /* signal types */
7
+#if !defined(__FreeBSD__)
8
 #ifdef HAVE_SIGNAL
9
 #ifndef HAVE___SIGHANDLER_T
10
 #ifndef HAVE_SIGHANDLER_T
11
@@ -59,6 +60,7 @@ typedef sighandler_t __sighandler_t;
12
 #endif /* HAVE_SIGHANDLER_T */
13
 #endif /* !HAVE___SIGHANDLER_T */
14
 #endif /* HAVE_SIGNAL */
15
+#endif
16
 
17
 /* sig_atomic_t */
18
 #ifndef HAVE_SIG_ATOMIC_T

Return to bug 220157