mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-09 22:45:08 +00:00
571c71e6f7
We are migrating packages that meet below requirements: 1. using `callPackage` 2. called path is a directory 3. overriding set is empty (`{ }`) 4. not containing path expressions other than relative path (to makenixpkgs-vet happy) 5. not referenced by nix files outside of the directory, other than`pkgs/top-level/all-packages.nix` 6. not referencing nix files outside of the directory 7. not referencing `default.nix` (since it's changed to `package.nix`) 8. `outPath` doesn't change after migration The tool is here: https://github.com/Aleksanaa/by-name-migrate.
61 lines
2.2 KiB
Nix
61 lines
2.2 KiB
Nix
{ lib, stdenv, fetchFromGitHub, autoreconfHook, givaro, pkg-config, blas, lapack
|
|
, gmpxx
|
|
}:
|
|
|
|
assert (!blas.isILP64) && (!lapack.isILP64);
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "fflas-ffpack";
|
|
version = "2.5.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "linbox-team";
|
|
repo = pname;
|
|
rev = "v${version}";
|
|
sha256 = "sha256-Eztc2jUyKRVUiZkYEh+IFHkDuPIy+Gx3ZW/MsuOVaMc=";
|
|
};
|
|
|
|
nativeCheckInputs = [
|
|
gmpxx
|
|
];
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
nativeBuildInputs = [
|
|
autoreconfHook
|
|
pkg-config
|
|
] ++ lib.optionals doCheck nativeCheckInputs;
|
|
|
|
buildInputs = [ givaro blas lapack ];
|
|
|
|
configureFlags = [
|
|
"--with-blas-libs=-lcblas"
|
|
"--with-lapack-libs=-llapacke"
|
|
"--without-archnative"
|
|
] ++ lib.optionals stdenv.hostPlatform.isx86_64 [
|
|
# disable SIMD instructions (which are enabled *when available* by default)
|
|
# 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)
|
|
"--${if stdenv.hostPlatform.sse3Support then "enable" else "disable"}-sse3"
|
|
"--${if stdenv.hostPlatform.ssse3Support then "enable" else "disable"}-ssse3"
|
|
"--${if stdenv.hostPlatform.sse4_1Support then "enable" else "disable"}-sse41"
|
|
"--${if stdenv.hostPlatform.sse4_2Support then "enable" else "disable"}-sse42"
|
|
"--${if stdenv.hostPlatform.avxSupport then "enable" else "disable"}-avx"
|
|
"--${if stdenv.hostPlatform.avx2Support then "enable" else "disable"}-avx2"
|
|
"--${if stdenv.hostPlatform.avx512Support then "enable" else "disable"}-avx512f"
|
|
"--${if stdenv.hostPlatform.avx512Support then "enable" else "disable"}-avx512dq"
|
|
"--${if stdenv.hostPlatform.avx512Support then "enable" else "disable"}-avx512vl"
|
|
"--${if stdenv.hostPlatform.fmaSupport then "enable" else "disable"}-fma"
|
|
"--${if stdenv.hostPlatform.fma4Support then "enable" else "disable"}-fma4"
|
|
];
|
|
doCheck = true;
|
|
|
|
meta = with lib; {
|
|
description = "Finite Field Linear Algebra Subroutines";
|
|
mainProgram = "fflas-ffpack-config";
|
|
license = licenses.lgpl21Plus;
|
|
maintainers = teams.sage.members;
|
|
platforms = platforms.unix;
|
|
homepage = "https://linbox-team.github.io/fflas-ffpack/";
|
|
};
|
|
}
|