aboutsummaryrefslogtreecommitdiff
path: root/Makefile.in
blob: ee9daae83dac4f87cac132e013347885a26e53f3 (plain) (blame)
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
# @configure_input@

INC		= cryptech.h
LIB		= libcryptech.a
OBJ		= ${IO_OBJ} csprng.o hash.o aes_keywrap.o errorstrings.o

IO_OBJ		= ${IO_OBJ_@FPGA_BUS@}
IO_OBJ_EIM	= hal_io_eim.o novena-eim.o
IO_OBJ_I2C 	= hal_io_i2c.o

CC		= @CC@
CFLAGS		= @CFLAGS@
LDFLAGS		= @LDFLAGS@

prefix		= @prefix@
exec_prefix	= @exec_prefix@
includedir	= @includedir@
libdir		= @libdir@

all: ${LIB}
	cd tests; ${MAKE} $@

${OBJ}: ${INC}

${LIB}: ${OBJ}
	ar rcs $@ $^

test: all
	cd tests; ${MAKE} -k $@

install: ${LIB} ${INC}
	install ${LIB} ${libdir}
	install ${INC} ${includedir}

uninstall:
	cd ${libdir}; rm -f ${LIB}
	cd ${includedir}; rm -f ${INC}

clean:
	rm -f ${OBJ} ${LIB}
	cd tests; ${MAKE} $@

distclean: clean
	cd tests; ${MAKE} $@
	rm -f config.log config.status TAGS Makefile

tags: TAGS

TAGS: *.[ch]
	etags $^