@@ -15,6 +15,8 @@
1515# Select a specific optimization target (other than the default)
1616# See https://github.com/xianyi/OpenBLAS/blob/develop/TargetList.txt
1717, target ? null
18+# Select whether DYNAMIC_ARCH is enabled or not.
19+, dynamicArch ? null
1820, enableStatic ? stdenv.hostPlatform.isStatic
1921, enableShared ? !stdenv.hostPlatform.isStatic
2022}:
@@ -25,27 +27,28 @@ let blas64_ = blas64; in
2527
2628let
2729 setTarget = x: if target == null then x else target;
30+ setDynamicArch = x: if dynamicArch == null then x else dynamicArch;
2831
2932 # To add support for a new platform, add an element to this set.
3033 configs = {
3134 armv6l-linux = {
3235 BINARY = 32;
3336 TARGET = setTarget "ARMV6";
34− DYNAMIC_ARCH = false;
37+ DYNAMIC_ARCH = setDynamicArch false;
3538 USE_OPENMP = true;
3639 };
3740
3841 armv7l-linux = {
3942 BINARY = 32;
4043 TARGET = setTarget "ARMV7";
41− DYNAMIC_ARCH = false;
44+ DYNAMIC_ARCH = setDynamicArch false;
4245 USE_OPENMP = true;
4346 };
4447
4548 aarch64-darwin = {
4649 BINARY = 64;
4750 TARGET = setTarget "VORTEX";
48− DYNAMIC_ARCH = true;
51+ DYNAMIC_ARCH = setDynamicArch true;
4952 USE_OPENMP = false;
5053 MACOSX_DEPLOYMENT_TARGET = "11.0";
5154 };
@@ -53,21 +56,21 @@ let
5356 aarch64-linux = {
5457 BINARY = 64;
5558 TARGET = setTarget "ARMV8";
56− DYNAMIC_ARCH = true;
59+ DYNAMIC_ARCH = setDynamicArch true;
5760 USE_OPENMP = true;
5861 };
5962
6063 i686-linux = {
6164 BINARY = 32;
6265 TARGET = setTarget "P2";
63− DYNAMIC_ARCH = true;
66+ DYNAMIC_ARCH = setDynamicArch true;
6467 USE_OPENMP = true;
6568 };
6669
6770 x86_64-darwin = {
6871 BINARY = 64;
6972 TARGET = setTarget "ATHLON";
70− DYNAMIC_ARCH = true;
73+ DYNAMIC_ARCH = setDynamicArch true;
7174 USE_OPENMP = false;
7275 MACOSX_DEPLOYMENT_TARGET = "10.7";
7376 };
@@ -75,14 +78,14 @@ let
7578 x86_64-linux = {
7679 BINARY = 64;
7780 TARGET = setTarget "ATHLON";
78− DYNAMIC_ARCH = true;
81+ DYNAMIC_ARCH = setDynamicArch true;
7982 USE_OPENMP = !stdenv.hostPlatform.isMusl;
8083 };
8184
8285 powerpc64le-linux = {
8386 BINARY = 64;
8487 TARGET = setTarget "POWER5";
85− DYNAMIC_ARCH = true;
88+ DYNAMIC_ARCH = setDynamicArch true;
8689 USE_OPENMP = !stdenv.hostPlatform.isMusl;
8790 };
8891 };