Compilation environment fixes to make make install work correctly.
[crypto.git] / lib / silccrypt / Makefile.ad
1 #
2 #  Makefile.ad
3 #
4 #  Author: Pekka Riikonen <priikone@silcnet.org>
5 #
6 #  Copyright (C) 2000 - 2008 Pekka Riikonen
7 #
8 #  This program is free software; you can redistribute it and/or modify
9 #  it under the terms of the GNU General Public License as published by
10 #  the Free Software Foundation; version 2 of the License.
11 #
12 #  This program is distributed in the hope that it will be useful,
13 #  but WITHOUT ANY WARRANTY; without even the implied warranty of
14 #  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15 #  GNU General Public License for more details.
16 #
17
18 AUTOMAKE_OPTIONS = 1.0 no-dependencies foreign
19
20 SUBDIRS=tests
21
22 noinst_LTLIBRARIES = libsilccrypt.la
23
24 if SILC_AES_ASM
25 if SILC_I486
26 SILC_AES_S = aes_x86.asm aes.c
27 endif
28 if SILC_X86_64
29 SILC_AES_S = aes_x86_64.asm aes.c
30 endif
31 else
32 SILC_AES_S = aes.c
33 endif
34
35 libsilccrypt_la_SOURCES =       \
36         none.c                  \
37         md5.c                   \
38         $(SILC_AES_S)           \
39         rsa.c                   \
40         dsa.c                   \
41         sha1.c                  \
42         sha256.c                \
43         sha256_x86.S            \
44         sha512.c                \
45         twofish.c               \
46         blowfish.c              \
47         cast5.c                 \
48         des.c                   \
49         silccrypto.c            \
50         silccipher.c            \
51         silchash.c              \
52         silcmac.c               \
53         silcrng.c               \
54         silcpkcs.c              \
55         silcpkcs1.c             \
56         silcpk.c
57
58 CFLAGS = @SILC_CRYPTO_CFLAGS@
59
60 include_HEADERS =               \
61         silccrypto.h            \
62         silccipher.h            \
63         silccipher_i.h          \
64         silchash.h              \
65         silcmac.h               \
66         silcpkcs.h              \
67         silcpkcs_i.h            \
68         silcrng.h               \
69         silcpkcs1.h             \
70         silcpk.h
71
72 SILC_EXTRA_DIST =
73
74 SUFFIXES = .asm
75
76 .asm.lo:
77         $(LIBTOOL) --tag=CC --mode=compile @SILC_ASSEMBLER@ $< @SILC_AES_ASM_FLAGS@
78
79 EXTRA_DIST = *.h *.asm $(SILC_EXTRA_DIST)
80
81 include $(top_srcdir)/Makefile.defines.in
82
83 # Workaround a bug in GCC 2.x which causes memory exhaustion
84 # when compiling sha1 with optimizations on UltraSPARC.
85 #
86 @FIX_SHA1@sha1.lo:
87 @FIX_SHA1@      $(LTCOMPILE) -O0 -c -o $@ `test -f 'sha1.c' || echo '$(srcdir)/'`sha1.c
88 @FIX_SHA1@