From a85314e3da4beb5d228d8ba9a73b12be39c60722 Mon Sep 17 00:00:00 2001 From: Maho Nakata Date: Sun, 19 Nov 2006 01:42:13 +0000 Subject: Update to 1.7.4 - Add support for OpenMPI (requires math/blacs compiled with OpenMPI) - Make it possible to use math/blas instead of math/atlas PR: 105497 Submitted by: trasz --- math/scalapack/files/SLmake.inc-mpich.diff | 62 ++++++++++++++++++++++++++++ math/scalapack/files/SLmake.inc-openmpi.diff | 62 ++++++++++++++++++++++++++++ math/scalapack/files/patch-SLmake.inc | 62 ---------------------------- math/scalapack/files/pkg-message.in | 8 ++++ 4 files changed, 132 insertions(+), 62 deletions(-) create mode 100644 math/scalapack/files/SLmake.inc-mpich.diff create mode 100644 math/scalapack/files/SLmake.inc-openmpi.diff delete mode 100644 math/scalapack/files/patch-SLmake.inc (limited to 'math/scalapack/files') diff --git a/math/scalapack/files/SLmake.inc-mpich.diff b/math/scalapack/files/SLmake.inc-mpich.diff new file mode 100644 index 000000000000..b484fadc4a89 --- /dev/null +++ b/math/scalapack/files/SLmake.inc-mpich.diff @@ -0,0 +1,62 @@ +--- SLmake.inc.orig Thu Aug 9 11:59:50 2001 ++++ SLmake.inc Mon May 5 11:51:11 2003 +@@ -19,26 +19,26 @@ + # The complete path to the top level of ScaLAPACK directory, usually + # $(HOME)/SCALAPACK + # +-home = $(HOME)/SCALAPACK ++home = @WRKSRC@ + # + # The platform identifier to suffix to the end of library names + # +-PLAT = LINUX ++PLAT = FreeBSD + # + # BLACS setup. All version need the debug level (0 or 1), + # and the directory where the BLACS libraries are + # + BLACSDBGLVL = 0 +-BLACSdir = /usr/local/lib ++BLACSdir = @LOCALBASE@/lib + # + # MPI setup; tailor to your system if using MPIBLACS + # Will need to comment out these 6 lines if using PVM + # + USEMPI = -DUsingMpiBlacs +-SMPLIB = /usr/local/mpich-1.2.1/lib/libmpich.a +-BLACSFINIT = $(BLACSdir)/libmpiblacsF77init-p4.a +-BLACSCINIT = $(BLACSdir)/libmpiblacsCinit-p4.a +-BLACSLIB = $(BLACSdir)/libmpiblacs-p4.a ++SMPLIB = @LOCALBASE@/mpich2/lib/libmpich.a ++BLACSFINIT = $(BLACSdir)/libblacsf77.a ++BLACSCINIT = $(BLACSdir)/libblacsc.a ++BLACSLIB = $(BLACSdir)/libblacs.a + TESTINGdir = $(home)/TESTING + + # +@@ -67,12 +67,12 @@ + # + # The fortran and C compilers, loaders, and their flags + # +-F77 = g77 ++F77 = @F77@ + #F77 = /usr/local/pgi/linux86/bin/pgf77 +-CC = gcc ++CC = @CC@ + NOOPT = +-F77FLAGS = -O3 $(NOOPT) +-CCFLAGS = -O4 ++F77FLAGS = @FFLAGS@ ++CCFLAGS = @CFLAGS@ + SRCFLAG = + F77LOADER = $(F77) + CCLOADER = $(CC) +@@ -94,7 +94,7 @@ + # The name of the libraries to be created/linked to + # + SCALAPACKLIB = $(home)/libscalapack.a +-BLASLIB = /usr/local/lib/libf77blas.a /usr/local/lib/libatlas.a ++BLASLIB = -L@LOCALBASE@/lib @BLAS@ + # + PBLIBS = $(SCALAPACKLIB) $(FBLACSLIB) $(BLASLIB) $(SMPLIB) + PRLIBS = $(SCALAPACKLIB) $(CBLACSLIB) $(SMPLIB) diff --git a/math/scalapack/files/SLmake.inc-openmpi.diff b/math/scalapack/files/SLmake.inc-openmpi.diff new file mode 100644 index 000000000000..6b60fbd8e810 --- /dev/null +++ b/math/scalapack/files/SLmake.inc-openmpi.diff @@ -0,0 +1,62 @@ +--- SLmake.inc.orig Thu Aug 9 04:59:50 2001 ++++ SLmake.inc Mon Nov 13 15:45:36 2006 +@@ -19,26 +19,26 @@ + # The complete path to the top level of ScaLAPACK directory, usually + # $(HOME)/SCALAPACK + # +-home = $(HOME)/SCALAPACK ++home = @WRKSRC@ + # + # The platform identifier to suffix to the end of library names + # +-PLAT = LINUX ++PLAT = FreeBSD + # + # BLACS setup. All version need the debug level (0 or 1), + # and the directory where the BLACS libraries are + # + BLACSDBGLVL = 0 +-BLACSdir = /usr/local/lib ++BLACSdir = @LOCALBASE@/lib + # + # MPI setup; tailor to your system if using MPIBLACS + # Will need to comment out these 6 lines if using PVM + # + USEMPI = -DUsingMpiBlacs +-SMPLIB = /usr/local/mpich-1.2.1/lib/libmpich.a +-BLACSFINIT = $(BLACSdir)/libmpiblacsF77init-p4.a +-BLACSCINIT = $(BLACSdir)/libmpiblacsCinit-p4.a +-BLACSLIB = $(BLACSdir)/libmpiblacs-p4.a ++SMPLIB = ++BLACSFINIT = $(BLACSdir)/libblacsf77.a ++BLACSCINIT = $(BLACSdir)/libblacsc.a ++BLACSLIB = $(BLACSdir)/libblacs.a + TESTINGdir = $(home)/TESTING + + # +@@ -67,12 +67,12 @@ + # + # The fortran and C compilers, loaders, and their flags + # +-F77 = g77 ++F77 = mpif77 + #F77 = /usr/local/pgi/linux86/bin/pgf77 +-CC = gcc ++CC = mpicc + NOOPT = +-F77FLAGS = -O3 $(NOOPT) +-CCFLAGS = -O4 ++F77FLAGS = @FFLAGS@ ++CCFLAGS = @CFLAGS@ + SRCFLAG = + F77LOADER = $(F77) + CCLOADER = $(CC) +@@ -94,7 +94,7 @@ + # The name of the libraries to be created/linked to + # + SCALAPACKLIB = $(home)/libscalapack.a +-BLASLIB = /usr/local/lib/libf77blas.a /usr/local/lib/libatlas.a ++BLASLIB = -L@LOCALBASE@/lib @BLAS@ + # + PBLIBS = $(SCALAPACKLIB) $(FBLACSLIB) $(BLASLIB) $(SMPLIB) + PRLIBS = $(SCALAPACKLIB) $(CBLACSLIB) $(SMPLIB) diff --git a/math/scalapack/files/patch-SLmake.inc b/math/scalapack/files/patch-SLmake.inc deleted file mode 100644 index b484fadc4a89..000000000000 --- a/math/scalapack/files/patch-SLmake.inc +++ /dev/null @@ -1,62 +0,0 @@ ---- SLmake.inc.orig Thu Aug 9 11:59:50 2001 -+++ SLmake.inc Mon May 5 11:51:11 2003 -@@ -19,26 +19,26 @@ - # The complete path to the top level of ScaLAPACK directory, usually - # $(HOME)/SCALAPACK - # --home = $(HOME)/SCALAPACK -+home = @WRKSRC@ - # - # The platform identifier to suffix to the end of library names - # --PLAT = LINUX -+PLAT = FreeBSD - # - # BLACS setup. All version need the debug level (0 or 1), - # and the directory where the BLACS libraries are - # - BLACSDBGLVL = 0 --BLACSdir = /usr/local/lib -+BLACSdir = @LOCALBASE@/lib - # - # MPI setup; tailor to your system if using MPIBLACS - # Will need to comment out these 6 lines if using PVM - # - USEMPI = -DUsingMpiBlacs --SMPLIB = /usr/local/mpich-1.2.1/lib/libmpich.a --BLACSFINIT = $(BLACSdir)/libmpiblacsF77init-p4.a --BLACSCINIT = $(BLACSdir)/libmpiblacsCinit-p4.a --BLACSLIB = $(BLACSdir)/libmpiblacs-p4.a -+SMPLIB = @LOCALBASE@/mpich2/lib/libmpich.a -+BLACSFINIT = $(BLACSdir)/libblacsf77.a -+BLACSCINIT = $(BLACSdir)/libblacsc.a -+BLACSLIB = $(BLACSdir)/libblacs.a - TESTINGdir = $(home)/TESTING - - # -@@ -67,12 +67,12 @@ - # - # The fortran and C compilers, loaders, and their flags - # --F77 = g77 -+F77 = @F77@ - #F77 = /usr/local/pgi/linux86/bin/pgf77 --CC = gcc -+CC = @CC@ - NOOPT = --F77FLAGS = -O3 $(NOOPT) --CCFLAGS = -O4 -+F77FLAGS = @FFLAGS@ -+CCFLAGS = @CFLAGS@ - SRCFLAG = - F77LOADER = $(F77) - CCLOADER = $(CC) -@@ -94,7 +94,7 @@ - # The name of the libraries to be created/linked to - # - SCALAPACKLIB = $(home)/libscalapack.a --BLASLIB = /usr/local/lib/libf77blas.a /usr/local/lib/libatlas.a -+BLASLIB = -L@LOCALBASE@/lib @BLAS@ - # - PBLIBS = $(SCALAPACKLIB) $(FBLACSLIB) $(BLASLIB) $(SMPLIB) - PRLIBS = $(SCALAPACKLIB) $(CBLACSLIB) $(SMPLIB) diff --git a/math/scalapack/files/pkg-message.in b/math/scalapack/files/pkg-message.in index 61261cc6fa64..28d99c43a274 100644 --- a/math/scalapack/files/pkg-message.in +++ b/math/scalapack/files/pkg-message.in @@ -20,6 +20,14 @@ ? end % %%LOCALBASE%%/mpich2/bin/mpdallexit + If you're using OpenMPI, use this instead: + % cd %%DATADIR%%/TESTING + % LD_LIBRARY_PATH=%%LOCALBASE%%/mpi/openmpi/lib/ export LD_LIBRARY_PATH + % PATH=$PATH:%%LOCALBASE%%/mpi/openmpi/bin/ export PATH + % mpirun -np 4 ./xcbrd + % mpirun -np 4 ./xcdblu + etc., etc. ... + You can change -np 4 to any number to meet your environment. See files at %%DOCSDIR%% for detail. ********************************************************************** -- cgit v1.2.3