pkgs/development/libraries/science/math/liblapack: fixed build and updated to version 3.2.1
svn path=/nixpkgs/trunk/; revision=19672
This commit is contained in:
parent
a5030f06df
commit
8cb6ced793
@ -0,0 +1,24 @@
|
||||
diff -Naur lapack-3.2.old/SRC/Makefile lapack-3.2/SRC/Makefile
|
||||
--- lapack-3.2.old/SRC/Makefile 2009-02-04 11:33:35.006839507 +0100
|
||||
+++ lapack-3.2/SRC/Makefile 2009-02-04 11:33:51.987551506 +0100
|
||||
@@ -367,7 +367,7 @@
|
||||
$(ALLAUX)
|
||||
|
||||
../$(LAPACKLIB): $(ALLOBJ) $(ALLXOBJ)
|
||||
- $(ARCH) $(ARCHFLAGS) $@ $(ALLOBJ) $(ALLXOBJ)
|
||||
+ $(ARCH) $(ARCHFLAGS) $@ $(ALLOBJ) $(ALLXOBJ) -lblas
|
||||
$(RANLIB) $@
|
||||
|
||||
single: $(SLASRC) $(ALLAUX) $(SCLAUX)
|
||||
diff -Naur lapack-3.2.old/TESTING/MATGEN/Makefile lapack-3.2/TESTING/MATGEN/Makefile
|
||||
--- lapack-3.2.old/TESTING/MATGEN/Makefile 2009-02-04 11:35:10.426806473 +0100
|
||||
+++ lapack-3.2/TESTING/MATGEN/Makefile 2009-02-04 11:34:42.850565181 +0100
|
||||
@@ -60,7 +60,7 @@
|
||||
|
||||
../../$(TMGLIB): $(SMATGEN) $(CMATGEN) $(SCATGEN) $(DMATGEN) \
|
||||
$(ZMATGEN) $(DZATGEN)
|
||||
- $(ARCH) $(ARCHFLAGS) $@ $(ALLOBJ)
|
||||
+ $(ARCH) $(ARCHFLAGS) $@ $(ALLOBJ) -lblas
|
||||
$(RANLIB) $@
|
||||
|
||||
single: $(SMATGEN) $(SCATGEN)
|
@ -1,25 +1,50 @@
|
||||
args: with args;
|
||||
{ stdenv, fetchurl, gfortran, blas }:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "liblapack-3.1.1";
|
||||
name = "liblapack-3.2.1";
|
||||
src = fetchurl {
|
||||
url = http://www.netlib.org/lapack/lapack.tgz;
|
||||
sha256 = "0am0yzgqhaz6yzliaxc2cgm2mbqjzwcq70b01migk5231frkbhz4";
|
||||
url = "http://www.netlib.org/lapack/lapack-3.2.1.tgz";
|
||||
sha256 = "5825f83971157001fd4235514afe8ff5fc16e1c06b2e872e442c242efd6c166d";
|
||||
};
|
||||
|
||||
buildInputs = [gfortran];
|
||||
patches = [ ./gfortran.patch ];
|
||||
buildInputs = [gfortran blas];
|
||||
patches = [ ./blas-link.patch ];
|
||||
|
||||
configurePhase = ''
|
||||
echo >make.inc "SHELL = ${stdenv.bash}/bin/bash"
|
||||
echo >>make.inc "PLAT ="
|
||||
echo >>make.inc "FORTRAN = gfortran"
|
||||
echo >>make.inc "OPTS = -O2 -fPIC"
|
||||
echo >>make.inc "DRVOPTS = \$(OPTS)"
|
||||
echo >>make.inc "NOOPT = -O0 -fPIC"
|
||||
echo >>make.inc "LOADER = gfortran"
|
||||
echo >>make.inc "LOADOPTS ="
|
||||
echo >>make.inc "TIMER = INT_ETIME"
|
||||
echo >>make.inc "ARCH = gfortran"
|
||||
echo >>make.inc "ARCHFLAGS = -shared -o"
|
||||
echo >>make.inc "RANLIB = echo"
|
||||
echo >>make.inc "BLASLIB = -lblas"
|
||||
echo >>make.inc "LAPACKLIB = liblapack.so.3"
|
||||
echo >>make.inc "TMGLIB = libtmglib.so.3"
|
||||
echo >>make.inc "EIGSRCLIB = libeigsrc.so.3"
|
||||
echo >>make.inc "LINSRCLIB = liblinsrc.so.3"
|
||||
'';
|
||||
|
||||
buildPhase = ''
|
||||
cp make.inc.example make.inc
|
||||
make blaslib
|
||||
# make lapacklib
|
||||
cd SRC
|
||||
make
|
||||
make clean
|
||||
make lib
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
ensureDir "$out/lib"
|
||||
install -m755 *.so* "$out/lib"
|
||||
ln -sf liblapack.so.3 "$out/lib/liblapack.so"
|
||||
ln -sf libtmglib.so.3 "$out/lib/libtmglib.so"
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "lapack library";
|
||||
license = "Free, copyrighted";
|
||||
homepage = http://www.netlib.org/lapac;
|
||||
description = "Linear Algebra PACKage";
|
||||
license = "Free, copyrighted";
|
||||
homepage = "http://www.netlib.org/lapack/";
|
||||
};
|
||||
}
|
||||
|
@ -8406,9 +8406,9 @@ let
|
||||
libXmu libXext libXcursor;
|
||||
};
|
||||
|
||||
/* liblapack = import ../development/libraries/science/math/liblapack {
|
||||
inherit fetchurl stdenv gfortran;
|
||||
}; */
|
||||
liblapack = import ../development/libraries/science/math/liblapack {
|
||||
inherit fetchurl stdenv gfortran blas;
|
||||
};
|
||||
|
||||
|
||||
### SCIENCE/LOGIC
|
||||
|
Loading…
Reference in New Issue
Block a user