aboutsummaryrefslogtreecommitdiff
path: root/lib/curve25519-donna/Makefile
diff options
context:
space:
mode:
authorMark Haines <mjark@negativecurvature.net>2015-02-26 16:40:56 +0000
committerMark Haines <mjark@negativecurvature.net>2015-02-26 16:40:56 +0000
commit6c56bcf2fd3db38c679b9cf9345051a7309fa02f (patch)
treed587e9a7d8f7e0fc91d4d04b2e4903175a682a83 /lib/curve25519-donna/Makefile
parent09d8e84c7cbbf21195f3fd2eabbcff44042d5a4e (diff)
parente50ac707316ea6d8059f7036322450727773952d (diff)
Merge commit 'e50ac707316ea6d8059f7036322450727773952d' as 'lib/curve25519-donna'
Diffstat (limited to 'lib/curve25519-donna/Makefile')
-rw-r--r--lib/curve25519-donna/Makefile56
1 files changed, 56 insertions, 0 deletions
diff --git a/lib/curve25519-donna/Makefile b/lib/curve25519-donna/Makefile
new file mode 100644
index 0000000..e31fcca
--- /dev/null
+++ b/lib/curve25519-donna/Makefile
@@ -0,0 +1,56 @@
+CFLAGS=-Wmissing-prototypes -Wdeclaration-after-statement -O2 -Wall
+CFLAGS_32=-m32
+
+targets: curve25519-donna.a curve25519-donna-c64.a
+
+test: test-donna test-donna-c64
+
+clean:
+ rm -f *.o *.a *.pp test-curve25519-donna test-curve25519-donna-c64 speed-curve25519-donna speed-curve25519-donna-c64 test-noncanon-curve25519-donna test-noncanon-curve25519-donna-c64
+
+curve25519-donna.a: curve25519-donna.o
+ ar -rc curve25519-donna.a curve25519-donna.o
+ ranlib curve25519-donna.a
+
+curve25519-donna.o: curve25519-donna.c
+ gcc -c curve25519-donna.c $(CFLAGS) $(CFLAGS_32)
+
+curve25519-donna-c64.a: curve25519-donna-c64.o
+ ar -rc curve25519-donna-c64.a curve25519-donna-c64.o
+ ranlib curve25519-donna-c64.a
+
+curve25519-donna-c64.o: curve25519-donna-c64.c
+ gcc -c curve25519-donna-c64.c $(CFLAGS)
+
+test-donna: test-curve25519-donna
+ ./test-curve25519-donna | head -123456 | tail -1
+
+test-donna-c64: test-curve25519-donna-c64
+ ./test-curve25519-donna-c64 | head -123456 | tail -1
+
+test-curve25519-donna: test-curve25519.c curve25519-donna.a
+ gcc -o test-curve25519-donna test-curve25519.c curve25519-donna.a $(CFLAGS) $(CFLAGS_32)
+
+test-curve25519-donna-c64: test-curve25519.c curve25519-donna-c64.a
+ gcc -o test-curve25519-donna-c64 test-curve25519.c curve25519-donna-c64.a $(CFLAGS)
+
+speed-curve25519-donna: speed-curve25519.c curve25519-donna.a
+ gcc -o speed-curve25519-donna speed-curve25519.c curve25519-donna.a $(CFLAGS) $(CFLAGS_32)
+
+speed-curve25519-donna-c64: speed-curve25519.c curve25519-donna-c64.a
+ gcc -o speed-curve25519-donna-c64 speed-curve25519.c curve25519-donna-c64.a $(CFLAGS)
+
+test-sc-curve25519-donna-c64: test-sc-curve25519.c curve25519-donna-c64.a
+ gcc -o test-sc-curve25519-donna-c64 -O test-sc-curve25519.c curve25519-donna-c64.a test-sc-curve25519.s $(CFLAGS)
+
+test-noncanon-donna: test-noncanon-curve25519-donna
+ ./test-noncanon-curve25519-donna
+
+test-noncanon-donna-c64: test-noncanon-curve25519-donna-c64
+ ./test-noncanon-curve25519-donna-c64
+
+test-noncanon-curve25519-donna: test-noncanon.c curve25519-donna.a
+ gcc -o test-noncanon-curve25519-donna test-noncanon.c curve25519-donna.a $(CFLAGS) $(CFLAGS_32)
+
+test-noncanon-curve25519-donna-c64: test-noncanon.c curve25519-donna-c64.a
+ gcc -o test-noncanon-curve25519-donna-c64 test-noncanon.c curve25519-donna-c64.a $(CFLAGS)