2010-08-02 15:20:39 +04:00
|
|
|
{ stdenv
|
|
|
|
, fetchurl
|
|
|
|
, gfortran
|
2015-06-07 21:44:24 +03:00
|
|
|
, openblas
|
2010-08-02 15:20:39 +04:00
|
|
|
}:
|
|
|
|
stdenv.mkDerivation {
|
2012-02-23 02:41:44 +04:00
|
|
|
name = "qrupdate-1.1.2";
|
2010-08-02 15:20:39 +04:00
|
|
|
src = fetchurl {
|
2012-02-23 02:41:44 +04:00
|
|
|
url = mirror://sourceforge/qrupdate/qrupdate-1.1.2.tar.gz ;
|
2015-06-07 21:44:24 +03:00
|
|
|
sha256 = "024f601685phcm1pg8lhif3lpy5j9j0k6n0r46743g4fvh8wg8g2";
|
2010-08-02 15:20:39 +04:00
|
|
|
};
|
2015-06-07 21:44:24 +03:00
|
|
|
|
|
|
|
configurePhase =
|
|
|
|
''
|
|
|
|
export PREFIX=$out
|
|
|
|
sed -i -e 's,^BLAS=.*,BLAS=-L${openblas}/lib -lopenblas,' \
|
|
|
|
-e 's,^LAPACK=.*,LAPACK=-L${openblas}/lib -lopenblas,' \
|
|
|
|
Makeconf
|
|
|
|
''
|
|
|
|
+ stdenv.lib.optionalString openblas.blas64
|
|
|
|
''
|
|
|
|
sed -i Makeconf -e '/^FFLAGS=.*/ s/$/-fdefault-integer-8/'
|
|
|
|
'';
|
2012-02-23 02:41:44 +04:00
|
|
|
|
|
|
|
doCheck = true;
|
|
|
|
|
|
|
|
checkTarget = "test";
|
|
|
|
|
2015-06-07 21:44:24 +03:00
|
|
|
buildFlags = [ "lib" "solib" ];
|
|
|
|
|
2016-07-14 21:47:23 +03:00
|
|
|
installTargets = if stdenv.isDarwin
|
|
|
|
then ["install-staticlib" "install-shlib"]
|
|
|
|
else "install";
|
2012-02-23 02:41:44 +04:00
|
|
|
|
2015-06-07 21:44:24 +03:00
|
|
|
buildInputs = [ gfortran openblas ];
|
2016-08-02 19:06:29 +03:00
|
|
|
|
|
|
|
meta = {
|
|
|
|
platforms = stdenv.lib.platforms.unix;
|
|
|
|
};
|
2010-08-02 15:20:39 +04:00
|
|
|
}
|