summaryrefslogtreecommitdiff
path: root/asm.m4
diff options
context:
space:
mode:
authorNiels Möller <nisse@lysator.liu.se>2012-07-12 22:36:13 +0200
committerNiels Möller <nisse@lysator.liu.se>2012-07-12 22:36:13 +0200
commit5933421316cf047db0313f637097c69fb73f0661 (patch)
tree7ad78892a21e1054d673fb5d43eb32f2a4f52657 /asm.m4
parentee6ff2cc52df67191c06760f7e9c88e8e83862c1 (diff)
downloadnettle-5933421316cf047db0313f637097c69fb73f0661.tar.gz
m4 portability fix for ALIGN macro.
Diffstat (limited to 'asm.m4')
-rw-r--r--asm.m49
1 files changed, 7 insertions, 2 deletions
diff --git a/asm.m4 b/asm.m4
index e2721d4b..d632585b 100644
--- a/asm.m4
+++ b/asm.m4
@@ -23,9 +23,14 @@ define(<EPILOGUE>,
<.size C_NAME($1), . - C_NAME($1)>,<>)>)
dnl Argument to ALIGN is always logarithmic
-dnl Can't use << operator with our choice of quote characters...
+
+dnl Need changequote to be able to use the << operator (using **
+dnl instead is not portable, and is not supported by openbsd m4).
define(<ALIGN>,
-<.align ifelse(ALIGN_LOG,yes,$1,eval(2 ** $1))>)
+<changequote([,])dnl
+.align ifelse(ALIGN_LOG,yes,$1,eval(1 << $1))dnl >> balance
+changequote(<,>)dnl
+>)
dnl Struct defining macros