aboutsummaryrefslogtreecommitdiffstats
path: root/configure.py
diff options
context:
space:
mode:
Diffstat (limited to 'configure.py')
-rwxr-xr-xconfigure.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/configure.py b/configure.py
index f314a9d57..47a5b473c 100755
--- a/configure.py
+++ b/configure.py
@@ -1784,6 +1784,16 @@ def generate_amalgamation(build_config, options):
if tgt not in botan_amalg_files:
botan_amalg_files[tgt] = open_amalg_file(tgt)
+
+ if tgt != '':
+ for isa in mod.need_isa:
+ if isa == 'aesni':
+ isa = "aes,ssse3,pclmul"
+ elif isa == 'rdrand':
+ isa = 'rdrnd'
+
+ botan_amalg_files[tgt].write('#if defined(__GNUG__)\n#pragma GCC target ("%s")\n#endif\n' % (isa))
+
if tgt not in headers_written:
headers_written[tgt] = headers_written_in_h_files.copy()