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

Collapse All | Expand All

(-)/home/trasz/blacs/Makefile (-4 / +15 lines)
Lines 7-13 Link Here
7
7
8
PORTNAME=	blacs
8
PORTNAME=	blacs
9
PORTVERSION=	1.7
9
PORTVERSION=	1.7
10
PORTREVISION=	2
10
PORTREVISION=	3
11
CATEGORIES=	math
11
CATEGORIES=	math
12
MASTER_SITES=	ftp://ftp.netlib.org/blacs/
12
MASTER_SITES=	ftp://ftp.netlib.org/blacs/
13
DISTNAME=	BLACS
13
DISTNAME=	BLACS
Lines 22-34 Link Here
22
MAINTAINER=	maho@FreeBSD.org
22
MAINTAINER=	maho@FreeBSD.org
23
COMMENT=	The BLACS (Basic Linear Algebra Communication Subprograms)
23
COMMENT=	The BLACS (Basic Linear Algebra Communication Subprograms)
24
24
25
BUILD_DEPENDS=	${LOCALBASE}/mpich2/lib/libmpich.a:${PORTSDIR}/net/mpich2
26
RUN_DEPENDS=	${LOCALBASE}/mpich2/bin/mpirun:${PORTSDIR}/net/mpich2
27
28
PKGMESSAGE=	${WRKDIR}/pkg-message
25
PKGMESSAGE=	${WRKDIR}/pkg-message
29
SUB_FILES=	pkg-message
26
SUB_FILES=	pkg-message
30
27
31
.include <bsd.port.pre.mk>
28
.include <bsd.port.pre.mk>
29
30
.if exists(${LOCALBASE}/mpi/openmpi/bin/mpirun)
31
WITH_OPENMPI=	yes
32
.endif
33
34
.if defined(WITH_OPENMPI)
35
BUILD_DEPENDS=	${LOCALBASE}/mpi/openmpi/lib/libmpi.so:${PORTSDIR}/net/openmpi
36
RUN_DEPENDS=	${LOCALBASE}/mpi/openmpi/bin/mpirun:${PORTSDIR}/net/openmpi
37
EXTRA_PATCHES+=	${FILESDIR}/Bmake.inc-openmpi.diff
38
.else
39
BUILD_DEPENDS=	${LOCALBASE}/mpich2/lib/libmpich.a:${PORTSDIR}/net/mpich2
40
RUN_DEPENDS=	${LOCALBASE}/mpich2/bin/mpirun:${PORTSDIR}/net/mpich2
41
EXTRA_PATCHES+=	${FILESDIR}/Bmake.inc-mpich.diff
42
.endif
32
43
33
pre-fetch:
44
pre-fetch:
34
	@${ECHO} "If you want to use compiler other than f77,"
45
	@${ECHO} "If you want to use compiler other than f77,"
(-)/home/trasz/blacs/files/Bmake.inc-mpich.diff (+64 lines)
Line 0 Link Here
1
--- Bmake.inc.orig	Mon May  5 10:53:00 2003
2
+++ Bmake.inc	Mon May  5 10:58:38 2003
3
@@ -13,7 +13,7 @@
4
 #  -----------------------------
5
 #  The top level BLACS directory
6
 #  -----------------------------
7
-   BTOPdir = $(HOME)/BLACS
8
+   BTOPdir = @WRKSRC@
9
 
10
 #  ---------------------------------------------------------------------------
11
 #  The communication library your BLACS have been written for.
12
@@ -32,14 +32,14 @@
13
 #  -------------------------------------------------------------
14
 #  The platform identifier to suffix to the end of library names
15
 #  -------------------------------------------------------------
16
-   PLAT = LINUX
17
+   PLAT = FreeBSD
18
 
19
 #  ----------------------------------------------------------
20
 #  Name and location of the BLACS library.  See section 2 for 
21
 #  details on BLACS debug level (BLACSDBGLVL).
