build: remove trailing whitespace from makefiles
[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 # API version. Must be incremented whenever something changes.
8 LIBMAJOR=1
9 LIBMINOR=1
10
11 srcdir=@srcdir@
12 include @TOP_OBJDIR@/src/config/Makefile.config
13 include @TOP_OBJDIR@/src/config/Makefile.shared
14
15
16 HEADERS= ${TOP_INCDIR}/hcrypto/aes.h \
17          ${TOP_INCDIR}/hcrypto/des.h \
18          ${TOP_INCDIR}/hcrypto/engine.h \
19          ${TOP_INCDIR}/hcrypto/evp.h \
20          ${TOP_INCDIR}/hcrypto/evp-hcrypto.h \
21          ${TOP_INCDIR}/hcrypto/evp-cc.h \
22          ${TOP_INCDIR}/hcrypto/hmac.h \
23          ${TOP_INCDIR}/hcrypto/md2.h \
24          ${TOP_INCDIR}/hcrypto/md4.h \
25          ${TOP_INCDIR}/hcrypto/md5.h \
26          ${TOP_INCDIR}/hcrypto/rand.h \
27          ${TOP_INCDIR}/hcrypto/rc2.h \
28          ${TOP_INCDIR}/hcrypto/rc4.h \
29          ${TOP_INCDIR}/hcrypto/sha.h \
30          ${TOP_INCDIR}/hcrypto/ui.h
31
32 UPSTREAM= ${TOP_SRCDIR}/external/heimdal
33
34 MODULE_INCLUDE=-I${srcdir} -I${TOP_INCDIR}/hcrypto -I$(UPSTREAM)/hcrypto
35
36 SHLIBOBJ= libafshcrypto.${SHLIB_SUFFIX}.${LIBMAJOR}.${LIBMINOR}
37
38 all: ${HEADERS} ${TOP_LIBDIR}/${SHLIBOBJ} \
39         ${TOP_LIBDIR}/libafshcrypto.a \
40         ${TOP_LIBDIR}/libafshcrypto_lwp.a
41
42 buildtools: ${HEADERS} ${TOP_LIBDIR}/libafshcrypto.a
43
44 install: libafshcrypto.a ${SHLIBOBJ}
45         ${TOP_OBJDIR}/src/config/shlib-install -d ${DESTDIR}${libdir} \
46                 -l libafshcrypto -M ${LIBMAJOR} -m ${LIBMINOR}
47         ${INSTALL_DATA} libafshcrypto.a ${DESTDIR}${libdir}/libafshcrypto.a
48
49 dest: libafshcrypto.a ${SHLIBOBJ}
50         ${TOP_OBJDIR}/src/config/shlib-install -d ${DEST}/lib \
51                 -l libafshcrypto -M ${LIBMAJOR} -m ${LIBMINOR}
52         ${INSTALL_DATA} libafshcrypto.a ${DEST}/lib/libafshcrypto.a
53
54 clean:
55         $(RM) -f ${OBJECTS} ${SHLIBOBJ} rand-fortuna_lwp.o \
56                 libafshcrypto.a libafshcrypto_lwp.a libafshcrypto.exp \
57                 test_cipher test_cipher.o
58
59 COMMON_OBJS= aes.o camellia.o camellia-ntt.o des.o engine.o evp.o \
60              evp-hcrypto.o evp-cc.o hmac.o md2.o md4.o md5.o pkcs5.o \
61              rand-egd.o rand-timer.o rand-unix.o rand.o rc2.o rc4.o \
62              rijndael-alg-fst.o rnd_keys.o sha.o sha256.o sha512.o ui.o \
63              validate.o
64
65 OBJECTS = $(COMMON_OBJS) rand-fortuna.o
66
67 LWP_OBJS = $(COMMON_OBJS) rand-fortuna_lwp.o
68
69 ${TOP_LIBDIR}/${SHLIBOBJ}: ${SHLIBOBJ}
70         ${TOP_OBJDIR}/src/config/shlib-install -d ${TOP_LIBDIR} \
71                 -l libafshcrypto -M ${LIBMAJOR} -m ${LIBMINOR}
72
73 ${SHLIBOBJ}: ${OBJECTS} libafshcrypto.map
74         ${TOP_OBJDIR}/src/config/shlib-build -d $(srcdir) -l libafshcrypto \
75                 -M ${LIBMAJOR} -m ${LIBMINOR} -- \
76                 ${OBJECTS} $(LDFLAGS_roken) $(LIB_roken) ${MT_LIBS}
77
78 libafshcrypto.a: ${OBJECTS}
79         $(RM) -f $@
80         $(AR) crv $@ ${OBJECTS}
81         $(RANLIB) $@
82
83 libafshcrypto_lwp.a: $(LWP_OBJS)
84         $(RM) -f $@
85         $(AR) crv $@ $(LWP_OBJS)
86         $(RANLIB) $@
87
88 test_cipher: test_cipher.o libafshcrypto.a
89         $(AFS_LDRULE) test_cipher.o libafshcrypto.a $(LIB_roken)
90
91 ${TOP_INCDIR}/hcrypto/aes.h: ${UPSTREAM}/hcrypto/aes.h
92         ${INSTALL_DATA} $? $@
93
94 ${TOP_INCDIR}/hcrypto/bn.h: ${UPSTREAM}/hcrypto/bn.h
95         ${INSTALL_DATA} $? $@
96
97 ${TOP_INCDIR}/hcrypto/des.h: ${UPSTREAM}/hcrypto/des.h
98         ${INSTALL_DATA} $? $@
99
100 ${TOP_INCDIR}/hcrypto/dh.h: ${UPSTREAM}/hcrypto/dh.h
101         ${INSTALL_DATA} $? $@
102
103 ${TOP_INCDIR}/hcrypto/dsa.h: ${UPSTREAM}/hcrypto/dsa.h
104         ${INSTALL_DATA} $? $@
105
106 ${TOP_INCDIR}/hcrypto/engine.h: engine.h
107         ${INSTALL_DATA} $? $@
108
109 ${TOP_INCDIR}/hcrypto/evp.h: ${UPSTREAM}/hcrypto/evp.h
110         ${INSTALL_DATA} $? $@
111
112 ${TOP_INCDIR}/hcrypto/evp-hcrypto.h: ${UPSTREAM}/hcrypto/evp-hcrypto.h
113         ${INSTALL_DATA} $? $@
114
115 ${TOP_INCDIR}/hcrypto/evp-cc.h: ${UPSTREAM}/hcrypto/evp-cc.h
116         ${INSTALL_DATA} $? $@
117
118 ${TOP_INCDIR}/hcrypto/hmac.h: ${UPSTREAM}/hcrypto/hmac.h
119         ${INSTALL_DATA} $? $@
120
121 ${TOP_INCDIR}/hcrypto/md2.h: ${UPSTREAM}/hcrypto/md2.h
122         ${INSTALL_DATA} $? $@
123
124 ${TOP_INCDIR}/hcrypto/md4.h: ${UPSTREAM}/hcrypto/md4.h
125         ${INSTALL_DATA} $? $@
126
127 ${TOP_INCDIR}/hcrypto/md5.h: ${UPSTREAM}/hcrypto/md5.h
128         ${INSTALL_DATA} $? $@
129
130 ${TOP_INCDIR}/hcrypto/pkcs12.h: ${UPSTREAM}/hcrypto/pkcs12.h
131         ${INSTALL_DATA} $? $@
132
133 ${TOP_INCDIR}/hcrypto/rand.h: ${UPSTREAM}/hcrypto/rand.h
134         ${INSTALL_DATA} $? $@
135
136 ${TOP_INCDIR}/hcrypto/rc2.h: ${UPSTREAM}/hcrypto/rc2.h
137         ${INSTALL_DATA} $? $@
138
139 ${TOP_INCDIR}/hcrypto/rc4.h: ${UPSTREAM}/hcrypto/rc4.h
140         ${INSTALL_DATA} $? $@
141
142 ${TOP_INCDIR}/hcrypto/rsa.h: ${UPSTREAM}/hcrypto/rsa.h
143         ${INSTALL_DATA} $? $@
144
145 ${TOP_INCDIR}/hcrypto/sha.h: ${UPSTREAM}/hcrypto/sha.h
146         ${INSTALL_DATA} $? $@
147
148 ${TOP_INCDIR}/hcrypto/ui.h: ${UPSTREAM}/hcrypto/ui.h
149         ${INSTALL_DATA} $? $@
150
151 ${TOP_LIBDIR}/libafshcrypto.a: libafshcrypto.a
152         ${INSTALL_DATA} $? $@
153
154 ${TOP_LIBDIR}/libafshcrypto_lwp.a: libafshcrypto_lwp.a
155         ${INSTALL_DATA} $? $@
156
157 # Pthread Targets
158
159 CFLAGS_test_cipher.o= -I${UPSTREAM}/roken/
160 CFLAGS_rand-unix.o=@CFLAGS_NOERROR@
161 CFLAGS_validate.o=@CFLAGS_NOERROR@
162 CFLAGS_evp.o=-DHAVE_CONFIG_H
163
164 aes.o: ${UPSTREAM}/hcrypto/aes.c ${HEADERS}
165         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/aes.c
166
167 bn.o: ${UPSTREAM}/hcrypto/bn.c ${HEADERS}
168         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/bn.c
169
170 camellia.o: ${UPSTREAM}/hcrypto/camellia.c ${HEADERS}
171         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/camellia.c
172
173 camellia-ntt.o: ${UPSTREAM}/hcrypto/camellia-ntt.c ${HEADERS}
174         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/camellia-ntt.c
175
176 des.o: ${UPSTREAM}/hcrypto/des.c ${HEADERS}
177         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/des.c
178
179 evp.o: ${UPSTREAM}/hcrypto/evp.c ${HEADERS}
180         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/evp.c
181
182 evp-hcrypto.o: ${UPSTREAM}/hcrypto/evp-hcrypto.c ${HEADERS}
183         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/evp-hcrypto.c
184
185 evp-cc.o: ${UPSTREAM}/hcrypto/evp-cc.c ${HEADERS}
186         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/evp-cc.c
187
188 hmac.o: ${UPSTREAM}/hcrypto/hmac.c ${HEADERS}
189         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/hmac.c
190
191 md2.o: ${UPSTREAM}/hcrypto/md2.c ${HEADERS}
192         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/md2.c
193
194 md4.o: ${UPSTREAM}/hcrypto/md4.c ${HEADERS}
195         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/md4.c
196
197 md5.o: ${UPSTREAM}/hcrypto/md5.c ${HEADERS}
198         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/md5.c
199
200 pkcs5.o: ${UPSTREAM}/hcrypto/pkcs5.c ${HEADERS}
201         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/pkcs5.c
202
203 rand-egd.o: ${UPSTREAM}/hcrypto/rand-egd.c ${HEADERS}
204         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/rand-egd.c
205
206 rand-fortuna.o: ${UPSTREAM}/hcrypto/rand-fortuna.c ${HEADERS}
207         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/rand-fortuna.c
208
209 rand-timer.o: ${UPSTREAM}/hcrypto/rand-timer.c ${HEADERS}
210         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/rand-timer.c
211
212 rand-unix.o: ${UPSTREAM}/hcrypto/rand-unix.c ${HEADERS}
213         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/rand-unix.c
214
215 rand.o: ${UPSTREAM}/hcrypto/rand.c ${HEADERS}
216         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/rand.c
217
218 rc2.o: ${UPSTREAM}/hcrypto/rc2.c ${HEADERS}
219         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/rc2.c
220
221 rc4.o: ${UPSTREAM}/hcrypto/rc4.c ${HEADERS}
222         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/rc4.c
223
224 rijndael-alg-fst.o: ${UPSTREAM}/hcrypto/rijndael-alg-fst.c ${HEADERS}
225         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/rijndael-alg-fst.c
226
227 rnd_keys.o: ${UPSTREAM}/hcrypto/rnd_keys.c ${HEADERS}
228         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/rnd_keys.c
229
230 sha.o: ${UPSTREAM}/hcrypto/sha.c ${HEADERS}
231         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/sha.c
232
233 sha256.o: ${UPSTREAM}/hcrypto/sha256.c ${HEADERS}
234         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/sha256.c
235
236 sha512.o: ${UPSTREAM}/hcrypto/sha512.c ${HEADERS}
237         ${AFS_CCRULE} $(UPSTREAM)/hcrypto/sha512.c
238
239 ui.o: ${UPSTREAM}/hcrypto/ui.c ${HEADERS}
240         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/ui.c
241
242 validate.o: ${UPSTREAM}/hcrypto/validate.c ${HEADERS}
243         ${AFS_CCRULE} ${UPSTREAM}/hcrypto/validate.c
244
245 test_cipher.o: ${UPSTREAM}/hcrypto/test_cipher.c ${HEADERS}
246         $(AFS_CCRULE) $(UPSTREAM)/hcrypto/test_cipher.c
247
248 # LWP Targets
249
250 rand-fortuna_lwp.o: ${UPSTREAM}/hcrypto/rand-fortuna.c ${HEADERS}
251         $(LWP_CCRULE) $(UPSTREAM)/hcrypto/rand-fortuna.c
252