summaryrefslogtreecommitdiffstats
path: root/secure/lib/libcipher/test/Makefile
blob: 50ae57100caf8b6154fdcd176a614d69ef9a0368 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
#
#	Hacked Makefile to compile and run the DES-certification program,
#	but not install anything.
#
# $FreeBSD$
#
LIBCRYPT!=cd $(.CURDIR)/..; \
	printf "xxx:\n\techo \$${.OBJDIR}/libcipher.a\n" | make -r -s -f - xxx

#CFLAGS+= -DHAVE_CRYPT16
LIBCRYPT+= -lcrypt

TARGETS=cert speedcrypt speeddes

all: ${TARGETS}

test: all testcrypt testencrypt testdes testspeed

testcrypt: cert
	@./cert -c

testencrypt: cert
	@./cert -e < ${.CURDIR}/cert.input

testdes: cert
	@./cert -d < ${.CURDIR}/cert.input

testspeed: cryptspeed desspeed

cryptspeed: speedcrypt
	@./speedcrypt 30 1
	@./speedcrypt 30 1
	@./speedcrypt 30 0
	@./speedcrypt 30 0

desspeed: speeddes
	@./speeddes 30 1
	@./speeddes 30 1
	@./speeddes 40 25
	@./speeddes 40 25

cert: cert.c ${LIBCRYPT}
	$(CC) $(CFLAGS) -o cert ${.CURDIR}/cert.c ${LIBCRYPT}

speedcrypt: speedcrypt.c ${LIBCRYPT}
	$(CC) $(CFLAGS) -o speedcrypt ${.CURDIR}/speedcrypt.c ${LIBCRYPT}

speeddes: speeddes.c ${LIBCRYPT}
	$(CC) $(CFLAGS) -o speeddes ${.CURDIR}/speeddes.c ${LIBCRYPT}

clean:
	rm -f ${TARGETS}

install:

.include <bsd.prog.mk>
OpenPOWER on IntegriCloud