22
 #  ----------------------------------------------------------
23
    BLACSdir    = $(BTOPdir)/LIB
24
-   BLACSDBGLVL = 0
25
+   BLACSDBGLVL = @DEBUG_LEVEL@
26
    BLACSFINIT  = $(BLACSdir)/blacsF77init_$(COMMLIB)-$(PLAT)-$(BLACSDBGLVL).a
27
    BLACSCINIT  = $(BLACSdir)/blacsCinit_$(COMMLIB)-$(PLAT)-$(BLACSDBGLVL).a
28
    BLACSLIB    = $(BLACSdir)/blacs_$(COMMLIB)-$(PLAT)-$(BLACSDBGLVL).a
29
@@ -47,10 +47,10 @@
30
 #  -------------------------------------
31
 #  Name and location of the MPI library.
32
 #  -------------------------------------
33
-   MPIdir = /usr/local/mpich
34
+   MPIdir = @LOCALBASE@/mpich2
35
    MPILIBdir = $(MPIdir)/lib/
36
    MPIINCdir = $(MPIdir)/include
37
-   MPILIB = $(MPILIBdir)/libmpich.a
38
+   MPILIB = $(MPILIBdir)/libmpich.a
39
 
40
 #  -------------------------------------
41
 #  All libraries required by the tester.
42
@@ -195,16 +195,15 @@
43
 #  optimization.  This is the F77NO_OPTFLAG.  The usage of the remaining
44
 #  macros should be obvious from the names.
45
 #=============================================================================
46
-   F77            = g77
47
-   F77NO_OPTFLAGS = 
48
-   F77FLAGS       = $(F77NO_OPTFLAGS) -O
49
-   F77LOADER      = $(F77)
50
+   F77            = @F77@
51
+   F77NO_OPTFLAGS = @F77EXTRAFLAGS@
52
+   F77FLAGS       = @FFLAGS@
53
+   F77LOADER      = @F77@
54
    F77LOADFLAGS   = 
55
-   CC             = gcc
56
-   CCFLAGS        = -O4
57
+   CC             = @CC@
58
+   CCFLAGS        = @CFLAGS@
59
    CCLOADER       = $(CC)
60
    CCLOADFLAGS    = 
61
-
62
 #  --------------------------------------------------------------------------
63
 #  The archiver and the flag(s) to use when building an archive (library).
64
 #  Also the ranlib routine.  If your system has no ranlib, set RANLIB = echo.
(-)/home/trasz/blacs/files/Bmake.inc-openmpi.diff (+84 lines)
Line 0 Link Here
1
--- Bmake.inc.orig	Mon Nov 13 14:17:35 2006
2
+++ Bmake.inc	Mon Nov 13 14:19:18 2006
3
@@ -13,7 +13,7 @@
4
 #  -----------------------------
5
 #  The top level BLACS directory
6
 #  -----------------------------
7
-   BTOPdir = $(HOME)/BLACS
8
+   BTOPdir = @WRKSRC@
9
 
10
 #  ---------------------------------------------------------------------------
11
 #  The communication library your BLACS have been written for.
12
@@ -32,14 +32,14 @@
13
 #  -------------------------------------------------------------
14
 #  The platform identifier to suffix to the end of library names
15
 #  -------------------------------------------------------------
16
-   PLAT = LINUX
17
+   PLAT = FreeBSD
18
 
19
 #  ----------------------------------------------------------
20
 #  Name and location of the BLACS library.  See section 2 for 
21
 #  details on BLACS debug level (BLACSDBGLVL).
22
 #  ----------------------------------------------------------
23
    BLACSdir    = $(BTOPdir)/LIB
24
-   BLACSDBGLVL = 0
25
+   BLACSDBGLVL = @DEBUG_LEVEL@
26
    BLACSFINIT  = $(BLACSdir)/blacsF77init_$(COMMLIB)-$(PLAT)-$(BLACSDBGLVL).a
