4a38c500e8ed61d7c280ceb132e3cbbf5fe3d3b7
[openssl.git] / fips / rsa / Makefile
1 #
2 # OpenSSL/fips/rsa/Makefile
3 #
4
5 DIR=    rsa
6 TOP=    ../..
7 CC=     cc
8 INCLUDES=
9 CFLAG=-g
10 INSTALL_PREFIX=
11 OPENSSLDIR=     /usr/local/ssl
12 INSTALLTOP=/usr/local/ssl
13 MAKEDEPPROG=    makedepend
14 MAKEDEPEND=     $(TOP)/util/domd $(TOP) -MD $(MAKEDEPPROG)
15 MAKEFILE=       Makefile
16 AR=             ar r
17
18 CFLAGS= $(INCLUDES) $(CFLAG)
19
20 GENERAL=Makefile
21 TEST= fips_rsavtest.c fips_rsastest.c fips_rsagtest.c
22 APPS=
23
24 LIB=$(TOP)/libcrypto.a
25 LIBSRC= fips_rsa_selftest.c fips_rsa_x931g.c \
26         fips_rsa_sign.c fips_rsa_lib.c
27 LIBOBJ= fips_rsa_selftest.o fips_rsa_x931g.o \
28         fips_rsa_sign.o fips_rsa_lib.o
29
30 SRC= $(LIBSRC)
31
32 EXHEADER=
33 HEADER= $(EXHEADER)
34
35 ALL=    $(GENERAL) $(SRC) $(HEADER)
36
37 top:
38         (cd $(TOP); $(MAKE) DIRS=fips FDIRS=$(DIR) sub_all)
39
40 all:    lib
41
42 lib:    $(LIBOBJ)
43         @echo $(LIBOBJ) > lib
44
45 files:
46         $(PERL) $(TOP)/util/files.pl Makefile >> $(TOP)/MINFO
47
48 links:
49         @$(PERL) $(TOP)/util/mklink.pl $(TOP)/include/openssl $(EXHEADER)
50         @$(PERL) $(TOP)/util/mklink.pl $(TOP)/test $(TEST)
51         @$(PERL) $(TOP)/util/mklink.pl $(TOP)/apps $(APPS)
52
53 install:
54         @headerlist="$(EXHEADER)"; for i in $$headerlist; \
55         do \
56           (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \
57           chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \
58         done
59
60 tags:
61         ctags $(SRC)
62
63 tests:
64
65 Q=../testvectors/rsa/req
66 A=../testvectors/rsa/rsp
67 Q62=../testvectors/rsa_salt_62/req
68 A62=../testvectors/rsa_salt_62/rsp
69
70 fips_test:
71         -rm -rf $(A) $(A62)
72         mkdir $(A) $(A62)
73         if [ -f $(Q)/SigGen15.req ]; then $(TOP)/util/shlib_wrap.sh $(TOP)/test/fips_rsastest < $(Q)/SigGen15.req  > $(A)/SigGen15.rsp; fi
74         if [ -f $(Q)/SigVer15.req ]; then $(TOP)/util/shlib_wrap.sh $(TOP)/test/fips_rsavtest < $(Q)/SigVer15.req > $(A)/SigVer15.rsp; fi
75         if [ -f $(Q)/SigGenPSS.req ]; then $(TOP)/util/shlib_wrap.sh $(TOP)/test/fips_rsastest -saltlen 0 < $(Q)/SigGenPSS.req > $(A)/SigGenPSS.rsp; fi
76         if [ -f $(Q)/SigVerPSS.req ]; then $(TOP)/util/shlib_wrap.sh $(TOP)/test/fips_rsavtest -saltlen 0 < $(Q)/SigVerPSS.req > $(A)/SigVerPSS.rsp; fi
77         if [ -f $(Q)/SigGenRSA.req ]; then $(TOP)/util/shlib_wrap.sh $(TOP)/test/fips_rsastest -x931 < $(Q)/SigGenRSA.req > $(A)/SigGenRSA.rsp; fi
78         if [ -f $(Q)/SigVerRSA.req ]; then $(TOP)/util/shlib_wrap.sh $(TOP)/test/fips_rsavtest -x931 < $(Q)/SigVerRSA.req > $(A)/SigVerRSA.rsp; fi
79         if [ -f $(Q62)/SigGenPSS.req ]; then $(TOP)/util/shlib_wrap.sh $(TOP)/test/fips_rsastest -saltlen 62 < $(Q62)/SigGenPSS.req >$(A62)/SigGenPSS.rsp; fi
80         if [ -f $(Q62)/SigVerPSS.req ]; then $(TOP)/util/shlib_wrap.sh $(TOP)/test/fips_rsavtest -saltlen 62 <$(Q62)/SigVerPSS.req >$(A62)/SigVerPSS.rsp; fi
81         if [ -f $(Q)/KeyGenRSA.req ]; then $(TOP)/util/shlib_wrap.sh $(TOP)/test/fips_rsagtest < $(Q)/KeyGenRSA.req > $(A)/KeyGenRSA.rsp; fi
82
83 lint:
84         lint -DLINT $(INCLUDES) $(SRC)>fluff
85
86 depend:
87         $(MAKEDEPEND) -- $(CFLAG) $(INCLUDES) $(DEPFLAG) -- $(SRC) $(TEST)
88
89 dclean:
90         $(PERL) -pe 'if (/^# DO NOT DELETE THIS LINE/) {print; exit(0);}' $(MAKEFILE) >Makefile.new
91         mv -f Makefile.new $(MAKEFILE)
92
93 clean:
94         rm -f *.o *.obj lib tags core .pure .nfs* *.old *.bak fluff
95 # DO NOT DELETE THIS LINE -- make depend depends on it.
96
97 fips_rsa_eay.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h
98 fips_rsa_eay.o: ../../include/openssl/bn.h ../../include/openssl/crypto.h
99 fips_rsa_eay.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h
100 fips_rsa_eay.o: ../../include/openssl/fips.h ../../include/openssl/lhash.h
101 fips_rsa_eay.o: ../../include/openssl/opensslconf.h
102 fips_rsa_eay.o: ../../include/openssl/opensslv.h
103 fips_rsa_eay.o: ../../include/openssl/ossl_typ.h ../../include/openssl/rand.h
104 fips_rsa_eay.o: ../../include/openssl/rsa.h ../../include/openssl/safestack.h
105 fips_rsa_eay.o: ../../include/openssl/stack.h ../../include/openssl/symhacks.h
106 fips_rsa_eay.o: fips_rsa_eay.c
107 fips_rsa_gen.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h
108 fips_rsa_gen.o: ../../include/openssl/bn.h ../../include/openssl/crypto.h
109 fips_rsa_gen.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h
110 fips_rsa_gen.o: ../../include/openssl/evp.h ../../include/openssl/fips.h
111 fips_rsa_gen.o: ../../include/openssl/lhash.h ../../include/openssl/obj_mac.h
112 fips_rsa_gen.o: ../../include/openssl/objects.h
113 fips_rsa_gen.o: ../../include/openssl/opensslconf.h
114 fips_rsa_gen.o: ../../include/openssl/opensslv.h
115 fips_rsa_gen.o: ../../include/openssl/ossl_typ.h ../../include/openssl/rsa.h
116 fips_rsa_gen.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h
117 fips_rsa_gen.o: ../../include/openssl/symhacks.h ../fips_locl.h fips_rsa_gen.c
118 fips_rsa_lib.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h
119 fips_rsa_lib.o: ../../include/openssl/bn.h ../../include/openssl/crypto.h
120 fips_rsa_lib.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h
121 fips_rsa_lib.o: ../../include/openssl/evp.h ../../include/openssl/fips.h
122 fips_rsa_lib.o: ../../include/openssl/lhash.h ../../include/openssl/obj_mac.h
123 fips_rsa_lib.o: ../../include/openssl/objects.h
124 fips_rsa_lib.o: ../../include/openssl/opensslconf.h
125 fips_rsa_lib.o: ../../include/openssl/opensslv.h
126 fips_rsa_lib.o: ../../include/openssl/ossl_typ.h ../../include/openssl/rsa.h
127 fips_rsa_lib.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h
128 fips_rsa_lib.o: ../../include/openssl/symhacks.h fips_rsa_lib.c
129 fips_rsa_selftest.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h
130 fips_rsa_selftest.o: ../../include/openssl/bn.h ../../include/openssl/crypto.h
131 fips_rsa_selftest.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h
132 fips_rsa_selftest.o: ../../include/openssl/evp.h ../../include/openssl/fips.h
133 fips_rsa_selftest.o: ../../include/openssl/lhash.h
134 fips_rsa_selftest.o: ../../include/openssl/obj_mac.h
135 fips_rsa_selftest.o: ../../include/openssl/objects.h
136 fips_rsa_selftest.o: ../../include/openssl/opensslconf.h
137 fips_rsa_selftest.o: ../../include/openssl/opensslv.h
138 fips_rsa_selftest.o: ../../include/openssl/ossl_typ.h
139 fips_rsa_selftest.o: ../../include/openssl/rsa.h
140 fips_rsa_selftest.o: ../../include/openssl/safestack.h
141 fips_rsa_selftest.o: ../../include/openssl/stack.h
142 fips_rsa_selftest.o: ../../include/openssl/symhacks.h fips_rsa_selftest.c
143 fips_rsa_sign.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h
144 fips_rsa_sign.o: ../../include/openssl/crypto.h ../../include/openssl/e_os2.h
145 fips_rsa_sign.o: ../../include/openssl/err.h ../../include/openssl/evp.h
146 fips_rsa_sign.o: ../../include/openssl/fips.h ../../include/openssl/lhash.h
147 fips_rsa_sign.o: ../../include/openssl/obj_mac.h
148 fips_rsa_sign.o: ../../include/openssl/objects.h
149 fips_rsa_sign.o: ../../include/openssl/opensslconf.h
150 fips_rsa_sign.o: ../../include/openssl/opensslv.h
151 fips_rsa_sign.o: ../../include/openssl/ossl_typ.h ../../include/openssl/rsa.h
152 fips_rsa_sign.o: ../../include/openssl/safestack.h ../../include/openssl/sha.h
153 fips_rsa_sign.o: ../../include/openssl/stack.h ../../include/openssl/symhacks.h
154 fips_rsa_sign.o: fips_rsa_sign.c
155 fips_rsa_x931g.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h
156 fips_rsa_x931g.o: ../../include/openssl/bn.h ../../include/openssl/crypto.h
157 fips_rsa_x931g.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h
158 fips_rsa_x931g.o: ../../include/openssl/fips.h ../../include/openssl/lhash.h
159 fips_rsa_x931g.o: ../../include/openssl/opensslconf.h
160 fips_rsa_x931g.o: ../../include/openssl/opensslv.h
161 fips_rsa_x931g.o: ../../include/openssl/ossl_typ.h ../../include/openssl/rsa.h
162 fips_rsa_x931g.o: ../../include/openssl/safestack.h
163 fips_rsa_x931g.o: ../../include/openssl/stack.h
164 fips_rsa_x931g.o: ../../include/openssl/symhacks.h fips_rsa_x931g.c
165 fips_rsagtest.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h
166 fips_rsagtest.o: ../../include/openssl/bn.h ../../include/openssl/buffer.h
167 fips_rsagtest.o: ../../include/openssl/conf.h ../../include/openssl/crypto.h
168 fips_rsagtest.o: ../../include/openssl/e_os2.h ../../include/openssl/ec.h
169 fips_rsagtest.o: ../../include/openssl/ecdh.h ../../include/openssl/ecdsa.h
170 fips_rsagtest.o: ../../include/openssl/err.h ../../include/openssl/evp.h
171 fips_rsagtest.o: ../../include/openssl/fips.h ../../include/openssl/hmac.h
172 fips_rsagtest.o: ../../include/openssl/lhash.h ../../include/openssl/obj_mac.h
173 fips_rsagtest.o: ../../include/openssl/objects.h
174 fips_rsagtest.o: ../../include/openssl/opensslconf.h
175 fips_rsagtest.o: ../../include/openssl/opensslv.h
176 fips_rsagtest.o: ../../include/openssl/ossl_typ.h ../../include/openssl/pkcs7.h
177 fips_rsagtest.o: ../../include/openssl/rsa.h ../../include/openssl/safestack.h
178 fips_rsagtest.o: ../../include/openssl/sha.h ../../include/openssl/stack.h
179 fips_rsagtest.o: ../../include/openssl/symhacks.h ../../include/openssl/x509.h
180 fips_rsagtest.o: ../../include/openssl/x509_vfy.h
181 fips_rsagtest.o: ../../include/openssl/x509v3.h ../fips_utl.h fips_rsagtest.c
182 fips_rsastest.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h
183 fips_rsastest.o: ../../include/openssl/bn.h ../../include/openssl/buffer.h
184 fips_rsastest.o: ../../include/openssl/conf.h ../../include/openssl/crypto.h
185 fips_rsastest.o: ../../include/openssl/e_os2.h ../../include/openssl/ec.h
186 fips_rsastest.o: ../../include/openssl/ecdh.h ../../include/openssl/ecdsa.h
187 fips_rsastest.o: ../../include/openssl/err.h ../../include/openssl/evp.h
188 fips_rsastest.o: ../../include/openssl/fips.h ../../include/openssl/hmac.h
189 fips_rsastest.o: ../../include/openssl/lhash.h ../../include/openssl/obj_mac.h
190 fips_rsastest.o: ../../include/openssl/objects.h
191 fips_rsastest.o: ../../include/openssl/opensslconf.h
192 fips_rsastest.o: ../../include/openssl/opensslv.h
193 fips_rsastest.o: ../../include/openssl/ossl_typ.h ../../include/openssl/pkcs7.h
194 fips_rsastest.o: ../../include/openssl/rsa.h ../../include/openssl/safestack.h
195 fips_rsastest.o: ../../include/openssl/sha.h ../../include/openssl/stack.h
196 fips_rsastest.o: ../../include/openssl/symhacks.h ../../include/openssl/x509.h
197 fips_rsastest.o: ../../include/openssl/x509_vfy.h
198 fips_rsastest.o: ../../include/openssl/x509v3.h ../fips_utl.h fips_rsastest.c
199 fips_rsavtest.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h
200 fips_rsavtest.o: ../../include/openssl/bn.h ../../include/openssl/buffer.h
201 fips_rsavtest.o: ../../include/openssl/conf.h ../../include/openssl/crypto.h
202 fips_rsavtest.o: ../../include/openssl/e_os2.h ../../include/openssl/ec.h
203 fips_rsavtest.o: ../../include/openssl/ecdh.h ../../include/openssl/ecdsa.h
204 fips_rsavtest.o: ../../include/openssl/err.h ../../include/openssl/evp.h
205 fips_rsavtest.o: ../../include/openssl/fips.h ../../include/openssl/hmac.h
206 fips_rsavtest.o: ../../include/openssl/lhash.h ../../include/openssl/obj_mac.h
207 fips_rsavtest.o: ../../include/openssl/objects.h
208 fips_rsavtest.o: ../../include/openssl/opensslconf.h
209 fips_rsavtest.o: ../../include/openssl/opensslv.h
210 fips_rsavtest.o: ../../include/openssl/ossl_typ.h ../../include/openssl/pkcs7.h
211 fips_rsavtest.o: ../../include/openssl/rsa.h ../../include/openssl/safestack.h
212 fips_rsavtest.o: ../../include/openssl/sha.h ../../include/openssl/stack.h
213 fips_rsavtest.o: ../../include/openssl/symhacks.h ../../include/openssl/x509.h
214 fips_rsavtest.o: ../../include/openssl/x509_vfy.h
215 fips_rsavtest.o: ../../include/openssl/x509v3.h ../fips_utl.h fips_rsavtest.c