summaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile12
1 files changed, 9 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index f41a87e..bc15f74 100644
--- a/Makefile
+++ b/Makefile
@@ -9,6 +9,9 @@
BINS = keygen crypt
OBJS1 = keygen.o keygen_args.o miller_rabin.o
OBJS2 = crypt.o crypt_args.o
+BIGINT_OBJS = ./bigint/BigUnsigned.o ./bigint/BigInteger.o \
+ ./bigint/BigIntegerAlgorithms.o ./bigint/BigUnsignedInABase.o \
+ ./bigint/BigIntegerUtils.o
CC = g++
DBGFLAGS = -g -O0
ifdef DEBUG
@@ -20,8 +23,8 @@ LDFLAGS = -lm
all: $(BINS)
-crypt: $(OBJS2)
- $(CC) $(LDFLAGS) $(OBJS2) -o crypt
+crypt: $(OBJS2) bigint
+ $(CC) $(LDFLAGS) $(OBJS2) $(BIGINT_OBJS) -o crypt
keygen: $(OBJS1)
$(CC) $(LDFLAGS) $(OBJS1) -o keygen
@@ -41,7 +44,10 @@ keygen_args.o: %.o: %.cpp %.h
miller_rabin.o: %.o: %.cpp %.h
$(CC) -c $(CFLAGS) $<
-.PHONY: clean
+bigint:
+ cd ./bigint && make && cd ..
+
+.PHONY: clean bigint
clean:
rm -f $(OBJS1) $(OBJS2) $(BINS) *.xml