27
    BLACSCINIT  = $(BLACSdir)/blacsCinit_$(COMMLIB)-$(PLAT)-$(BLACSDBGLVL).a
28
    BLACSLIB    = $(BLACSdir)/blacs_$(COMMLIB)-$(PLAT)-$(BLACSDBGLVL).a
29
@@ -47,10 +47,10 @@
30
 #  -------------------------------------
31
 #  Name and location of the MPI library.
32
 #  -------------------------------------
33
-   MPIdir = /usr/local/mpich
34
-   MPILIBdir = $(MPIdir)/lib/
35
+   MPIdir = @LOCALBASE@/mpi/openmpi
36
+   MPILIBdir = 
37
    MPIINCdir = $(MPIdir)/include
38
-   MPILIB = $(MPILIBdir)/libmpich.a
39
+   MPILIB = 
40
 
41
 #  -------------------------------------
42
 #  All libraries required by the tester.
43
@@ -86,7 +86,7 @@
44
 #  The directory to find the required communication library include files, 
45
 #  if they are required by your system.
46
 #  -----------------------------------------------------------------------
47
-   SYSINC = -I$(MPIINCdir)
48
+   SYSINC = 
49
 
50
 #  ---------------------------------------------------------------------------
51
 #  The Fortran 77 to C interface to be used.  If you are unsure of the correct
52
@@ -140,7 +140,7 @@
53
 #  If you know that your MPI uses the same handles for fortran and C
54
 #  communicators, you can replace the empty macro definition below with
55
 #  the macro definition on the following line.
56
-  TRANSCOMM = -DCSameF77
57
+  TRANSCOMM = -DUseMpi2
58
 #  -----------------------------------------------------------------------
59
 #  TRANSCOMM =
60
 
61
@@ -195,16 +195,15 @@
62
 #  optimization.  This is the F77NO_OPTFLAG.  The usage of the remaining
63
 #  macros should be obvious from the names.
64
 #=============================================================================
65
-   F77            = g77
66
-   F77NO_OPTFLAGS = 
67
-   F77FLAGS       = $(F77NO_OPTFLAGS) -O
68
-   F77LOADER      = $(F77)
69
+   F77            = mpif77
70
+   F77NO_OPTFLAGS = @F77EXTRAFLAGS@
71
+   F77FLAGS       = @FFLAGS@
72
+   F77LOADER      = mpif77
73
    F77LOADFLAGS   = 
74
-   CC             = gcc
75
-   CCFLAGS        = -O4
76
-   CCLOADER       = $(CC)
77
+   CC             = mpicc
78
+   CCFLAGS        = @CFLAGS@
79
+   CCLOADER       = mpicc
80
    CCLOADFLAGS    = 
81
-
82
 #  --------------------------------------------------------------------------
83
 #  The archiver and the flag(s) to use when building an archive (library).
84
 #  Also the ranlib routine.  If your system has no ranlib, set RANLIB = echo.
(-)/home/trasz/blacs/files/patch-Bmake.inc (-64 lines)
Lines 1-64 Link Here
1
--- Bmake.inc.orig	Mon May  5 10:53:00 2003
2
+++ Bmake.inc	Mon May  5 10:58:38 2003
3
@@ -13,7 +13,7 @@
4
 #  -----------------------------
5
 #  The top level BLACS directory
6
 #  -----------------------------
7
-   BTOPdir = $(HOME)/BLACS
8
+   BTOPdir = @WRKSRC@
9
 
10
 #  ---------------------------------------------------------------------------
11
 #  The communication library your BLACS have been written for.
12
@@ -32,14 +32,14 @@
13
 #  -------------------------------------------------------------
14
 #  The platform identifier to suffix to the end of library names
15
 #  -------------------------------------------------------------
16
-   PLAT = LINUX
17
+   PLAT = FreeBSD
18
 
19
 #  ----------------------------------------------------------
