0d260d199857de7dd47e9b3856a6618f13acc0ea
[openafs.git] / src / crypto / hcrypto / Makefile.in
1 # Copyright 2010, Your File System Inc
2 # All rights reserved
3 #
4 # This software has been released under the terms of the BSD License
5 # For details, see the LICENSE file in the top level source directory
6
7 srcdir=@srcdir@
8 include @TOP_OBJDIR@/src/config/Makefile.config
9 include @TOP_OBJDIR@/src/config/Makefile.lwp
10 include @TOP_OBJDIR@/src/config/Makefile.lwptool
11 top_builddir=@top_builddir@
12
13 LT_current = 2
14 LT_revision = 0
15 LT_age = 0
16
17 LT_objs = aes.lo camellia.lo camellia-ntt.lo des.lo engine.lo evp.lo \
18           evp-hcrypto.lo evp-cc.lo hmac.lo md2.lo md4.lo md5.lo pkcs5.lo \
19           rand-egd.lo rand-timer.lo rand-unix.lo rand.lo rc2.lo rc4.lo \
20           rijndael-alg-fst.lo rnd_keys.lo sha.lo sha256.lo sha512.lo ui.lo \
21           validate.lo rand-fortuna.lo
22
23 LT_libs = $(LDFLAGS_roken) $(LIB_roken)
24
25 HEADERS= ${TOP_INCDIR}/hcrypto/aes.h \
26          ${TOP_INCDIR}/hcrypto/des.h \
27          ${TOP_INCDIR}/hcrypto/engine.h \
28          ${TOP_INCDIR}/hcrypto/evp.h \
29          ${TOP_INCDIR}/hcrypto/evp-hcrypto.h \
30          ${TOP_INCDIR}/hcrypto/evp-cc.h \
31          ${TOP_INCDIR}/hcrypto/hmac.h \
32          ${TOP_INCDIR}/hcrypto/md2.h \
33          ${TOP_INCDIR}/hcrypto/md4.h \
34          ${TOP_INCDIR}/hcrypto/md5.h \
35          ${TOP_INCDIR}/hcrypto/rand.h \
36          ${TOP_INCDIR}/hcrypto/rc2.h \
37          ${TOP_INCDIR}/hcrypto/rc4.h \
38          ${TOP_INCDIR}/hcrypto/sha.h \
39          ${TOP_INCDIR}/hcrypto/ui.h
40
41 UPSTREAM= ${TOP_SRCDIR}/external/heimdal
42
43 MODULE_INCLUDE=-I${srcdir} -I${TOP_INCDIR}/hcrypto -I$(UPSTREAM)/hcrypto
44
45 all: @hcrypto_all_target@
46
47 all-internal: ${HEADERS} ${TOP_LIBDIR}/libafshcrypto.$(SHLIB_SUFFIX) \
48         ${TOP_LIBDIR}/libafshcrypto.a \
49         ${TOP_LIBDIR}/libafshcrypto_lwp.a
50
51 all-lwp: ${HEADERS} ${TOP_LIBDIR}/libafshcrypto_lwp.a
52
53 buildtools: ${HEADERS} ${TOP_LIBDIR}/libafshcrypto.a
54
55 install: @hcrypto_install_target@
56
57 install-internal: libafshcrypto.la libafshcrypto.a
58         ${LT_INSTALL_DATA} libafshcrypto.la ${DESTDIR}${libdir}/libafshcrypto.la
59         ${RM} ${DESTDIR}${libdir}/libafshcrypto.la
60         ${INSTALL_DATA} libafshcrypto.a ${DESTDIR}${libdir}/libafshcrypto.a
61
62 dest: libafshcrypto.la libafshcrypto.a
63         ${LT_INSTALL_DATA} libafshcrypto.la ${DEST}/lib/libafshcrypto.la
64         ${RM} ${DEST}/lib/libafshcrypto.la
65         ${INSTALL_DATA} libafshcrypto.a ${DEST}/lib/libafshcrypto.a
66
67 clean:
68         $(LT_CLEAN)
69         $(RM) -f ${OBJECTS} rand-fortuna_lwp.o \
70                 libafshcrypto.a libafshcrypto_lwp.a libafshcrypto.exp \
71                 test_cipher test_cipher.o
72
73 $(LT_objs): $(HEADERS)
74
75 libafshcrypto.la: libafshcrypto.la.sym $(LT_objs)
76         $(LT_LDLIB_shlib) $(LT_objs) $(LT_libs)
77
78 libafshcrypto.a: $(LT_objs)
79         $(LT_LDLIB_static) $(LT_objs)
80
81 libafshcrypto_lwp.a: $(LT_objs)
82         $(LT_LDLIB_lwp) $(LT_objs)
83
84 test_cipher: test_cipher.lo libafshcrypto.la
85         $(LT_LDRULE_static) test_cipher.lo libafshcrypto.la
86
87 ${TOP_INCDIR}/hcrypto/aes.h: ${UPSTREAM}/hcrypto/aes.h
88         ${INSTALL_DATA} $? $@
89
90 ${TOP_INCDIR}/hcrypto/bn.h: ${UPSTREAM}/hcrypto/bn.h
91         ${INSTALL_DATA} $? $@
92
93 ${TOP_INCDIR}/hcrypto/des.h: ${UPSTREAM}/hcrypto/des.h
94         ${INSTALL_DATA} $? $@
95
96 ${TOP_INCDIR}/hcrypto/dh.h: ${UPSTREAM}/hcrypto/dh.h
97         ${INSTALL_DATA} $? $@
98
99 ${TOP_INCDIR}/hcrypto/dsa.h: ${UPSTREAM}/hcrypto/dsa.h
100         ${INSTALL_DATA} $? $@
101
102 ${TOP_INCDIR}/hcrypto/engine.h: engine.h
103         ${INSTALL_DATA} $? $@
104
105 ${TOP_INCDIR}/hcrypto/evp.h: ${UPSTREAM}/hcrypto/evp.h
106         ${INSTALL_DATA} $? $@
107
108 ${TOP_INCDIR}/hcrypto/evp-hcrypto.h: ${UPSTREAM}/hcrypto/evp-hcrypto.h
109         ${INSTALL_DATA} $? $@
110
111 ${TOP_INCDIR}/hcrypto/evp-cc.h: ${UPSTREAM}/hcrypto/evp-cc.h
112         ${INSTALL_DATA} $? $@
113
114 ${TOP_INCDIR}/hcrypto/hmac.h: ${UPSTREAM}/hcrypto/hmac.h
115         ${INSTALL_DATA} $? $@
116
117 ${TOP_INCDIR}/hcrypto/md2.h: ${UPSTREAM}/hcrypto/md2.h
118         ${INSTALL_DATA} $? $@
119
120 ${TOP_INCDIR}/hcrypto/md4.h: ${UPSTREAM}/hcrypto/md4.h
121         ${INSTALL_DATA} $? $@
122
123 ${TOP_INCDIR}/hcrypto/md5.h: ${UPSTREAM}/hcrypto/md5.h
124         ${INSTALL_DATA} $? $@
125
126 ${TOP_INCDIR}/hcrypto/pkcs12.h: ${UPSTREAM}/hcrypto/pkcs12.h
127         ${INSTALL_DATA} $? $@
128
129 ${TOP_INCDIR}/hcrypto/rand.h: ${UPSTREAM}/hcrypto/rand.h
130         ${INSTALL_DATA} $? $@
131
132 ${TOP_INCDIR}/hcrypto/rc2.h: ${UPSTREAM}/hcrypto/rc2.h
133         ${INSTALL_DATA} $? $@
134
135 ${TOP_INCDIR}/hcrypto/rc4.h: ${UPSTREAM}/hcrypto/rc4.h
136         ${INSTALL_DATA} $? $@
137
138 ${TOP_INCDIR}/hcrypto/rsa.h: ${UPSTREAM}/hcrypto/rsa.h
139         ${INSTALL_DATA} $? $@
140
141 ${TOP_INCDIR}/hcrypto/sha.h: ${UPSTREAM}/hcrypto/sha.h
142         ${INSTALL_DATA} $? $@
143
144 ${TOP_INCDIR}/hcrypto/ui.h: ${UPSTREAM}/hcrypto/ui.h
145         ${INSTALL_DATA} $? $@
146
147 ${TOP_LIBDIR}/libafshcrypto.$(SHLIB_SUFFIX): libafshcrypto.la
148         $(LT_INSTALL_DATA) libafshcrypto.la $(TOP_LIBDIR)/libafshcrypto.la
149         # libtool gets confused if we leave these around
150         $(RM) $(TOP_LIBDIR)/libafshcrypto.la
151
152 ${TOP_LIBDIR}/libafshcrypto.a: libafshcrypto.a
153         ${INSTALL_DATA} $? $@
154
155 ${TOP_LIBDIR}/libafshcrypto_lwp.a: libafshcrypto_lwp.a
156         ${INSTALL_DATA} $? $@
157
158 # Pthread Targets
159
160 CFLAGS_test_cipher.lo= -I${UPSTREAM}/roken/
161 CFLAGS_rand-unix.lo=@CFLAGS_NOERROR@
162 CFLAGS_validate.lo=@CFLAGS_NOERROR@
163 CFLAGS_evp.lo=-DHAVE_CONFIG_H
164
165 # Here we have explicit rules for all the libtool objects we might need to
166 # build.  The implicit rules don't work since the sources are in a different
167 # castle.
168 aes.lo: ${UPSTREAM}/hcrypto/aes.c ${HEADERS}
169         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/aes.c
170
171 bn.lo: ${UPSTREAM}/hcrypto/bn.c ${HEADERS}
172         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/bn.c
173
174 camellia.lo: ${UPSTREAM}/hcrypto/camellia.c ${HEADERS}
175         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/camellia.c
176
177 camellia-ntt.lo: ${UPSTREAM}/hcrypto/camellia-ntt.c ${HEADERS}
178         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/camellia-ntt.c
179
180 des.lo: ${UPSTREAM}/hcrypto/des.c ${HEADERS}
181         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/des.c
182
183 evp.lo: ${UPSTREAM}/hcrypto/evp.c ${HEADERS}
184         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/evp.c
185
186 evp-hcrypto.lo: ${UPSTREAM}/hcrypto/evp-hcrypto.c ${HEADERS}
187         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/evp-hcrypto.c
188
189 evp-cc.lo: ${UPSTREAM}/hcrypto/evp-cc.c ${HEADERS}
190         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/evp-cc.c
191
192 hmac.lo: ${UPSTREAM}/hcrypto/hmac.c ${HEADERS}
193         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/hmac.c
194
195 md2.lo: ${UPSTREAM}/hcrypto/md2.c ${HEADERS}
196         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/md2.c
197
198 md4.lo: ${UPSTREAM}/hcrypto/md4.c ${HEADERS}
199         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/md4.c
200
201 md5.lo: ${UPSTREAM}/hcrypto/md5.c ${HEADERS}
202         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/md5.c
203
204 pkcs5.lo: ${UPSTREAM}/hcrypto/pkcs5.c ${HEADERS}
205         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/pkcs5.c
206
207 rand-egd.lo: ${UPSTREAM}/hcrypto/rand-egd.c ${HEADERS}
208         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/rand-egd.c
209
210 rand-fortuna.lo: ${UPSTREAM}/hcrypto/rand-fortuna.c ${HEADERS}
211         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/rand-fortuna.c
212
213 rand-timer.lo: ${UPSTREAM}/hcrypto/rand-timer.c ${HEADERS}
214         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/rand-timer.c
215
216 rand-unix.lo: ${UPSTREAM}/hcrypto/rand-unix.c ${HEADERS}
217         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/rand-unix.c
218
219 rand.lo: ${UPSTREAM}/hcrypto/rand.c ${HEADERS}
220         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/rand.c
221
222 rc2.lo: ${UPSTREAM}/hcrypto/rc2.c ${HEADERS}
223         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/rc2.c
224
225 rc4.lo: ${UPSTREAM}/hcrypto/rc4.c ${HEADERS}
226         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/rc4.c
227
228 rijndael-alg-fst.lo: ${UPSTREAM}/hcrypto/rijndael-alg-fst.c ${HEADERS}
229         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/rijndael-alg-fst.c
230
231 rnd_keys.lo: ${UPSTREAM}/hcrypto/rnd_keys.c ${HEADERS}
232         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/rnd_keys.c
233
234 sha.lo: ${UPSTREAM}/hcrypto/sha.c ${HEADERS}
235         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/sha.c
236
237 sha256.lo: ${UPSTREAM}/hcrypto/sha256.c ${HEADERS}
238         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/sha256.c
239
240 sha512.lo: ${UPSTREAM}/hcrypto/sha512.c ${HEADERS}
241         ${LTLWP_CCRULE} $(UPSTREAM)/hcrypto/sha512.c
242
243 ui.lo: ${UPSTREAM}/hcrypto/ui.c ${HEADERS}
244         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/ui.c
245
246 validate.lo: ${UPSTREAM}/hcrypto/validate.c ${HEADERS}
247         ${LTLWP_CCRULE} ${UPSTREAM}/hcrypto/validate.c
248
249 test_cipher.lo: ${UPSTREAM}/hcrypto/test_cipher.c ${HEADERS}
250         $(LTLWP_CCRULE) $(UPSTREAM)/hcrypto/test_cipher.c