e02b1526eda3b9df2df84cd03014b70b9a62f781
[silc.git] / lib / silcsim / Makefile.am
1 #
2 #  Makefile.am
3 #
4 #  Author: Pekka Riikonen <priikone@poseidon.pspt.fi>
5 #
6 #  Copyright (C) 2000 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; either version 2 of the License, or
11 #  (at your option) any later version.
12 #
13 #  This program is distributed in the hope that it will be useful,
14 #  but WITHOUT ANY WARRANTY; without even the implied warranty of
15 #  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16 #  GNU General Public License for more details.
17 #
18
19 AUTOMAKE_OPTIONS = 1.0 no-dependencies foreign
20
21 if SILC_SIM
22 noinst_LTLIBRARIES = libsilcsim.la
23 else
24 noinst_LTLIBRARIES = 
25 endif
26
27 libsilcsim_la_SOURCES = \
28         silcsim.c \
29         silcsimutil.c
30
31 #
32 # SILC Ciphers to be compiled as modules
33 #
34 SIM_CIPHER_OBJS = \
35         none.o \
36         blowfish.o \
37         rc5.o \
38         rc6.o \
39         aes.o \
40         rsa.o \
41         twofish.o \
42         cast.o
43
44 #
45 # SILC Hash Functions to be compiled as modules
46 #
47 SIM_HASH_OBJS = \
48         md5.o \
49         sha1.o
50
51 if SILC_SIM
52 all: $(SIM_CIPHER_OBJS) $(SIM_HASH_OBJS)
53 endif
54
55 $(SIM_CIPHER_OBJS):
56         @if test '!' -f lib$*.la ; then \
57           $(LIBTOOL) --mode=link $(CCLD) -rpath $(silc_modulesdir) \
58                 ../silccrypt/$*.lo -o lib$*.la; \
59           cd $(srcdir) && $(LN_S) -f $(srcdir)/.libs/lib$*.so \
60                 $(srcdir)/$*.sim.so; \
61         fi
62
63 $(SIM_HASH_OBJS):
64         @if test '!' -f lib$*.la ; then \
65           $(LIBTOOL) --mode=link $(CCLD) -rpath $(silc_modulesdir) \
66                 ../silccrypt/$*.lo -o lib$*.la; \
67           cd $(srcdir) && $(LN_S) -f $(srcdir)/.libs/lib$*.so \
68                 $(srcdir)/$*.sim.so; \
69         fi
70
71 CLEANFILES = *.sim.so *.la
72
73 if SILC_DIST_TOOLKIT
74 include_HEADERS = silcsim.h silcsimutil.h
75 endif
76
77 EXTRA_DIST = *.h
78
79 include $(top_srcdir)/Makefile.defines.in