20
 #  Name and location of the BLACS library.  See section 2 for 
21
 #  details on BLACS debug level (BLACSDBGLVL).
22
 #  ----------------------------------------------------------
23
    BLACSdir    = $(BTOPdir)/LIB
24
-   BLACSDBGLVL = 0
25
+   BLACSDBGLVL = @DEBUG_LEVEL@
26
    BLACSFINIT  = $(BLACSdir)/blacsF77init_$(COMMLIB)-$(PLAT)-$(BLACSDBGLVL).a
27
    BLACSCINIT  = $(BLACSdir)/blacsCinit_$(COMMLIB)-$(PLAT)-$(BLACSDBGLVL).a
28
    BLACSLIB    = $(BLACSdir)/blacs_$(COMMLIB)-$(PLAT)-$(BLACSDBGLVL).a
29
@@ -47,10 +47,10 @@
30
 #  -------------------------------------
31
 #  Name and location of the MPI library.
32
 #  -------------------------------------
33
-   MPIdir = /usr/local/mpich
34
+   MPIdir = @LOCALBASE@/mpich2
35
    MPILIBdir = $(MPIdir)/lib/
36
    MPIINCdir = $(MPIdir)/include
37
-   MPILIB = $(MPILIBdir)/libmpich.a
38
+   MPILIB = $(MPILIBdir)/libmpich.a
39
 
40
 #  -------------------------------------
41
 #  All libraries required by the tester.
42
@@ -195,16 +195,15 @@
43
 #  optimization.  This is the F77NO_OPTFLAG.  The usage of the remaining
44
 #  macros should be obvious from the names.
45
 #=============================================================================
46
-   F77            = g77
47
-   F77NO_OPTFLAGS = 
48
-   F77FLAGS       = $(F77NO_OPTFLAGS) -O
49
-   F77LOADER      = $(F77)
50
+   F77            = @F77@
51
+   F77NO_OPTFLAGS = @F77EXTRAFLAGS@
52
+   F77FLAGS       = @FFLAGS@
53
+   F77LOADER      = @F77@
54
    F77LOADFLAGS   = 
55
-   CC             = gcc
56
-   CCFLAGS        = -O4
57
+   CC             = @CC@
58
+   CCFLAGS        = @CFLAGS@
59
    CCLOADER       = $(CC)
60
    CCLOADFLAGS    = 
61
-
62
 #  --------------------------------------------------------------------------
63
 #  The archiver and the flag(s) to use when building an archive (library).
64
 #  Also the ranlib routine.  If your system has no ranlib, set RANLIB = echo.
(-)/home/trasz/blacs/files/pkg-message.in (+7 lines)
Lines 9-14 Link Here
9
  % %%LOCALBASE%%/mpich2/bin/mpirun -np 4 ./xFbtest_MPI-FreeBSD
9
  % %%LOCALBASE%%/mpich2/bin/mpirun -np 4 ./xFbtest_MPI-FreeBSD
10
  % %%LOCALBASE%%/mpich2/bin/mpdallexit
10
  % %%LOCALBASE%%/mpich2/bin/mpdallexit
11
11
12
 Or, if you're using OpenMPI:
13
  % cd %%PREFIX%%/share/BLACS/TESTING
14
  % LD_LIBRARY_PATH=%%LOCALBASE%%/mpi/openmpi/lib/ export LD_LIBRARY_PATH
15
  % PATH=$PATH:%%LOCALBASE%%/mpi/openmpi/bin/ export PATH
16
  % mpirun -np 4 ./xCbtest_MPI-FreeBSD
17
  % mpirun -np 4 ./xFbtest_MPI-FreeBSD
18
12
You can change -np 4 to any number to meet your local environment.
19
You can change -np 4 to any number to meet your local environment.
13
See files at %%DOCSDIR%% for detail.
20
See files at %%DOCSDIR%% for detail.
14
*********************************************************************
21
*********************************************************************

Return to bug 105474