nixpkgs/pkgs/development/libraries/tbb/default.nix

46 lines
1.6 KiB
Nix
Raw Normal View History

{ stdenv, fetchFromGitHub, compiler ? if stdenv.cc.isClang then "clang" else null, stdver ? null }:
2012-07-18 11:44:34 +01:00
with stdenv.lib; stdenv.mkDerivation rec {
name = "tbb-${version}";
version = "2019_U7";
2012-07-18 11:44:34 +01:00
src = fetchFromGitHub {
owner = "01org";
repo = "tbb";
rev = version;
sha256 = "0hf8vkb1g2dqihqw7fzhc90i1p7yvp45gbamj0mnnhffz2ablz1b";
2012-07-18 11:44:34 +01:00
};
makeFlags = concatStringsSep " " (
optional (compiler != null) "compiler=${compiler}" ++
optional (stdver != null) "stdver=${stdver}"
);
patches = stdenv.lib.optional stdenv.hostPlatform.isMusl ./glibc-struct-mallinfo.patch;
2012-07-18 11:44:34 +01:00
installPhase = ''
2019-04-02 09:41:10 +01:00
mkdir -p $out/lib
2017-09-12 20:36:41 +01:00
cp "build/"*release*"/"*${stdenv.hostPlatform.extensions.sharedLibrary}* $out/lib/
2012-07-18 11:44:34 +01:00
mv include $out/
rm $out/include/index.html
'';
enableParallelBuilding = true;
meta = {
2012-07-18 11:44:34 +01:00
description = "Intel Thread Building Blocks C++ Library";
homepage = "http://threadingbuildingblocks.org/";
license = licenses.asl20;
2012-07-18 11:44:34 +01:00
longDescription = ''
Intel Threading Building Blocks offers a rich and complete approach to
expressing parallelism in a C++ program. It is a library that helps you
take advantage of multi-core processor performance without having to be a
threading expert. Intel TBB is not just a threads-replacement library. It
represents a higher-level, task-based parallelism that abstracts platform
details and threading mechanisms for scalability and performance.
'';
platforms = with platforms; linux ++ darwin;
maintainers = with maintainers; [ thoughtpolice dizfer ];
2012-07-18 11:44:34 +01:00
};
}