Makefile revision 194206
1142425Snectar#
2160814Ssimon# OpenSSL/crypto/cast/Makefile
3142425Snectar#
4142425Snectar
5142425SnectarDIR=	cast
6142425SnectarTOP=	../..
7142425SnectarCC=	cc
8142425SnectarCPP=	$(CC) -E
9142425SnectarINCLUDES=
10142425SnectarCFLAG=-g
11142425SnectarMAKEFILE=	Makefile
12142425SnectarAR=		ar r
13142425Snectar
14142425SnectarCAST_ENC=c_enc.o
15142425Snectar
16142425SnectarCFLAGS= $(INCLUDES) $(CFLAG)
17142425SnectarASFLAGS= $(INCLUDES) $(ASFLAG)
18160814SsimonAFLAGS= $(ASFLAGS)
19142425Snectar
20142425SnectarGENERAL=Makefile
21142425SnectarTEST=casttest.c
22142425SnectarAPPS=
23142425Snectar
24142425SnectarLIB=$(TOP)/libcrypto.a
25142425SnectarLIBSRC=c_skey.c c_ecb.c c_enc.c c_cfb64.c c_ofb64.c 
26142425SnectarLIBOBJ=c_skey.o c_ecb.o $(CAST_ENC) c_cfb64.o c_ofb64.o
27142425Snectar
28142425SnectarSRC= $(LIBSRC)
29142425Snectar
30142425SnectarEXHEADER= cast.h
31142425SnectarHEADER=	cast_s.h cast_lcl.h $(EXHEADER)
32142425Snectar
33142425SnectarALL=    $(GENERAL) $(SRC) $(HEADER)
34142425Snectar
35142425Snectartop:
36142425Snectar	(cd ../..; $(MAKE) DIRS=crypto SDIRS=$(DIR) sub_all)
37142425Snectar
38142425Snectarall:	lib
39142425Snectar
40142425Snectarlib:	$(LIBOBJ)
41194206Ssimon	$(ARX) $(LIB) $(LIBOBJ)
42142425Snectar	$(RANLIB) $(LIB) || echo Never mind.
43142425Snectar	@touch lib
44142425Snectar
45160814Ssimon# ELF
46160814Ssimoncx86-elf.s: asm/cast-586.pl ../perlasm/x86asm.pl ../perlasm/cbc.pl
47160814Ssimon	(cd asm; $(PERL) cast-586.pl elf $(CLAGS) $(PROCESSOR) > ../$@)
48160814Ssimon# COFF
49160814Ssimoncx86-cof.s: asm/cast-586.pl ../perlasm/x86asm.pl ../perlasm/cbc.pl
50160814Ssimon	(cd asm; $(PERL) cast-586.pl coff $(CLAGS) $(PROCESSOR) > ../$@)
51142425Snectar# a.out
52160814Ssimoncx86-out.s: asm/cast-586.pl ../perlasm/x86asm.pl ../perlasm/cbc.pl
53160814Ssimon	(cd asm; $(PERL) cast-586.pl a.out $(CLAGS) $(PROCESSOR) > ../$@)
54142425Snectar
55142425Snectarfiles:
56142425Snectar	$(PERL) $(TOP)/util/files.pl Makefile >> $(TOP)/MINFO
57142425Snectar
58142425Snectarlinks:
59142425Snectar	@$(PERL) $(TOP)/util/mklink.pl ../../include/openssl $(EXHEADER)
60142425Snectar	@$(PERL) $(TOP)/util/mklink.pl ../../test $(TEST)
61142425Snectar	@$(PERL) $(TOP)/util/mklink.pl ../../apps $(APPS)
62142425Snectar
63142425Snectarinstall:
64160814Ssimon	@[ -n "$(INSTALLTOP)" ] # should be set by top Makefile...
65160814Ssimon	@headerlist="$(EXHEADER)"; for i in $$headerlist ; \
66142425Snectar	do  \
67142425Snectar	(cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \
68142425Snectar	chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \
69142425Snectar	done;
70142425Snectar
71142425Snectartags:
72142425Snectar	ctags $(SRC)
73142425Snectar
74142425Snectartests:
75142425Snectar
76142425Snectarlint:
77142425Snectar	lint -DLINT $(INCLUDES) $(SRC)>fluff
78142425Snectar
79142425Snectardepend:
80160814Ssimon	@[ -n "$(MAKEDEPEND)" ] # should be set by upper Makefile...
81142425Snectar	$(MAKEDEPEND) -- $(CFLAG) $(INCLUDES) $(DEPFLAG) -- $(PROGS) $(LIBSRC)
82142425Snectar
83142425Snectardclean:
84142425Snectar	$(PERL) -pe 'if (/^# DO NOT DELETE THIS LINE/) {print; exit(0);}' $(MAKEFILE) >Makefile.new
85142425Snectar	mv -f Makefile.new $(MAKEFILE)
86142425Snectar
87142425Snectarclean:
88160814Ssimon	rm -f *.s *.o *.obj lib tags core .pure .nfs* *.old *.bak fluff
89142425Snectar
90142425Snectar# DO NOT DELETE THIS LINE -- make depend depends on it.
91142425Snectar
92142425Snectarc_cfb64.o: ../../e_os.h ../../include/openssl/cast.h
93142425Snectarc_cfb64.o: ../../include/openssl/e_os2.h ../../include/openssl/opensslconf.h
94142425Snectarc_cfb64.o: c_cfb64.c cast_lcl.h
95142425Snectarc_ecb.o: ../../e_os.h ../../include/openssl/cast.h
96142425Snectarc_ecb.o: ../../include/openssl/e_os2.h ../../include/openssl/opensslconf.h
97142425Snectarc_ecb.o: ../../include/openssl/opensslv.h c_ecb.c cast_lcl.h
98142425Snectarc_enc.o: ../../e_os.h ../../include/openssl/cast.h
99142425Snectarc_enc.o: ../../include/openssl/e_os2.h ../../include/openssl/opensslconf.h
100142425Snectarc_enc.o: c_enc.c cast_lcl.h
101142425Snectarc_ofb64.o: ../../e_os.h ../../include/openssl/cast.h
102142425Snectarc_ofb64.o: ../../include/openssl/e_os2.h ../../include/openssl/opensslconf.h
103142425Snectarc_ofb64.o: c_ofb64.c cast_lcl.h
104142425Snectarc_skey.o: ../../e_os.h ../../include/openssl/cast.h
105194206Ssimonc_skey.o: ../../include/openssl/crypto.h ../../include/openssl/e_os2.h
106194206Ssimonc_skey.o: ../../include/openssl/fips.h ../../include/openssl/opensslconf.h
107194206Ssimonc_skey.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h
108194206Ssimonc_skey.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h
109194206Ssimonc_skey.o: ../../include/openssl/symhacks.h c_skey.c cast_lcl.h cast_s.h
110