2021-01-21 09:00:13 -08:00
|
|
|
{lib, stdenv, fetchurl, unzip}:
|
2011-03-03 05:41:06 -08:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2018-03-09 03:58:15 -08:00
|
|
|
name = "libf2c-20160102";
|
2016-02-10 16:03:11 -08:00
|
|
|
|
2011-03-03 05:41:06 -08:00
|
|
|
src = fetchurl {
|
2020-03-31 18:11:51 -07:00
|
|
|
url = "http://www.netlib.org/f2c/libf2c.zip";
|
2018-03-09 03:58:15 -08:00
|
|
|
sha256 = "1q78y8j8xpl8zdzdxmn5ablss56hi5a7vz3idam9l2nfx5q40h6a";
|
2011-03-03 05:41:06 -08:00
|
|
|
};
|
|
|
|
|
|
|
|
unpackPhase = ''
|
|
|
|
mkdir build
|
|
|
|
cd build
|
|
|
|
unzip ${src}
|
|
|
|
'';
|
|
|
|
|
2019-10-27 06:03:25 -07:00
|
|
|
makeFlags = [ "-f" "makefile.u" ];
|
2011-03-03 05:41:06 -08:00
|
|
|
|
|
|
|
installPhase = ''
|
2012-01-18 12:16:00 -08:00
|
|
|
mkdir -p $out/include $out/lib
|
2011-03-03 05:41:06 -08:00
|
|
|
cp libf2c.a $out/lib
|
|
|
|
cp f2c.h $out/include
|
|
|
|
'';
|
|
|
|
|
2021-02-20 13:01:53 -08:00
|
|
|
nativeBuildInputs = [ unzip ];
|
2011-03-03 05:41:06 -08:00
|
|
|
|
2016-02-26 09:38:15 -08:00
|
|
|
hardeningDisable = [ "format" ];
|
2016-02-10 16:03:11 -08:00
|
|
|
|
2011-03-03 05:41:06 -08:00
|
|
|
meta = {
|
|
|
|
description = "F2c converts Fortran 77 source code to C";
|
2020-03-31 18:11:51 -07:00
|
|
|
homepage = "http://www.netlib.org/f2c/";
|
2021-01-21 09:00:13 -08:00
|
|
|
license = lib.licenses.mit;
|
|
|
|
platforms = lib.platforms.unix;
|
2011-03-03 05:41:06 -08:00
|
|
|
};
|
|
|
|
}
|