1 { lib, stdenv, fetchFromGitHub, autoreconfHook, givaro, pkg-config, blas, lapack
5 assert (!blas.isILP64) && (!lapack.isILP64);
7 stdenv.mkDerivation rec {
8 pname = "fflas-ffpack";
11 src = fetchFromGitHub {
12 owner = "linbox-team";
15 sha256 = "sha256-Eztc2jUyKRVUiZkYEh+IFHkDuPIy+Gx3ZW/MsuOVaMc=";
22 enableParallelBuilding = true;
27 ] ++ lib.optionals doCheck checkInputs;
29 buildInputs = [ givaro blas lapack ];
32 "--with-blas-libs=-lcblas"
33 "--with-lapack-libs=-llapacke"
34 ] ++ lib.optionals stdenv.isx86_64 [
35 # disable SIMD instructions (which are enabled *when available* by default)
36 # for now we need to be careful to disable *all* relevant versions of an instruction set explicitly (https://github.com/linbox-team/fflas-ffpack/issues/284)
37 "--${if stdenv.hostPlatform.sse3Support then "enable" else "disable"}-sse3"
38 "--${if stdenv.hostPlatform.ssse3Support then "enable" else "disable"}-ssse3"
39 "--${if stdenv.hostPlatform.sse4_1Support then "enable" else "disable"}-sse41"
40 "--${if stdenv.hostPlatform.sse4_2Support then "enable" else "disable"}-sse42"
41 "--${if stdenv.hostPlatform.avxSupport then "enable" else "disable"}-avx"
42 "--${if stdenv.hostPlatform.avx2Support then "enable" else "disable"}-avx2"
43 "--${if stdenv.hostPlatform.avx512Support then "enable" else "disable"}-avx512f"
44 "--${if stdenv.hostPlatform.avx512Support then "enable" else "disable"}-avx512dq"
45 "--${if stdenv.hostPlatform.avx512Support then "enable" else "disable"}-avx512vl"
46 "--${if stdenv.hostPlatform.fmaSupport then "enable" else "disable"}-fma"
47 "--${if stdenv.hostPlatform.fma4Support then "enable" else "disable"}-fma4"
52 broken = stdenv.isDarwin;
53 description = "Finite Field Linear Algebra Subroutines";
54 license = licenses.lgpl21Plus;
55 maintainers = teams.sage.members;
56 platforms = platforms.unix;
57 homepage = "https://linbox-team.github.io/fflas-ffpack/";