]> git.ipfire.org Git - thirdparty/strongswan.git/blob - lib/libcrypto/libaes/Makefile
- import of strongswan-2.7.0
[thirdparty/strongswan.git] / lib / libcrypto / libaes / Makefile
1 CFLAGS=-O3 -fomit-frame-pointer -D__KERNEL__ -Wall -Wcast-qual $(EXTRA_CFLAGS)
2 INC=-I../include
3
4 AES_CORE_OBJ:=aes.o
5
6 ASM-$(ARCH_ASM):=1
7 ASM_X86:=$(ASM-i586)$(ASM-i686)
8 ifneq ($(strip $(ASM_X86)),)
9 AES_CORE_OBJ:= asm/aes-i586.o
10 endif
11
12 LIBOBJ := aes_xcbc_mac.o aes_cbc.o $(AES_CORE_OBJ)
13 LDLIBS := -laes
14 LDFLAGS := -L.
15
16 BLIB := libaes.a
17
18 L_TARGET := $(BLIB)
19
20 .c.o:
21 $(CC) $(CPPFLAGS) $(CFLAGS) $(INC) -c $< -o $@
22
23 .S.o:
24 $(CC) $(AFLAGS) -c $< -o $@
25
26 $(BLIB): $(LIBOBJ)
27 /bin/rm -f $(BLIB)
28 ar cr $(BLIB) $(LIBOBJ)
29 -if test -s /bin/ranlib; then /bin/ranlib $(BLIB); \
30 else if test -s /usr/bin/ranlib; then /usr/bin/ranlib $(BLIB); \
31 else exit 0; fi; fi
32
33 testx: test_main_mac.o $(BLIB)
34 $(CC) -o $@ $^
35
36 test: test_main.o $(BLIB)
37 $(CC) -o $@ $^
38
39 clean:
40 rm -f *.[oa] asm/*.o core $(TARGET) test testx