at master 57 lines 1.3 kB view raw
1{ 2 cmake, 3 doctest, 4 fetchFromGitHub, 5 lib, 6 replaceVars, 7 stdenv, 8}: 9 10stdenv.mkDerivation (finalAttrs: { 11 pname = "taskflow"; 12 version = "3.10.0"; 13 14 src = fetchFromGitHub { 15 owner = "taskflow"; 16 repo = "taskflow"; 17 tag = "v${finalAttrs.version}"; 18 hash = "sha256-s0A8zJoq0VfmAks9h4v63J7tPX5JnlNTzJJMilzc5yM="; 19 }; 20 21 patches = [ 22 (replaceVars ./unvendor-doctest.patch { 23 inherit doctest; 24 }) 25 ]; 26 27 postPatch = '' 28 rm -r 3rd-party 29 30 # tries to use x86 intrinsics on aarch64-darwin 31 sed -i '/^#if __has_include (<immintrin\.h>)/,/^#endif/d' taskflow/utility/os.hpp 32 ''; 33 34 nativeBuildInputs = [ 35 cmake 36 ]; 37 38 cmakeFlags = [ 39 # building the tests implies running them in the buildPhase 40 (lib.cmakeBool "TF_BUILD_TESTS" finalAttrs.finalPackage.doCheck) 41 ]; 42 43 doCheck = true; 44 45 meta = { 46 description = "General-purpose Parallel and Heterogeneous Task Programming System"; 47 homepage = "https://taskflow.github.io/"; 48 changelog = 49 let 50 release = lib.replaceStrings [ "." ] [ "-" ] finalAttrs.version; 51 in 52 "https://taskflow.github.io/taskflow/release-${release}.html"; 53 license = lib.licenses.mit; 54 platforms = lib.platforms.unix; 55 maintainers = with lib.maintainers; [ dotlambda ]; 56 }; 57})