Blob Blame History Raw
--- scalapack-1.7/scalapack-1.7.5/Makefile.fedora	2001-08-10 11:44:13.000000000 -0500
+++ scalapack-1.7/scalapack-1.7.5/Makefile	2006-03-08 18:08:21.000000000 -0600
@@ -49,7 +49,7 @@
 all: lib
 #all: lib exe
 
-lib: toolslib pblaslib redistlib scalapacklib
+lib: toolslib pblaslib redistlib scalapacklib shared
 
 exe: pblasexe redistexe scalapackexe
 
@@ -90,3 +90,6 @@
 	( cd $(SRCdir); $(MAKE) clean )
 	( cd $(TOOLSdir); $(MAKE) clean )
 	( cd $(REDISTdir)/SRC; $(MAKE) clean )
+
+shared: scalapacklib
+	( mkdir tmp ; cp $(SCALAPACKLIB) tmp ; cd tmp ; ar x $(SCALAPACKLIB) ; $(CC) -shared -o $(home)/libscalapack.so.1.0.0 *.o -Wl,-soname=libscalapack.so.1 -lblas -llapack -lmpiblacs -lmpiblacsF77init -lmpiblacsCinit -lm -lgfortran; cd .. )
--- scalapack-1.7.5/scalapack-1.7.5/SLmake.inc.fedora	2001-08-08 21:59:50.000000000 -0500
+++ scalapack-1.7.5/scalapack-1.7.5/SLmake.inc	2006-03-08 18:09:05.000000000 -0600
@@ -19,7 +19,7 @@
 #  The complete path to the top level of ScaLAPACK directory, usually
 #  $(HOME)/SCALAPACK
 #
-home          = $(HOME)/SCALAPACK
+home          = $(RPM_BUILD_DIR)/scalapack-1.7.5/scalapack-1.7.5-FOO
 #
 #  The platform identifier to suffix to the end of library names
 #
@@ -35,10 +35,10 @@
 #  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    = -lmpiblacsF77init
+BLACSCINIT    = -lmpiblacsCinit
+BLACSLIB      = -lmpiblacs
 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
-NOOPT         = 
-F77FLAGS      =  -O3 $(NOOPT)
-CCFLAGS       = -O4
+CC            = mpicc
+NOOPT         = -fPIC
+F77FLAGS      = $(RPM_OPT_FLAGS) $(NOOPT)
+CCFLAGS       = $(RPM_OPT_FLAGS) $(NOOPT)
 SRCFLAG       =
 F77LOADER     = $(F77)
 CCLOADER      = $(CC)
@@ -82,7 +82,7 @@
 #  C preprocessor defs for compilation 
 #  (-DNoChange, -DAdd_, -DUpCase, or -Df77IsF2C)
 #
-CDEFS         = -Df77IsF2C -DNO_IEEE $(USEMPI)
+CDEFS         = -DAdd_ -DNO_IEEE $(USEMPI)
 #
 #  The archiver and the flag(s) to use when building archive (library)
 #  Also the ranlib routine.  If your system has no ranlib, set RANLIB = echo
@@ -94,9 +94,10 @@
 #  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
+SCALAPACKSLIB = -L$(home) -lscalapack
+BLASLIB       = -lblas
 #
-PBLIBS        = $(SCALAPACKLIB) $(FBLACSLIB) $(BLASLIB) $(SMPLIB)
-PRLIBS        = $(SCALAPACKLIB) $(CBLACSLIB) $(SMPLIB)
-RLIBS         = $(SCALAPACKLIB) $(FBLACSLIB) $(CBLACSLIB) $(BLASLIB) $(SMPLIB)
+PBLIBS        = $(SCALAPACKSLIB) $(FBLACSLIB) $(BLASLIB) $(SMPLIB)
+PRLIBS        = $(SCALAPACKSLIB) $(CBLACSLIB) $(SMPLIB)
+RLIBS         = $(SCALAPACKSLIB) $(FBLACSLIB) $(CBLACSLIB) $(BLASLIB) $(SMPLIB)
 LIBS          = $(PBLIBS)