9 # Select SIMD alignment width (in bytes) for vectorization.
11 # Pad arrays to simdWidth by default?
12 # Note: Only useful if simdWidth > 1
13 , enablePadding ? false
14 # Activate serialization through Boost.Serialize?
15 , enableSerialization ? true
16 # Activate test-suite?
17 # WARNING: Some of the tests require up to 1700MB of memory to compile.
22 inherit (lib) optional optionals;
24 stdenv.mkDerivation rec {
28 src = fetchFromGitHub {
32 sha256 = "0nq84vwvvbq7m0my6h835ijfw53bxdp42qjc6kjhk436888qy9rh";
35 nativeBuildInputs = [ pkg-config python2 texinfo ];
36 buildInputs = [ gfortran texinfo boost ];
48 "--disable-latex-docs"
49 "--enable-simd-width=${toString simdWidth}"
50 "--with-boost=${boost.dev}"
51 "--with-boost-libdir=${boost.out}/lib"
52 ] ++ optional enablePadding "--enable-array-length-padding"
53 ++ optional enableSerialization "--enable-serialization"
54 ++ optional stdenv.is64bit "--enable-64bit";
56 # skip broken library name detection
57 ax_boost_user_serialization_lib = lib.optionalString stdenv.isDarwin "boost_serialization";
59 enableParallelBuilding = true;
62 checkTarget = "check-testsuite check-examples";
65 description = "Fast multi-dimensional array library for C++";
66 homepage = "https://sourceforge.net/projects/blitz/";
67 license = licenses.lgpl3;
68 platforms = platforms.unix;
69 maintainers = with maintainers; [ ToxicFrog ];
71 Blitz++ is a C++ class library for scientific computing which provides
72 performance on par with Fortran 77/90. It uses template techniques to
73 achieve high performance. Blitz++ provides dense arrays and vectors,
74 random number generators, and small vectors (useful for representing
75 multicomponent or vector fields).