Commit 3f823b5e authored by Lorenz Huedepohl's avatar Lorenz Huedepohl
Browse files

Madness for Sebastian

In order to be able to figure out the matching MKL version for a given
compiler/MPI repository we emit a new macro '%matching_mkl_version' in
the cases this makes sense
parent 0d8a6e9f
......@@ -480,9 +480,16 @@ Macros:
a.tail = "\n "
r.tail = "\n "
# In order to be able to figure out the matching MKL version for a given
# compiler/MPI repository we emit a new macro '%matching_mkl_version' in
# the cases this makes sense
matching_mkl = []
prjconf.append("%if %_repository == {0}".format(name))
for prefer in prefers(name):
if prefer.startswith("mkl_"):
matching_mkl.append(prefer)
prjconf.append("Prefer: " + prefer)
prjconf.append("Macros:")
prjconf.append("%is_compiler_repository {0}".format(1 if is_compiler else 0))
......@@ -497,6 +504,12 @@ Macros:
if is_cuda:
prjconf.append("%cuda_repository {0}".format(cuda_repo))
if matching_mkl:
matching_mkl, = matching_mkl
matching_mkl, _ = matching_mkl[len("mkl_"):].split("-module")
matching_mkl = matching_mkl.replace("_", ".")
prjconf.append("%matching_mkl_version {0}".format(matching_mkl))
for macro, value in kwargs.items():
prjconf.append("%{0} {1}".format(macro, value))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment